arptables

package
v0.0.0-...-e9f4c3e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 26, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Copyright 2021 The Everoute Authors.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Append

func Append(chain, table string, rulespec ...string) error

func AppendUnique

func AppendUnique(chain, table string, rule *ArpRule) error

func Delete

func Delete(chain, table string, rulespec ...string) error

func DeleteAll

func DeleteAll(chain, table string, rulespec ...string)

func Exists

func Exists(chain, table string, target *ArpRule) (bool, error)

func Flush

func Flush(chain string) error

func Insert

func Insert(chain, table string, pos int, rulespec ...string) error

func InsertUnique

func InsertUnique(chain, table string, pos int, rule *ArpRule) error

Types

type ArpRule

type ArpRule struct {
	SrcIP     string
	DstIP     string
	SrcMac    string
	DstMac    string
	HwLength  string
	OpCode    string
	HwType    string
	ProtoType string
	InIface   string
	OutIface  string
	Target    string
	Match     string
}

func List

func List(chain, table string) ([]*ArpRule, error)

func Parse

func Parse(rulespec ...string) (*ArpRule, error)

func (*ArpRule) ToSpec

func (a *ArpRule) ToSpec() []string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL