Commit 509f98b1 authored by Peter Müller's avatar Peter Müller Committed by Michael Tremer

importer.py: add source information for RIR data feeds

Signed-off-by: default avatarPeter Müller <peter.mueller@ipfire.org>
Signed-off-by: default avatarMichael Tremer <michael.tremer@ipfire.org>
parent 28b08385
......@@ -25,50 +25,68 @@ import urllib.request
log = logging.getLogger("location.importer")
log.propagate = 1
WHOIS_SOURCES = (
WHOIS_SOURCES = {
# African Network Information Centre
"https://ftp.afrinic.net/pub/pub/dbase/afrinic.db.gz",
"AFRINIC": [
"https://ftp.afrinic.net/pub/pub/dbase/afrinic.db.gz"
],
# Asia Pacific Network Information Centre
"https://ftp.apnic.net/apnic/whois/apnic.db.inet6num.gz",
"https://ftp.apnic.net/apnic/whois/apnic.db.inetnum.gz",
#"https://ftp.apnic.net/apnic/whois/apnic.db.route6.gz",
#"https://ftp.apnic.net/apnic/whois/apnic.db.route.gz",
"https://ftp.apnic.net/apnic/whois/apnic.db.aut-num.gz",
"https://ftp.apnic.net/apnic/whois/apnic.db.organisation.gz",
"APNIC": [
"https://ftp.apnic.net/apnic/whois/apnic.db.inet6num.gz",
"https://ftp.apnic.net/apnic/whois/apnic.db.inetnum.gz",
#"https://ftp.apnic.net/apnic/whois/apnic.db.route6.gz",
#"https://ftp.apnic.net/apnic/whois/apnic.db.route.gz",
"https://ftp.apnic.net/apnic/whois/apnic.db.aut-num.gz",
"https://ftp.apnic.net/apnic/whois/apnic.db.organisation.gz"
],
# American Registry for Internet Numbers
# XXX there is nothing useful for us in here
#"https://ftp.arin.net/pub/rr/arin.db",
# ARIN: [
# "https://ftp.arin.net/pub/rr/arin.db"
# ],
# Latin America and Caribbean Network Information Centre
# XXX ???
# Réseaux IP Européens
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.inet6num.gz",
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.inetnum.gz",
#"https://ftp.ripe.net/ripe/dbase/split/ripe.db.route6.gz",
#"https://ftp.ripe.net/ripe/dbase/split/ripe.db.route.gz",
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.aut-num.gz",
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.organisation.gz",
)
EXTENDED_SOURCES = (
"RIPE": [
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.inet6num.gz",
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.inetnum.gz",
#"https://ftp.ripe.net/ripe/dbase/split/ripe.db.route6.gz",
#"https://ftp.ripe.net/ripe/dbase/split/ripe.db.route.gz",
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.aut-num.gz",
"https://ftp.ripe.net/ripe/dbase/split/ripe.db.organisation.gz"
],
}
EXTENDED_SOURCES = {
# African Network Information Centre
#"https://ftp.afrinic.net/pub/stats/afrinic/delegated-afrinic-extended-latest",
# "ARIN": [
# "https://ftp.afrinic.net/pub/stats/afrinic/delegated-afrinic-extended-latest"
# ],
# Asia Pacific Network Information Centre
#"https://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-extended-latest",
# "APNIC": [
# "https://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-extended-latest"
# ],
# American Registry for Internet Numbers
"https://ftp.arin.net/pub/stats/arin/delegated-arin-extended-latest",
"ARIN": [
"https://ftp.arin.net/pub/stats/arin/delegated-arin-extended-latest"
],
# Latin America and Caribbean Network Information Centre
"https://ftp.lacnic.net/pub/stats/lacnic/delegated-lacnic-extended-latest",
"LACNIC": [
"https://ftp.lacnic.net/pub/stats/lacnic/delegated-lacnic-extended-latest"
],
# Réseaux IP Européens
#"https://ftp.ripe.net/pub/stats/ripencc/delegated-ripencc-extended-latest",
)
# "RIPE": [
# "https://ftp.ripe.net/pub/stats/ripencc/delegated-ripencc-extended-latest"
# ],
}
class Downloader(object):
def __init__(self):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment