feat(botfilter): config.go part 3/4

This commit is contained in:
hoelee committed 2026-03-12 10:05:00 +08:00
1 parent f22c5733a5
commit 260512045e
1 file changed
+9
+9
View File
@@ -104,3 +104,12 @@ func compileConfig(input *Config) (*compiledConfig, error) {
return nil, fmt.Errorf("botfilter: maxTrackedIPs and maxScoreEventsPerIP must be greater than zero")
}
whitelist, err := parseCIDRs(cfg.WhitelistCIDRs, "whitelistCIDRs")
if err != nil {
return nil, err
}
trusted, err := parseCIDRs(cfg.TrustedProxyCIDRs, "trustedProxyCIDRs")
if err != nil {
return nil, err
}