MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / failed_login_spike

Method failed_login_spike

nodedb/src/control/security/observability.rs:137–140  ·  view source on GitHub ↗

Check if failed login rate exceeds threshold (anomaly alert).

(&self, threshold: u64)

Source from the content-addressed store, hash-verified

135
136 /// Check if failed login rate exceeds threshold (anomaly alert).
137 pub fn failed_login_spike(&self, threshold: u64) -> bool {
138 self.rotate_window_if_needed();
139 self.failed_login_window.load(Ordering::Relaxed) > threshold
140 }
141
142 /// Rotate the 1-minute anomaly detection window if expired.
143 fn rotate_window_if_needed(&self) {

Callers

nothing calls this directly

Calls 2

loadMethod · 0.45

Tested by

no test coverage detected