vpp_nat

package
v3.5.0 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2023 License: Apache-2.0 Imports: 9 Imported by: 11

Documentation

Index

Constants

View Source
const (
	// InvalidKeyPart is used in key for parts which are invalid
	InvalidKeyPart = "<invalid>"
)
View Source
const ModuleName = "vpp.nat"

ModuleName is the module name used for models.

View Source
const (
	// key derived when NAT44 is configured in the endpoint-dependent mode
	Nat44EndpointDepKey = "vpp/nat44/endpoint-dependent"
)
View Source
const (

	// TwiceNATDerivedKeyPrefix is common prefix for (derived) keys each representing twiceNAT address pool
	TwiceNATDerivedKeyPrefix = "vpp/nat44/twiceNAT-pool/"
)

Variables

View Source
var (
	ModelNat44Global = models.Register(&Nat44Global{}, models.Spec{
		Module:  ModuleName,
		Type:    "nat44-global",
		Version: "v2",
	})

	ModelDNat44 = models.Register(&DNat44{}, models.Spec{
		Module:  ModuleName,
		Type:    "dnat44",
		Version: "v2",
	}, models.WithNameTemplate("{{.Label}}"))

	ModelNat44Interface = models.Register(&Nat44Interface{}, models.Spec{
		Module:  ModuleName,
		Type:    "nat44-interface",
		Version: "v2",
	}, models.WithNameTemplate("{{.Name}}"))

	ModelNat44AddressPool = models.Register(&Nat44AddressPool{}, models.Spec{
		Module:  ModuleName,
		Type:    "nat44-pool",
		Version: "v2",
	}, models.WithNameTemplate(
		"{{if .Name}}"+
			"{{.Name}}"+
			"{{else}}"+
			"vrf/{{.VrfId}}"+
			"/address/{{.FirstIp}}"+
			"{{if and .LastIp (ne .FirstIp .LastIp)}}-{{.LastIp}}{{end}}"+
			"{{end}}",
	))
)
View Source
var (
	DNat44_Protocol_name = map[int32]string{
		0: "TCP",
		1: "UDP",
		2: "ICMP",
	}
	DNat44_Protocol_value = map[string]int32{
		"TCP":  0,
		"UDP":  1,
		"ICMP": 2,
	}
)

Enum value maps for DNat44_Protocol.

View Source
var (
	DNat44_StaticMapping_TwiceNatMode_name = map[int32]string{
		0: "DISABLED",
		1: "ENABLED",
		2: "SELF",
	}
	DNat44_StaticMapping_TwiceNatMode_value = map[string]int32{
		"DISABLED": 0,
		"ENABLED":  1,
		"SELF":     2,
	}
)

Enum value maps for DNat44_StaticMapping_TwiceNatMode.

View Source
var File_ligato_vpp_nat_nat_proto protoreflect.FileDescriptor

Functions

func DNAT44Key

func DNAT44Key(label string) string

DNAT44Key returns the key used in NB DB to store the configuration of the given DNAT-44 configuration.

func DerivedAddressNAT44Key

func DerivedAddressNAT44Key(address string, twiceNat bool) string

DerivedAddressNAT44Key returns (derived) key representing NAT44 configuration for a single IP address from the NAT44 address pool. Address is inserted into the key without validation!

func DerivedInterfaceNAT44Key

func DerivedInterfaceNAT44Key(iface string, isInside bool) string

DerivedInterfaceNAT44Key returns (derived) key representing NAT44 configuration for a given interface.

func DerivedTwiceNATAddressPoolKey added in v3.2.0

func DerivedTwiceNATAddressPoolKey(firstIP, lastIP string, vrfID uint32) (key string)

DerivedTwiceNATAddressPoolKey returns (derived) key representing TwiceNAT address pool configuration.

func GlobalNAT44Key

func GlobalNAT44Key() string

GlobalNAT44Key returns key for Nat44Global.

func Nat44InterfaceKey

func Nat44InterfaceKey(name string) string

Nat44InterfaceKey returns the key used in NB DB to store the configuration of the given NAT44 interface.

func ParseDerivedAddressNAT44Key

func ParseDerivedAddressNAT44Key(key string) (address string, twiceNat bool, isAddressNAT44Key bool)

ParseDerivedAddressNAT44Key parses configuration of a single NAT44 address from a key returned by DerivedAddressNAT44Key().

