cache-key-discriminator-audit
Installation
SKILL.md
cache-key-discriminator-audit
The defect this finds
A cache key is a function of an operation plus a set of discriminators: the request dimensions the response body actually varies on. If the response varies on something the key does not carry, two different requests hash to the same slot and the second requester is served the first requester's response.
The worst version of this is not slow, and it is not stale. It is a
data-exposure defect: one user's data served to another user. A
missing tenant_id in a multi-tenant cache is a confidentiality bug
with the same blast radius as a missing authorization check, because
the cache is doing the serving and the authorization code never runs
on the second request. Triage it as a security defect, not as a
performance or freshness issue.