HttpProtect.bannedNetworks() method

The current block list, as a Networks object.

Signature:

bannedNetworks(): Promise<Networks>;

Returns:

Promise<Networks>

Every banned address, each widened to a /32 network.

Remarks

Reads the whole set on every call and builds a fresh Networks, so it costs an SMEMBERS plus parsing — fine for an admin endpoint, not for a hot path.

The /32 suffix is applied to every address regardless of family, which is correct for IPv4 and wrong for IPv6: a /32 IPv6 prefix covers 2^96 addresses, so a single banned IPv6 address makes this object match a vast range around it. HttpProtect.verify() does not use this — it matches exact addresses in Redis — so real blocking is unaffected, but HttpProtect.isBanned() inherits the over-match. Do not use either as an authority for IPv6.

Read this page as plain markdown — no HTML, no navigation. For pasting into an LLM, or for an agent to fetch.