Resilient identity in .NET — Entra is not your single point of failure; Entra plus an empty cache is
The Mesh Series · Article 46 · Part I
Microsoft Entra ID.NET & C#Third-party riskDORAmTLSOn-behalf-of flowSPIFFE

It is 09:12 on a Monday and sign-ins are slow. Not down — slow, then failing for some users, then fine, then failing again. Nothing was deployed. The status page says "investigating". In the incident channel somebody types the sentence you have been waiting two years to read: so we just moved the single point of failure, didn't we.
It is a fair challenge, and this series owes it an answer. Forty-five articles have put Entra at the front of every user request. If the answer to "what happens when it blips" is "we wait", the architecture has a hole in it.
One idea: concentrated is not the same as fragile
The old estate had identity smeared across every service — an LDAP bind here, a service account there. That failed too, but it failed unknowably: nobody could say which services would survive a directory outage, because each had its own private relationship with the directory. Moving to Entra concentrates that dependency at one boundary. Concentration is not the problem. An unengineered concentration is.
So ask the precise question. When the identity provider is unreachable for twenty minutes, what actually stops working? The answer is narrower than the incident channel thinks, because three separate mechanisms are in play and they fail independently.
The user plane has a cache. A user who signed in at 08:30 holds a token. Your API validates it with signing keys it already fetched; nothing calls Entra per request. The service that needs a new token — an On-Behalf-Of exchange for the next hop (Article 17) — goes to MSAL's token cache first and only then to the network. If that cache is warm, the blip is invisible. If it is empty — a fresh pod, an in-memory cache that died with the last rollout — every request becomes a call to an identity provider that is not answering.
Microsoft runs a second path. The backup authentication service re-issues tokens for sessions that already exist when the primary service cannot, and Conditional Access resilience defaults let those sessions continue when a policy cannot be evaluated in real time. Note the word existing. It keeps Monday's 08:30 users working. It does nothing for the user who opens a laptop at 09:15.
The workload plane never asked Entra in the first place. The SVIDs behind your mTLS are minted by istiod, not by Entra (Article 14). Service-to-service identity, STRICT mode, every AuthorizationPolicy keyed on a SPIFFE principal — all of it carries on. The two planes Article 10 told you to compose rather than merge now pay for that separation: one can blip without the other noticing.
Put together, the blast radius of a user-IdP blip is new sign-ins and cold-cache token exchanges. Everything else is already holding what it needs.

Why it matters: the regulator has already asked this question
DORA does not let you answer "the provider was down". Article 6 of Regulation (EU) 2022/2554 puts the ICT risk management framework — and its resilience — on you. Article 11 asks for response and recovery plans that have actually been tested. And Articles 28 to 30 make your identity provider what it obviously is: an ICT third-party service supporting a critical function, which means concentration risk you assess and an entry in the Register of Information (Article 36 of this series). NIS2 says the same in one line, Article 21(2)(c): business continuity and crisis management.
The regional readings are blunter. An RBI inspection team hears "we moved authentication to the cloud" and asks whether you moved the single point of failure or removed it. SAMA's maturity model grades continuous operation, and a morning of failed logins is a gap in exactly that. Neither accepts a status page as a control.
The useful reframe: nobody is asking you to make Entra more available than Microsoft does. They are asking what your services do in the window when it is not — and whether you decided that on purpose.
How it comes together: decide the degraded mode before the outage does
Three decisions, in the order they bite.
Make the cache survive the pod. AddInMemoryTokenCaches() is the default every sample uses and it is right for one long-lived process. On a cluster it is a cache with the lifetime of a pod: every rollout, every node drain, every scale-out starts cold. AddDistributedTokenCaches() puts an L2 store — Redis, usually — behind an L1 memory cache, so a new pod inherits the fleet's tokens. Then engineer the obvious objection: a Redis blip must not become your authentication outage. The adapter already treats an L2 failure as non-fatal and keeps serving from L1; OnL2CacheFailure is where you reconnect and say whether to retry. Encrypt the L2 entries. They are bearer tokens at rest.
Stop hammering a service that is struggling. A fleet that retries in tight loops against a degraded identity provider turns a blip into throttling — 429s that outlast the incident. One credential object per process, reused, so its cache and its backoff are shared. Proactive refresh — acquiring the next token while the current one still has life — rather than refresh at expiry, so there is always headroom when the provider has a bad quarter of an hour.
Write the degraded path as code, not as hope. When a token exchange fails because the provider is unavailable — not because the user is unauthorised; those are different exceptions and conflating them is how you end up fail-open — the service has to do something. Decide it per verb. A read can be served from a short-lived cache of what this caller was already entitled to see, marked as stale. A write fails closed: 503 with Retry-After, never an optimistic "we'll check later". A payment authorised against an identity you could not verify is not resilience; it is a finding. And every request that took the degraded branch says so in the log — auth.mode=degraded-cache — because the incident review, and the DORA timeline that may follow it (Article 38), will ask exactly which requests were served on cached trust.
Continuous access evaluation changes the arithmetic in your favour, with one condition. CAE-capable clients and APIs get long-lived tokens because revocation is pushed rather than polled, so a held token survives a much longer outage. That is only safe because it is revocable — which means the long lifetime is a property you get by enabling CAE end to end, not one you award yourself by raising a token lifetime policy.
Show the config: the cache, the credential, the branch
The cache that outlives the pod.

