diff --git a/projects/lib/src/oauth-service.ts b/projects/lib/src/oauth-service.ts index 8aca86c4..b4446b40 100644 --- a/projects/lib/src/oauth-service.ts +++ b/projects/lib/src/oauth-service.ts @@ -1734,6 +1734,7 @@ export class OAuthService extends AuthConfig implements OnDestroy { return Promise.resolve(); } + if(!options.disableOAuth2StateCheck) { const success = this.validateNonce(nonceInState); if (!success) { const event = new OAuthErrorEvent('invalid_nonce_in_state', null); @@ -1741,7 +1742,7 @@ export class OAuthService extends AuthConfig implements OnDestroy { return Promise.reject(event); } } - + this.storeSessionState(sessionState); if (code) {