Description of problem: Login via the web ui seems to redirect back to the oauth idp selection. No error is displayed in the ui, no obvious logs associated with that login event show in the oauth pods. First time logins for both OpenShift_SRE IDP and GitHub IDP, when authenticated by the user webhook result in in-cluster User objects being created for that username. The user is not permitted access to whatever resource was being accessed (such as the cluster’s console). Subsequent access requests do not result in additional calls to the webhook (presumably because the User object already exists). Version-Release number of selected component (if applicable): 4.8-rc.1 Actual results: After attempting to login, webconsole redirects back to the idp selection page without an error. Expected results: Users should be able to login via IDP Additional info: Previous working version, 4.8-fc.7
We have not seen this issue when deploying a new cluster at 4.8-rc.1
We found the root cause: This bug happens when a custom service account issuer is configured in conjunction with an external identity provider. In this case oauth-apiserver would also reject bound service account tokens. We are providing a fix shortly. The workaround is to configure a unsupported config override for oauth-apiserver.
current workaround: unsupportedConfigOverrides: oauthAPIServer: apiServerArguments: api-audiences: - https://custom-issuer-url
Tested in sts cluster 4.9.0-0.nightly-2021-06-30-030414 1. check the custom service account issuer existed in cluser $ oc get authentication.config cluster -o json | jq .spec.serviceAccountIssuer "https://custom-issuer-url" 2. configure external identity provider with Google/OpenID/GitLab/GitHub/RequestHeader respectively 3. login via the web UI with different external identity provider and check whether user can login successfully After apply the workaround, user can login successfully via web UI for all above external identity provider
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Moderate: OpenShift Container Platform 4.9.0 bug fix and security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2021:3759