func ParseDerivedInterfaceNAT44Key

func ParseDerivedInterfaceNAT44Key(key string) (iface string, isInside bool, isInterfaceNAT44Key bool)

ParseDerivedInterfaceNAT44Key parses interface name and the assigned NAT44 feature from Interface-NAT44 key.

func ParseDerivedTwiceNATAddressPoolKey added in v3.2.0

func ParseDerivedTwiceNATAddressPoolKey(key string) (firstIP, lastIP string, vrfID uint32, isTwiceNatKey bool)

ParseDerivedTwiceNATAddressPoolKey parses configuration of a twiceNAT address pool from a key returned by DerivedTwiceNATAddressPoolKey().

Types

type DNat44

type DNat44 struct {

	// Unique identifier for the DNAT configuration.
	Label string `protobuf:"bytes,1,opt,name=label,proto3" json:"label,omitempty"`
	// A list of static mappings in DNAT.
	StMappings []*DNat44_StaticMapping `protobuf:"bytes,2,rep,name=st_mappings,json=stMappings,proto3" json:"st_mappings,omitempty"`
	// A list of identity mappings in DNAT.
	IdMappings []*DNat44_IdentityMapping `protobuf:"bytes,3,rep,name=id_mappings,json=idMappings,proto3" json:"id_mappings,omitempty"`
	// contains filtered or unexported fields
}

DNat44 defines destination NAT44 configuration.

func (*DNat44) Descriptor deprecated

func (*DNat44) Descriptor() ([]byte, []int)

Deprecated: Use DNat44.ProtoReflect.Descriptor instead.

func (*DNat44) GetIdMappings

func (x *DNat44) GetIdMappings() []*DNat44_IdentityMapping

func (*DNat44) GetLabel

func (x *DNat44) GetLabel() string

func (*DNat44) GetStMappings

func (x *DNat44) GetStMappings() []*DNat44_StaticMapping

func (*DNat44) ProtoMessage

func (*DNat44) ProtoMessage()

func (*DNat44) ProtoReflect added in v3.2.0

func (x *DNat44) ProtoReflect() protoreflect.Message

func (*DNat44) Reset

func (x *DNat44) Reset()

func (*DNat44) String

func (x *DNat44) String() string

type DNat44_IdentityMapping

type DNat44_IdentityMapping struct {

	// VRF (table) ID. Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto).
	VrfId uint32 `protobuf:"varint,1,opt,name=vrf_id,json=vrfId,proto3" json:"vrf_id,omitempty"`
	// Name of the interface to use address from; preferred over ip_address.
	Interface string `protobuf:"bytes,2,opt,name=interface,proto3" json:"interface,omitempty"`
	// IP address.
	IpAddress string `protobuf:"bytes,3,opt,name=ip_address,json=ipAddress,proto3" json:"ip_address,omitempty"`
	// Port (do not set for address mapping).
	Port uint32 `protobuf:"varint,4,opt,name=port,proto3" json:"port,omitempty"`
	// Protocol used for identity mapping.
	Protocol DNat44_Protocol `protobuf:"varint,5,opt,name=protocol,proto3,enum=ligato.vpp.nat.DNat44_Protocol" json:"protocol,omitempty"`
	// contains filtered or unexported fields
}

IdentityMapping defines an identity mapping in DNAT.

func (*DNat44_IdentityMapping) Descriptor deprecated

func (*DNat44_IdentityMapping) Descriptor() ([]byte, []int)

Deprecated: Use DNat44_IdentityMapping.ProtoReflect.Descriptor instead.

func (*DNat44_IdentityMapping) GetInterface

func (x *DNat44_IdentityMapping) GetInterface() string

func (*DNat44_IdentityMapping) GetIpAddress

func (x *DNat44_IdentityMapping) GetIpAddress() string

func (*DNat44_IdentityMapping) GetPort

func (x *DNat44_IdentityMapping) GetPort() uint32

func (*DNat44_IdentityMapping) GetProtocol

func (x *DNat44_IdentityMapping) GetProtocol() DNat44_Protocol

func (*DNat44_IdentityMapping) GetVrfId

func (x *DNat44_IdentityMapping) GetVrfId() uint32

func (*DNat44_IdentityMapping) ProtoMessage

func (*DNat44_IdentityMapping) ProtoMessage()

func (*DNat44_IdentityMapping) ProtoReflect added in v3.2.0

