AzureAD Login: IDX21323: RequireNonce is ‘System.Boolean’.

We upgraded our puppeteer to v97 and had a challenge with one application , the application show this error when i use the latest version.

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.

It turned out Google chrome has a new flag to manage the cookies. it’s the “samesite” flag. I finaly fix by changing our chrome launch parameter, see the change i bold below:

const browser = await puppeteer.launch({headless:false,ignoreHTTPSErrors: true,ignoreDefaultArgs: [“–disable-extensions”,”–enable-automation”],
args:[‘–no-sandbox’,’load-extension=/config/chrome-ntlm-ext/’,
‘–disable-extensions-except=/config/chrome-ntlm-ext/’,
‘–disable-features=SameSiteByDefaultCookies’,
‘–disable-setuid-sandbox’,’–disable-dev-shm-usage’,’–window-size=1920,1080′]});

Leave a Reply

Your email address will not be published. Required fields are marked *