Observation-only nftables table (prerouting -150, counters and a rate-limited log, never drops or modifies), a per-minute counters file, probe sources ingress and ingresscnt, a per-host hourly aggregate in the hub (exact totals, sampled ports/ASNs/countries, banned share by the hub's own ban state, no ban feedback loop), GET /api/v1/ingress, a Defense section, doctor check, docs EN/pt-BR and tests. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
11 lines
306 B
Go
11 lines
306 B
Go
package store
|
|
|
|
// Banned reports whether a jail (fail2ban or Urutau's own) currently bans the
|
|
// address, according to the ban and unban lines this instance has read.
|
|
func (s *Store) Banned(ip string) bool {
|
|
s.mu.RLock()
|
|
defer s.mu.RUnlock()
|
|
r := s.ips[KeyOf(ip)]
|
|
return r != nil && len(r.Jails) > 0
|
|
}
|