func (x *DNat44_IdentityMapping) ProtoReflect() protoreflect.Message

func (*DNat44_IdentityMapping) Reset

func (x *DNat44_IdentityMapping) Reset()

func (*DNat44_IdentityMapping) String

func (x *DNat44_IdentityMapping) String() string

type DNat44_Protocol

type DNat44_Protocol int32

Available protocols.

const (
	DNat44_TCP DNat44_Protocol = 0
	DNat44_UDP DNat44_Protocol = 1
	// ICMP is not permitted for load balanced entries.
	DNat44_ICMP DNat44_Protocol = 2
)

func (DNat44_Protocol) Descriptor added in v3.2.0

func (DNat44_Protocol) Enum added in v3.2.0

func (x DNat44_Protocol) Enum() *DNat44_Protocol

func (DNat44_Protocol) EnumDescriptor deprecated

func (DNat44_Protocol) EnumDescriptor() ([]byte, []int)

Deprecated: Use DNat44_Protocol.Descriptor instead.

func (DNat44_Protocol) Number added in v3.2.0

func (DNat44_Protocol) String

func (x DNat44_Protocol) String() string

func (DNat44_Protocol) Type added in v3.2.0

type DNat44_StaticMapping

type DNat44_StaticMapping struct {

	// Interface to use external IP from; preferred over external_ip.
	ExternalInterface string `protobuf:"bytes,1,opt,name=external_interface,json=externalInterface,proto3" json:"external_interface,omitempty"`
	// External address.
	ExternalIp string `protobuf:"bytes,2,opt,name=external_ip,json=externalIp,proto3" json:"external_ip,omitempty"`
	// Port (do not set for address mapping).
	ExternalPort uint32 `protobuf:"varint,3,opt,name=external_port,json=externalPort,proto3" json:"external_port,omitempty"`
	// List of local IP addresses. If there is more than one entry, load-balancing is enabled.
	LocalIps []*DNat44_StaticMapping_LocalIP `protobuf:"bytes,4,rep,name=local_ips,json=localIps,proto3" json:"local_ips,omitempty"`
	// Protocol used for static mapping.
	Protocol DNat44_Protocol `protobuf:"varint,5,opt,name=protocol,proto3,enum=ligato.vpp.nat.DNat44_Protocol" json:"protocol,omitempty"`
	// Enable/disable (self-)twice NAT.
	TwiceNat DNat44_StaticMapping_TwiceNatMode `` /* 140-byte string literal not displayed */
	// IP address from Twice-NAT address pool that should be used as source IP in twice-NAT processing.
	// This is override for default behaviour of choosing the first IP address from twice-NAT pool that
	// has available at least one free port (NAT is tracking translation sessions and exhausts free ports
	// for given IP address). This is needed for example in use cases when multiple twice-NAT
	// translations need to use different IP Addresses as source IP addresses.
	// This functionality works with VPP 20.09 and newer. It also needs to have twice_nat set to ENABLED.
	// It doesn't work for load-balanced static mappings (=local_ips has multiple values).
	TwiceNatPoolIp string `protobuf:"bytes,8,opt,name=twice_nat_pool_ip,json=twiceNatPoolIp,proto3" json:"twice_nat_pool_ip,omitempty"`
	// Session affinity. 0 means disabled, otherwise client IP affinity sticky time in seconds.
	SessionAffinity uint32 `protobuf:"varint,7,opt,name=session_affinity,json=sessionAffinity,proto3" json:"session_affinity,omitempty"`
	// contains filtered or unexported fields
}

StaticMapping defines a list of static mappings in DNAT.

func (*DNat44_StaticMapping) Descriptor deprecated

func (*DNat44_StaticMapping) Descriptor() ([]byte, []int)

Deprecated: Use DNat44_StaticMapping.ProtoReflect.Descriptor instead.

func (*DNat44_StaticMapping) GetExternalInterface

func (x *DNat44_StaticMapping) GetExternalInterface() string

func (*DNat44_StaticMapping) GetExternalIp

func (x *DNat44_StaticMapping) GetExternalIp() string

func (*DNat44_StaticMapping) GetExternalPort

func (x *DNat44_StaticMapping) GetExternalPort() uint32

func (*DNat44_StaticMapping) GetLocalIps

func (*DNat44_StaticMapping) GetProtocol

