dfoxx / laravel-shibboleth

NC State Shibboleth for Laravel
MIT License
2 stars 2 forks source link

installation failed #1

Open ghost opened 7 years ago

ghost commented 7 years ago

During the first step with execute: "composer require dfoxx/laravel-shibboleth", return the following error, is there anything I missed?

Using version ^1.0 for dfoxx/laravel-shibboleth ./composer.json has been updated Loading composer repositories with package information Updating dependencies (including require-dev) Package operations: 1 install, 0 updates, 0 removals

Script php artisan optimize handling the post-update-cmd event returned with error code 1

Installation failed, reverting ./composer.json to its original content.

dfoxx commented 7 years ago

Can you confirm you are using Laravel 5.4? I just tried it myself to be sure and my install didn't break.

ghost commented 7 years ago

Thanks for replying. Quick question: is your plug-in required to be used with NC state? Yes, I fresh installed new project using Laravel 5.4. And the previous error didn't show, but installation still failed. Thank you very much for the help. what I have tried:

  1. Fresh install a project;
  2. Active the default Laravel Authentication by "php artisan make:auth" and "php artisan migrate";
  3. Follow your installing step; ["'auth.shib' => \Dfoxx\Shibboleth\AuthenticateWithShibboleth::class," was added into Kernel.php "$middleware" array, not "$middlewareGroups" or "$routeMiddleware", right?]
  4. Then "php artisan vendor:publish", and "php artisan migrate"; and migrate error:

[Symfony\Component\Debug\Exception\FatalThrowableError]
Class '' not found

Additional: If I didn't do the 2-step to active the default Laravel Authentication, the migrate also have error:

[Symfony\Component\Debug\Exception\FatalErrorException]
Cannot declare class CreateUsersTable, because the name is already in use

dfoxx commented 7 years ago

So this package is unique to the NC State in that server variables are unique to the environment. That's why this is more of a guide as a opposed to something that will work straight out of the box, because the method for verifying the authenticated user will be different for whatever your Shibboleth identity provider has set up. At the very least you will need to change the logic in the ShibbolethGuard.php shibbolethCredentials(). You will also probably need to look at the Authentication documentation for how this is all supposed to work together.