Documentation
¶
Index ¶
- Variables
- func GetVersion() string
- func PrintVersion()
- func WithQNAME(qname string) func(*Task)
- func WithQTYPE(qtype string) func(*Task)
- func WithResolver(resolver string) func(*Task)
- func WithTimeout(timeout int64) func(*Task)
- type DNS
- type ReadableMsg
- type ReadableMsgHdr
- type ReadableQuestion
- type ReadableRR
- type Task
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Version string = "0.0.0" Commit string = "unknown" Date string = time.Now().Format("2006-01-02") )
View Source
var DNSClient dns.Client
Functions ¶
func GetVersion ¶
func GetVersion() string
func PrintVersion ¶
func PrintVersion()
func WithResolver ¶
func WithTimeout ¶
Types ¶
type DNS ¶
type DNS struct { Request *ReadableMsg `json:"request"` Response *ReadableMsg `json:"response"` }
type ReadableMsg ¶
type ReadableMsg struct { Header ReadableMsgHdr `json:"header"` Questions []ReadableQuestion `json:"questions,omitempty"` Answers []ReadableRR `json:"answers,omitempty"` Ns []ReadableRR `json:"authority,omitempty"` Extra []ReadableRR `json:"additional,omitempty"` }
func NewReadableMsg ¶
func NewReadableMsg(msg *dns.Msg) *ReadableMsg
type ReadableMsgHdr ¶
func (ReadableMsgHdr) MarshalJSON ¶
func (h ReadableMsgHdr) MarshalJSON() ([]byte, error)
type ReadableQuestion ¶
func (ReadableQuestion) MarshalJSON ¶
func (q ReadableQuestion) MarshalJSON() ([]byte, error)
type ReadableRR ¶
func (ReadableRR) MarshalJSON ¶
func (rr ReadableRR) MarshalJSON() ([]byte, error)
Click to show internal directories.
Click to hide internal directories.