exp:addoauthauthorizepolicy
Available since Exponential 6.0.15 (in development, not in a release yet).
Summary
Grant oauth/authorize to the roles that let users sign in (6.0.15 upgrade; dry run unless --apply)
Usage
./console exp:addoauthauthorizepolicy [options] php bin/php/addoauthauthorizepolicy.php [options]
Help
The output of ./console help exp:addoauthauthorizepolicy (the script run with --help), without the standard options:
Usage: bin/php/addoauthauthorizepolicy.php [OPTION]...
Grant the policy oauth/authorize to every role that lets users sign in (user/login),
with the same siteaccess limitation, so the users who could authorize OAuth clients before 6.0.15
still can. Roles that have the policy already are left alone; the script can run again.
Prints PASS or FAIL at the end. Without --apply nothing is written: the script lists the roles it
would grant the policy to. --dry-run is still accepted and means the same as no flag; --apply
together with --dry-run is a usage error (exit 2).
Example: php bin/php/addoauthauthorizepolicy.php
php bin/php/addoauthauthorizepolicy.php --apply
php bin/php/addoauthauthorizepolicy.php --apply --role=Editor --role=5
Options:
--apply Write the changes (the default is a dry run that lists them and changes nothing)
--dry-run The default, kept for scripts that pass it: list what would be granted, change nothing
--role=VALUE... Only this role (ID or name), may be repeated; a listed role without user/login gets an unlimited policyOptions
| Option | Value | Description |
|---|---|---|
| --apply | - | Write the changes (the default is a dry run that lists them and changes nothing) |
| --dry-run | - | The default, kept for scripts that pass it: list what would be granted, change nothing |
| --role | required | Only this role (ID or name), may be repeated; a listed role without user/login gets an unlimited policy |
Standard options
Every script also takes the standard options of the script framework: --help, --quiet, --siteaccess, --debug, --colors, --no-colors, --logfiles, --no-logfiles, --verbose and --allow-root-user.
Source
bin/php/addoauthauthorizepolicy.php, kernel/private/classes/commands/addoauthauthorizepolicy.php
See also
Generated example: exp:addoauthauthorizepolicy
Added to the reference for Exponential 6.0.15.
Contributors
- Graham Brookins Updated
Comments
Add a comment