This is a quick guide how to use ACL command line interface. It assumes you understand the idea of tasks (see CLI Task for more information).
To display the list of available actions, just enter from the Vegas-built project root:
php cli/cli.php vegas:security_acl:role
php cli/cli.php vegas:security_acl:role add [options]
[options]
--name -n Name of role
--description -d Description of rolevegas:security_acl:role add -n Manager -d "Manages regular users"
php cli/cli.php vegas:security_acl:role remove [options]
[options]
--name -n Name of rolevegas:security_acl:role remove -n Manager
php cli/cli.php vegas:security_acl:role allow [options]
[options]
--name -n Name of role
--resource -r Resource to allow
--access_list -al List of accesses in resource to allowvegas:security_acl:role allow -n Editor -r mvc:wiki:Frontend-Handbook -al index
php cli/cli.php vegas:security_acl:role deny [options]
[options]
--name -n Name of role
--resource -r Resource to deny
--access_list -al List of accesses in resource to denyvegas:security_acl:role deny -n Editor -r mvc:wiki:Frontend-Handbook -al delete
php cli/cli.php vegas:security_acl:role setup
php cli/cli.php vegas:security_acl:role build@ACL annotations in controllers.app/config/config.php DI configuration using following convention:return [
// ...
'acl' => [
\Vegas\Security\Acl\Resource::WILDCARD => [
'description' => 'All privileges (for super admin)',
'accessList' => [
[
'name' => \Vegas\Security\Acl\Resource::ACCESS_WILDCARD,
'description' => 'All',
'inherit' => ''
]
]
],
// more resources...
],
];