fix(SEC-38,SEC-39): preserve aggregate and fallback throttles
This commit is contained in:
@@ -138,7 +138,9 @@ would otherwise let any peer throttle a key it does not hold — and it joins th
|
||||
partition only when the presented token is validly shaped
|
||||
(`mxgw_<keyId>_<secret>`, key id at most 64 characters), with at most 32 key-id
|
||||
partitions per address before the overflow collapses onto that address's fallback
|
||||
partition. An over-limit state admits one probe per
|
||||
partition. That peer-layer collapse does not exempt a validly shaped key id from
|
||||
the cross-peer aggregate: its failures still feed and consult the key-id aggregate,
|
||||
whose own cardinality is bounded by the configured LRU cap. An over-limit state admits one probe per
|
||||
`ApiKeyFailureProbeIntervalSeconds` through to the real verifier and refuses
|
||||
everything else with `ResourceExhausted` before the store read, so a legitimate
|
||||
holder presenting the correct secret always reaches the constant-time compare and
|
||||
|
||||
Reference in New Issue
Block a user