cache

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrCacheMiss    = fmt.Errorf("Cache entry not found")
	ErrCacheExpired = fmt.Errorf("Cache entry expired")
)

Functions

func Key

func Key(name string, qtype uint16) uint64

Types

type Cache

type Cache struct {
	// contains filtered or unexported fields
}

func (*Cache) Get

func (c *Cache) Get(zone string, question dns.Question) (*dns.Msg, error)

Get returns an item from cache.

func (*Cache) Update

func (c *Cache) Update(zone string, question dns.Question, msg *dns.Msg) error

type Entry

type Entry struct {
	Name       string
	Type       uint16
	Status     ValidationStatus
	Rcode      int
	Records    []dns.RR
	Signatures []dns.RR
	TTL        uint32
	Expires    time.Time
}

type ValidationStatus

type ValidationStatus int
const (
	Indeterminate ValidationStatus = iota
	Secure
	Insecure
	Bogus
)

rename this so it starts with DNSSEC

Jump to

Keyboard shortcuts

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