Repository navigation
Custom IDP: OAuth 2.0 Errors Not Propagated to Application #36303
Unanswered
benhansson
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I’ve implemented a custom OpenID Connect Identity Provider (IDP) and integrated it into Keycloak. When executing the authorization flow, my IDP returns detailed error responses as per the OAuth 2.0 Authorization Framework.
However, I’ve observed that Keycloak does not propagate these errors, or even the error codes, to the application as expected. Instead, it seems several required error codes are missing. Upon reviewing the source code, the issue appears to originate from the following section:
keycloak/services/src/main/java/org/keycloak/broker/oidc/AbstractOAuth2IdentityProvider.java
Lines 524 to 535 in 0783e2a
Could you clarify if this is intentional behaviour or a limitation in the current implementation? If it’s the latter, is there a recommended workaround to ensure the error messages or codes from the custom IDP are correctly propagated to the client application?
All reactions