func (x *DNat44_StaticMapping) GetProtocol() DNat44_Protocol

func (*DNat44_StaticMapping) GetSessionAffinity

func (x *DNat44_StaticMapping) GetSessionAffinity() uint32

func (*DNat44_StaticMapping) GetTwiceNat

func (*DNat44_StaticMapping) GetTwiceNatPoolIp added in v3.2.0

func (x *DNat44_StaticMapping) GetTwiceNatPoolIp() string

func (*DNat44_StaticMapping) ProtoMessage

func (*DNat44_StaticMapping) ProtoMessage()

func (*DNat44_StaticMapping) ProtoReflect added in v3.2.0

func (x *DNat44_StaticMapping) ProtoReflect() protoreflect.Message

func (*DNat44_StaticMapping) Reset

func (x *DNat44_StaticMapping) Reset()

func (*DNat44_StaticMapping) String

func (x *DNat44_StaticMapping) String() string

type DNat44_StaticMapping_LocalIP

type DNat44_StaticMapping_LocalIP struct {

	// VRF (table) ID. Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto).
	VrfId uint32 `protobuf:"varint,1,opt,name=vrf_id,json=vrfId,proto3" json:"vrf_id,omitempty"`
	// Local IP address).
	LocalIp string `protobuf:"bytes,2,opt,name=local_ip,json=localIp,proto3" json:"local_ip,omitempty"`
	// Port (do not set for address mapping).
	LocalPort uint32 `protobuf:"varint,3,opt,name=local_port,json=localPort,proto3" json:"local_port,omitempty"`
	// Probability level for load-balancing mode.
	Probability uint32 `protobuf:"varint,4,opt,name=probability,proto3" json:"probability,omitempty"`
	// contains filtered or unexported fields
}

LocalIP defines a local IP addresses.

func (*DNat44_StaticMapping_LocalIP) Descriptor deprecated

func (*DNat44_StaticMapping_LocalIP) Descriptor() ([]byte, []int)

Deprecated: Use DNat44_StaticMapping_LocalIP.ProtoReflect.Descriptor instead.

func (*DNat44_StaticMapping_LocalIP) GetLocalIp

func (x *DNat44_StaticMapping_LocalIP) GetLocalIp() string

func (*DNat44_StaticMapping_LocalIP) GetLocalPort

func (x *DNat44_StaticMapping_LocalIP) GetLocalPort() uint32

func (*DNat44_StaticMapping_LocalIP) GetProbability

func (x *DNat44_StaticMapping_LocalIP) GetProbability() uint32

func (*DNat44_StaticMapping_LocalIP) GetVrfId

func (x *DNat44_StaticMapping_LocalIP) GetVrfId() uint32

func (*DNat44_StaticMapping_LocalIP) ProtoMessage

func (*DNat44_StaticMapping_LocalIP) ProtoMessage()

func (*DNat44_StaticMapping_LocalIP) ProtoReflect added in v3.2.0

func (*DNat44_StaticMapping_LocalIP) Reset

func (x *DNat44_StaticMapping_LocalIP) Reset()

func (*DNat44_StaticMapping_LocalIP) String

type DNat44_StaticMapping_TwiceNatMode

type DNat44_StaticMapping_TwiceNatMode int32

Available twice-NAT modes.

const (
	DNat44_StaticMapping_DISABLED DNat44_StaticMapping_TwiceNatMode = 0
	DNat44_StaticMapping_ENABLED  DNat44_StaticMapping_TwiceNatMode = 1
	DNat44_StaticMapping_SELF     DNat44_StaticMapping_TwiceNatMode = 2
)

func (DNat44_StaticMapping_TwiceNatMode) Descriptor added in v3.2.0

func (DNat44_StaticMapping_TwiceNatMode) Enum added in v3.2.0

func (DNat44_StaticMapping_TwiceNatMode) EnumDescriptor deprecated

func (DNat44_StaticMapping_TwiceNatMode) EnumDescriptor() ([]byte, []int)

Deprecated: Use DNat44_StaticMapping_TwiceNatMode.Descriptor instead.

func (DNat44_StaticMapping_TwiceNatMode) Number added in v3.2.0

func (DNat44_StaticMapping_TwiceNatMode) String

func (DNat44_StaticMapping_TwiceNatMode) Type added in v3.2.0

type Nat44AddressPool

