Code RoomCached token privilege escalation
HardPrep Room Coding #4425

Cached token privilege escalation

Vibe & agenticSecuritySenior–Staff~20 min

This Lambda (JavaScript) authorizer caches the decoded token at module scope to skip re-verification on warm invocations. The AI claimed it's a performance win. A pentester escalates privileges with it. Explain the vulnerability.

Implement
find_identity_bypasses(token_subjects: list[str]) → list[int]
Examples
in[["admin","alice","admin","bob"]]out[1,3]
in[["u1","u1","u1"]]out[]
What a strong answer looks like

Treat the AI’s output as a draft to verify, not an answer to trust. Name the specific flaw and the input that triggers it, say how you’d catch it (tests, edge cases, reading critically), and how you’d re-prompt or decompose to get it right.

0:00 of about 20 min

Vibe & agentic: describe the solution in plain language (or narrate it) and the coach grades your approach.

Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.