title: Adal to Msal conversion -> JWT token validation
body: <p>I have registered <code>xyz.com</code> domain in Azure Active Directory. Then I registered a React single page app in Azure AD App registrations.</p>
  <p>I am using <code>domain_name/AllowAnonymous</code> (<a href="http://example.com/user_impersonation" rel="nofollow noreferrer">http://example.com/user_impersonation</a>) scope in react app to generate a token using msal-react.</p>
  <p>The generated token from react app contains <code>domain_name/AllowAnonymous</code> (<a href="http://example.com/user_impersonation" rel="nofollow noreferrer">http://example.com/user_impersonation</a>) as audience in JWT token claims.</p>
  <p>In the backend, I am using client-id (api://&lt;client-id/Allow.AllUsers&gt;) as audience in JWT token validator to validate token.</p>
  <p>But token has <code>domain_name/AllowAnonymous</code> (<a href="http://example.com/user_impersonation" rel="nofollow noreferrer">http://example.com/user_impersonation</a>) as audience, due to which the token validation fails.</p>
  <p>How can I get the <code>domain_name</code> by client-id in backend C# code to validate token by <code>domain_name</code>?</p>
  <p>Is it secure to set client_id as scope in front-end application for generating JWT token?</p>