-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Closed
Labels
Needs: Author FeedbackThe author of this issue needs to respond in order for us to continue investigating this issue.The author of this issue needs to respond in order for us to continue investigating this issue.Status: No Recent Activityarea-authIncludes: Authn, Authz, OAuth, OIDC, BearerIncludes: Authn, Authz, OAuth, OIDC, Bearer
Description
Is there an existing issue for this?
- I have searched the existing issues
Describe the bug
I have an existing Blazor project which was in .NET 8 RC1. After upgrading to .NET 8 RC2, authentication and authorization using OIDC (Keycloak) isn't working as expected.
For example, on my IClaimsTransformation implementation I could access the realm_access property like this:
var realmAccessValue = principal.FindFirst("realm_access")?.Value;
Also, the exp, email_verified except for a few is missing on the ClaimsPrincipal object.
Expected Behavior
The ClaimsPrincipal object should contain all the token claims.
Steps To Reproduce
- Create a new Blazor Web App project without interactivity
- Add Microsoft.AspNetCore.Authentication.OpenIdConnect 8.0.0-rc.2.23480.2
- Configure to use Keycloak or any other OIDC provider
- Create and register an IClaimsTransformation implementation and register it in DI
- On the TransformAsync method try to access some values which is on the token (jwt.io). For example for Keycloak: var realmAccessValue = principal.FindFirst("realm_access")?.Value;
- The value is null
Exceptions (if any)
No response
.NET Version
8.0.100-rc.2.23502.2
Anything else?
No response
miaooss and boukenka
Metadata
Metadata
Assignees
Labels
Needs: Author FeedbackThe author of this issue needs to respond in order for us to continue investigating this issue.The author of this issue needs to respond in order for us to continue investigating this issue.Status: No Recent Activityarea-authIncludes: Authn, Authz, OAuth, OIDC, BearerIncludes: Authn, Authz, OAuth, OIDC, Bearer