AADSTS70021 Azure Origin: Platform & cloud Last updated 12 Oct 2026

AADSTS70021: No matching federated identity record found for presented assertion (GitHub Actions / workload identity)

The OIDC token from GitHub Actions/Kubernetes/another IdP doesn’t match any federated credential on the app — issuer, subject or audience differ.

Exact message you may see No matching federated identity record found for presented assertionfederated identity
Seen on: Azure

Meaning

Federated credentials match exactly on issuer and subject (e.g. repo:org/repo:ref:refs/heads/main or repo:org/repo:environment:prod). Running from another branch, a pull request, or an environment changes the subject.

Common causes

  • Subject doesn’t match (branch vs environment vs pull_request)
  • Wrong issuer URL
  • Audience not api://AzureADTokenExchange
  • Federated credential added to a different app

⚡ Quick fix

  1. Read the assertion’s subject from the error and add a matching federated credential
  2. Use environment-based subjects for deployment jobs
  3. Check the client ID used by azure/login

Detailed fix by platform

Azure CLI

  1. az ad app federated-credential create --id <app-id> --parameters '{"name":"main","issuer":"https://token.actions.githubusercontent.com","subject":"repo:myorg/myrepo:ref:refs/heads/main","audiences":["api://AzureADTokenExchange"]}'

How to diagnose

  1. Subject — Value in the error message
  2. Credentials — az ad app federated-credential list
  3. Client ID — Same app?

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: Platform & cloud. Errors that are often confused with or caused by this one (click to open):

AADSTS500113 — AADSTS500113: No reply address is registered for the application (Azure)AADSTS500113AADSTS50020 — AADSTS50020: User account from identity provider does not exist in tenant and cannot access the application (Azure)AADSTS50020AADSTS50034 — AADSTS50034: The user account does not exist in the directory (Azure)AADSTS50034AADSTS50053 — AADSTS50053: Your account is locked (Smart Lockout) / sign-in blocked due to suspicious activity (Azure)AADSTS50053AADSTS50055 — AADSTS50055: The password is expired (Azure)AADSTS50055AADSTS7000222 — AADSTS7000222: The provided client secret keys for app are expired (Azure)AADSTS7000222another operation is in progress — Error: UPGRADE FAILED: another operation (install/upgrade/rollback) is in progress (Kubernetes)another operation is …Command CodeSign failed — Command CodeSign failed with a nonzero exit code (errSecInternalComponent / resource fork, Finder information not allowed) (iOS)Command CodeSign fail…AADSTS700…

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.