david-garcia-garcia/traefik-geoblock
Über uns
Traefik Geoblock Plugin
Systeme und InfrastrukturGemessener Sternzuwachs
- in 24h
- 0
- in 7 days
- -1
- in 15 days
- -1
- in 1 month
- Verlauf wird gesammelt
Nettoänderungen in überlappenden Zeiträumen, keine Tagessummen. Fehlende Messwerte bleiben leer. Sterne zeigen Interesse, nicht Qualität.
README.md
Original🌍 Traefik Geoblock and Geoenrich
A Traefik middleware that looks up the client IP in a local GeoIP database (IP2Location, IPinfo, or MaxMind) and writes country, city, ASN, and related fields onto the request. Traefik access logs and your backends become geo-aware — no per-request GeoIP API. The same lookup can allow or block by country or CIDR when you want it to.
[!TIP]
Traefik Security
The basic middlewares you need to secure your Traefik ingress:
🌍 Geoblock: david-garcia-garcia/traefik-geoblock — Geo-enrich requests for logs and backends; optionally allow or block by country 🛡️ CrowdSec: david-garcia-garcia/crowdsec-bouncer-traefik-plugin — Real-time threat intelligence and automated blocking 🔒 ModSecurity CRS: david-garcia-garcia/traefik-modsecurity — Web Application Firewall with OWASP Core Rule Set 🚦 Ratelimit: Traefik Rate Limit — Control request rates and prevent abuse
[!WARNING]
Do not run Traefik middlewares as Yaegi plugins in production.
Traefik's plugin system interprets plugins at request time. For production traffic, compile the middleware into the Traefik binary instead — see traefik-with-plugins. Discussion: Traefik #12213.
Geo enrichment
Every request that reaches the plugin gets a local GeoIP lookup. The result is written onto the request (requestHeaderEnrich), not the HTTP response:
- Traefik access logs can
keepthose headers so every line is geo-aware — dashboards, SIEM, compliance. - Applications behind Traefik see the same headers (
X-Geo-Country, city, ASN, …) and can branch on them without calling a GeoIP service. - Headers are not copied onto the response, so browsers and other clients do not see them.
That is the feature most operators want. Blocking is optional.
Dashboards from access logs
Keep the enrich headers in Traefik JSON access logs and any log pipeline can chart traffic by country, city, ASN, ISP, and allow/block reason. Here is that data in New Relic:




