laminas-commons / lmc-rbac-mvc
Laminas Framework MVC Module that provides a layer of features of Laminas\Permissions\Rbac
Installs: 22 562
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 3
Forks: 2
Open Issues: 4
Requires
- php: ~7.2
- laminas/laminas-config: ^3.1
- laminas/laminas-dependency-plugin: ^1.0
- laminas/laminas-eventmanager: ^3.0
- laminas/laminas-mvc: ^3.0
- laminas/laminas-servicemanager: ^3.0.3
- zfr/rbac: ~1.2
Requires (Dev)
- doctrine/doctrine-orm-module: 2.1.7
- laminas/laminas-authentication: ~2.2
- laminas/laminas-developer-tools: ~1.1
- laminas/laminas-http: ~2.2
- laminas/laminas-i18n: ~2.7.3
- laminas/laminas-log: ~2.2
- laminas/laminas-serializer: ~2.2
- laminas/laminas-view: ~2.2
- php-coveralls/php-coveralls: ^2.2
- phpunit/phpunit: 8.5.8
- squizlabs/php_codesniffer: 3.5.5
Suggests
- doctrine/doctrine-module: if you want to use Doctrine role provider
- laminas/laminas-developer-tools: if you want to show information about the roles
This package is auto-updated.
Last update: 2020-10-07 12:03:33 UTC
README
Important: This respository is abandoned.
The library was moved to LM-Commons/LmcRbacMvc
LmcRbacMvc
Role-based access control module to provide additional features on top of Zend\Permissions\Rbac
Based on ZF-Commons/zfc-rbac v2.6.x. If you are looking for the Laminas version of zfc-rbac v3, please use Laminas-Commons/LmcRbac.
Important Notes:
This version has breaking changes with respect to ZfcRbac v2. See the Upgrade section for details.
Requirements
- PHP 7.2 or higher
- Zf-fr/Rbac component v1: this is actually a prototype for the ZF3 Rbac component.
- Laminas Components 2.x | 3.x or higher
Optional
- DoctrineModule: if you want to use some built-in role and permission providers.
- Laminas\DeveloperTools: if you want to have useful stats added to the Laminas Developer toolbar.
Upgrade
LmcRbac introduces breaking changes from zfcrbac v2:
- The namespace has been changed from
ZfcRbac
toLmcRbacMvc
. - The key
zfc-rbac
in autoload and module config files has been replaced by thelmc-rbac
key.
You can find an upgrade guide to quickly upgrade your application from major versions of ZfcRbac.
Installation
LmcRbacMvc only officially supports installation through Composer. For Composer documentation, please refer to getcomposer.org.
Install the module:
$ php composer.phar require laminas-commons/lmc-rbac-mvc:^3.0
This will install a Laminas MVC equivalent of zfc-rbac 2.6.3.
Enable the module by adding LmcRbacMvc
key to your application.config.php
or modules.config.php
file. Customize the module by copy-pasting
the lmc_rbac.global.php.dist
file to your config/autoload
folder.
Documentation
The official documentation is available in the /docs folder.
You can also find some Doctrine entities in the /data folder that will help you to more quickly take advantage of LmcRbac.
Support
- File issues at https://github.com/Laminas-Commons/LmcRbacMvc/issues.
- Ask questions in the LaminasCommons gitter chat.