exp:accesscheck
Check what a user may do with a node or object (content/read, edit, ...) and which limitation refuses it.
Script bin/php/accesscheck.php, code in kernel/private/classes/commands/accesscheck.php. Run it from the installation root, as the user the web server runs as:
./console exp:accesscheck --help
./console exp:access:check --help
php bin/php/accesscheck.php --helpHelp text
Access check for a user
Whether a user may read, edit, remove ... a node or an object, decided as the views decide
it, and when not, the policies and the limitation that refused, those of extensions
included. Nobody signs in and nothing is changed.
./console exp:access:check --user=editor --node=2
./console exp:access:check --user=14 --object=57 --function=edit --language=eng-GB
./console exp:access:check --user=anonymous --node=2 --json
Functions:Options
| Option | Value | Help |
|---|---|---|
--user | required | The user: its content object ID or its login; "anonymous" for the anonymous user |
--node | required | The node ID to check |
--object | required | The object ID to check (instead of a node) |
--function | required | The content function (default read) |
--language | required | A language code, for edit and translate |
--json | One JSON object instead of the text |
Read from the option definitions in the code (startup(), getOptions(), options() or ezcConsoleOption). Every script also takes the standard options of the script framework (--help, --siteaccess, --debug, --quiet, --allow-root-user ...).
Related
Generated by ./console exp:help:examples from bin/php/accesscheck.php, kernel/private/classes/commands/accesscheck.php. Do not edit this page: change the source and generate again (how). Free documentation: GFDL 1.3 or later.