|
ProtoCore v0.0.1
Deterministic, zero-heap network stack for embedded targets
|
Per-peer brute-force lockout state machine (PC_ENABLE_AUTH_LOCKOUT). More...
#include "auth_lockout.h"Go to the source code of this file.
Per-peer brute-force lockout state machine (PC_ENABLE_AUTH_LOCKOUT).
A bounded BSS table of buckets keyed by the source address (a pc_ip, so IPv4 and IPv6 peers are each their own bucket - never a lossy hash that a colliding address could poison). Each bucket holds the consecutive-failure count and, once the threshold is crossed, the start and duration of the current lockout (exponential backoff, capped). Compiled only when PC_ENABLE_AUTH_LOCKOUT is set; the host unit tests enable it.
Definition in file auth_lockout.cpp.