Prefer OpenID for Swagger login when available - #1855
Merged
Conversation
Signed-off-by: Charles Graham <charles.r.graham@usace.army.mil>
MikeNeilson
approved these changes
Jul 30, 2026
Collaborator
Author
|
Test errors appear db related and not to this PR |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/CWMSLoginavailability probe, which could mistake an unrelated successful HTML response for a working CWMS AAA login endpoint.This is a UI hotfix for CWBI/AWS deployments. The dev deployment currently advertises
CwmsAAACacAutheven though it is not running with T7/CWMS AAA.Its
/CWMSLoginpath returns the generic water.dev landing page with HTTP 200, causing the UI to incorrectly select CWMS AAA instead of the valid OpenID configuration.The backend should still be corrected so CWBI/AWS deployments do not advertise CWMS AAA when it is unavailable.
When I looked back, it appeared that
cwms.dataapi.access.providersstopped controlling active authentication providers after authentication was refactored in #1073.Authenticatornow loads every service-providedIdentityProviderwhosegetScheme()returns a value. BecauseCwmsAaaIdentityProvider.getScheme()always returns a scheme,CwmsAAACacAuthis included in the generated OpenAPI document even when the configured provider list isKeyAccessManager,OpenID.A backend fix could fix provider filtering in
Authenticator, this keeps the existing provider name mappings:Related Issue
Validation
npx.cmd eslint src/pages/swagger-ui/index.jsx --ext js,jsx --report- unused-disable-directives --max-warnings 0npm.cmd run build/CWMSLoginreturns the generic water.dev HTML page rather than a CWMS AAA login flow.Checklist