accessLog:
filePath: "/var/log/traefik/access.log"
format: json
fields:
headers:
names:
X-Geo-Country: keep
X-Geo-Country-Name: keep
X-Geo-City: keep
X-Geo-Region: keep
X-Geo-Asn: keep
X-Geo-Isp: keep
X-Geoblock-Decision: keep
The backend already received the same request headers. Clients do not.
Decision reasons (logStatusDetailHeader)
Format {action}:{reason}. These are the values on X-Geoblock-Decision (or whatever name you set) and in the dashboard donut. The header is written only in block / enrichandblock, and only when logStatusDetailHeader is set.
Bypass (skip blocking after enrichment):
| Value | Description | Example |
|---|---|---|
pass:ignore_verb |
HTTP method is in ignoreVerbs |
OPTIONS CORS preflight |
pass:not_included_regex |
includedPathsRegex is set and the request did not match |
/docs when include is /secure/.* |
pass:excluded_regex |
Request matched excludedPathsRegex |
/health |
pass:bypass_header |
Request matched bypassHeaders |
Internal service with a secret header |
Allowed by geo rules:
| Value | Description | Example |
|---|---|---|
pass:allow_private |
Private/internal IP and allowPrivate is true |
192.168.1.100 |
pass:allowed_ip_block |
CIDR in allowedIPBlocks or allowedIPBlocksDir |
Trusted partner 203.0.113.50 |
pass:allowed_country |
Country is in allowedCountries |
US when allowedCountries: ["US"] |
pass:default_allow |
No rule matched and defaultAllow is true |
Unknown country, permissive config |
pass:none |
No IP found to evaluate | Misconfigured ipHeaders |
Denied:
| Value | Description | Example |
|---|---|---|
block:allow_private |
Private/internal IP and allowPrivate is false |
Internal IP, strict config |
block:blocked_ip_block |
CIDR in blockedIPBlocks or blockedIPBlocksDir |
Known bad range |
block:blocked_country |
Country is in blockedCountries |
Request from a blocked region |
block:default_allow |
No rule matched and defaultAllow is false |
Unknown country, strict config |
block:error |
Lookup failed, or countryHeader is missing/null in block mode, and banIfError is true. A skip reason above wins over a failed lookup. |
Database lookup failure |
Enrich configuration
http:
middlewares:
geo-enrich:
plugin:
geoblock:
mode: enrich
countryHeader: X-IPCountry
requestHeaderEnrich:
X-IPCountry: country
X-Geo-Country: country
X-Geo-Country-Name: country_name
X-Geo-Continent: continent
X-Geo-Continent-Code: continent_code
X-Geo-Region: region
X-Geo-City: city
X-Geo-Isp: isp
X-Geo-Domain: domain
X-Geo-Asn: asn
logStatusDetailHeader: X-Geoblock-Decision
Every mapped header is written. A missing field is the string null. Country on a private IP is PRIVATE. A public IP for which no enabled source returns a country is XX.
Which fields are populated depends on the database you load (country-only LITE vs city/ISP/ASN packages). Map only the keys your file actually has if you want to avoid null columns.
| Header | Source |
|---|---|
requestHeaderEnrich |
Geo fields on the request |
countryHeader |
ISO country (default X-IPCountry). Lookup writes it; block reads it |
logStatusDetailHeader |
pass:{reason} or block:{reason} when set; unused in enrich / disabled |
Optional geoblock
Set mode to choose lookup, block, or both. Empty mode is enrichandblock. enrich and enrichandblock open the GeoIP database; block does not. disabled is pass-through with no database.
mode |
Lookup + headers | Allow / block |
|---|---|---|
enrich |
yes | no |
block |
no | yes (reads countryHeader) |
enrichandblock |
yes | yes |
disabled |
no | no |
To share one database and token across routes, put mode: enrich on a shared middleware and mode: block (country lists only) on each route. Chain enrich before block. If block runs first, countryHeader is missing and banIfError applies.
http:
middlewares:
geo-enrich:
plugin:
geoblock:
mode: enrich
countryHeader: X-IPCountry
ipHeaders:
- x-forwarded-for
- x-real-ip
# databaseSources / auto-update live here
geo-block-us:
plugin:
geoblock:
mode: block
countryHeader: X-IPCountry
ipHeaders:
- x-forwarded-for
- x-real-ip
allowedCountries:
- US
defaultAllow: false
routers:
app:
rule: Host(`app.example`)
middlewares:
- geo-enrich
- geo-block-us
You can also keep a single middleware with mode: enrichandblock and the country lists on that same block.
Installation
Traefik v3.5.0 or later is required, and unsafe operations must be enabled for this plugin. Traefik may label that setting "unsafe"; it is a Yaegi sandbox flag the IP2Location reader needs, not a security warning about the plugin.
Install locally or from the Traefik Plugin catalog.
Plugin catalog
experimental:
plugins:
geoblock:
moduleName: github.com/david-garcia-garcia/traefik-geoblock
version: v1.2.0
settings:
useunsafe: true
Local plugin
experimental:
localPlugins:
geoblock:
moduleName: github.com/david-garcia-garcia/traefik-geoblock
settings:
useunsafe: true
Clone the plugin into the Traefik plugins tree:
RUN mkdir -p /plugins-local/src/github.com/david-garcia-garcia
RUN git clone https://github.com/david-garcia-garcia/traefik-geoblock \
/plugins-local/src/github.com/david-garcia-garcia/traefik-geoblock \
--branch v1.2.0 --single-branch
With the official Traefik image you normally do not need TRAEFIK_PLUGIN_GEOBLOCK_PATH. When it is unset, the plugin looks where Traefik puts it, relative to Traefik's working directory (/ in the official image): plugins-local/src/github.com/david-garcia-garcia/traefik-geoblock (local plugin), then plugins-storage/sources/*/src/github.com/david-garcia-garcia/traefik-geoblock (catalog plugin; Traefik unpacks it under gop-<random>).
Set TRAEFIK_PLUGIN_GEOBLOCK_PATH when the plugin lives elsewhere. It takes the plugin root: an exact directory, or a glob. A set env (glob or exact) does not fall through to the defaults. If several directories match, the most recently modified one is used for every bundled file. The plugin opens {that dir}/seeds/<filename> or {that dir}/<filename> — it does not walk the tree. geoblockban.html is at the plugin root, not under seeds/. When the bundled file cannot be found, the error names the directory and the exact paths tried. A source with a url then logs one WARN and waits for the download; a source without one fails to start.
# Only when the plugin is not under Traefik's default plugin paths
# Docker Compose
environment:
- TRAEFIK_PLUGIN_GEOBLOCK_PATH=/plugins-local/src/github.com/david-garcia-garcia/traefik-geoblock
# Docker run
docker run -e TRAEFIK_PLUGIN_GEOBLOCK_PATH=/plugins-local/src/github.com/david-garcia-garcia/traefik-geoblock traefik:latest
GeoIP database
Lookups are local. There is no outbound GeoIP API on the request path. Enable auto-update and point databaseAutoUpdateDir at a persistent volume so the file stays current and hot-swaps without restarting Traefik.
An empty catalog opens the bundled IP2Location LITE country database (default_ip2location). Enable another source and set default_ip2location.enabled: false if you do not want both. Several enabled rows merge in lexicographic catalog-key order (first non-empty field wins).
databaseAutoUpdateDir: "/data/geoblock"
databaseSources:
default_ip2location:
enabled: false
litezip:
url: "https://download.ip2location.com/lite/IP2LOCATION-LITE-DB1.IPV6.BIN.ZIP"
databaseType: bin
archive: zip
defaultFile: IP2LOCATION-LITE-DB1.IPV6.BIN
fieldsPreconfigured: ip2location_lite
# paid:
# url: "https://www.ip2location.com/download?token=YOUR_TOKEN&file=DB8BINIPV6"
# databaseType: bin
# archive: zip
# fieldsPreconfigured: ip2location_db8
# lite:
# url: "https://ipinfo.io/data/ipinfo_lite.mmdb?token=YOUR_TOKEN"
# databaseType: mmdb
# archive: none
# fieldsPreconfigured: ipinfo_lite
# geolite:
# url: "https://download.maxmind.com/geoip/databases/GeoLite2-Country/download?suffix=tar.gz"
# databaseType: mmdb
# archive: tar.gz
# fieldsPreconfigured: maxmind_country
# headers:
# Authorization: "Basic YOUR_BASE64_ACCOUNTID_LICENSEKEY"
Each enabled row needs databaseType (bin or mmdb) and either fieldsPreconfigured or a fields map — not both. Token and permalink URLs with no file extension need archive (zip, tar.gz, or none).
Reserved catalog keys are inserted when missing. An operator-defined reserved key is kept.
| Key | Inserted as | Type / archive | fieldsPreconfigured |
Bundled defaultFile |
URL |
|---|---|---|---|---|---|
default_ip2location |
enabled | bin / zip |
ip2location_lite |
IP2LOCATION-LITE-DB1.IPV6.BIN |
https://download.ip2location.com/lite/IP2LOCATION-LITE-DB1.IPV6.BIN.ZIP |
default_ipinfo |
disabled | mmdb |
ipinfo_lite |
ipinfo_lite.mmdb |
add https://ipinfo.io/data/ipinfo_lite.mmdb?token=YOUR_TOKEN to keep current |
default_maxmind |
disabled | mmdb |
maxmind_country |
GeoIP2-Country-Test.mmdb (official dummy Country fixture) |
official GeoLite: operator row below |
default_geolite |
disabled | mmdb / none |
maxmind_country |
unofficial https://github.com/P3TERX/GeoLite.mmdb/raw/download/GeoLite2-Country.mmdb |
Token and account downloads are operator rows (any key name). Set archive on permalinks that have no path extension.
| Example key | Type / archive | fieldsPreconfigured |
URL |
|---|---|---|---|
paid |
bin / zip |
ip2location_db8 |
https://www.ip2location.com/download?token=YOUR_TOKEN&file=DB8BINIPV6 |
asnlite |
bin / zip |
ip2location_asn |
https://www.ip2location.com/download?token=YOUR_TOKEN&file=DBASNLITEBINIPV6 |
lite |
mmdb / none |
ipinfo_lite |
https://ipinfo.io/data/ipinfo_lite.mmdb?token=YOUR_TOKEN |
geolite |
mmdb / tar.gz |
maxmind_country (or maxmind_city / maxmind_asn) |
https://download.maxmind.com/geoip/databases/GeoLite2-Country/download?suffix=tar.gz plus headers.Authorization: Basic … |
fieldsPreconfigured
fieldsPreconfigured names a vendor column map. Record keys you can map in requestHeaderEnrich are country, country_name, continent, continent_code, region, city, isp, domain, asn. Extra vendor columns (coords, ZIP, timezone, privacy flags) stay unused.
Every shipped name — IP2Location DB/LITE/ASN file= codes, IPinfo Lite/Core/Plus, MaxMind Country/City/ASN/ISP/Domain/Enterprise, and geolite2_* / geoip2_* aliases — is listed in docs/fields-preconfigured.md.
fields is the same map written by hand (country.iso_code: country). Do not set both on one row.
A custom fields map:
custom:
databaseType: mmdb
fields:
country_code: country
country.iso_code: country
autonomous_system_number:
key: asn
type: uint32
Which file is used
databaseSources.<name>.path is the seed / fallback, not the live copy once a dated file is stored in databaseAutoUpdateDir. For each enabled source the plugin picks a file in this order:
databaseAutoUpdateDir— newest dated file for that catalog key (YYYYMMDD_<catalogKey>.BINor.mmdb) when the dir is set.pathon that source — if it is an existing file (full path you mounted or copied).- Bundled database —
seeds/<defaultFile>under the plugin install, found viaTRAEFIK_PLUGIN_GEOBLOCK_PATH. Do not put that relative name inpath.
If none of those exist, plugin creation fails. An ASN LITE row may omit both path and defaultFile (token download only).
Set databaseAutoUpdateDir when a bound entry has a URL. Prefer a persistent volume that survives container replace. If the dir is empty, the plugin WARNs and writes dated files under the process temp dir (traefik-geoblock). That path is wiped on container replace — do not rely on /tmp in production. After a restart with an empty dir the plugin falls back to seed/path and downloads again.
databaseAutoUpdateDir: "/data/geoblock"
# volumes:
# - geoblock-db:/data/geoblock
Network for auto-update
For automatic updates, allow outbound HTTPS to the vendor you configured:
download.ip2location.com— IP2Location LITE DB1 (no token)www.ip2location.com— IP2Location token downloads (paid packages and ASN LITE)ipinfo.io— IPinfo Lite MMDB (token; the response redirects to IPinfo’s CDN)download.maxmind.com— MaxMind GeoLite2/GeoIP2 permalink (accountId:licenseKey; the response redirects)
An empty databaseSources still inserts enabled default_ip2location with the LITE ZIP URL, so auto-update still needs download.ip2location.com unless you disable that row or keep the reserved key without a URL. Lookups stay local either way.
Configuration reference
http:
middlewares:
geoblock:
plugin:
geoblock:
mode: enrichandblock
defaultAllow: false
allowPrivate: true # default is false
banIfError: true # default true (fail-closed until a handle exists)
disallowedStatusCode: 403
allowedCountries:
- US
- CA
- GB
blockedCountries:
- RU
- CN
allowedIPBlocks:
- "10.0.0.0/8"
- "2001:db8::/32"
blockedIPBlocks:
- "203.0.113.0/24"
# Directory of .txt files (one CIDR per line, # comments). Scanned
# recursively at plugin start. Useful for shared ConfigMaps.
# File changes need a plugin restart.
# allowedIPBlocksDir: "/data/allowed-ips/"
# blockedIPBlocksDir: "/data/blocked-ips/"
ipHeaders:
- x-forwarded-for
- x-real-ip
# - cf-connecting-ip # Cloudflare
# - remoteAddress # SYNTHETIC: req.RemoteAddr
ipHeaderStrategy: CheckAll # CheckAll | CheckFirst | CheckFirstNonePrivate | RightmostUntrusted
# trustedProxies: # only with RightmostUntrusted
# - 10.10.60.0/24
ignoreVerbs:
- OPTIONS
- HEAD
includedPathsRegex: ""
excludedPathsRegex: ""
# Empty bypassHeaders values are rejected at plugin creation.
bypassHeaders:
X-Internal-Request: "true"
countryHeader: X-IPCountry
requestHeaderEnrich:
X-Geo-Country: country
X-Geo-City: city
X-Geo-Asn: asn
logStatusDetailHeader: X-Geoblock-Decision
databaseAutoUpdateDir: "/data/geoblock"
databaseSources:
default_ip2location:
enabled: true
logLevel: info # trace | debug | info | warn | error
logFormat: json # json | text (default text)
# Plugin logs go to stdout (Traefik process log).
# banHtmlFilePath: "/path/to/geoblockban.html" # {{.IP}} {{.Country}}; GET only
# With ban HTML, use a real status (not 204).
Client IP (ipHeaders)
ipHeaders cannot be empty (except mode: disabled, which skips this check). Header order matters: headers are read in list order; within a header, IPs are left-to-right (leftmost is usually the original client). Duplicates are dropped, first occurrence kept.
remoteAddress is a synthetic name for req.RemoteAddr (the direct connection). Use it when you also need the hop that connected to Traefik:
ipHeaders:
- x-forwarded-for
- remoteAddress
ipHeaderStrategy |
Which IPs are evaluated |
|---|---|
CheckAll |
Every IP found (default) |
CheckFirst |
Only the first IP |
CheckFirstNonePrivate |
First public IP; if none, the last private hop |
RightmostUntrusted |
Walk the selected chain from the right; skip trustedProxies; evaluate one hop |
CheckAll / CheckFirst / CheckFirstNonePrivate still concatenate every present ipHeaders entry and keep the first occurrence of a repeated IP. They read only the first field line of each header.
RightmostUntrusted
This strategy uses the same rule as Traefik ipStrategy.excludedIPs: walk hops from the right, skip trusted proxies, evaluate exactly one hop. A client cannot pick the country by forging left-side hops.
Forwarding headers (every ipHeaders entry except remoteAddress) are alternatives, tried in config order, so list them by priority. The first header that yields at least one hop is the selected header; a header that is absent, empty, or has no address in it (" , ") is skipped. Later forwarding headers are ignored for that request; they are never concatenated. The default ipHeaders (x-forwarded-for, x-real-ip) stays valid: X-Forwarded-For when present, else X-Real-IP.
remoteAddress, when listed, must be last and always closes the chain. A direct peer that is not in trustedProxies is then the evaluated hop, so every forwarding header is ignored. Omitting remoteAddress is allowed (one warning at creation): headers are trusted without checking who sent them. Put remoteAddress last so a request that did not come through your proxies cannot choose a header.
Several HTTP field lines of the selected header are one list (every line, in order, each split on ,).
ipHeaders:
- cf-connecting-ip # requests that come through Cloudflare
- x-forwarded-for # requests that come through the load balancer
- remoteAddress # always last: the direct peer
ipHeaderStrategy: RightmostUntrusted
trustedProxies:
- 10.10.60.0/24 # load balancer
- 173.245.48.0/20 # Cloudflare range (example; use the published list)
Each proxy in front of Traefik must overwrite or strip every configured forwarding header it does not set. Otherwise a client that can get an earlier header through (for example CF-Connecting-IP through a load balancer that only sets X-Forwarded-For) picks the header. Binding each header to the proxies allowed to set it is not implemented.
When every hop is a trusted proxy (a load balancer health check, an internal call from inside the proxy chain), the leftmost hop, where the request started, is evaluated. A private load balancer address therefore follows allowPrivate; to allow it with allowPrivate: false, add it to allowedIPBlocks. Only a request with no hop at all goes to the banIfError path.
When the evaluated hop is not an IP address (for example CF-Connecting-IP: garbage), banIfError: true blocks it; with banIfError: false, defaultAllow decides.
trustedProxies entries are CIDRs or single addresses (10.10.60.5, 2001:db8::1, ::ffff:10.10.60.5). A single address trusts only that host; an IPv4-mapped address is the IPv4 host.
trustedProxies is rejected with CheckAll / CheckFirst / CheckFirstNonePrivate. Empty trustedProxies with RightmostUntrusted is valid: the rightmost hop (often the direct peer) is the client.
Traefik entrypoint forwardedHeaders.trustedIPs runs before this plugin. When the TCP peer is not in that list and insecure is false, Traefik deletes managed X-Forwarded-* / X-Real-Ip and then fills empties: X-Forwarded-For is empty at middleware time, X-Real-Ip is the TCP peer, and req.RemoteAddr is still the TCP peer. Listing remoteAddress last still gives this plugin a hop to evaluate. This product's compose sets forwardedHeaders.insecure=true, so it does not show that delete path.
Country allow/block uses the single countryHeader value (first public country written). CheckAll still applies CIDR and private rules to every selected IP. To choose which hop’s country is written, use CheckFirst / CheckFirstNonePrivate. To deny a later hop by address, use blockedIPBlocks, or omit that hop from ipHeaders.
Every selected hop can deny. An earlier allowed hop does not vouch for the ones after it; pass:{reason} names the first allowing hop. If a forwarding proxy leaves its own private address in the chain, set allowPrivate: true or use CheckFirstNonePrivate — allowedIPBlocks cannot allow a private hop, because private, IPv6 ULA, and loopback addresses answer to allowPrivate before the CIDR lists are consulted. CGNAT (100.64/10), link-local, and benchmark IPs are not PRIVATE; they enrich as XX.
On lookup modes, countryHeader starts as PRIVATE and is overwritten by the first real country. An IP header value the plugin cannot parse enriches as XX, never as itself — the header only ever carries an ISO country, PRIVATE or XX. A public IP for which no enabled source returns a country is XX, so it reaches the country rules and defaultAllow rather than allowPrivate. XX is ISO 3166-1 user-assigned and may be listed in allowedCountries / blockedCountries. An IP2Location bin miss (country_short -) is empty at merge, so a later catalog source may fill country and a BIN-only miss still writes XX.
Path include / exclude
includedPathsRegex and excludedPathsRegex are one Go RE2 regex each, matched against {host}{path} (for example example.com/api/users). The plugin uses req.Host as Traefik sent it and does not strip a port. Path starts with / and has no query string. Empty is unset (no effect). Include runs first; exclude still wins after a match. Skip-blocking requests were already enriched.
A public URL match is not a secret — anyone who can guess the path skips blocking. For health checks, bypassHeaders is stronger.
includedPathsRegex: "^[^/]*/secure/.*"
excludedPathsRegex: "^[^/]*/(health|ready|live)$"
| Example | Matches |
|---|---|
^[^/]*/secure/.* |
/secure/* on any host |
^app\\.example\\.com/admin/.* |
/admin/* on that host |
^[^/]*/health$ |
/health on any host |
^api\\.example\\.com/.* |
all paths on api.example.com |
ignoreVerbs is case-insensitive. Those methods skip blocking and still get enrichment.
Ban page
banHtmlFilePath empty means status only. If you set a path and that file is not there, the plugin looks for geoblockban.html under $TRAEFIK_PLUGIN_GEOBLOCK_PATH (seeds/ then the plugin root). Placeholders: {{.IP}} and {{.Country}}. The HTML body is written only for GET; other methods get the status with no body. Do not pair HTML with status 204.
Processing order
mode: disabled→ pass through- Read IPs from
ipHeadersin list order and applyipHeaderStrategy enrich/enrichandblock→ lookup and writecountryHeader+requestHeaderEnrichenrich(no block) → pass through- Skip blocking (enrichment already done):
ignoreVerbs, thenincludedPathsRegexmiss, thenexcludedPathsRegexmatch, thenbypassHeaders - Lookup failed and
banIfError→block:error block/enrichandblock→ private and CIDR per selected IP, then country fromcountryHeaderdefaultAllowif no country rule matched
| Setting | Role |
|---|---|
mode |
disabled | enrich | block | enrichandblock (empty = enrichandblock) |
requestHeaderEnrich |
Header name → geo key |
countryHeader |
Country bridge between enrich and block (default X-IPCountry) |
logStatusDetailHeader |
pass:{reason} / block:{reason} on the request when set; unused in enrich / disabled |
allowedCountries / blockedCountries |
ISO 3166-1 alpha-2 |
defaultAllow |
When no country or CIDR rule matches |
allowPrivate |
RFC 1918, IPv6 ULA, and loopback (country PRIVATE). Default false. |
allowedIPBlocks / blockedIPBlocks |
CIDR allow / deny (more specific prefix wins) |
allowedIPBlocksDir / blockedIPBlocksDir |
Shared .txt CIDR files, loaded at start |
ipHeaders |
Where to read client IPs (remoteAddress is the direct connection) |
ipHeaderStrategy |
Which hop to evaluate when several IPs are present |
ignoreVerbs / path regex / bypassHeaders |
Skip blocking; enrichment still runs |
banIfError / disallowedStatusCode / banHtmlFilePath |
Lookup failure, missing country header, or no client IP. Default banIfError: true. false is fail-open on lookup only: CIDR, private, country lists, and defaultAllow still apply. |
databaseSources / databaseAutoUpdateDir |
Local files and optional download. An unreadable dated file falls back to the seed and warns. |
logLevel / logFormat |
Plugin logs on Traefik stdout (logFormat default text) |
📄 Apache License 2.0 — see LICENSE.
🌍 This project includes IP2Location LITE data available from lite.ip2location.com.
🌍 This project includes IPinfo Lite data (CC-BY-SA 4.0). IP address data powered by IPinfo.
🌍 This product includes GeoLite Data created by MaxMind, available from https://www.maxmind.com.
Ähnliche Projekte entdecken
Wird geladen…