AzureADQuickStarts / AppModelv2-WebApp-OpenIDConnect-DotNet

ASP.NET Web Server - OpenID Connect v2 Endpoint Sample
Apache License 2.0
96 stars 91 forks source link

The nonce cannot be validated issue occurred #37

Open Nandhakumar2187 opened 3 years ago

Nandhakumar2187 commented 3 years ago

Hi, We have received the below error while running this source.

Error: IDX21323: RequireNonce is 'System.Boolean'. OpenIdConnectProtocolValidationContext.Nonce was null, OpenIdConnectProtocol.ValidatedIdToken.Payload.Nonce was not null. The nonce cannot be validated. If you don't need to check the nonce, set OpenIdConnectProtocolValidator.RequireNonce to 'false'. Note if a 'nonce' is found it will be evaluated.

Kindly let us know if anything to be added in startup.cs page.

Thank you in advance.

jmprieur commented 3 years ago

@Nandhakumar2187 did you start the app as http:// wheareas the redirect uri is https:// ?

Nandhakumar2187 commented 3 years ago

@jmprieur Yes, we have start the app as http:// and we have given the Redirect URI as http://localhost:53016/

anishninan1984 commented 1 year ago

@Nandhakumar2187 Do you still have the issue persists or any resolution being done. As I am also experiencing the same issue while using localhost as the PostLogoutRedirectUri