Documentation ¶
Index ¶
- Constants
- Variables
- type Client
- func (c *Client) AppendIptableRule(version, tableName, chainName, match, target string) error
- func (c *Client) ChainExists(version, tableName, chainName string) bool
- func (c *Client) CreateChain(version, tableName, chainName string) error
- func (c *Client) DeleteIptableRule(version, tableName, chainName, match, target string) error
- func (c *Client) GetAppendIptableRuleCmd(version, tableName, chainName, match, target string) IPTableEntry
- func (c *Client) GetCreateChainCmd(version, tableName, chainName string) IPTableEntry
- func (c *Client) GetInsertIptableRuleCmd(version, tableName, chainName, match, target string) IPTableEntry
- func (c *Client) InsertIptableRule(version, tableName, chainName, match, target string) error
- func (c *Client) RuleExists(version, tableName, chainName, match, target string) bool
- func (c *Client) RunCmd(version, params string) error
- type IPTableEntry
Constants ¶
View Source
const ( CNIInputChain = "AZURECNIINPUT" CNIOutputChain = "AZURECNIOUTPUT" )
cni iptable chains
View Source
const ( Input = "INPUT" Output = "OUTPUT" Forward = "FORWARD" Prerouting = "PREROUTING" Postrouting = "POSTROUTING" Swift = "SWIFT" Snat = "SNAT" Return = "RETURN" )
standard iptable chains
View Source
const ( Filter = "filter" Nat = "nat" Mangle = "mangle" )
Standard Table names
View Source
const ( Accept = "ACCEPT" Drop = "DROP" Masquerade = "MASQUERADE" )
target
View Source
const ( Insert = "I" Append = "A" Delete = "D" )
actions
View Source
const ( Established = "ESTABLISHED" Related = "RELATED" )
states
View Source
const ( V4 = "4" V6 = "6" )
View Source
const ( DNSPort = 53 HTTPPort = 80 )
known ports
View Source
const ( UDP = "udp" TCP = "tcp" )
known protocols
Variables ¶
View Source
var DisableIPTableLock bool
Functions ¶
This section is empty.
Types ¶
type Client ¶ added in v1.5.17
type Client struct{}
func (*Client) AppendIptableRule ¶ added in v1.5.17
Append iptable rule at end of iptable chain
func (*Client) ChainExists ¶ added in v1.5.17
check if iptable chain alreay exists
func (*Client) CreateChain ¶ added in v1.5.17
create new iptable chain under specified table name
func (*Client) DeleteIptableRule ¶ added in v1.5.17
Delete matched iptable rule
func (*Client) GetAppendIptableRuleCmd ¶ added in v1.5.17
func (c *Client) GetAppendIptableRuleCmd(version, tableName, chainName, match, target string) IPTableEntry
func (*Client) GetCreateChainCmd ¶ added in v1.5.17
func (c *Client) GetCreateChainCmd(version, tableName, chainName string) IPTableEntry
func (*Client) GetInsertIptableRuleCmd ¶ added in v1.5.17
func (c *Client) GetInsertIptableRuleCmd(version, tableName, chainName, match, target string) IPTableEntry
func (*Client) InsertIptableRule ¶ added in v1.5.17
Insert iptable rule at beginning of iptable chain
func (*Client) RuleExists ¶ added in v1.5.17
check if iptable rule alreay exists
type IPTableEntry ¶
Click to show internal directories.
Click to hide internal directories.