123456789101112131415161718192021222324252627282930313233343536 |
- <?php
- namespace Shibboleth;
- $dir = dirname(__FILE__);
- include_once($dir . '/../init.php');
- include_once($dir . '/../app/lib/scaffolder/scaffolder.class.php');
- if (!ShibbolethTest::is_enabled())
- {
- echo 'This is not a test server';
- die;
- }
- if (!Shibboleth::session()->is_logged_in())
- {
- echo 'Not authorized';
- die;
- }
- $name = 'user';
- $result = Scaffolder::instance()->scaffold($name);
- file_put_contents("$dir/output/$name.class.php", $result);
- header('content-type: text/plain');
- echo $result;
|