Download the PHP package mnshankar/laravel-shib-auth without Composer

On this page you can find all versions of the php package mnshankar/laravel-shib-auth. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-shib-auth

Shibboleth-Laravel authentication bridge

Shibboleth authentication typically results in the identity provider setting a bunch of server variables after successful authentication. This is a Laravel 5.0+/PHP 5.4+ package helps with converting those server tokens into Laravel User Table fields so that regular Laravel semantics of authentication can be followed.

Note that shib auth must already have occured - usually using directives in the .htaccess file.

The included middleware checks the user table and

  1. If a matching user is NOT found, it creates a new user row
  2. If a user is found in the users table, the corresponding user record is retrieved
  3. The user is then logged in to the application using Auth::login($user)

Installation

require the package via composer

Next, setup the service provider. This allows you to modify the config file (the default tokens are specific to UF implementation of Shibboleth)

In your config/app providers array, add:

You must insure that

  1. The mapped fields exist in your users table.
  2. Shibboleth sets valid values for all tokens specified (else exception is thrown)
  3. "password" field in the users table must be nullable as we will not be using it.

Usage

Edit your http kernel.php file to include the shib middleware from the package like so:

Now, you can use the middleware either from the controller or from your route.

  1. In your controller:

  2. In your route:

    Using Laravel 5.0

    Using Laravel 5.1+

    You can continue using Laravel 5.0 style.. or use chaining:

    You may also use route groups. Please look up Laravel documentation on Middleware to learn more https://laravel.com/docs/5.2/middleware

Configuration Options

You can customize the configuration options by publishing them


All versions of laravel-shib-auth with dependencies

PHP Build Version
Package Version
Requires php Version >=5.4.0
illuminate/support Version >=5.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mnshankar/laravel-shib-auth contains the following files

Loading the files please wait ....