Download the PHP package fillup/zfauthsaml without Composer
On this page you can find all versions of the php package fillup/zfauthsaml. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download fillup/zfauthsaml
More information about fillup/zfauthsaml
Files in fillup/zfauthsaml
Package zfauthsaml
Short Description Zend\Authentication SAML adapter. Uses existing simpleSAMLphp install.
License GPL-2.0+
Homepage https://github.com/fillup/zfauthsaml
Informations about the package zfauthsaml
zfauthsaml
Goal
The goal of this project is to provide a Zend\Authentication adapter that wraps simpleSAMLphp to provide SAML authentication. At this point I'm not sure if simpleSAMLphp can be used strictly as a library or if it requires you to use its defined configuration files and such. Initially I'm working on the adapter to use an existing configured instance of simpleSAMLphp and then hope to refactor to wrap the library itself to be fully inclusive and support standard ZF application configuration strategies.
Todo
- [x] Implement support for an existing simpleSAMLphp install and use APIs to check if user is authenticated and persist identity information if so.
- [x] Implement support for BjyAuthorize to grant/deny access based on groups returned by SAML
- [x] Move return url path to config file and enable dynamic return url based on originally requested url
- [x] Refactor user entity to actually be populated based on SAML data
- [x] Implement local account provisioning on successful first login
- [x] Find better way to manage role list/config to prevent error when SAML returns a group/role not already configured. Perhaps support pulling from a RESTful API?
- [ ] Further abstract user entity and mapper classes to support user defined entity models that can be persisted
Needs
If you have expertise with simpleSAMLphp or writing extensions/adapters/customizations for ZfcUser I would love some help, connect with me through github.
Setup
1) Update your composer to require these modules (if not already requiring them):
2) Copy to
3) Change two settings within zfcuser.global.php:
4) Copy to
5) Change four settings in module.bjyauthorize.global.php:
6) Enable modules in :
7) Update your init_autoloader.php to autoload simpleSAMLphp. For my dev area this looks like:
8) Apply schema changes to your user table. This assumes you created the initial user table defined with ZfcUser. Schema file located at
That should be it, users who are not logged in and do not have access to requested resources should be redirected to /login which will redirect them to the IdP you have configured to login. After login they will come back to simplesaml which will them redirect them to /return on your application which will load their identity into persistence and create a local user one does not already exist.