Skip to content

About

Go library for using the iptoasn.com data

Resources

Stars

2 stars

Watchers

0 watching

Forks

Latest commit

 

History

32 Commits

Folders and files

Repository files navigation

iptoasn-go

This is a utility for efficiently using the iptoasn.com GeoIP data in Go programs, by converting the raw .tsv data to the mmdb format (MaxMind DB File Format). It uses the maxmind/mmdbwriter library for the mmdb conversion.

Usage

  1. Installation - go install github.com/case/iptoasn-go/cmd/iptoasn@v1.0.0
  2. Usage - iptoasn --download -o iptoasn.mmdb - downloads and converts the default ip2asn-combined.tsv.gz file
  3. Use the resulting .mmdb file in your Go programs, via the oschwald/geoip2-golang library

Misc

Minimum Go version supported - 1.24 (as required by maxmind/mmdbwriter)

IPtoASN supported files:

  • ip2asn-combined.tsv.gz
  • ip2asn-v4.tsv.gz
  • ip2asn-v6.tsv.gz
  • ip2country-v4.tsv.gz
  • ip2country-v6.tsv.gz

Thank you 🙏

  • Frank Denis, for providing the iptoasn.com data service
  • MaxMind, for the mmdb file format, and the read & write Go code
  • Julia Evans, for her explorations in the space

About

Go library for using the iptoasn.com data

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages