service

package
v0.0.0-...-1a3d976 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2021 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildDNSMessage

func BuildDNSMessage(record *config.LocalDNSRecord) ([]byte, error)

func CreateLocalRecords

func CreateLocalRecords(conf *config.Configuration) (map[string][]byte, error)

func GetAddressFromResource

func GetAddressFromResource(resource dnsmessage.Resource) string

func HashMessageFields

func HashMessageFields(msgSerial *[]byte) (string, error)

func SetResponseId

func SetResponseId(serial []byte, Id uint16) ([]byte, error)

func StartDNSService

func StartDNSService(c *net.UDPConn, conf *config.Configuration)

Types

type Operation

type Operation uint16
const (
	OpCallback Operation = 1
	OpAdd      Operation = 2
	OpRespond  Operation = 3
	OpDelete   Operation = 4
)

type StateOperation

type StateOperation struct {
	Operation     Operation
	RequestHash   string
	RequestorAddr *net.UDPAddr
	ByteData      []byte
	RequestId     uint16
}

Jump to

Keyboard shortcuts

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