Documentation
¶
Index ¶
Constants ¶
View Source
const ( // BanFilePrefix is the prefix for ban config files BanFilePrefix = "50-ban-" // WhitelistFilePrefix is the prefix for whitelist config files WhitelistFilePrefix = "50-whitelist-" )
Variables ¶
This section is empty.
Functions ¶
func Build ¶
Build loads all geoban country files and returns consolidated SetData This replaces the slow bash implementation with fast Go parsing
Performance: <2s for 2,259 CIDRs (vs 120s timeout in bash)
Features: - Reads from /etc/nftban/geoban.d/50-ban-*.conf files - IPv4/IPv6 automatic separation - CIDR normalization - Comment and empty line filtering - Streaming parsing (memory efficient)
func ListBannedCountries ¶
ListBannedCountries returns list of currently banned countries
func ListWhitelistedCountries ¶
ListWhitelistedCountries returns list of currently whitelisted countries
Types ¶
Click to show internal directories.
Click to hide internal directories.