Blog / A01:2021 Broken Access Control
A01:2021 · Broken Access Control

The revocation check that approves every credential

A stubbed status lookup returns an empty list every time. Callers read empty as clean, so a revoked or suspended credential sails straight through authorization.

caller submits acredentialstatus serviceignores the inputreturns an emptyresultcaller readsempty as cleanrevokedcredential…ATTACKER INPUTIMPACTcheck absent
Attack path · caller submits a credential → status service ignores the input → returns an empty result → caller reads empty as clean → revoked credential is accepted

A stubbed status lookup returns an empty list every time. Callers read empty as clean, so a revoked or suspended credential sails straight through authorization.

What goes wrong

The function takes a credential and a set of status purposes, then returns an empty result no matter what you pass. Maybe it was a stub someone meant to finish. The danger lives entirely in how callers read that answer. An empty list of problems looks identical to "checked, found nothing," so a revoked credential and a healthy one produce the same output.

This is fail-open behavior dressed up as a normal return. There's no exception and no null. Nothing trips an error path. The call succeeds, monitoring stays green, and tests that only assert "no error" pass while the control does nothing.

The pattern

Vulnerable
function lookupStatus(credential, purposes):
    // TODO: query the status service
    return []            // empty means no problems found

function authorize(credential):
    problems = lookupStatus(credential, ["revoked", "suspended"])
    if problems.isEmpty():
        return ALLOW
    return DENY
Hardened
function lookupStatus(credential, purposes):
    result = statusService.query(credential, purposes)
    if result == null:
        throw StatusUnavailable()   // missing is not clean
    return result

function authorize(credential):
    status = lookupStatus(credential, ["revoked", "suspended"])
    if status.isRevoked() or status.isSuspended():
        return DENY
    return ALLOW
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

A control that fails open is worse than no control, because everyone downstream assumes it works. Your authorization flow trusts this answer to gate access. If the lookup is unfinished, unreachable, or misconfigured, you want the request to stop, not sail through. Decide what "unknown" means before an incident decides for you.

Check your own code