You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Which version of Microsoft.IdentityModel are you using?
Microsoft.IdentityModel.Protocols.OpenIdConnect 7.0.3
Where is the issue?
Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer deserialization error.
Is this a new or an existing app?
The app is in production and I haven't upgraded Microsoft.IdentityModel.Protocols.OpenIdConnect, but started seeing this issue.
Which version of Microsoft.IdentityModel are you using?
Microsoft.IdentityModel.Protocols.OpenIdConnect 7.0.3
Where is the issue?
Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer deserialization error.
Is this a new or an existing app?
The app is in production and I haven't upgraded Microsoft.IdentityModel.Protocols.OpenIdConnect, but started seeing this issue.
Repro
Expected behavior
Returns an OpenIdConnectConfiguration instance.
Actual behavior
System.InvalidOperationException: IDX20803: Unable to obtain configuration from: 'my_discovery_endpoint'. Will retry at '11/15/2023 1:20:12 PM +00:00'. Exception: 'System.Text.Json.JsonException: IDX11022: Expecting json reader to be positioned on 'JsonTokenType.StartArray', reader was positioned at: 'String', Reading: 'Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfiguration.response_modes_supported', Position: '172', CurrentDepth: '2', BytesConsumed: '179'.
at Microsoft.IdentityModel.Tokens.Json.JsonSerializerPrimitives.ReadStrings(Utf8JsonReader& reader, ICollection
1 strings, String propertyName, String className, Boolean read) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer.Read(Utf8JsonReader& reader, OpenIdConnectConfiguration config) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer.Read(String json, OpenIdConnectConfiguration config) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer.Read(String json) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationRetriever.GetAsync(String address, IDocumentRetriever retriever, CancellationToken cancel) at Microsoft.IdentityModel.Protocols.ConfigurationManager
1.GetConfigurationAsync(CancellationToken cancel)'.---> System.Text.Json.JsonException: IDX11022: Expecting json reader to be positioned on 'JsonTokenType.StartArray', reader was positioned at: 'String', Reading: 'Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfiguration.response_modes_supported', Position: '172', CurrentDepth: '2', BytesConsumed: '179'.
at Microsoft.IdentityModel.Tokens.Json.JsonSerializerPrimitives.ReadStrings(Utf8JsonReader& reader, ICollection
1 strings, String propertyName, String className, Boolean read) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer.Read(Utf8JsonReader& reader, OpenIdConnectConfiguration config) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer.Read(String json, OpenIdConnectConfiguration config) at Microsoft.IdentityModel.Protocols.OpenIdConnect.OpenIdConnectConfigurationSerializer.Read(String json) at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.ProcessRequests[TContext](IHttpApplication
1 application)Possible solution
There is an obvious issue with the OpenIdConnectConfigurationSerializer.cs and the way it deserializes case insensitive properties.
The text was updated successfully, but these errors were encountered: