Prevent misconfigurations when admin updates the Web IDE OAuth application
MR: Prevent admin Web IDE OAuth app misconfigurations (!157093 - merged)
Description
With Add web_ide_oauth feature flag (!138015 - merged), we introduce the web_ide_oauth
feature flag and the happy path setup. There are some possible edge cases that will break OAuth functioning correctly with the Web IDE. Those that are significant to this issue:
- If the
application_settings.oauth_application
exists but the scopes aren't sufficient. - If the
application_settings.oauth_application
exists butredirect_uri
does not include the expected URI.
which occurs when the admin edits the OAuth application to settings that fail to adhere to what the Web IDE expects.
Acceptance Criteria
To mitigate this, display an alert within the edit Web IDE OAuth application admin page to warn admins that changes to the config can affect the Web IDE and an action button to restore application to default settings.
Technical Requirements
-
Display alert in edit admin web IDE OAuth application page with action to restore to default
Design Requirements
- Add alert with
info
variant within the edit admin web IDE OAuth page with the following copy:-
Alert message:
Changes to this application configuration can affect the Web IDE's functionality. Ensure that the configuration satisfies these conditions: - The **api** scope is checked. - The redirect URIs includes the `/-/ide/oauth_redirect/` path, for example: `https://${host_name}/-/ide/oauth_redirect/`. - **Trusted** is checked - **Confidential** is unchecked
-
CTA:
Restore to default
-
- Clicking restore default will trigger a confirmation modal. When admin accepts, configuration is reset to the original.
Edited by Cindy Halim