Documentation
¶
Overview ¶
Package iptables contains code for managing firewall rules. This package really only works reliably on Linux. In all other systems the functionality in here is just a set of stubs returning errors.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CensoringPolicy ¶
type CensoringPolicy struct {
DropIPs []string // drop IP traffic to these IPs
DropKeywordsHex []string // drop IP packets with these hex keywords
DropKeywords []string // drop IP packets with these keywords
HijackDNSAddress string // where to hijack DNS to
HijackHTTPSAddress string // where to hijack HTTPS to
HijackHTTPAddress string // where to hijack HTTP to
ResetIPs []string // RST TCP/IP traffic to these IPs
ResetKeywordsHex []string // RST TCP/IP flows with these hex keywords
ResetKeywords []string // RST TCP/IP flows with these keywords
// contains filtered or unexported fields
}
CensoringPolicy implements a censoring policy.
func NewCensoringPolicy ¶
func NewCensoringPolicy() *CensoringPolicy
NewCensoringPolicy returns a new censoring policy.
func (*CensoringPolicy) Apply ¶
func (c *CensoringPolicy) Apply() (err error)
Apply applies the censorship policy
func (*CensoringPolicy) Waive ¶
func (c *CensoringPolicy) Waive() error
Waive removes any censorship policy
Click to show internal directories.
Click to hide internal directories.