Documentation ¶
Index ¶
- func ParseAnswer(ans dns.RR) interface{}
- func TranslateMiekgErrorCode(err int) zdns.Status
- type Answer
- type CAAAnswer
- type CachedResult
- type DNSFlags
- type DNSKEYAnswer
- type DSAnswer
- type GlobalLookupFactory
- func (s *GlobalLookupFactory) AddCachedAnswer(answer interface{}, name string, dnsType uint16, ttl uint32, depth int, ...)
- func (s *GlobalLookupFactory) AddFlags(f *flag.FlagSet)
- func (s *GlobalLookupFactory) BlacklistInit() error
- func (s *GlobalLookupFactory) GetCachedResult(name string, dnsType uint16, isAuthCheck bool, depth int, threadID int) (Result, bool)
- func (s *GlobalLookupFactory) Help() string
- func (s *GlobalLookupFactory) Initialize(c *zdns.GlobalConf) error
- func (s *GlobalLookupFactory) MakeRoutineFactory(threadID int) (zdns.RoutineLookupFactory, error)
- func (s *GlobalLookupFactory) SetDNSClass(dnsClass uint16)
- func (s *GlobalLookupFactory) SetDNSType(dnsType uint16)
- func (s *GlobalLookupFactory) VerboseGlobalLog(depth int, threadID int, args ...interface{})
- type IsCached
- type Lookup
- func (s *Lookup) DoLookup(name string) (interface{}, []interface{}, zdns.Status, error)
- func (s *Lookup) DoMiekgLookup(name string) (interface{}, []interface{}, zdns.Status, error)
- func (s *Lookup) DoMiekgLookupForClass(name string, dnsClass uint16) (interface{}, []interface{}, zdns.Status, error)
- func (s *Lookup) DoTxtLookup(name string) (string, []interface{}, zdns.Status, error)
- func (s *Lookup) DoTypedMiekgLookup(name string, dnsType uint16) (interface{}, []interface{}, zdns.Status, error)
- func (s *Lookup) DoTypedMiekgLookupInClass(name string, dnsType uint16, dnsClass uint16) (interface{}, []interface{}, zdns.Status, error)
- func (s *Lookup) Initialize(nameServer string, dnsType uint16, dnsClass uint16, ...) error
- func (s *Lookup) SafeAddCachedAnswer(a interface{}, layer string, debugType string, depth int)
- func (s *Lookup) VerboseLog(depth int, args ...interface{})
- type MXAnswer
- type NAPTRAnswer
- type NSEC3Answer
- type NSEC3ParamAnswer
- type NSECAnswer
- type RRSIGAnswer
- type Result
- type RoutineLookupFactory
- type SOAAnswer
- type SRVAnswer
- type TLSAAnswer
- type TimedAnswer
- type TraceStep
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseAnswer ¶
func TranslateMiekgErrorCode ¶
Types ¶
type Answer ¶
type Answer struct { Ttl uint32 `json:"ttl" groups:"ttl,normal,long,trace"` Type string `json:"type,omitempty" groups:"short,normal,long,trace"` Class string `json:"class,omitempty" groups:"short,normal,long,trace"` Name string `json:"name,omitempty" groups:"short,normal,long,trace"` Answer string `json:"answer,omitempty" groups:"short,normal,long,trace"` // contains filtered or unexported fields }
type CachedResult ¶
type CachedResult struct {
Answers map[interface{}]TimedAnswer
}
type DNSFlags ¶
type DNSFlags struct { Response bool `json:"response" groups:"flags,long,trace"` Opcode int `json:"opcode" groups:"flags,long,trace"` Authoritative bool `json:"authoritative" groups:"flags,long,trace"` Truncated bool `json:"truncated" groups:"flags,long,trace"` RecursionDesired bool `json:"recursion_desired" groups:"flags,long,trace"` RecursionAvailable bool `json:"recursion_available" groups:"flags,long,trace"` Authenticated bool `json:"authenticated" groups:"flags,long,trace"` CheckingDisabled bool `json:"checking_disabled" groups:"flags,long,trace"` ErrorCode int `json:"error_code" groups:"flags,long,trace"` }
type DNSKEYAnswer ¶
type DNSKEYAnswer struct { Answer Flags uint16 `json:"flags" groups:"short,normal,long,trace"` Protocol uint8 `json:"protocol" groups:"short,normal,long,trace"` Algorithm uint8 `json:"algorithm" groups:"short,normal,long,trace"` PublicKey string `json:"public_key" groups:"short,normal,long,trace"` }
type GlobalLookupFactory ¶
type GlobalLookupFactory struct { zdns.BaseGlobalLookupFactory IterativeCache cachehash.ShardedCacheHash DNSType uint16 DNSClass uint16 BlacklistPath string Blacklist *blacklist.Blacklist BlMu sync.Mutex }
func (*GlobalLookupFactory) AddCachedAnswer ¶
func (*GlobalLookupFactory) AddFlags ¶
func (s *GlobalLookupFactory) AddFlags(f *flag.FlagSet)
func (*GlobalLookupFactory) BlacklistInit ¶
func (s *GlobalLookupFactory) BlacklistInit() error
func (*GlobalLookupFactory) GetCachedResult ¶
func (*GlobalLookupFactory) Help ¶
func (s *GlobalLookupFactory) Help() string
func (*GlobalLookupFactory) Initialize ¶
func (s *GlobalLookupFactory) Initialize(c *zdns.GlobalConf) error
func (*GlobalLookupFactory) MakeRoutineFactory ¶
func (s *GlobalLookupFactory) MakeRoutineFactory(threadID int) (zdns.RoutineLookupFactory, error)
func (*GlobalLookupFactory) SetDNSClass ¶
func (s *GlobalLookupFactory) SetDNSClass(dnsClass uint16)
func (*GlobalLookupFactory) SetDNSType ¶
func (s *GlobalLookupFactory) SetDNSType(dnsType uint16)
func (*GlobalLookupFactory) VerboseGlobalLog ¶
func (s *GlobalLookupFactory) VerboseGlobalLog(depth int, threadID int, args ...interface{})
type Lookup ¶
type Lookup struct { zdns.BaseLookup Factory *RoutineLookupFactory DNSType uint16 DNSClass uint16 Prefix string NameServer string IterativeStop time.Time }
func (*Lookup) DoMiekgLookup ¶
func (*Lookup) DoMiekgLookupForClass ¶
func (*Lookup) DoTxtLookup ¶
func (*Lookup) DoTypedMiekgLookup ¶
func (*Lookup) DoTypedMiekgLookupInClass ¶
func (*Lookup) Initialize ¶
func (*Lookup) SafeAddCachedAnswer ¶
func (*Lookup) VerboseLog ¶
type NAPTRAnswer ¶
type NAPTRAnswer struct { Answer Order uint16 `json:"order" groups:"short,normal,long,trace"` Preference uint16 `json:"preference" groups:"short,normal,long,trace"` Flags string `json:"flags" groups:"short,normal,long,trace"` Service string `json:"service" groups:"short,normal,long,trace"` Regexp string `json:"regexp" groups:"short,normal,long,trace"` Replacement string `json:"replacement" groups:"short,normal,long,trace"` }
type NSEC3Answer ¶
type NSEC3Answer struct { Answer HashAlgorithm uint8 `json:"hash_algorithm" groups:"short,normal,long,trace"` Flags uint8 `json:"flags" groups:"short,normal,long,trace"` Iterations uint16 `json:"iterations" groups:"short,normal,long,trace"` Salt string `json:"salt" groups:"short,normal,long,trace"` }
type NSEC3ParamAnswer ¶
type NSEC3ParamAnswer struct { Answer HashAlgorithm uint8 `json:"hash_algorithm" groups:"short,normal,long,trace"` Flags uint8 `json:"flags" groups:"short,normal,long,trace"` Iterations uint16 `json:"iterations" groups:"short,normal,long,trace"` Salt string `json:"salt" groups:"short,normal,long,trace"` }
type NSECAnswer ¶
type NSECAnswer struct {
Answer
}
type RRSIGAnswer ¶
type RRSIGAnswer struct { Answer TypeCovered uint16 `json:"type_covered" groups:"short,normal,long,trace"` Algorithm uint8 `json:"algorithm" groups:"short,normal,long,trace"` Labels uint8 `json:"labels" groups:"short,normal,long,trace"` OriginalTtl uint32 `json:"original_ttl" groups:"short,normal,long,trace"` Expiration uint32 `json:"expiration" groups:"short,normal,long,trace"` Inception uint32 `json:"inception" groups:"short,normal,long,trace"` KeyTag uint16 `json:"keytag" groups:"short,normal,long,trace"` SignerName string `json:"signer_name" groups:"short,normal,long,trace"` Signature string `json:"signature" groups:"short,normal,long,trace"` }
type Result ¶
type Result struct { Answers []interface{} `json:"answers" groups:"short,normal,long,trace"` Additional []interface{} `json:"additionals" groups:"short,normal,long,trace"` Authorities []interface{} `json:"authorities" groups:"short,normal,long,trace"` Protocol string `json:"protocol" groups:"protocol,normal,long,trace"` Resolver string `json:"resolver" groups:"resolver,normal,long,trace"` Flags DNSFlags `json:"flags" groups:"flags,long,trace"` }
result to be returned by scan of host
type RoutineLookupFactory ¶
type RoutineLookupFactory struct { Factory *GlobalLookupFactory Client *dns.Client TCPClient *dns.Client Retries int MaxDepth int Timeout time.Duration IterativeTimeout time.Duration IterativeResolution bool Trace bool DNSType uint16 DNSClass uint16 ThreadID int }
func (*RoutineLookupFactory) Initialize ¶
func (s *RoutineLookupFactory) Initialize(c *zdns.GlobalConf)
func (*RoutineLookupFactory) MakeLookup ¶
func (s *RoutineLookupFactory) MakeLookup() (zdns.Lookup, error)
type SOAAnswer ¶
type SOAAnswer struct { Answer Ns string `json:"ns" groups:"short,normal,long,trace"` Mbox string `json:"mbox" groups:"short,normal,long,trace"` Serial uint32 `json:"serial" groups:"short,normal,long,trace"` Refresh uint32 `json:"refresh" groups:"short,normal,long,trace"` Retry uint32 `json:"retry" groups:"short,normal,long,trace"` Expire uint32 `json:"expire" groups:"short,normal,long,trace"` Minttl uint32 `json:"min_ttl" groups:"short,normal,long,trace"` }
type TLSAAnswer ¶
type TLSAAnswer struct { Answer CertUsage uint8 `json:"cert_usage" groups:"short,normal,long,trace"` Selector uint8 `json:"selector" groups:"short,normal,long,trace"` MatchingType uint8 `json:"matching_type" groups:"short,normal,long,trace"` Certificate string `json:"certificate" groups:"short,normal,long,trace"` }
type TimedAnswer ¶
type TraceStep ¶
type TraceStep struct { Result Result `json:"results" groups:"trace"` DnsType uint16 `json:"type" groups:"trace"` DnsClass uint16 `json:"class" groups:"trace"` Name string `json:"name" groups:"trace"` NameServer string `json:"name_server" groups:"trace"` Depth int `json:"depth" groups:"trace"` Layer string `json:"layer" groups:"trace"` Cached IsCached `json:"cached" groups:"trace"` }
Click to show internal directories.
Click to hide internal directories.