Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlacklistMap ¶
type BlacklistMap struct {
// contains filtered or unexported fields
}
BlacklistMap wraps a Map by checking first the requested domain against a blacklist. If the domain appears in the blacklist, no further lookups are made and a permanent error is returned.
func NewBlacklistMap ¶
func NewBlacklistMap(wrap Map) *BlacklistMap
NewBlacklistMap creates a BlacklistMap wrapping the given Map.
type Map ¶
type Map interface {
// Lookup a domain in the map. A note on error semantics: if
// the lookup is successful and the domain is not found, the
// result string will be empty and error will be nil. If there
// is an error in the lookup, error will be non-nil.
Lookup(string) (string, error)
}
Map implements a domain-based lookup table.
func NewDNSLookupMap ¶
NewDNSLookupMap returns a Map that looks up DNS SRV records and returns a result of the form transport:[SRV target].
func NewLimitMap ¶
NewLimitMap wraps a Map with overload protection based on the number of inflight requests.
type Server ¶
type Server struct {
// EnableDebug enables debug logging of every request.
EnableDebug bool
// contains filtered or unexported fields
}
Server implements the protocol described in Postfix's tcp_table(5).
Click to show internal directories.
Click to hide internal directories.