Documentation
¶
Index ¶
- type NodeFakeIPTables
- func (f *NodeFakeIPTables) ChainExists(table iptables.Table, chain iptables.Chain) (bool, error)
- func (f *NodeFakeIPTables) DeleteChain(table iptables.Table, chain iptables.Chain) error
- func (f *NodeFakeIPTables) DeleteRule(table iptables.Table, chain iptables.Chain, args ...string) error
- func (f *NodeFakeIPTables) EnsureChain(table iptables.Table, chain iptables.Chain) (bool, error)
- func (f *NodeFakeIPTables) EnsureRule(position iptables.RulePosition, table iptables.Table, chain iptables.Chain, ...) (bool, error)
- func (f *NodeFakeIPTables) FlushChain(table iptables.Table, chain iptables.Chain) error
- func (f *NodeFakeIPTables) HasRandomFully() bool
- func (f *NodeFakeIPTables) IsIPv6() bool
- func (f *NodeFakeIPTables) IsPresent(position iptables.RulePosition, table iptables.Table, chain iptables.Chain, ...) bool
- func (f *NodeFakeIPTables) Monitor(canary iptables.Chain, tables []iptables.Table, reloadFunc func(), ...)
- func (f *NodeFakeIPTables) Present() bool
- func (f *NodeFakeIPTables) Protocol() iptables.Protocol
- func (*NodeFakeIPTables) Restore(table iptables.Table, data []byte, flush iptables.FlushFlag, ...) error
- func (f *NodeFakeIPTables) RestoreAll(data []byte, flush iptables.FlushFlag, counters iptables.RestoreCountersFlag) error
- func (f *NodeFakeIPTables) SaveInto(table iptables.Table, buffer *bytes.Buffer) error
- type NodeFakeIPTablesInterface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NodeFakeIPTables ¶
type NodeFakeIPTables struct {
// contains filtered or unexported fields
}
NodeFakeIPTables is no-op implementation of iptables Interface.
func (*NodeFakeIPTables) ChainExists ¶
ChainExists is part of iptables.Interface
func (*NodeFakeIPTables) DeleteChain ¶
DeleteChain is part of iptables.Interface
func (*NodeFakeIPTables) DeleteRule ¶
func (f *NodeFakeIPTables) DeleteRule(table iptables.Table, chain iptables.Chain, args ...string) error
DeleteRule is part of iptables.Interface
func (*NodeFakeIPTables) EnsureChain ¶
EnsureChain is part of iptables.Interface
func (*NodeFakeIPTables) EnsureRule ¶
func (f *NodeFakeIPTables) EnsureRule(position iptables.RulePosition, table iptables.Table, chain iptables.Chain, args ...string) (bool, error)
EnsureRule is part of iptables.Interface
func (*NodeFakeIPTables) FlushChain ¶
FlushChain is part of iptables.Interface
func (*NodeFakeIPTables) HasRandomFully ¶
func (f *NodeFakeIPTables) HasRandomFully() bool
HasRandomFully is part of iptables.Interface
func (*NodeFakeIPTables) IsIPv6 ¶
func (f *NodeFakeIPTables) IsIPv6() bool
IsIPv6 is part of iptables.Interface
func (*NodeFakeIPTables) IsPresent ¶
func (f *NodeFakeIPTables) IsPresent(position iptables.RulePosition, table iptables.Table, chain iptables.Chain, args ...string) bool
IsPresent is part of NodeFakeIPTablesInterface
func (*NodeFakeIPTables) Monitor ¶
func (f *NodeFakeIPTables) Monitor(canary iptables.Chain, tables []iptables.Table, reloadFunc func(), interval time.Duration, stopCh <-chan struct{})
Monitor is part of iptables.Interface
func (*NodeFakeIPTables) Present ¶
func (f *NodeFakeIPTables) Present() bool
func (*NodeFakeIPTables) Protocol ¶
func (f *NodeFakeIPTables) Protocol() iptables.Protocol
Protocol is part of iptables.Interface
func (*NodeFakeIPTables) Restore ¶
func (*NodeFakeIPTables) Restore(table iptables.Table, data []byte, flush iptables.FlushFlag, counters iptables.RestoreCountersFlag) error
Restore is part of iptables.Interface
func (*NodeFakeIPTables) RestoreAll ¶
func (f *NodeFakeIPTables) RestoreAll(data []byte, flush iptables.FlushFlag, counters iptables.RestoreCountersFlag) error
RestoreAll is part of iptables.Interface
type NodeFakeIPTablesInterface ¶
type NodeFakeIPTablesInterface interface { iptables.Interface // IsPresent checks if the given rule is present in the iptables or not. If the rule existed, return true. IsPresent(position iptables.RulePosition, table iptables.Table, chain iptables.Chain, args ...string) bool }
NodeFakeIPTablesInterface extends iptables.Interface
func NewIPv6Fake ¶
func NewIPv6Fake() NodeFakeIPTablesInterface
NewIPv6Fake returns a no-op iptables.Interface with IsIPv6() == true