diff --git a/lg.py b/lg.py index 21781a3..47ed204 100644 --- a/lg.py +++ b/lg.py @@ -24,6 +24,7 @@ from collections import defaultdict from logging.handlers import TimedRotatingFileHandler from urllib import quote, unquote from urllib2 import urlopen + import json import logging import memcache @@ -60,15 +61,6 @@ def get_asn_from_as(n): return [field.strip() for field in data.split("|")] -def get_asn_from_as(n): - asn_zone = app.config.get("ASN_ZONE", "asn.cymru.com") - try: - data = resolve("AS%s.%s" % (n, asn_zone) ,"TXT").replace("'","").replace('"','') - except: - return " "*5 - return [ field.strip() for field in data.split("|") ] - - def add_links(text): """Browser a string and replace ipv4, ipv6, as number, with a whois link """