Download the PHP package lucidprogrammer/yii2-simplesamlphp without Composer

On this page you can find all versions of the php package lucidprogrammer/yii2-simplesamlphp. 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 yii2-simplesamlphp

yii2-simplesamlphp

SAML Service Provider(SP) for Yii2 using simplesamlphp (yii2 extension). This is useful when you want to act as a Service Provider(SP), where a partner company is acting as a SAML Identity Provider (IDP). User data and their credentials are with the IDP and you are using SAML based login and use those users information in your yii2 application.

This is a very basic implementation where we are not persisting user data coming from the IDP at the Service Provider side for reporting on usage etc. However, those are fairly straightforward additions one can do.

Installation

This is available to be installed via composer. In your yii2 application folder, run the following command.

This will install the package as a yii2 extension and update the extensions and installs the simplesamlphp project too in the vendor folder.

Configuration

Step 1 - Configuring an alias for /saml in your web server.

In a standard web server configuration like Apache, the DocumentRoot will be pointing to the yii2 application's web folder. Create an alias for /saml pointing to pathto_my-yii2-app/vendor/simplesamlphp/simplesamlphp/www.

In the case of Apache, you may do something like (replace pathto_my-yii2-app with your real path.)

To explain it visually, following could help.

Step 2 - Configure yii2 configuration.

Yii configuration straightforward, just add the following in your config/web.php

ADFS example,

Note on enabling authentication for a route using yii2

Let's say you have a rule like the following in your yii2 setting,

After the component is installed, the moment you hit the site/about page, it should redirect you to the configured saml idp login page.

So, if you want to do SAML provided attributes and want to implement a fine grained access control, yii2 makes it easy.

Note on yii2 login link.

If your application has links to login, for example, 'site/login', you need to change to saml/login.

However, it is best if you use Yii::$app->user->loginUrl[0], so it will take whatever is the correct loginUrl, so it will work with or without this plugin.

Sample app

https://github.com/lucidprogrammer/yii2-adfs-saml20-sp

Changelog

02 March 2018 http://www.yiiframework.com/doc-2.0/yii-base-object.html The class name Object is invalid since PHP 7.2, use [[BaseObject]] instead. [handle backward compatibility to yii base Object] Added SamlSettings options for easy configuration. Tested with ADFS 3.0, Windows 2012 R2 & simplesamlphp (IDP)


All versions of yii2-simplesamlphp with dependencies

PHP Build Version
Package Version
Requires yiisoft/yii2 Version 2.*.*
simplesamlphp/simplesamlphp Version >=1.14
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 lucidprogrammer/yii2-simplesamlphp contains the following files

Loading the files please wait ....