The workload credential: one instance, patient retries.

The degraded branch: reads from cache, writes refused, both logged.

Security · Audit · Integration
Security: the degraded path never widens access — a read is served only from what this caller was already entitled to, a write is refused, and "identity provider unavailable" is caught as a different exception from "caller unauthorised", so an outage cannot become fail-open.
Audit: every request served on cached trust carries auth.mode=degraded-cache with the caller's object id, so the incident timeline can state exactly which requests ran in degraded mode — the record DORA Art. 11 recovery testing and an Art. 19 report both need.
Integration: the user plane degrades at the token cache; the workload plane (istiod SVIDs, mTLS, SPIFFE-keyed policy) does not degrade at all; Entra sits in the Register of Information as a critical ICT third party with this document as its exit-and-outage plan.
Alternatives, and when you'd pick them
A second identity provider on standby. The instinct of every continuity committee. In practice two IdPs means two sets of app registrations, two claim shapes, two Conditional Access postures and a failover nobody has rehearsed. Pick it only if a regulator names it or the concentration assessment under DORA Article 29 genuinely cannot be closed otherwise — and budget for testing the switch, because an untested standby is a second single point of failure with a cost centre.
Longer token lifetimes. Cheap, effective, and a direct trade against revocation. Without CAE, an eight-hour token is eight hours in which a disabled account still works. Reach for CAE first; raise lifetimes only on low-risk read paths, and write down that you did.
Fail open "just for the outage". The option the business will ask for at 09:40. Decline it for anything that moves money or changes state. If a specific read-only journey must stay up, that is what the entitled-read cache is for — a decision made in design, logged, bounded — not a feature flag flipped in an incident.
Do nothing; accept the risk. Legitimate for an internal tool with no critical-function label. It needs to be an accepted risk with a name against it, not an omission.
From simple to standard, and what's next
The simple version is the default sample: an in-memory cache and a hope. The standard version is a distributed token cache that survives the pod and a Redis blip, one reused credential with backoff and proactive refresh, CAE where it is available, and a degraded path written per verb — reads from an entitled cache, writes refused with Retry-After, every such request logged as degraded. The workload plane needs nothing, because it never depended on the user's identity provider. That is the answer to the incident channel: you did not move the single point of failure. You put it somewhere you could engineer around, and then you did.
All of which is a set of claims about behaviour under failure, and a claim about failure that has never been exercised is a comment. Next, Article 47 closes Part I: testing a meshed .NET service — you can't audit what you never tested.
The token you already hold is the one that keeps you trading.
Next in the series: Art. 47, testing a meshed .NET service (Part I closer). Earlier: Art. 45 (continuous evidence), Art. 38 (the incident clocks), Art. 36 (the Register of Information), Art. 17 (On-Behalf-Of), Art. 15 (workload identity federation), Art. 14 (mTLS and SPIFFE), Art. 10 (two planes, composed not merged).
Key skills & topics in this article
Microsoft Entra ID.NET & C#Third-party riskDORAmTLSOn-behalf-of flowSPIFFE