Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
DatabasePath string
}
Config specifies configuration parsed for Caddyfile
type GeoIP ¶
type GeoIP struct {
Next httpserver.Handler
DBHandler *maxminddb.Reader
ASNDB *asndb.ASNDB
Config Config
}
GeoIP represents a middleware instance
type GeoIPRecord ¶
type GeoIPRecord struct {
Country struct {
ISOCode string `maxminddb:"iso_code"`
IsInEuropeanUnion bool `maxminddb:"is_in_european_union"`
Names map[string]string `maxminddb:"names"`
GeoNameID uint64 `maxminddb:"geoname_id"`
} `maxminddb:"country"`
City struct {
Names map[string]string `maxminddb:"names"`
GeoNameID uint64 `maxminddb:"geoname_id"`
} `maxminddb:"city"`
Location struct {
Latitude float64 `maxminddb:"latitude"`
Longitude float64 `maxminddb:"longitude"`
TimeZone string `maxminddb:"time_zone"`
} `maxminddb:"location"`
ASN *asndb.ASN
}
Click to show internal directories.
Click to hide internal directories.