rootanchors

package module
v0.0.0-...-63aee68 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 18, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

README

go-dns-root-anchors

Root zone trust anchors in Go, updated with Github Actions.

Documentation

Index

Constants

View Source
const IanaRootAnchorsXml = `` /* 1860-byte string literal not displayed */

https://data.iana.org/root-anchors/root-anchors.xml BEGIN IANA ROOT ANCHORS XML DATA

Variables

This section is empty.

Functions

func GetValidDNSKEYRecords

func GetValidDNSKEYRecords() map[uint16]*dns.DNSKEY

GetValidDNSKEYRecords returns root anchors as DNSKEY records defined by miekg/dns.

func GetValidDSRecords

func GetValidDSRecords() map[uint16]dns.DS

GetDSRecords returns root anchors as DS records defined by miekg/dns.

Types

type KeyDigest

type KeyDigest struct {
	ID         string `xml:"id,attr"`
	ValidFrom  string `xml:"validFrom,attr"`
	ValidUntil string `xml:"validUntil,attr,omitempty"`
	KeyTag     uint16 `xml:"KeyTag"`
	Algorithm  uint8  `xml:"Algorithm"`
	DigestType uint8  `xml:"DigestType"`
	Digest     string `xml:"Digest"`
	PublicKey  string `xml:"PublicKey,omitempty"`
	Flags      uint16 `xml:"Flags,omitempty"`
}

KeyDigest represents the KeyDigest elements inside TrustAnchor.

type TrustAnchor

type TrustAnchor struct {
	XMLName    xml.Name    `xml:"TrustAnchor"`
	ID         string      `xml:"id,attr"`
	Source     string      `xml:"source,attr"`
	Zone       string      `xml:"Zone"`
	KeyDigests []KeyDigest `xml:"KeyDigest"`
}

TrustAnchor represents the main XML structure.

func GetRawAnchors

func GetRawAnchors() TrustAnchor

GetRawAnchors returns the raw XML data parsed into a TrustAnchor struct.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL