Blog / A07:2021 Identification and Authentication Failures
A07:2021 · Identification and Authentication Failures

Passing auth is not the same as authorizing this

The biometric result comes back successful, but the handle handed to the operation was created after the fact, not returned by the prompt. Success without authorization.

promptauthenticates…returned handleis nullnew handlecreated post-authoperation runsunauthorized…ATTACKER INPUTIMPACTcheck absent
Attack path · prompt authenticates the user → returned handle is null → new handle created post-auth → operation runs unauthorized by the key

The biometric result comes back successful, but the handle handed to the operation was created after the fact, not returned by the prompt. Success without authorization.

What goes wrong

There is a subtle difference between "the user authenticated" and "the user authorized this operation." A bound cryptographic handle is what carries the second meaning. It ties this specific success to this specific key use. Swap it out and you keep the reassuring success signal while losing what it was supposed to guarantee.

When the returned handle is null, this callback builds a replacement after authentication and passes it to the keyed operation. The replacement was never presented to the prompt, so the key it wraps was never gated by the user's biometric. You end up with a genuine authentication event attached to an operation it never covered. From the outside it looks airtight, which is what makes it easy to miss in review.

The pattern

Vulnerable
function onAuthenticated(result) {
  const handle = result.handle != null
    ? result.handle
    : createCryptoHandle()          // built after auth, unbound
  doKeyedOperation(handle)
}
Hardened
function onAuthenticated(result) {
  // use nothing the prompt did not hand back
  if (result.handle == null)
    return fail("prompt returned no bound handle")
  doKeyedOperation(result.handle)
}
How the pipeline adjudicated itHELD
ABCDEFGH

Grounding and reachability were confirmed. The exploit-path gate would not conclude without the calling code, so the finding was held and an evidence request was raised instead of being reported as fact.

Ed25519 · per-tenant signing key · gate ledger A–H · verify offline against the published payload hash

Why it matters to you

Compliance reviews and threat models both hinge on one claim: this sensitive operation required a fresh user authentication. If the operation can run on a handle the authentication never covered, that claim is false, and false in a way logs and metrics will not show you. Everything reports success.

Make the bound handle non-negotiable. If the platform did not return one, the user did not authorize the operation, and the only correct response is to stop.

Check your own code