type Nat44AddressPool struct {

	// Unique name for address pool
	Name string `protobuf:"bytes,5,opt,name=name,proto3" json:"name,omitempty"`
	// VRF id of tenant, 0xFFFFFFFF means independent of VRF.
	// Non-zero (and not all-ones) VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto).
	VrfId uint32 `protobuf:"varint,1,opt,name=vrf_id,json=vrfId,proto3" json:"vrf_id,omitempty"`
	// First IP address of the pool.
	FirstIp string `protobuf:"bytes,2,opt,name=first_ip,json=firstIp,proto3" json:"first_ip,omitempty"`
	// Last IP address of the pool. Should be higher than first_ip or empty.
	LastIp string `protobuf:"bytes,3,opt,name=last_ip,json=lastIp,proto3" json:"last_ip,omitempty"`
	// Enable/disable twice NAT.
	TwiceNat bool `protobuf:"varint,4,opt,name=twice_nat,json=twiceNat,proto3" json:"twice_nat,omitempty"`
	// contains filtered or unexported fields
}

Nat44AddressPool defines an address pool used for NAT44.

func (*Nat44AddressPool) Descriptor deprecated

func (*Nat44AddressPool) Descriptor() ([]byte, []int)

Deprecated: Use Nat44AddressPool.ProtoReflect.Descriptor instead.

func (*Nat44AddressPool) GetFirstIp

func (x *Nat44AddressPool) GetFirstIp() string

func (*Nat44AddressPool) GetLastIp

func (x *Nat44AddressPool) GetLastIp() string

func (*Nat44AddressPool) GetName added in v3.2.0

func (x *Nat44AddressPool) GetName() string

func (*Nat44AddressPool) GetTwiceNat

func (x *Nat44AddressPool) GetTwiceNat() bool

func (*Nat44AddressPool) GetVrfId

func (x *Nat44AddressPool) GetVrfId() uint32

func (*Nat44AddressPool) ProtoMessage

func (*Nat44AddressPool) ProtoMessage()

func (*Nat44AddressPool) ProtoReflect added in v3.2.0

func (x *Nat44AddressPool) ProtoReflect() protoreflect.Message

func (*Nat44AddressPool) Reset

func (x *Nat44AddressPool) Reset()

func (*Nat44AddressPool) String

func (x *Nat44AddressPool) String() string

type Nat44Global

type Nat44Global struct {

	// Enable/disable forwarding. By default it is disabled.
	Forwarding bool `protobuf:"varint,1,opt,name=forwarding,proto3" json:"forwarding,omitempty"`
	// Enable/disable endpoint-independent mode.
	// In endpoint-independent (also known as "simple") mode the VPP NAT plugin holds
	// less information for each session, but only works with outbound NAT and static mappings.
	// In endpoint-dependent mode, which ligato selects as the default, the VPP NAT plugin uses
	// more information to track each session, which in turn enables additional features
	// such as out-to-in-only and twice-nat.
	// In older versions of VPP (<= 20.09) this field is ignored because mode at which the NAT44 plugin
	// operates is given by the VPP startup configuration file (i.e. config created before VPP even starts,
	// therefore not managed by ligato). The endpoint-independent mode is the default and the dependent mode
	// is turned on with this config stanza (included in vpp.conf used by ligato for older VPPs):
	//     nat {
	//         endpoint-dependent
	//     }
	EndpointIndependent bool `protobuf:"varint,5,opt,name=endpoint_independent,json=endpointIndependent,proto3" json:"endpoint_independent,omitempty"`
	// List of NAT-enabled interfaces. Deprecated - use separate Nat44Interface entries instead.
	//
	// Deprecated: Do not use.
	NatInterfaces []*Nat44Global_Interface `protobuf:"bytes,2,rep,name=nat_interfaces,json=natInterfaces,proto3" json:"nat_interfaces,omitempty"`
	// Address pool used for source IP NAT. Deprecated - use separate Nat44AddressPool entries instead.
	//
	// Deprecated: Do not use.
	AddressPool []*Nat44Global_Address `protobuf:"bytes,3,rep,name=address_pool,json=addressPool,proto3" json:"address_pool,omitempty"`
	// Virtual reassembly for IPv4.
	VirtualReassembly *VirtualReassembly `protobuf:"bytes,4,opt,name=virtual_reassembly,json=virtualReassembly,proto3" json:"virtual_reassembly,omitempty"`
	// contains filtered or unexported fields
}

