Owin OpenId connection with NET Framework - error IDX21323

67 views Asked by At

I have a problemi with my .net Framework 7.4.2 Project. Now i'm using the project using ADFS connection using Owin+Identitymodel Packeges. I added the new autentication method using Owin openid to connect to my IdentityServer project.

i'm using the following setup on Startup class:

app.UseOpenIdConnectAuthentication(new OpenIdConnectAuthenticationOptions
                    {

                        AuthenticationType = "oidc",
                        SignInAsAuthenticationType = "cookies",

                        Authority = "https://test-c.test.com/IdentityServer/",

                        ClientId = "test.app",
                        ClientSecret = "2VzvldfHrQ30ddas7qJUUeXSGt6CBddGTLCQ+djUQUQ=",

                        RedirectUri = "http://localhost/test/",
                        PostLogoutRedirectUri = "http://localhost/test/",

                        ResponseType = "id_token token",
                        Scope = "openid test.api",

                        UseTokenLifetime = false,
                        SaveTokens = true,
                        RedeemCode = true,
                        UsePkce = true
                    });

When i enter to my project for the first time (http://localhost/test/) all is fine because i will send to identity server login. After i enter the credential, the identity server allow me to make access( sure 100%) BUT i recive the following error:

IDX21323: RequireNonce is '[PII is hidden]'. 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.

How is possible? the nonce is mandatory for my identity server and i'm sure that i send the nonce.

Ty

the solution or documentation links

0

There are 0 answers