RequireNonce is true (default) but validationContext.Nonce is null
Asked Answered
S

2

14

I have an app running in azure using Azure active directory. Some of the users have just reported getting this error trying to access the app. I can access it ok, so can many other users, its only certain users that are having the issue, heres the error message

IDX10311: RequireNonce is true (default) but validationContext.Nonce is null. A Nonce cannot be validated. If you dont need to check the nonce, set OpenIdConnectProtocolValidator.RequireNonce to false

Ive googled it but I cant find a solution, has anyone else experienced this problem ? How Can I fix it ?

Slagle answered 8/9, 2017 at 14:16 Comment(3)
Possible Duplicate - #39413070Ottillia
possible dupliacet what ?Slagle
Link is given in the commentOttillia
B
3

I had the same problem but switching back the Microsoft.Owin.Security.OpenIdConnect to version 3.0.1 solved the issue

OWIN OpenIdConnect Middleware IDX10311 nonce cannot be validated

Bearwood answered 22/2, 2018 at 12:35 Comment(1)
Have you tried to upgrade your OpenIdConnect library again to see if the problem persists? We are running 3.1.0 and it generally works fine. I've seen a couple reports of the IDX13011 error, but I think they are related to users coming from IE browsers.Villus
R
0

Error: IDX21323: RequireNonce is '[PII is hidden. For more details, see https://aka.ms/IdentityModel/PII.]'. 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.

Resolution: i recreate visual studio virtual directory. i notice while i rebuild the solution there was access denied for the virtual directory. i create new virtual directory by using the project property and the error is gone.

Rectify answered 31/10, 2022 at 14:41 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.