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

Make the proof optional and the binding is optional

A sender-bound token is only bound if the proof is required. Mark the proof header optional and a stolen token replays as a plain bearer.

present a stolenbound tokenomit the proofheaderendpoint treatsproof as optionaltoken accepted asa plain bearerATTACKER INPUTIMPACTcheck absent
Attack path · present a stolen bound token → omit the proof header → endpoint treats proof as optional → token accepted as a plain bearer

A sender-bound token is only bound if the proof is required. Mark the proof header optional and a stolen token replays as a plain bearer.

What goes wrong

Steal a sender-bound token and it is worthless, unless the server lets you drop one header. This endpoint does. Sender-constrained tokens (DPoP) solve the bearer-token problem: a stolen token is useless without the matching proof-of-possession key. The binding only holds if the proof is mandatory whenever the token claims to be bound. Make it optional and you have quietly brought bearer semantics back.

The endpoint accepts the token and treats the proof header as nice-to-have, then forwards both downstream. If the downstream does not independently insist on a proof for any token that is sender-bound, an attacker who lifted a bound token just leaves the header off and replays it like an old-fashioned bearer. The stronger scheme was on the token. The check that would have enforced it was optional.

The pattern

Vulnerable
function userInfo(req) {
  const token = req.header("Authorization")   // attacker-supplied
  const proof = req.header("DPoP") || null      // treated as optional
  // no check that a bound token actually carries a proof
  return identity.lookup(token, proof)
}
Hardened
function userInfo(req) {
  const token = req.header("Authorization")
  const proof = req.header("DPoP")
  if (isSenderBound(token) && !proof) return deny("proof required")
  verifyProof(proof, token)                     // bind token to caller
  return identity.lookup(token, proof)
}
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

Token theft happens: a token sitting in a log file, or a token on a phone that has changed hands. The reason to adopt sender-constrained tokens is to make that theft worthless. An optional proof header hands the value right back, and it does so silently, because a downgraded request looks like a perfectly normal one.

Wherever a token can be sender-bound, the proof has to be required for those tokens, at every service that accepts them. Optional binding is the same as no binding to anyone willing to omit a header.

Check your own code