blob: 9a637e2e7e4a8cad425ae50afa20c2bf65bf1917 (
plain)
1
2
3
4
5
6
7
8
9
10
|
#!/usr/bin/env python3
import dns.edns
import sys
if len(sys.argv) > 1:
opt = dns.edns.ECSOption.from_text(sys.argv[1])
print("-e %d:%s" % (dns.edns.ECS, opt.to_wire().hex()))
else:
print("usage: dnsperf-ecs-gen.py <address/srclen[/scopelen]>")
|