unable to find the kid in the list of keys to validate the id token

Rahul Sadaphal 40 Reputation points
2023-01-24T07:06:42.7833333+00:00

I am getting id token once i click on the user flow in azure ad b2c.

Now i simply need to validate that id token using the kid from the token header

But I cannot find key ids in discovery/keys url which matches with the kid of token header. I have tried below url to fetch the keys list

https://login.microsoftonline.com/{tenant_id}/discovery/v2.0/keys

https://login.microsoftonline.com/common/discovery/v2.0/keys

I am getting below kid from the token - X5eXk4xyojNFum1kl2Ytv8dlNP4-c57dO6QGTVBwaNk

This key id is not available in the list of keys.

I will really appreciate if someone helps me with this, as I am stuck on such a minor issue.

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,571 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
18,620 questions
{count} votes