Changeset View
Changeset View
Standalone View
Standalone View
contrib/seeds/makeseeds.py
Show All 9 Lines | |||||
import dns.resolver | import dns.resolver | ||||
import re | import re | ||||
import sys | import sys | ||||
from typing import List, Dict, Union | from typing import List, Dict, Union | ||||
NSEEDS = 512 | NSEEDS = 512 | ||||
MAX_SEEDS_PER_ASN = { | MAX_SEEDS_PER_ASN = { | ||||
'ipv4': 2, | 'ipv4': 6, | ||||
'ipv6': 10, | 'ipv6': 10, | ||||
} | } | ||||
MIN_BLOCKS = 760000 | MIN_BLOCKS = 760000 | ||||
PATTERN_IPV4 = re.compile( | PATTERN_IPV4 = re.compile( | ||||
r"^((\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})):(\d+)$") | r"^((\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})):(\d+)$") | ||||
PATTERN_IPV6 = re.compile(r"^\[([0-9a-z:]+)\]:(\d+)$") | PATTERN_IPV6 = re.compile(r"^\[([0-9a-z:]+)\]:(\d+)$") | ||||
▲ Show 20 Lines • Show All 256 Lines • Show Last 20 Lines |