Skip to content

Country db

Country/category IP database sourced from MMDB or binary geoip.dat. MMDB records may contain country.iso_code, a single string, or an array of string labels.

Fields

tag

  • Type: string
  • Required: yes

Unique tag, also used as the inbound tag of download connections.

url

  • Type: string
  • Required: no
  • Default: https://git.io/GeoLite2-Country.mmdb

HTTP(S) source URL. Used only when path does not exist. Defaults to the MaxMind GeoLite2 Country database in MMDB format. The V2Ray/Xray protobuf geoip.dat is also accepted; the format is detected from the contents, and it is always converted to redb.

path

  • Type: path
  • Required: yes

Persistent file, relative to the working directory. A .mmdb suffix selects direct MMDB lookups; other suffixes retain redb conversion. A geoip.dat source requires a non-.mmdb path. Cost about 3mb for mmdb file. Redb format not recommended for country database, as it is slower and larger.