Documentation
¶
Overview ¶
Package filter provides connection filtering by domain and IP.
Index ¶
- type Filter
- func (f *Filter) AddDomains(domains []string)
- func (f *Filter) AddIPs(ips []string)
- func (f *Filter) AllowHost(host string) bool
- func (f *Filter) IsEnabled() bool
- func (f *Filter) RemoveDomain(domain string)
- func (f *Filter) SetAllowlist(domains []string, ips []string)
- func (f *Filter) SetEnabled(enabled bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Filter ¶
type Filter struct {
// contains filtered or unexported fields
}
Filter manages domain and IP allowlists.
func (*Filter) AddDomains ¶
AddDomains adds domains to the allowlist.
func (*Filter) RemoveDomain ¶
RemoveDomain removes a domain from the allowlist.
func (*Filter) SetAllowlist ¶
SetAllowlist sets the domain and IP allowlists.
func (*Filter) SetEnabled ¶
SetEnabled enables or disables the filter.
Click to show internal directories.
Click to hide internal directories.