1
0
Fork 0
mirror of https://github.com/NeoCloud/NeoNetwork synced 2024-12-25 14:29:24 +08:00

fix write_named_trust_anchors in dns-generator

This commit is contained in:
JerryXiao 2022-12-05 22:35:03 +08:00
parent 8733a70456
commit 1696d5dd91
Signed by: Jerry
GPG key ID: 22618F758B5BE2E5

View file

@ -33,7 +33,8 @@ def write_named_trust_anchors():
for entry in dnskeys_exported: for entry in dnskeys_exported:
zone, records = entry['zone'], [r['dnskey'] for r in entry['records']] zone, records = entry['zone'], [r['dnskey'] for r in entry['records']]
for record in records: for record in records:
contents.append(f" {zone:>{maxzonelen}s} static-key \"{record}\";") a1, a2, a3, a4 = record.split(maxsplit=3)
contents.append(f" {zone:>{maxzonelen}s} static-key {a1} {a2} {a3} \"{a4}\";")
NAMED_TURST_ANCHORS_FILE.write_text(header + '\n'.join(contents) + footer) NAMED_TURST_ANCHORS_FILE.write_text(header + '\n'.join(contents) + footer)
def main(): def main():