MCPcopy
hub / github.com/evilsocket/opensnitch / Firewall

Interface Firewall

daemon/firewall/rules.go:15–38  ·  view source on GitHub ↗

Firewall is the interface that all firewalls (iptables, nftables) must implement.

Source from the content-addressed store, hash-verified

13
14// Firewall is the interface that all firewalls (iptables, nftables) must implement.
15type Firewall interface {
16 Init(uint16, string, string, bool)
17 Stop()
18 Name() string
19 IsRunning() bool
20 SetQueueNum(num uint16)
21
22 SaveConfiguration(rawConfig string) error
23
24 EnableInterception()
25 DisableInterception(bool)
26 QueueDNSResponses(bool, bool) (error, error)
27 QueueConnections(bool, bool) (error, error)
28 CleanRules(bool)
29
30 AddSystemRules(bool, bool)
31 DeleteSystemRules(bool, bool, bool)
32
33 Serialize() (*protocol.SysFirewall, error)
34 Deserialize(sysfw *protocol.SysFirewall) ([]byte, error)
35
36 ErrorsChan() <-chan string
37 ErrChanEmpty() bool
38}
39
40var (
41 fw Firewall

Callers 54

InitFunction · 0.65
InitFunction · 0.65
StopFunction · 0.65
NewRulesCheckerMethod · 0.65
StopCheckingRulesMethod · 0.65
InitFunction · 0.65
CleanupMethod · 0.65
NewFunction · 0.65
lookupPidDescriptorsFunction · 0.65
getProcPidsFunction · 0.65
readDescriptorsMethod · 0.65
IsRunningFunction · 0.65

Calls

no outgoing calls

Tested by

no test coverage detected