Skip to content

Implementing static/dynamic OAuth2 scopes

Dmitry Chubar requested to merge 6.0.x into 3133698-support-for-the

• Implementing static scopes via Plugin YAML discovery. • Implementing dynamic scopes via Config entity. • Introduced scope provider service; which is leveraging the adapter design pattern. The service instantiated via a factory; due the fact that the instantiation is dependent on config settings. • Added scope provider setting. • Added dedicated overview pages per scope provider. • Added controller for the static scope view operation. • Moved "Oauth2GenerateKeyForm" and "Oauth2TokenSettingsForm" from Entity namespace/dir, these forms are not related to the Entity. • Moved "AccessTokenAccessControlHandler" and "Oauth2TokenListBuilder" to "src/Entity/Access"; this is a more fitting place for these files/classes. • Removed redundant "_admin_route" and "base_route" option in the routing, because routes that start with "/admin" will by default have the option "_admin_route" set to TRUE and "base_route" is not applicable in the routing.yml. • Moved token entity routes under the "oauth2_token" namespace, we have now multiple entities and they should be structered. • Added custom menu link to show the active scope provider in the menu. • Added dedicated scope permissions. • Added Unit/Kernel tests for the scope: entity, plugin, plugin manager, provider.

Merge request reports

Loading