From 31ee4d13b4872cfc090440237da3d0e53abf34be Mon Sep 17 00:00:00 2001 From: Anbiniyar Muniandy Date: Sat, 22 Jul 2017 17:54:13 -0700 Subject: [PATCH] Fix state bug This fixes a bug where the state is url encoded when sent but was not decoded on receipt. Therefore ";" gets encoded and breaks nonce checking logic --- src/oauth-service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/oauth-service.ts b/src/oauth-service.ts index 191de9e8..cb6e5228 100644 --- a/src/oauth-service.ts +++ b/src/oauth-service.ts @@ -269,7 +269,7 @@ export class OAuthService { var accessToken = parts["access_token"]; var idToken = parts["id_token"]; - var state = parts["state"]; + var state = decodeURIComponent(parts["state"]); var oidcSuccess = false; var oauthSuccess = false;