Cybersecurity-Projects/PROJECTS/advanced/haskell-reverse-proxy/src/Aenebris
CarterPerez-dev 15f795f10c fix: extract Aenebris.Net.IP to dedupe SockAddr rendering (Finding 10)
- New module src/Aenebris/Net/IP.hs exposes
  sockAddrToIPBytes :: SockAddr -> ByteString.
  Single canonical implementation for IPv4 dotted-decimal, IPv6
  colon-hex (8 groups), and unix-socket "unix:<path>" rendering.

- Aenebris.RateLimit.clientIPKey reduces to
  `sockAddrToIPBytes . remoteHost`. Removes the local v6Bytes,
  the hostAddressToTuple/hostAddress6ToTuple/printf/showHex/
  intercalate imports, and the duplicated implementation.

- Aenebris.DDoS.ConnLimit drops its private copy of the same
  function. ipBytesFromSockAddr is kept as a thin alias for
  test backward-compatibility (= sockAddrToIPBytes), so existing
  callers and the connLimitSpec test continue to compile without
  rename churn.

- aenebris.cabal: expose Aenebris.Net.IP in the library stanza
  (now 30 modules total).

- test/Spec.hs: new netIpSpec asserts IPv4 dotted decimal,
  loopback, unix-socket prefix, and IPv6 colon-separated rendering
  (8 groups → 7 colons). Wires netIpSpec into main right after
  geoSpec.

362 examples passing, 0 failures, 0 GHC warnings.
2026-04-29 02:19:56 -04:00
..
DDoS fix: extract Aenebris.Net.IP to dedupe SockAddr rendering (Finding 10) 2026-04-29 02:19:56 -04:00
Fingerprint fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
ML fix: close audit-pass-1 remaining MAJOR + quick MINOR (Findings 14, 19, 20, 28, 29) 2026-04-29 02:15:14 -04:00
Middleware fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
Net fix: extract Aenebris.Net.IP to dedupe SockAddr rendering (Finding 10) 2026-04-29 02:19:56 -04:00
WAF fix: close audit-pass-1 remaining MAJOR + quick MINOR (Findings 14, 19, 20, 28, 29) 2026-04-29 02:15:14 -04:00
Backend.hs fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
Config.hs fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
Connection.hs fix: close audit-pass-1 CRITICAL findings (Findings 1-6) 2026-04-29 01:59:36 -04:00
Geo.hs fix: close audit-pass-1 remaining MAJOR + quick MINOR (Findings 14, 19, 20, 28, 29) 2026-04-29 02:15:14 -04:00
HealthCheck.hs fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
Honeypot.hs fix: close audit-pass-1 remaining MAJOR + quick MINOR (Findings 14, 19, 20, 28, 29) 2026-04-29 02:15:14 -04:00
LoadBalancer.hs fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
Proxy.hs fix: close audit-pass-1 MAJOR systemic findings (Findings 7-13) 2026-04-29 02:12:00 -04:00
RateLimit.hs fix: extract Aenebris.Net.IP to dedupe SockAddr rendering (Finding 10) 2026-04-29 02:19:56 -04:00
TLS.hs fix: close audit-pass-1 CRITICAL findings (Findings 1-6) 2026-04-29 01:59:36 -04:00
Tunnel.hs fix: close audit-pass-1 CRITICAL findings (Findings 1-6) 2026-04-29 01:59:36 -04:00