Download the PHP package memcrab/access without Composer
On this page you can find all versions of the php package memcrab/access. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package access
PHP Router as Composer Library
Status
It's lightweight php access rights module.
Features
- Support services, actions and roles that need to be controlled by access rights
- Support access groups that combaine multiple services and actions for access all of them to some role
- All configurations is array based and it may be simple YAML file
- Allows you to check role access to any Service/Action
- Allows to check role access to group of actions
- Allows you to get all groups that available for current role
- Allows to use rights matrix by roles or by services or by access groups it's allows you to check any rights by simple isset() using only keys of array.
- Used High performance yaml parse throw using updated pecl yaml-ext 2.0.0 for php 7.0
- Strict standart coding with full Typing of params and returns (by php 7.1)
- PSR-4 autoloading compliant structure
- Unit-Testing with PHPUnit
- Easy to use to any framework
Install
Dependencies
php extension YAML:
-
for Ubuntu/Debian
- for OS X
Usage
- init Access:
new memCrab\Access()
- load rules:
->loadRules(array $rules)
- $rules - Rules from yaml file for exaple
- run checks:
->checkRights(string $service, string $action, string $userRole)
- $service - name of service (or maybe controller)
- $action - name of action
- $userRole - name of user role
Yaml Config Example
Run Example
MIT Licensed
All versions of access with dependencies
PHP Build Version
Package Version
Requires
php Version
>=7.1
The package memcrab/access contains the following files
Loading the files please wait ....