b2c + msaljs acquireTokenSilent does not execute custom policy?

JL 51 Reputation points
2021-09-28T10:26:38.54+00:00

I have a b2c sign in custom policy (which calls a REST API Connector)

In my spa app, I can sign in successfully (using msaljs 2).

But if I then call msalInstance.acquireTokenSilent(), it does not run through the custom policy again (ie, does not call my REST API Connector)

Calling either msalInstance.acquireTokenRedirect or msalInstance.acquireTokenPopup runs through the custom policy as I expected.

I have tried passing in forceRefresh, but no luck

msalInstance.acquireTokenSilent({ scopes, forceRefresh: true })

Is there any way to force acquireTokenSilent to run through the custom policy again, without requiring a popup/redirect?

Thanks

Microsoft Entra External ID
Microsoft Entra External ID
A modern identity solution for securing access to customer, citizen and partner-facing apps and services. It is the converged platform of Azure AD External Identities B2B and B2C. Replaces Azure Active Directory External Identities.
2,652 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,569 questions
0 comments No comments
{count} votes