mirror of
https://github.com/adulau/crl-monitor.git
synced 2024-11-24 19:17:13 +00:00
Exlude IPv6 addresses until now
This commit is contained in:
parent
9aa4329918
commit
7d9f1ca0b8
1 changed files with 6 additions and 0 deletions
|
@ -11,6 +11,7 @@ import redis
|
||||||
import sys
|
import sys
|
||||||
import netaddr
|
import netaddr
|
||||||
import json
|
import json
|
||||||
|
import re
|
||||||
|
|
||||||
import tornado.httpserver
|
import tornado.httpserver
|
||||||
import tornado.ioloop
|
import tornado.ioloop
|
||||||
|
@ -33,6 +34,11 @@ class SSLQueryHandler(tornado.web.RequestHandler):
|
||||||
subnets = [input]
|
subnets = [input]
|
||||||
out = {}
|
out = {}
|
||||||
for subnet in subnets:
|
for subnet in subnets:
|
||||||
|
if re.findall(r":", subnet):
|
||||||
|
self.clear()
|
||||||
|
self.set_status(400)
|
||||||
|
self.finish('IPv6 is not (yet) supported')
|
||||||
|
continue
|
||||||
try:
|
try:
|
||||||
iplist = netaddr.IPNetwork(subnet)
|
iplist = netaddr.IPNetwork(subnet)
|
||||||
except:
|
except:
|
||||||
|
|
Loading…
Reference in a new issue