Entropic 2.14.3
Local-first agentic inference engine
Loading...
Searching...
No Matches
entropic::http::AuthThrottle Class Reference

Refuses after repeated authentication failures (decision #84). More...

#include </home/runner/work/entropic/entropic/src/facade/http_listener.h>

Public Types

using Clock = std::chrono::steady_clock
 

Public Member Functions

bool blocked (Clock::time_point now) const
 Whether requests are refused at now.
 
void record_failure (Clock::time_point now)
 Record one failed authentication at now.
 

Detailed Description

Refuses after repeated authentication failures (decision #84).

Five failures inside one minute block every request for thirty seconds. Thread-safe; the clock is passed in so the policy is testable.

@dg_internal

Version
2.14.0

Definition at line 137 of file http_listener.h.

Member Typedef Documentation

◆ Clock

using entropic::http::AuthThrottle::Clock = std::chrono::steady_clock

Definition at line 139 of file http_listener.h.

Member Function Documentation

◆ blocked()

bool entropic::http::AuthThrottle::blocked ( Clock::time_point  now) const

Whether requests are refused at now.

Parameters
nowCurrent time.
Returns
true while a block is in force.
Version
2.14.0
Parameters
nowCurrent time.
Returns
true while a block is in force. @req REQ-BRIDGE-001
Version
2.14.0

Definition at line 197 of file http_listener.cpp.

◆ record_failure()

void entropic::http::AuthThrottle::record_failure ( Clock::time_point  now)

Record one failed authentication at now.

Parameters
nowCurrent time.
Version
2.14.0
Parameters
nowCurrent time. @req REQ-BRIDGE-001
Version
2.14.0

Definition at line 208 of file http_listener.cpp.


The documentation for this class was generated from the following files: