lrfc2136

package
v0.10.6 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2025 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseTypesSet added in v0.10.0

func ParseTypesSet(in []string) (map[uint16]struct{}, error)

func TsigSecrets

func TsigSecrets(clients ...Client) (map[string]string, error)

Types

type Client

type Client struct {
	Name       string
	Secret     string
	XFRAllowed bool
	AutoDelete bool
	Zones      []string
	Types      TypesSet
}

func (*Client) IsNameAllowed added in v0.10.0

func (c *Client) IsNameAllowed(name string) bool

func (*Client) IsTypeAllowed added in v0.10.0

func (c *Client) IsTypeAllowed(rrType uint16) bool

func (*Client) IsXFRAllowed added in v0.10.0

func (c *Client) IsXFRAllowed() bool

func (*Client) SOA added in v0.10.0

func (c *Client) SOA(name string) (*dns.SOA, error)

func (*Client) ShouldAutoDelete added in v0.10.0

func (c *Client) ShouldAutoDelete() bool

func (*Client) Zone added in v0.10.0

func (c *Client) Zone(name string) string

type Clients

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

func TsigClients

func TsigClients(clients ...Client) (*Clients, error)

func (*Clients) Client added in v0.10.0

func (a *Clients) Client(r *dns.Msg) (*Client, error)

type Config

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

func NewConfig

func NewConfig() *Config

func (*Config) Addr

func (c *Config) Addr(addr string) *Config

func (*Config) AppendClient

func (c *Config) AppendClient(client Client) *Config

func (*Config) Clients

func (c *Config) Clients(clients ...Client) *Config

func (*Config) Nets

func (c *Config) Nets(nets ...string) *Config

func (*Config) Upstream

func (c *Config) Upstream(upstream upstream.Upstream) *Config

func (*Config) Validate

func (c *Config) Validate() error

type Listener

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

func NewListener

func NewListener(cfg *Config) (*Listener, error)

func (*Listener) ListenAndServe

func (a *Listener) ListenAndServe() error

func (*Listener) ServeDNS

func (a *Listener) ServeDNS(w dns.ResponseWriter, r *dns.Msg)

func (*Listener) Shutdown

func (a *Listener) Shutdown(ctx context.Context) error

type TypesSet added in v0.10.0

type TypesSet map[uint16]struct{}

Directories

Path Synopsis
Code generated by errsgen; DO NOT EDIT.
Code generated by errsgen; DO NOT EDIT.
errsgen command

Jump to

Keyboard shortcuts

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