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

Method String

daemon/rule/rule.go:70–76  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

68}
69
70func (r *Rule) String() string {
71 enabled := "Disabled"
72 if r.Enabled {
73 enabled = "Enabled"
74 }
75 return fmt.Sprintf("[%s] %s: if(%s){ %s %s }", enabled, r.Name, r.Operator.String(), r.Action, r.Duration)
76}
77
78// Match performs on a connection the checks a Rule has, to determine if it
79// must be allowed or denied.

Callers 15

loadRuleMethod · 0.95
acceptOrDenyFunction · 0.45
onConnectionMethod · 0.45
TrackAnswersFunction · 0.45
HostOrFunction · 0.45
dnsWorkerFunction · 0.45
AddSystemRulesMethod · 0.45
TestExprProtocolFunction · 0.45
TestExprPortFunction · 0.45
TestExprPortRangeFunction · 0.45
TestExprVerdictFunction · 0.45

Calls

no outgoing calls

Tested by 9

TestExprProtocolFunction · 0.36
TestExprPortFunction · 0.36
TestExprPortRangeFunction · 0.36
TestExprVerdictFunction · 0.36
TestExprVerdictRejectFunction · 0.36
TestExprVerdictQueueFunction · 0.36
TestExprEtherFunction · 0.36
TestExprIfaceFunction · 0.36
setupConnectionFunction · 0.36