e2e

package
v0.37.0 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2026 License: Apache-2.0 Imports: 30 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FormatRecordForMokka

func FormatRecordForMokka(rr dns.RR) string

FormatRecordForMokka formats a DNS RR for use in dns-mokka configuration Returns the format: "TYPE rdata TTL" Example: "A 192.0.2.1 300"

Types

type DNSSECChainData

type DNSSECChainData struct {
	// Parent zone (e.g., "example.")
	ParentZone       string
	ParentDNSKEY     *dns.DNSKEY
	ParentPrivateKey *ecdsa.PrivateKey

	// Child zone (e.g., "child.example.")
	ChildZone       string
	ChildDNSKEY     *dns.DNSKEY
	ChildPrivateKey *ecdsa.PrivateKey

	// DS record linking child to parent
	DS *dns.DS

	// DS RRSIG (parent signs the DS record)
	DSRRSIG *dns.RRSIG

	// Child's A record and signature
	ARecord *dns.A
	ARRRSIG *dns.RRSIG

	// DNSKEY RRSIGs (self-signed per RFC 4035 §5.2)
	ChildDNSKEYRRSIG  *dns.RRSIG
	ParentDNSKEYRRSIG *dns.RRSIG
}

DNSSECChainData holds a complete DNSSEC chain with parent and child zones

func GenerateDNSSECChain

func GenerateDNSSECChain(parentZone, childZone, hostname, ipAddr string) (*DNSSECChainData, error)

GenerateDNSSECChain generates a complete DNSSEC chain with parent and child zones This creates a parent zone, child zone, DS record, and all necessary signatures

type DNSSECTestData

type DNSSECTestData struct {
	ARecord    *dns.A
	RRSIG      *dns.RRSIG
	DNSKEY     *dns.DNSKEY
	PrivateKey *ecdsa.PrivateKey

	// DNSKEY RRSIG (self-signed per RFC 4035 §5.2)
	DNSKEYRRSIG *dns.RRSIG
}

DNSSECTestData holds generated DNSSEC test data for e2e tests

func GenerateMismatchedDNSSEC

func GenerateMismatchedDNSSEC(zone, hostname, ipAddr string) (signed, wrongKey *DNSSECTestData, err error)

GenerateMismatchedDNSSEC generates DNSSEC data where RRSIG and DNSKEY don't match The A record is signed with keyA, but a different keyB, with the RRSIG that it makes over its own DNSKEY RRset, is returned for DNSKEY queries

func GenerateValidDNSSEC

func GenerateValidDNSSEC(zone, hostname, ipAddr string) (*DNSSECTestData, error)

GenerateValidDNSSEC generates a valid DNSSEC-signed A record with matching DNSKEY This creates cryptographically correct DNSSEC data for testing validation

Jump to

Keyboard shortcuts

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