Scope are not supported while getting authCodeUrl with protocol mode OIDC
Rajan
0
Reputation points
Application : Azure AD B2C
Library: MSAL Node
I am migrating from client secret to federated credential with AKS. Therefore, I have to change the default AAD protocol to OIDC.
this.client = new ConfidentialClientApplication({
auth: {
clientId: configuration.clientId,
authority: this.signInSignUpAuthority,
knownAuthorities: [`https://${authorityDomain}`],
protocolMode: `OIDC`,
clientAssertion: `${clientAssertionValue}`
}
});
Unfortunaely, it does not work while getting AuthCodeUrl. I am stuck and did not find what is the problem here.
result = await this.client.getAuthCodeUrl({
authority: authority,
redirectUri: this.configuration.baseRedirectUri + 'auth/' + ActionPathname.REDIRECT,
scopes: this.configuration.scopes,
codeChallenge: challenge,
codeChallengeMethod: 'S256',
state: state ?? undefined
});
Both openid and offline_Access scopes are added to App in App registration.
error: invalid_request
**error_description:**AADB2C90012: The scope 'openid profile offline_access' provided in request is not supported.
state: {"target":"https://localhost:3000/","appStage":0}
Sign in to answer