Nat44Global defines global NAT44 configuration. In VPP version 21.01 and newer the NAT44 plugin has to be explicitly enabled (by default it is disabled so that it doesn't consume any computational resources). With ligato control-plane the NAT44 plugin is enabled by submitting the NAT44Global configuration (even default values will make the plugin enabled). Without Nat44Global, all other NAT44 configuration items (DNat44, Nat44Interface and Nat44AddressPool) will be in the PENDING state.

func (*Nat44Global) Descriptor deprecated

func (*Nat44Global) Descriptor() ([]byte, []int)

Deprecated: Use Nat44Global.ProtoReflect.Descriptor instead.

func (*Nat44Global) GetAddressPool deprecated

func (x *Nat44Global) GetAddressPool() []*Nat44Global_Address

Deprecated: Do not use.

func (*Nat44Global) GetEndpointIndependent added in v3.3.0

func (x *Nat44Global) GetEndpointIndependent() bool

func (*Nat44Global) GetForwarding

func (x *Nat44Global) GetForwarding() bool

func (*Nat44Global) GetNatInterfaces deprecated

func (x *Nat44Global) GetNatInterfaces() []*Nat44Global_Interface

Deprecated: Do not use.

func (*Nat44Global) GetVirtualReassembly

func (x *Nat44Global) GetVirtualReassembly() *VirtualReassembly

func (*Nat44Global) ProtoMessage

func (*Nat44Global) ProtoMessage()

func (*Nat44Global) ProtoReflect added in v3.2.0

func (x *Nat44Global) ProtoReflect() protoreflect.Message

func (*Nat44Global) Reset

func (x *Nat44Global) Reset()

func (*Nat44Global) String

func (x *Nat44Global) String() string

type Nat44Global_Address

type Nat44Global_Address struct {

	// IPv4 address.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// VRF id of tenant, 0xFFFFFFFF means independent of VRF.
	// Non-zero (and not all-ones) VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto).
	VrfId uint32 `protobuf:"varint,2,opt,name=vrf_id,json=vrfId,proto3" json:"vrf_id,omitempty"`
	// Enable/disable twice NAT.
	TwiceNat bool `protobuf:"varint,3,opt,name=twice_nat,json=twiceNat,proto3" json:"twice_nat,omitempty"`
	// contains filtered or unexported fields
}

Address defines an address to be used for source IP NAT.

func (*Nat44Global_Address) Descriptor deprecated

func (*Nat44Global_Address) Descriptor() ([]byte, []int)

Deprecated: Use Nat44Global_Address.ProtoReflect.Descriptor instead.

func (*Nat44Global_Address) GetAddress

func (x *Nat44Global_Address) GetAddress() string

func (*Nat44Global_Address) GetTwiceNat

func (x *Nat44Global_Address) GetTwiceNat() bool

func (*Nat44Global_Address) GetVrfId

func (x *Nat44Global_Address) GetVrfId() uint32

func (*Nat44Global_Address) ProtoMessage

func (*Nat44Global_Address) ProtoMessage()

func (*Nat44Global_Address) ProtoReflect added in v3.2.0

func (x *Nat44Global_Address) ProtoReflect() protoreflect.Message

func (*Nat44Global_Address) Reset

func (x *Nat44Global_Address) Reset()

func (*Nat44Global_Address) String

func (x *Nat44Global_Address) String() string

type Nat44Global_Interface

type Nat44Global_Interface struct {

	// Interface name (logical).
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Distinguish between inside/outside interface.
	IsInside bool `protobuf:"varint,2,opt,name=is_inside,json=isInside,proto3" json:"is_inside,omitempty"`
	// Enable/disable output feature.
	OutputFeature bool `protobuf:"varint,3,opt,name=output_feature,json=outputFeature,proto3" json:"output_feature,omitempty"`
	// contains filtered or unexported fields
}

Interface defines a network interface enabled for NAT.

func (*Nat44Global_Interface) Descriptor deprecated

func (*Nat44Global_Interface) Descriptor() ([]byte, []int)

Deprecated: Use Nat44Global_Interface.ProtoReflect.Descriptor instead.

func (*Nat44Global_Interface) GetIsInside

func (x *Nat44Global_Interface) GetIsInside() bool

func (*Nat44Global_Interface) GetName

func (x *Nat44Global_Interface) GetName() string

func (*Nat44Global_Interface) GetOutputFeature

func (x *Nat44Global_Interface) GetOutputFeature() bool

func (*Nat44Global_Interface) ProtoMessage

func (*Nat44Global_Interface) ProtoMessage()

func (*Nat44Global_Interface) ProtoReflect added in v3.2.0

func (x *Nat44Global_Interface) ProtoReflect() protoreflect.Message

func (*Nat44Global_Interface) Reset

func (x *Nat44Global_Interface) Reset()

func (*Nat44Global_Interface) String

func (x *Nat44Global_Interface) String() string

type Nat44Interface

type Nat44Interface struct {

	// Interface name (logical).
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Enable/disable NAT on inside.
	NatInside bool `protobuf:"varint,2,opt,name=nat_inside,json=natInside,proto3" json:"nat_inside,omitempty"`
	// Enable/disable NAT on outside.
	NatOutside bool `protobuf:"varint,3,opt,name=nat_outside,json=natOutside,proto3" json:"nat_outside,omitempty"`
	//  Enable/disable output feature.
	OutputFeature bool `protobuf:"varint,4,opt,name=output_feature,json=outputFeature,proto3" json:"output_feature,omitempty"`
	// contains filtered or unexported fields
}

Nat44Interface defines a local network interfaces enabled for NAT44.

func (*Nat44Interface) Descriptor deprecated

func (*Nat44Interface) Descriptor() ([]byte, []int)

Deprecated: Use Nat44Interface.ProtoReflect.Descriptor instead.

func (*Nat44Interface) GetName

func (x *Nat44Interface) GetName() string

func (*Nat44Interface) GetNatInside

func (x *Nat44Interface) GetNatInside() bool

func (*Nat44Interface) GetNatOutside

func (x *Nat44Interface) GetNatOutside() bool

func (*Nat44Interface) GetOutputFeature

func (x *Nat44Interface) GetOutputFeature() bool

func (*Nat44Interface) ProtoMessage

func (*Nat44Interface) ProtoMessage()

func (*Nat44Interface) ProtoReflect added in v3.2.0

func (x *Nat44Interface) ProtoReflect() protoreflect.Message

func (*Nat44Interface) Reset

func (x *Nat44Interface) Reset()

func (*Nat44Interface) String

func (x *Nat44Interface) String() string

type VirtualReassembly

type VirtualReassembly struct {

	// Reassembly timeout.
	Timeout uint32 `protobuf:"varint,1,opt,name=timeout,proto3" json:"timeout,omitempty"`
	// Maximum number of concurrent reassemblies.
	MaxReassemblies uint32 `protobuf:"varint,2,opt,name=max_reassemblies,json=maxReassemblies,proto3" json:"max_reassemblies,omitempty"`
	// Maximum number of fragments per reassembly.
	MaxFragments uint32 `protobuf:"varint,3,opt,name=max_fragments,json=maxFragments,proto3" json:"max_fragments,omitempty"`
	// If set to true fragments are dropped, translated otherwise.
	DropFragments bool `protobuf:"varint,4,opt,name=drop_fragments,json=dropFragments,proto3" json:"drop_fragments,omitempty"`
	// contains filtered or unexported fields
}

VirtualReassembly defines NAT virtual reassembly settings.

func (*VirtualReassembly) Descriptor deprecated

func (*VirtualReassembly) Descriptor() ([]byte, []int)

Deprecated: Use VirtualReassembly.ProtoReflect.Descriptor instead.

func (*VirtualReassembly) GetDropFragments

func (x *VirtualReassembly) GetDropFragments() bool

func (*VirtualReassembly) GetMaxFragments

func (x *VirtualReassembly) GetMaxFragments() uint32

func (*VirtualReassembly) GetMaxReassemblies

func (x *VirtualReassembly) GetMaxReassemblies() uint32

func (*VirtualReassembly) GetTimeout

func (x *VirtualReassembly) GetTimeout() uint32

func (*VirtualReassembly) ProtoMessage

func (*VirtualReassembly) ProtoMessage()

func (*VirtualReassembly) ProtoReflect added in v3.2.0

func (x *VirtualReassembly) ProtoReflect() protoreflect.Message

func (*VirtualReassembly) Reset

func (x *VirtualReassembly) Reset()

func (*VirtualReassembly) String

func (x *VirtualReassembly) String() string

Jump to

Keyboard shortcuts

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