aboutsummaryrefslogtreecommitdiffstats
path: root/binapi/nat44_ed/nat44_ed.ba.go
diff options
context:
space:
mode:
Diffstat (limited to 'binapi/nat44_ed/nat44_ed.ba.go')
-rw-r--r--binapi/nat44_ed/nat44_ed.ba.go4637
1 files changed, 4637 insertions, 0 deletions
diff --git a/binapi/nat44_ed/nat44_ed.ba.go b/binapi/nat44_ed/nat44_ed.ba.go
new file mode 100644
index 0000000..938940e
--- /dev/null
+++ b/binapi/nat44_ed/nat44_ed.ba.go
@@ -0,0 +1,4637 @@
+// Code generated by GoVPP's binapi-generator. DO NOT EDIT.
+// versions:
+// binapi-generator: v0.6.0-dev
+// VPP: 22.02-release
+// source: /usr/share/vpp/api/plugins/nat44_ed.api.json
+
+// Package nat44_ed contains generated bindings for API file nat44_ed.api.
+//
+// Contents:
+// 1 enum
+// 1 struct
+// 104 messages
+//
+package nat44_ed
+
+import (
+ "strconv"
+
+ api "go.fd.io/govpp/api"
+ interface_types "go.fd.io/govpp/binapi/interface_types"
+ ip_types "go.fd.io/govpp/binapi/ip_types"
+ nat_types "go.fd.io/govpp/binapi/nat_types"
+ codec "go.fd.io/govpp/codec"
+)
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the GoVPP api package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// GoVPP api package needs to be updated.
+const _ = api.GoVppAPIPackageIsVersion2
+
+const (
+ APIFile = "nat44_ed"
+ APIVersion = "5.4.0"
+ VersionCrc = 0x5697d0ef
+)
+
+// Nat44ConfigFlags defines enum 'nat44_config_flags'.
+type Nat44ConfigFlags uint8
+
+const (
+ NAT44_IS_ENDPOINT_INDEPENDENT Nat44ConfigFlags = 0
+ NAT44_IS_ENDPOINT_DEPENDENT Nat44ConfigFlags = 1
+ NAT44_IS_STATIC_MAPPING_ONLY Nat44ConfigFlags = 2
+ NAT44_IS_CONNECTION_TRACKING Nat44ConfigFlags = 4
+ NAT44_IS_OUT2IN_DPO Nat44ConfigFlags = 8
+)
+
+var (
+ Nat44ConfigFlags_name = map[uint8]string{
+ 0: "NAT44_IS_ENDPOINT_INDEPENDENT",
+ 1: "NAT44_IS_ENDPOINT_DEPENDENT",
+ 2: "NAT44_IS_STATIC_MAPPING_ONLY",
+ 4: "NAT44_IS_CONNECTION_TRACKING",
+ 8: "NAT44_IS_OUT2IN_DPO",
+ }
+ Nat44ConfigFlags_value = map[string]uint8{
+ "NAT44_IS_ENDPOINT_INDEPENDENT": 0,
+ "NAT44_IS_ENDPOINT_DEPENDENT": 1,
+ "NAT44_IS_STATIC_MAPPING_ONLY": 2,
+ "NAT44_IS_CONNECTION_TRACKING": 4,
+ "NAT44_IS_OUT2IN_DPO": 8,
+ }
+)
+
+func (x Nat44ConfigFlags) String() string {
+ s, ok := Nat44ConfigFlags_name[uint8(x)]
+ if ok {
+ return s
+ }
+ str := func(n uint8) string {
+ s, ok := Nat44ConfigFlags_name[uint8(n)]
+ if ok {
+ return s
+ }
+ return "Nat44ConfigFlags(" + strconv.Itoa(int(n)) + ")"
+ }
+ for i := uint8(0); i <= 8; i++ {
+ val := uint8(x)
+ if val&(1<<i) != 0 {
+ if s != "" {
+ s += "|"
+ }
+ s += str(1 << i)
+ }
+ }
+ if s == "" {
+ return str(uint8(x))
+ }
+ return s
+}
+
+// Nat44LbAddrPort defines type 'nat44_lb_addr_port'.
+type Nat44LbAddrPort struct {
+ Addr ip_types.IP4Address `binapi:"ip4_address,name=addr" json:"addr,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ Probability uint8 `binapi:"u8,name=probability" json:"probability,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+}
+
+// Nat44AddDelAddressRange defines message 'nat44_add_del_address_range'.
+type Nat44AddDelAddressRange struct {
+ FirstIPAddress ip_types.IP4Address `binapi:"ip4_address,name=first_ip_address" json:"first_ip_address,omitempty"`
+ LastIPAddress ip_types.IP4Address `binapi:"ip4_address,name=last_ip_address" json:"last_ip_address,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+}
+
+func (m *Nat44AddDelAddressRange) Reset() { *m = Nat44AddDelAddressRange{} }
+func (*Nat44AddDelAddressRange) GetMessageName() string { return "nat44_add_del_address_range" }
+func (*Nat44AddDelAddressRange) GetCrcString() string { return "6f2b8055" }
+func (*Nat44AddDelAddressRange) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddDelAddressRange) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.FirstIPAddress
+ size += 1 * 4 // m.LastIPAddress
+ size += 4 // m.VrfID
+ size += 1 // m.IsAdd
+ size += 1 // m.Flags
+ return size
+}
+func (m *Nat44AddDelAddressRange) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.FirstIPAddress[:], 4)
+ buf.EncodeBytes(m.LastIPAddress[:], 4)
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint8(uint8(m.Flags))
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelAddressRange) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.FirstIPAddress[:], buf.DecodeBytes(4))
+ copy(m.LastIPAddress[:], buf.DecodeBytes(4))
+ m.VrfID = buf.DecodeUint32()
+ m.IsAdd = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ return nil
+}
+
+// Nat44AddDelAddressRangeReply defines message 'nat44_add_del_address_range_reply'.
+type Nat44AddDelAddressRangeReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44AddDelAddressRangeReply) Reset() { *m = Nat44AddDelAddressRangeReply{} }
+func (*Nat44AddDelAddressRangeReply) GetMessageName() string {
+ return "nat44_add_del_address_range_reply"
+}
+func (*Nat44AddDelAddressRangeReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44AddDelAddressRangeReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddDelAddressRangeReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44AddDelAddressRangeReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelAddressRangeReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44AddDelIdentityMapping defines message 'nat44_add_del_identity_mapping'.
+type Nat44AddDelIdentityMapping struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+}
+
+func (m *Nat44AddDelIdentityMapping) Reset() { *m = Nat44AddDelIdentityMapping{} }
+func (*Nat44AddDelIdentityMapping) GetMessageName() string { return "nat44_add_del_identity_mapping" }
+func (*Nat44AddDelIdentityMapping) GetCrcString() string { return "02faaa22" }
+func (*Nat44AddDelIdentityMapping) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddDelIdentityMapping) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 // m.Flags
+ size += 1 * 4 // m.IPAddress
+ size += 1 // m.Protocol
+ size += 2 // m.Port
+ size += 4 // m.SwIfIndex
+ size += 4 // m.VrfID
+ size += 64 // m.Tag
+ return size
+}
+func (m *Nat44AddDelIdentityMapping) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeString(m.Tag, 64)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelIdentityMapping) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Protocol = buf.DecodeUint8()
+ m.Port = buf.DecodeUint16()
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.VrfID = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ return nil
+}
+
+// Nat44AddDelIdentityMappingReply defines message 'nat44_add_del_identity_mapping_reply'.
+type Nat44AddDelIdentityMappingReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44AddDelIdentityMappingReply) Reset() { *m = Nat44AddDelIdentityMappingReply{} }
+func (*Nat44AddDelIdentityMappingReply) GetMessageName() string {
+ return "nat44_add_del_identity_mapping_reply"
+}
+func (*Nat44AddDelIdentityMappingReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44AddDelIdentityMappingReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddDelIdentityMappingReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44AddDelIdentityMappingReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelIdentityMappingReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44AddDelInterfaceAddr defines message 'nat44_add_del_interface_addr'.
+type Nat44AddDelInterfaceAddr struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+}
+
+func (m *Nat44AddDelInterfaceAddr) Reset() { *m = Nat44AddDelInterfaceAddr{} }
+func (*Nat44AddDelInterfaceAddr) GetMessageName() string { return "nat44_add_del_interface_addr" }
+func (*Nat44AddDelInterfaceAddr) GetCrcString() string { return "4aed50c0" }
+func (*Nat44AddDelInterfaceAddr) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddDelInterfaceAddr) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 4 // m.SwIfIndex
+ size += 1 // m.Flags
+ return size
+}
+func (m *Nat44AddDelInterfaceAddr) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ buf.EncodeUint8(uint8(m.Flags))
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelInterfaceAddr) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ return nil
+}
+
+// Nat44AddDelInterfaceAddrReply defines message 'nat44_add_del_interface_addr_reply'.
+type Nat44AddDelInterfaceAddrReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44AddDelInterfaceAddrReply) Reset() { *m = Nat44AddDelInterfaceAddrReply{} }
+func (*Nat44AddDelInterfaceAddrReply) GetMessageName() string {
+ return "nat44_add_del_interface_addr_reply"
+}
+func (*Nat44AddDelInterfaceAddrReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44AddDelInterfaceAddrReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddDelInterfaceAddrReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44AddDelInterfaceAddrReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelInterfaceAddrReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44AddDelLbStaticMapping defines message 'nat44_add_del_lb_static_mapping'.
+type Nat44AddDelLbStaticMapping struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ ExternalAddr ip_types.IP4Address `binapi:"ip4_address,name=external_addr" json:"external_addr,omitempty"`
+ ExternalPort uint16 `binapi:"u16,name=external_port" json:"external_port,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ Affinity uint32 `binapi:"u32,name=affinity" json:"affinity,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+ LocalNum uint32 `binapi:"u32,name=local_num" json:"-"`
+ Locals []Nat44LbAddrPort `binapi:"nat44_lb_addr_port[local_num],name=locals" json:"locals,omitempty"`
+}
+
+func (m *Nat44AddDelLbStaticMapping) Reset() { *m = Nat44AddDelLbStaticMapping{} }
+func (*Nat44AddDelLbStaticMapping) GetMessageName() string { return "nat44_add_del_lb_static_mapping" }
+func (*Nat44AddDelLbStaticMapping) GetCrcString() string { return "4f68ee9d" }
+func (*Nat44AddDelLbStaticMapping) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddDelLbStaticMapping) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 // m.Flags
+ size += 1 * 4 // m.ExternalAddr
+ size += 2 // m.ExternalPort
+ size += 1 // m.Protocol
+ size += 4 // m.Affinity
+ size += 64 // m.Tag
+ size += 4 // m.LocalNum
+ for j1 := 0; j1 < len(m.Locals); j1++ {
+ var s1 Nat44LbAddrPort
+ _ = s1
+ if j1 < len(m.Locals) {
+ s1 = m.Locals[j1]
+ }
+ size += 1 * 4 // s1.Addr
+ size += 2 // s1.Port
+ size += 1 // s1.Probability
+ size += 4 // s1.VrfID
+ }
+ return size
+}
+func (m *Nat44AddDelLbStaticMapping) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.ExternalAddr[:], 4)
+ buf.EncodeUint16(m.ExternalPort)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint32(m.Affinity)
+ buf.EncodeString(m.Tag, 64)
+ buf.EncodeUint32(uint32(len(m.Locals)))
+ for j0 := 0; j0 < len(m.Locals); j0++ {
+ var v0 Nat44LbAddrPort // Locals
+ if j0 < len(m.Locals) {
+ v0 = m.Locals[j0]
+ }
+ buf.EncodeBytes(v0.Addr[:], 4)
+ buf.EncodeUint16(v0.Port)
+ buf.EncodeUint8(v0.Probability)
+ buf.EncodeUint32(v0.VrfID)
+ }
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelLbStaticMapping) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.ExternalAddr[:], buf.DecodeBytes(4))
+ m.ExternalPort = buf.DecodeUint16()
+ m.Protocol = buf.DecodeUint8()
+ m.Affinity = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ m.LocalNum = buf.DecodeUint32()
+ m.Locals = make([]Nat44LbAddrPort, m.LocalNum)
+ for j0 := 0; j0 < len(m.Locals); j0++ {
+ copy(m.Locals[j0].Addr[:], buf.DecodeBytes(4))
+ m.Locals[j0].Port = buf.DecodeUint16()
+ m.Locals[j0].Probability = buf.DecodeUint8()
+ m.Locals[j0].VrfID = buf.DecodeUint32()
+ }
+ return nil
+}
+
+// Nat44AddDelLbStaticMappingReply defines message 'nat44_add_del_lb_static_mapping_reply'.
+type Nat44AddDelLbStaticMappingReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44AddDelLbStaticMappingReply) Reset() { *m = Nat44AddDelLbStaticMappingReply{} }
+func (*Nat44AddDelLbStaticMappingReply) GetMessageName() string {
+ return "nat44_add_del_lb_static_mapping_reply"
+}
+func (*Nat44AddDelLbStaticMappingReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44AddDelLbStaticMappingReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddDelLbStaticMappingReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44AddDelLbStaticMappingReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelLbStaticMappingReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44AddDelStaticMapping defines message 'nat44_add_del_static_mapping'.
+type Nat44AddDelStaticMapping struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ LocalIPAddress ip_types.IP4Address `binapi:"ip4_address,name=local_ip_address" json:"local_ip_address,omitempty"`
+ ExternalIPAddress ip_types.IP4Address `binapi:"ip4_address,name=external_ip_address" json:"external_ip_address,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ LocalPort uint16 `binapi:"u16,name=local_port" json:"local_port,omitempty"`
+ ExternalPort uint16 `binapi:"u16,name=external_port" json:"external_port,omitempty"`
+ ExternalSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=external_sw_if_index" json:"external_sw_if_index,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+}
+
+func (m *Nat44AddDelStaticMapping) Reset() { *m = Nat44AddDelStaticMapping{} }
+func (*Nat44AddDelStaticMapping) GetMessageName() string { return "nat44_add_del_static_mapping" }
+func (*Nat44AddDelStaticMapping) GetCrcString() string { return "5ae5f03e" }
+func (*Nat44AddDelStaticMapping) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddDelStaticMapping) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 // m.Flags
+ size += 1 * 4 // m.LocalIPAddress
+ size += 1 * 4 // m.ExternalIPAddress
+ size += 1 // m.Protocol
+ size += 2 // m.LocalPort
+ size += 2 // m.ExternalPort
+ size += 4 // m.ExternalSwIfIndex
+ size += 4 // m.VrfID
+ size += 64 // m.Tag
+ return size
+}
+func (m *Nat44AddDelStaticMapping) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.LocalIPAddress[:], 4)
+ buf.EncodeBytes(m.ExternalIPAddress[:], 4)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint16(m.LocalPort)
+ buf.EncodeUint16(m.ExternalPort)
+ buf.EncodeUint32(uint32(m.ExternalSwIfIndex))
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeString(m.Tag, 64)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelStaticMapping) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.LocalIPAddress[:], buf.DecodeBytes(4))
+ copy(m.ExternalIPAddress[:], buf.DecodeBytes(4))
+ m.Protocol = buf.DecodeUint8()
+ m.LocalPort = buf.DecodeUint16()
+ m.ExternalPort = buf.DecodeUint16()
+ m.ExternalSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.VrfID = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ return nil
+}
+
+// Nat44AddDelStaticMappingReply defines message 'nat44_add_del_static_mapping_reply'.
+type Nat44AddDelStaticMappingReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44AddDelStaticMappingReply) Reset() { *m = Nat44AddDelStaticMappingReply{} }
+func (*Nat44AddDelStaticMappingReply) GetMessageName() string {
+ return "nat44_add_del_static_mapping_reply"
+}
+func (*Nat44AddDelStaticMappingReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44AddDelStaticMappingReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddDelStaticMappingReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44AddDelStaticMappingReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelStaticMappingReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44AddDelStaticMappingV2 defines message 'nat44_add_del_static_mapping_v2'.
+// InProgress: the message form may change in the future versions
+type Nat44AddDelStaticMappingV2 struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ MatchPool bool `binapi:"bool,name=match_pool" json:"match_pool,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ PoolIPAddress ip_types.IP4Address `binapi:"ip4_address,name=pool_ip_address" json:"pool_ip_address,omitempty"`
+ LocalIPAddress ip_types.IP4Address `binapi:"ip4_address,name=local_ip_address" json:"local_ip_address,omitempty"`
+ ExternalIPAddress ip_types.IP4Address `binapi:"ip4_address,name=external_ip_address" json:"external_ip_address,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ LocalPort uint16 `binapi:"u16,name=local_port" json:"local_port,omitempty"`
+ ExternalPort uint16 `binapi:"u16,name=external_port" json:"external_port,omitempty"`
+ ExternalSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=external_sw_if_index" json:"external_sw_if_index,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+}
+
+func (m *Nat44AddDelStaticMappingV2) Reset() { *m = Nat44AddDelStaticMappingV2{} }
+func (*Nat44AddDelStaticMappingV2) GetMessageName() string { return "nat44_add_del_static_mapping_v2" }
+func (*Nat44AddDelStaticMappingV2) GetCrcString() string { return "5e205f1a" }
+func (*Nat44AddDelStaticMappingV2) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddDelStaticMappingV2) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 // m.MatchPool
+ size += 1 // m.Flags
+ size += 1 * 4 // m.PoolIPAddress
+ size += 1 * 4 // m.LocalIPAddress
+ size += 1 * 4 // m.ExternalIPAddress
+ size += 1 // m.Protocol
+ size += 2 // m.LocalPort
+ size += 2 // m.ExternalPort
+ size += 4 // m.ExternalSwIfIndex
+ size += 4 // m.VrfID
+ size += 64 // m.Tag
+ return size
+}
+func (m *Nat44AddDelStaticMappingV2) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeBool(m.MatchPool)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.PoolIPAddress[:], 4)
+ buf.EncodeBytes(m.LocalIPAddress[:], 4)
+ buf.EncodeBytes(m.ExternalIPAddress[:], 4)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint16(m.LocalPort)
+ buf.EncodeUint16(m.ExternalPort)
+ buf.EncodeUint32(uint32(m.ExternalSwIfIndex))
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeString(m.Tag, 64)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelStaticMappingV2) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.MatchPool = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.PoolIPAddress[:], buf.DecodeBytes(4))
+ copy(m.LocalIPAddress[:], buf.DecodeBytes(4))
+ copy(m.ExternalIPAddress[:], buf.DecodeBytes(4))
+ m.Protocol = buf.DecodeUint8()
+ m.LocalPort = buf.DecodeUint16()
+ m.ExternalPort = buf.DecodeUint16()
+ m.ExternalSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.VrfID = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ return nil
+}
+
+// Nat44AddDelStaticMappingV2Reply defines message 'nat44_add_del_static_mapping_v2_reply'.
+// InProgress: the message form may change in the future versions
+type Nat44AddDelStaticMappingV2Reply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44AddDelStaticMappingV2Reply) Reset() { *m = Nat44AddDelStaticMappingV2Reply{} }
+func (*Nat44AddDelStaticMappingV2Reply) GetMessageName() string {
+ return "nat44_add_del_static_mapping_v2_reply"
+}
+func (*Nat44AddDelStaticMappingV2Reply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44AddDelStaticMappingV2Reply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddDelStaticMappingV2Reply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44AddDelStaticMappingV2Reply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddDelStaticMappingV2Reply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44AddressDetails defines message 'nat44_address_details'.
+type Nat44AddressDetails struct {
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+}
+
+func (m *Nat44AddressDetails) Reset() { *m = Nat44AddressDetails{} }
+func (*Nat44AddressDetails) GetMessageName() string { return "nat44_address_details" }
+func (*Nat44AddressDetails) GetCrcString() string { return "0d1beac1" }
+func (*Nat44AddressDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44AddressDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.IPAddress
+ size += 1 // m.Flags
+ size += 4 // m.VrfID
+ return size
+}
+func (m *Nat44AddressDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint32(m.VrfID)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddressDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.VrfID = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44AddressDump defines message 'nat44_address_dump'.
+type Nat44AddressDump struct{}
+
+func (m *Nat44AddressDump) Reset() { *m = Nat44AddressDump{} }
+func (*Nat44AddressDump) GetMessageName() string { return "nat44_address_dump" }
+func (*Nat44AddressDump) GetCrcString() string { return "51077d14" }
+func (*Nat44AddressDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44AddressDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44AddressDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44AddressDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44DelSession defines message 'nat44_del_session'.
+type Nat44DelSession struct {
+ Address ip_types.IP4Address `binapi:"ip4_address,name=address" json:"address,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ ExtHostAddress ip_types.IP4Address `binapi:"ip4_address,name=ext_host_address" json:"ext_host_address,omitempty"`
+ ExtHostPort uint16 `binapi:"u16,name=ext_host_port" json:"ext_host_port,omitempty"`
+}
+
+func (m *Nat44DelSession) Reset() { *m = Nat44DelSession{} }
+func (*Nat44DelSession) GetMessageName() string { return "nat44_del_session" }
+func (*Nat44DelSession) GetCrcString() string { return "15a5bf8c" }
+func (*Nat44DelSession) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44DelSession) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.Address
+ size += 1 // m.Protocol
+ size += 2 // m.Port
+ size += 4 // m.VrfID
+ size += 1 // m.Flags
+ size += 1 * 4 // m.ExtHostAddress
+ size += 2 // m.ExtHostPort
+ return size
+}
+func (m *Nat44DelSession) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.Address[:], 4)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.ExtHostAddress[:], 4)
+ buf.EncodeUint16(m.ExtHostPort)
+ return buf.Bytes(), nil
+}
+func (m *Nat44DelSession) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.Address[:], buf.DecodeBytes(4))
+ m.Protocol = buf.DecodeUint8()
+ m.Port = buf.DecodeUint16()
+ m.VrfID = buf.DecodeUint32()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.ExtHostAddress[:], buf.DecodeBytes(4))
+ m.ExtHostPort = buf.DecodeUint16()
+ return nil
+}
+
+// Nat44DelSessionReply defines message 'nat44_del_session_reply'.
+type Nat44DelSessionReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44DelSessionReply) Reset() { *m = Nat44DelSessionReply{} }
+func (*Nat44DelSessionReply) GetMessageName() string { return "nat44_del_session_reply" }
+func (*Nat44DelSessionReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44DelSessionReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44DelSessionReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44DelSessionReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44DelSessionReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44DelUser defines message 'nat44_del_user'.
+type Nat44DelUser struct {
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ FibIndex uint32 `binapi:"u32,name=fib_index" json:"fib_index,omitempty"`
+}
+
+func (m *Nat44DelUser) Reset() { *m = Nat44DelUser{} }
+func (*Nat44DelUser) GetMessageName() string { return "nat44_del_user" }
+func (*Nat44DelUser) GetCrcString() string { return "99a9f998" }
+func (*Nat44DelUser) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44DelUser) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.IPAddress
+ size += 4 // m.FibIndex
+ return size
+}
+func (m *Nat44DelUser) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint32(m.FibIndex)
+ return buf.Bytes(), nil
+}
+func (m *Nat44DelUser) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.FibIndex = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44DelUserReply defines message 'nat44_del_user_reply'.
+type Nat44DelUserReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44DelUserReply) Reset() { *m = Nat44DelUserReply{} }
+func (*Nat44DelUserReply) GetMessageName() string { return "nat44_del_user_reply" }
+func (*Nat44DelUserReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44DelUserReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44DelUserReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44DelUserReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44DelUserReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44EdAddDelOutputInterface defines message 'nat44_ed_add_del_output_interface'.
+type Nat44EdAddDelOutputInterface struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+}
+
+func (m *Nat44EdAddDelOutputInterface) Reset() { *m = Nat44EdAddDelOutputInterface{} }
+func (*Nat44EdAddDelOutputInterface) GetMessageName() string {
+ return "nat44_ed_add_del_output_interface"
+}
+func (*Nat44EdAddDelOutputInterface) GetCrcString() string { return "47d6e753" }
+func (*Nat44EdAddDelOutputInterface) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44EdAddDelOutputInterface) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 4 // m.SwIfIndex
+ return size
+}
+func (m *Nat44EdAddDelOutputInterface) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdAddDelOutputInterface) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ return nil
+}
+
+// Nat44EdAddDelOutputInterfaceReply defines message 'nat44_ed_add_del_output_interface_reply'.
+type Nat44EdAddDelOutputInterfaceReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44EdAddDelOutputInterfaceReply) Reset() { *m = Nat44EdAddDelOutputInterfaceReply{} }
+func (*Nat44EdAddDelOutputInterfaceReply) GetMessageName() string {
+ return "nat44_ed_add_del_output_interface_reply"
+}
+func (*Nat44EdAddDelOutputInterfaceReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44EdAddDelOutputInterfaceReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44EdAddDelOutputInterfaceReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44EdAddDelOutputInterfaceReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdAddDelOutputInterfaceReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44EdOutputInterfaceDetails defines message 'nat44_ed_output_interface_details'.
+type Nat44EdOutputInterfaceDetails struct {
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+}
+
+func (m *Nat44EdOutputInterfaceDetails) Reset() { *m = Nat44EdOutputInterfaceDetails{} }
+func (*Nat44EdOutputInterfaceDetails) GetMessageName() string {
+ return "nat44_ed_output_interface_details"
+}
+func (*Nat44EdOutputInterfaceDetails) GetCrcString() string { return "0b45011c" }
+func (*Nat44EdOutputInterfaceDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44EdOutputInterfaceDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.SwIfIndex
+ return size
+}
+func (m *Nat44EdOutputInterfaceDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdOutputInterfaceDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ return nil
+}
+
+// Nat44EdOutputInterfaceGet defines message 'nat44_ed_output_interface_get'.
+type Nat44EdOutputInterfaceGet struct {
+ Cursor uint32 `binapi:"u32,name=cursor" json:"cursor,omitempty"`
+}
+
+func (m *Nat44EdOutputInterfaceGet) Reset() { *m = Nat44EdOutputInterfaceGet{} }
+func (*Nat44EdOutputInterfaceGet) GetMessageName() string { return "nat44_ed_output_interface_get" }
+func (*Nat44EdOutputInterfaceGet) GetCrcString() string { return "f75ba505" }
+func (*Nat44EdOutputInterfaceGet) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44EdOutputInterfaceGet) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Cursor
+ return size
+}
+func (m *Nat44EdOutputInterfaceGet) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.Cursor)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdOutputInterfaceGet) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Cursor = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44EdOutputInterfaceGetReply defines message 'nat44_ed_output_interface_get_reply'.
+type Nat44EdOutputInterfaceGetReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ Cursor uint32 `binapi:"u32,name=cursor" json:"cursor,omitempty"`
+}
+
+func (m *Nat44EdOutputInterfaceGetReply) Reset() { *m = Nat44EdOutputInterfaceGetReply{} }
+func (*Nat44EdOutputInterfaceGetReply) GetMessageName() string {
+ return "nat44_ed_output_interface_get_reply"
+}
+func (*Nat44EdOutputInterfaceGetReply) GetCrcString() string { return "53b48f5d" }
+func (*Nat44EdOutputInterfaceGetReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44EdOutputInterfaceGetReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 4 // m.Cursor
+ return size
+}
+func (m *Nat44EdOutputInterfaceGetReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint32(m.Cursor)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdOutputInterfaceGetReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.Cursor = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44EdPluginEnableDisable defines message 'nat44_ed_plugin_enable_disable'.
+// InProgress: the message form may change in the future versions
+type Nat44EdPluginEnableDisable struct {
+ InsideVrf uint32 `binapi:"u32,name=inside_vrf" json:"inside_vrf,omitempty"`
+ OutsideVrf uint32 `binapi:"u32,name=outside_vrf" json:"outside_vrf,omitempty"`
+ Sessions uint32 `binapi:"u32,name=sessions" json:"sessions,omitempty"`
+ SessionMemory uint32 `binapi:"u32,name=session_memory" json:"session_memory,omitempty"`
+ Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
+ Flags Nat44ConfigFlags `binapi:"nat44_config_flags,name=flags" json:"flags,omitempty"`
+}
+
+func (m *Nat44EdPluginEnableDisable) Reset() { *m = Nat44EdPluginEnableDisable{} }
+func (*Nat44EdPluginEnableDisable) GetMessageName() string { return "nat44_ed_plugin_enable_disable" }
+func (*Nat44EdPluginEnableDisable) GetCrcString() string { return "be17f8dd" }
+func (*Nat44EdPluginEnableDisable) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44EdPluginEnableDisable) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.InsideVrf
+ size += 4 // m.OutsideVrf
+ size += 4 // m.Sessions
+ size += 4 // m.SessionMemory
+ size += 1 // m.Enable
+ size += 1 // m.Flags
+ return size
+}
+func (m *Nat44EdPluginEnableDisable) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.InsideVrf)
+ buf.EncodeUint32(m.OutsideVrf)
+ buf.EncodeUint32(m.Sessions)
+ buf.EncodeUint32(m.SessionMemory)
+ buf.EncodeBool(m.Enable)
+ buf.EncodeUint8(uint8(m.Flags))
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdPluginEnableDisable) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.InsideVrf = buf.DecodeUint32()
+ m.OutsideVrf = buf.DecodeUint32()
+ m.Sessions = buf.DecodeUint32()
+ m.SessionMemory = buf.DecodeUint32()
+ m.Enable = buf.DecodeBool()
+ m.Flags = Nat44ConfigFlags(buf.DecodeUint8())
+ return nil
+}
+
+// Nat44EdPluginEnableDisableReply defines message 'nat44_ed_plugin_enable_disable_reply'.
+// InProgress: the message form may change in the future versions
+type Nat44EdPluginEnableDisableReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44EdPluginEnableDisableReply) Reset() { *m = Nat44EdPluginEnableDisableReply{} }
+func (*Nat44EdPluginEnableDisableReply) GetMessageName() string {
+ return "nat44_ed_plugin_enable_disable_reply"
+}
+func (*Nat44EdPluginEnableDisableReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44EdPluginEnableDisableReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44EdPluginEnableDisableReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44EdPluginEnableDisableReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdPluginEnableDisableReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44EdSetFqOptions defines message 'nat44_ed_set_fq_options'.
+// InProgress: the message form may change in the future versions
+type Nat44EdSetFqOptions struct {
+ FrameQueueNelts uint32 `binapi:"u32,name=frame_queue_nelts" json:"frame_queue_nelts,omitempty"`
+}
+
+func (m *Nat44EdSetFqOptions) Reset() { *m = Nat44EdSetFqOptions{} }
+func (*Nat44EdSetFqOptions) GetMessageName() string { return "nat44_ed_set_fq_options" }
+func (*Nat44EdSetFqOptions) GetCrcString() string { return "2399bd71" }
+func (*Nat44EdSetFqOptions) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44EdSetFqOptions) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.FrameQueueNelts
+ return size
+}
+func (m *Nat44EdSetFqOptions) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.FrameQueueNelts)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdSetFqOptions) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.FrameQueueNelts = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44EdSetFqOptionsReply defines message 'nat44_ed_set_fq_options_reply'.
+// InProgress: the message form may change in the future versions
+type Nat44EdSetFqOptionsReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44EdSetFqOptionsReply) Reset() { *m = Nat44EdSetFqOptionsReply{} }
+func (*Nat44EdSetFqOptionsReply) GetMessageName() string { return "nat44_ed_set_fq_options_reply" }
+func (*Nat44EdSetFqOptionsReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44EdSetFqOptionsReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44EdSetFqOptionsReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44EdSetFqOptionsReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdSetFqOptionsReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44EdShowFqOptions defines message 'nat44_ed_show_fq_options'.
+// InProgress: the message form may change in the future versions
+type Nat44EdShowFqOptions struct{}
+
+func (m *Nat44EdShowFqOptions) Reset() { *m = Nat44EdShowFqOptions{} }
+func (*Nat44EdShowFqOptions) GetMessageName() string { return "nat44_ed_show_fq_options" }
+func (*Nat44EdShowFqOptions) GetCrcString() string { return "51077d14" }
+func (*Nat44EdShowFqOptions) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44EdShowFqOptions) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44EdShowFqOptions) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdShowFqOptions) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44EdShowFqOptionsReply defines message 'nat44_ed_show_fq_options_reply'.
+// InProgress: the message form may change in the future versions
+type Nat44EdShowFqOptionsReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ FrameQueueNelts uint32 `binapi:"u32,name=frame_queue_nelts" json:"frame_queue_nelts,omitempty"`
+}
+
+func (m *Nat44EdShowFqOptionsReply) Reset() { *m = Nat44EdShowFqOptionsReply{} }
+func (*Nat44EdShowFqOptionsReply) GetMessageName() string { return "nat44_ed_show_fq_options_reply" }
+func (*Nat44EdShowFqOptionsReply) GetCrcString() string { return "7213b545" }
+func (*Nat44EdShowFqOptionsReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44EdShowFqOptionsReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 4 // m.FrameQueueNelts
+ return size
+}
+func (m *Nat44EdShowFqOptionsReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint32(m.FrameQueueNelts)
+ return buf.Bytes(), nil
+}
+func (m *Nat44EdShowFqOptionsReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.FrameQueueNelts = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44ForwardingEnableDisable defines message 'nat44_forwarding_enable_disable'.
+// Deprecated: the message will be removed in the future versions
+type Nat44ForwardingEnableDisable struct {
+ Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
+}
+
+func (m *Nat44ForwardingEnableDisable) Reset() { *m = Nat44ForwardingEnableDisable{} }
+func (*Nat44ForwardingEnableDisable) GetMessageName() string {
+ return "nat44_forwarding_enable_disable"
+}
+func (*Nat44ForwardingEnableDisable) GetCrcString() string { return "b3e225d2" }
+func (*Nat44ForwardingEnableDisable) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44ForwardingEnableDisable) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Enable
+ return size
+}
+func (m *Nat44ForwardingEnableDisable) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.Enable)
+ return buf.Bytes(), nil
+}
+func (m *Nat44ForwardingEnableDisable) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Enable = buf.DecodeBool()
+ return nil
+}
+
+// Nat44ForwardingEnableDisableReply defines message 'nat44_forwarding_enable_disable_reply'.
+// Deprecated: the message will be removed in the future versions
+type Nat44ForwardingEnableDisableReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44ForwardingEnableDisableReply) Reset() { *m = Nat44ForwardingEnableDisableReply{} }
+func (*Nat44ForwardingEnableDisableReply) GetMessageName() string {
+ return "nat44_forwarding_enable_disable_reply"
+}
+func (*Nat44ForwardingEnableDisableReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44ForwardingEnableDisableReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44ForwardingEnableDisableReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44ForwardingEnableDisableReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44ForwardingEnableDisableReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44ForwardingIsEnabled defines message 'nat44_forwarding_is_enabled'.
+// Deprecated: the message will be removed in the future versions
+type Nat44ForwardingIsEnabled struct{}
+
+func (m *Nat44ForwardingIsEnabled) Reset() { *m = Nat44ForwardingIsEnabled{} }
+func (*Nat44ForwardingIsEnabled) GetMessageName() string { return "nat44_forwarding_is_enabled" }
+func (*Nat44ForwardingIsEnabled) GetCrcString() string { return "51077d14" }
+func (*Nat44ForwardingIsEnabled) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44ForwardingIsEnabled) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44ForwardingIsEnabled) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44ForwardingIsEnabled) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44ForwardingIsEnabledReply defines message 'nat44_forwarding_is_enabled_reply'.
+// Deprecated: the message will be removed in the future versions
+type Nat44ForwardingIsEnabledReply struct {
+ Enabled bool `binapi:"bool,name=enabled" json:"enabled,omitempty"`
+}
+
+func (m *Nat44ForwardingIsEnabledReply) Reset() { *m = Nat44ForwardingIsEnabledReply{} }
+func (*Nat44ForwardingIsEnabledReply) GetMessageName() string {
+ return "nat44_forwarding_is_enabled_reply"
+}
+func (*Nat44ForwardingIsEnabledReply) GetCrcString() string { return "46924a06" }
+func (*Nat44ForwardingIsEnabledReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44ForwardingIsEnabledReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Enabled
+ return size
+}
+func (m *Nat44ForwardingIsEnabledReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.Enabled)
+ return buf.Bytes(), nil
+}
+func (m *Nat44ForwardingIsEnabledReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Enabled = buf.DecodeBool()
+ return nil
+}
+
+// Nat44IdentityMappingDetails defines message 'nat44_identity_mapping_details'.
+type Nat44IdentityMappingDetails struct {
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+}
+
+func (m *Nat44IdentityMappingDetails) Reset() { *m = Nat44IdentityMappingDetails{} }
+func (*Nat44IdentityMappingDetails) GetMessageName() string { return "nat44_identity_mapping_details" }
+func (*Nat44IdentityMappingDetails) GetCrcString() string { return "2a52a030" }
+func (*Nat44IdentityMappingDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44IdentityMappingDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Flags
+ size += 1 * 4 // m.IPAddress
+ size += 1 // m.Protocol
+ size += 2 // m.Port
+ size += 4 // m.SwIfIndex
+ size += 4 // m.VrfID
+ size += 64 // m.Tag
+ return size
+}
+func (m *Nat44IdentityMappingDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeString(m.Tag, 64)
+ return buf.Bytes(), nil
+}
+func (m *Nat44IdentityMappingDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Protocol = buf.DecodeUint8()
+ m.Port = buf.DecodeUint16()
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.VrfID = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ return nil
+}
+
+// Nat44IdentityMappingDump defines message 'nat44_identity_mapping_dump'.
+type Nat44IdentityMappingDump struct{}
+
+func (m *Nat44IdentityMappingDump) Reset() { *m = Nat44IdentityMappingDump{} }
+func (*Nat44IdentityMappingDump) GetMessageName() string { return "nat44_identity_mapping_dump" }
+func (*Nat44IdentityMappingDump) GetCrcString() string { return "51077d14" }
+func (*Nat44IdentityMappingDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44IdentityMappingDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44IdentityMappingDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44IdentityMappingDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44InterfaceAddDelFeature defines message 'nat44_interface_add_del_feature'.
+type Nat44InterfaceAddDelFeature struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+}
+
+func (m *Nat44InterfaceAddDelFeature) Reset() { *m = Nat44InterfaceAddDelFeature{} }
+func (*Nat44InterfaceAddDelFeature) GetMessageName() string { return "nat44_interface_add_del_feature" }
+func (*Nat44InterfaceAddDelFeature) GetCrcString() string { return "f3699b83" }
+func (*Nat44InterfaceAddDelFeature) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44InterfaceAddDelFeature) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 // m.Flags
+ size += 4 // m.SwIfIndex
+ return size
+}
+func (m *Nat44InterfaceAddDelFeature) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceAddDelFeature) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ return nil
+}
+
+// Nat44InterfaceAddDelFeatureReply defines message 'nat44_interface_add_del_feature_reply'.
+type Nat44InterfaceAddDelFeatureReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44InterfaceAddDelFeatureReply) Reset() { *m = Nat44InterfaceAddDelFeatureReply{} }
+func (*Nat44InterfaceAddDelFeatureReply) GetMessageName() string {
+ return "nat44_interface_add_del_feature_reply"
+}
+func (*Nat44InterfaceAddDelFeatureReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44InterfaceAddDelFeatureReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44InterfaceAddDelFeatureReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44InterfaceAddDelFeatureReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceAddDelFeatureReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44InterfaceAddDelOutputFeature defines message 'nat44_interface_add_del_output_feature'.
+// Deprecated: the message will be removed in the future versions
+type Nat44InterfaceAddDelOutputFeature struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+}
+
+func (m *Nat44InterfaceAddDelOutputFeature) Reset() { *m = Nat44InterfaceAddDelOutputFeature{} }
+func (*Nat44InterfaceAddDelOutputFeature) GetMessageName() string {
+ return "nat44_interface_add_del_output_feature"
+}
+func (*Nat44InterfaceAddDelOutputFeature) GetCrcString() string { return "f3699b83" }
+func (*Nat44InterfaceAddDelOutputFeature) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44InterfaceAddDelOutputFeature) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 // m.Flags
+ size += 4 // m.SwIfIndex
+ return size
+}
+func (m *Nat44InterfaceAddDelOutputFeature) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceAddDelOutputFeature) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ return nil
+}
+
+// Nat44InterfaceAddDelOutputFeatureReply defines message 'nat44_interface_add_del_output_feature_reply'.
+// Deprecated: the message will be removed in the future versions
+type Nat44InterfaceAddDelOutputFeatureReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44InterfaceAddDelOutputFeatureReply) Reset() {
+ *m = Nat44InterfaceAddDelOutputFeatureReply{}
+}
+func (*Nat44InterfaceAddDelOutputFeatureReply) GetMessageName() string {
+ return "nat44_interface_add_del_output_feature_reply"
+}
+func (*Nat44InterfaceAddDelOutputFeatureReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44InterfaceAddDelOutputFeatureReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44InterfaceAddDelOutputFeatureReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44InterfaceAddDelOutputFeatureReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceAddDelOutputFeatureReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44InterfaceAddrDetails defines message 'nat44_interface_addr_details'.
+type Nat44InterfaceAddrDetails struct {
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+}
+
+func (m *Nat44InterfaceAddrDetails) Reset() { *m = Nat44InterfaceAddrDetails{} }
+func (*Nat44InterfaceAddrDetails) GetMessageName() string { return "nat44_interface_addr_details" }
+func (*Nat44InterfaceAddrDetails) GetCrcString() string { return "e4aca9ca" }
+func (*Nat44InterfaceAddrDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44InterfaceAddrDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.SwIfIndex
+ size += 1 // m.Flags
+ return size
+}
+func (m *Nat44InterfaceAddrDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ buf.EncodeUint8(uint8(m.Flags))
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceAddrDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ return nil
+}
+
+// Nat44InterfaceAddrDump defines message 'nat44_interface_addr_dump'.
+type Nat44InterfaceAddrDump struct{}
+
+func (m *Nat44InterfaceAddrDump) Reset() { *m = Nat44InterfaceAddrDump{} }
+func (*Nat44InterfaceAddrDump) GetMessageName() string { return "nat44_interface_addr_dump" }
+func (*Nat44InterfaceAddrDump) GetCrcString() string { return "51077d14" }
+func (*Nat44InterfaceAddrDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44InterfaceAddrDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44InterfaceAddrDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceAddrDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44InterfaceDetails defines message 'nat44_interface_details'.
+type Nat44InterfaceDetails struct {
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+}
+
+func (m *Nat44InterfaceDetails) Reset() { *m = Nat44InterfaceDetails{} }
+func (*Nat44InterfaceDetails) GetMessageName() string { return "nat44_interface_details" }
+func (*Nat44InterfaceDetails) GetCrcString() string { return "5d286289" }
+func (*Nat44InterfaceDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44InterfaceDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Flags
+ size += 4 // m.SwIfIndex
+ return size
+}
+func (m *Nat44InterfaceDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ return nil
+}
+
+// Nat44InterfaceDump defines message 'nat44_interface_dump'.
+type Nat44InterfaceDump struct{}
+
+func (m *Nat44InterfaceDump) Reset() { *m = Nat44InterfaceDump{} }
+func (*Nat44InterfaceDump) GetMessageName() string { return "nat44_interface_dump" }
+func (*Nat44InterfaceDump) GetCrcString() string { return "51077d14" }
+func (*Nat44InterfaceDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44InterfaceDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44InterfaceDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44InterfaceOutputFeatureDetails defines message 'nat44_interface_output_feature_details'.
+// Deprecated: the message will be removed in the future versions
+type Nat44InterfaceOutputFeatureDetails struct {
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
+}
+
+func (m *Nat44InterfaceOutputFeatureDetails) Reset() { *m = Nat44InterfaceOutputFeatureDetails{} }
+func (*Nat44InterfaceOutputFeatureDetails) GetMessageName() string {
+ return "nat44_interface_output_feature_details"
+}
+func (*Nat44InterfaceOutputFeatureDetails) GetCrcString() string { return "5d286289" }
+func (*Nat44InterfaceOutputFeatureDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44InterfaceOutputFeatureDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Flags
+ size += 4 // m.SwIfIndex
+ return size
+}
+func (m *Nat44InterfaceOutputFeatureDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint32(uint32(m.SwIfIndex))
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceOutputFeatureDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ return nil
+}
+
+// Nat44InterfaceOutputFeatureDump defines message 'nat44_interface_output_feature_dump'.
+// Deprecated: the message will be removed in the future versions
+type Nat44InterfaceOutputFeatureDump struct{}
+
+func (m *Nat44InterfaceOutputFeatureDump) Reset() { *m = Nat44InterfaceOutputFeatureDump{} }
+func (*Nat44InterfaceOutputFeatureDump) GetMessageName() string {
+ return "nat44_interface_output_feature_dump"
+}
+func (*Nat44InterfaceOutputFeatureDump) GetCrcString() string { return "51077d14" }
+func (*Nat44InterfaceOutputFeatureDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44InterfaceOutputFeatureDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44InterfaceOutputFeatureDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44InterfaceOutputFeatureDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44LbStaticMappingAddDelLocal defines message 'nat44_lb_static_mapping_add_del_local'.
+type Nat44LbStaticMappingAddDelLocal struct {
+ IsAdd bool `binapi:"bool,name=is_add" json:"is_add,omitempty"`
+ ExternalAddr ip_types.IP4Address `binapi:"ip4_address,name=external_addr" json:"external_addr,omitempty"`
+ ExternalPort uint16 `binapi:"u16,name=external_port" json:"external_port,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ Local Nat44LbAddrPort `binapi:"nat44_lb_addr_port,name=local" json:"local,omitempty"`
+}
+
+func (m *Nat44LbStaticMappingAddDelLocal) Reset() { *m = Nat44LbStaticMappingAddDelLocal{} }
+func (*Nat44LbStaticMappingAddDelLocal) GetMessageName() string {
+ return "nat44_lb_static_mapping_add_del_local"
+}
+func (*Nat44LbStaticMappingAddDelLocal) GetCrcString() string { return "7ca47547" }
+func (*Nat44LbStaticMappingAddDelLocal) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44LbStaticMappingAddDelLocal) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.IsAdd
+ size += 1 * 4 // m.ExternalAddr
+ size += 2 // m.ExternalPort
+ size += 1 // m.Protocol
+ size += 1 * 4 // m.Local.Addr
+ size += 2 // m.Local.Port
+ size += 1 // m.Local.Probability
+ size += 4 // m.Local.VrfID
+ return size
+}
+func (m *Nat44LbStaticMappingAddDelLocal) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBool(m.IsAdd)
+ buf.EncodeBytes(m.ExternalAddr[:], 4)
+ buf.EncodeUint16(m.ExternalPort)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeBytes(m.Local.Addr[:], 4)
+ buf.EncodeUint16(m.Local.Port)
+ buf.EncodeUint8(m.Local.Probability)
+ buf.EncodeUint32(m.Local.VrfID)
+ return buf.Bytes(), nil
+}
+func (m *Nat44LbStaticMappingAddDelLocal) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.IsAdd = buf.DecodeBool()
+ copy(m.ExternalAddr[:], buf.DecodeBytes(4))
+ m.ExternalPort = buf.DecodeUint16()
+ m.Protocol = buf.DecodeUint8()
+ copy(m.Local.Addr[:], buf.DecodeBytes(4))
+ m.Local.Port = buf.DecodeUint16()
+ m.Local.Probability = buf.DecodeUint8()
+ m.Local.VrfID = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44LbStaticMappingAddDelLocalReply defines message 'nat44_lb_static_mapping_add_del_local_reply'.
+type Nat44LbStaticMappingAddDelLocalReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44LbStaticMappingAddDelLocalReply) Reset() { *m = Nat44LbStaticMappingAddDelLocalReply{} }
+func (*Nat44LbStaticMappingAddDelLocalReply) GetMessageName() string {
+ return "nat44_lb_static_mapping_add_del_local_reply"
+}
+func (*Nat44LbStaticMappingAddDelLocalReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44LbStaticMappingAddDelLocalReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44LbStaticMappingAddDelLocalReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44LbStaticMappingAddDelLocalReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44LbStaticMappingAddDelLocalReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44LbStaticMappingDetails defines message 'nat44_lb_static_mapping_details'.
+type Nat44LbStaticMappingDetails struct {
+ ExternalAddr ip_types.IP4Address `binapi:"ip4_address,name=external_addr" json:"external_addr,omitempty"`
+ ExternalPort uint16 `binapi:"u16,name=external_port" json:"external_port,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ Affinity uint32 `binapi:"u32,name=affinity" json:"affinity,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+ LocalNum uint32 `binapi:"u32,name=local_num" json:"-"`
+ Locals []Nat44LbAddrPort `binapi:"nat44_lb_addr_port[local_num],name=locals" json:"locals,omitempty"`
+}
+
+func (m *Nat44LbStaticMappingDetails) Reset() { *m = Nat44LbStaticMappingDetails{} }
+func (*Nat44LbStaticMappingDetails) GetMessageName() string { return "nat44_lb_static_mapping_details" }
+func (*Nat44LbStaticMappingDetails) GetCrcString() string { return "ed5ce876" }
+func (*Nat44LbStaticMappingDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44LbStaticMappingDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.ExternalAddr
+ size += 2 // m.ExternalPort
+ size += 1 // m.Protocol
+ size += 1 // m.Flags
+ size += 4 // m.Affinity
+ size += 64 // m.Tag
+ size += 4 // m.LocalNum
+ for j1 := 0; j1 < len(m.Locals); j1++ {
+ var s1 Nat44LbAddrPort
+ _ = s1
+ if j1 < len(m.Locals) {
+ s1 = m.Locals[j1]
+ }
+ size += 1 * 4 // s1.Addr
+ size += 2 // s1.Port
+ size += 1 // s1.Probability
+ size += 4 // s1.VrfID
+ }
+ return size
+}
+func (m *Nat44LbStaticMappingDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.ExternalAddr[:], 4)
+ buf.EncodeUint16(m.ExternalPort)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint32(m.Affinity)
+ buf.EncodeString(m.Tag, 64)
+ buf.EncodeUint32(uint32(len(m.Locals)))
+ for j0 := 0; j0 < len(m.Locals); j0++ {
+ var v0 Nat44LbAddrPort // Locals
+ if j0 < len(m.Locals) {
+ v0 = m.Locals[j0]
+ }
+ buf.EncodeBytes(v0.Addr[:], 4)
+ buf.EncodeUint16(v0.Port)
+ buf.EncodeUint8(v0.Probability)
+ buf.EncodeUint32(v0.VrfID)
+ }
+ return buf.Bytes(), nil
+}
+func (m *Nat44LbStaticMappingDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.ExternalAddr[:], buf.DecodeBytes(4))
+ m.ExternalPort = buf.DecodeUint16()
+ m.Protocol = buf.DecodeUint8()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.Affinity = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ m.LocalNum = buf.DecodeUint32()
+ m.Locals = make([]Nat44LbAddrPort, m.LocalNum)
+ for j0 := 0; j0 < len(m.Locals); j0++ {
+ copy(m.Locals[j0].Addr[:], buf.DecodeBytes(4))
+ m.Locals[j0].Port = buf.DecodeUint16()
+ m.Locals[j0].Probability = buf.DecodeUint8()
+ m.Locals[j0].VrfID = buf.DecodeUint32()
+ }
+ return nil
+}
+
+// Nat44LbStaticMappingDump defines message 'nat44_lb_static_mapping_dump'.
+type Nat44LbStaticMappingDump struct{}
+
+func (m *Nat44LbStaticMappingDump) Reset() { *m = Nat44LbStaticMappingDump{} }
+func (*Nat44LbStaticMappingDump) GetMessageName() string { return "nat44_lb_static_mapping_dump" }
+func (*Nat44LbStaticMappingDump) GetCrcString() string { return "51077d14" }
+func (*Nat44LbStaticMappingDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44LbStaticMappingDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44LbStaticMappingDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44LbStaticMappingDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44PluginEnableDisable defines message 'nat44_plugin_enable_disable'.
+// Deprecated: the message will be removed in the future versions
+type Nat44PluginEnableDisable struct {
+ InsideVrf uint32 `binapi:"u32,name=inside_vrf" json:"inside_vrf,omitempty"`
+ OutsideVrf uint32 `binapi:"u32,name=outside_vrf" json:"outside_vrf,omitempty"`
+ Users uint32 `binapi:"u32,name=users" json:"users,omitempty"`
+ UserMemory uint32 `binapi:"u32,name=user_memory" json:"user_memory,omitempty"`
+ Sessions uint32 `binapi:"u32,name=sessions" json:"sessions,omitempty"`
+ SessionMemory uint32 `binapi:"u32,name=session_memory" json:"session_memory,omitempty"`
+ UserSessions uint32 `binapi:"u32,name=user_sessions" json:"user_sessions,omitempty"`
+ Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
+ Flags Nat44ConfigFlags `binapi:"nat44_config_flags,name=flags" json:"flags,omitempty"`
+}
+
+func (m *Nat44PluginEnableDisable) Reset() { *m = Nat44PluginEnableDisable{} }
+func (*Nat44PluginEnableDisable) GetMessageName() string { return "nat44_plugin_enable_disable" }
+func (*Nat44PluginEnableDisable) GetCrcString() string { return "dea0d501" }
+func (*Nat44PluginEnableDisable) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44PluginEnableDisable) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.InsideVrf
+ size += 4 // m.OutsideVrf
+ size += 4 // m.Users
+ size += 4 // m.UserMemory
+ size += 4 // m.Sessions
+ size += 4 // m.SessionMemory
+ size += 4 // m.UserSessions
+ size += 1 // m.Enable
+ size += 1 // m.Flags
+ return size
+}
+func (m *Nat44PluginEnableDisable) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.InsideVrf)
+ buf.EncodeUint32(m.OutsideVrf)
+ buf.EncodeUint32(m.Users)
+ buf.EncodeUint32(m.UserMemory)
+ buf.EncodeUint32(m.Sessions)
+ buf.EncodeUint32(m.SessionMemory)
+ buf.EncodeUint32(m.UserSessions)
+ buf.EncodeBool(m.Enable)
+ buf.EncodeUint8(uint8(m.Flags))
+ return buf.Bytes(), nil
+}
+func (m *Nat44PluginEnableDisable) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.InsideVrf = buf.DecodeUint32()
+ m.OutsideVrf = buf.DecodeUint32()
+ m.Users = buf.DecodeUint32()
+ m.UserMemory = buf.DecodeUint32()
+ m.Sessions = buf.DecodeUint32()
+ m.SessionMemory = buf.DecodeUint32()
+ m.UserSessions = buf.DecodeUint32()
+ m.Enable = buf.DecodeBool()
+ m.Flags = Nat44ConfigFlags(buf.DecodeUint8())
+ return nil
+}
+
+// Nat44PluginEnableDisableReply defines message 'nat44_plugin_enable_disable_reply'.
+// Deprecated: the message will be removed in the future versions
+type Nat44PluginEnableDisableReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44PluginEnableDisableReply) Reset() { *m = Nat44PluginEnableDisableReply{} }
+func (*Nat44PluginEnableDisableReply) GetMessageName() string {
+ return "nat44_plugin_enable_disable_reply"
+}
+func (*Nat44PluginEnableDisableReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44PluginEnableDisableReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44PluginEnableDisableReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44PluginEnableDisableReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44PluginEnableDisableReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44SessionCleanup defines message 'nat44_session_cleanup'.
+// Deprecated: the message will be removed in the future versions
+type Nat44SessionCleanup struct{}
+
+func (m *Nat44SessionCleanup) Reset() { *m = Nat44SessionCleanup{} }
+func (*Nat44SessionCleanup) GetMessageName() string { return "nat44_session_cleanup" }
+func (*Nat44SessionCleanup) GetCrcString() string { return "51077d14" }
+func (*Nat44SessionCleanup) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44SessionCleanup) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44SessionCleanup) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44SessionCleanup) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44SessionCleanupReply defines message 'nat44_session_cleanup_reply'.
+// Deprecated: the message will be removed in the future versions
+type Nat44SessionCleanupReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44SessionCleanupReply) Reset() { *m = Nat44SessionCleanupReply{} }
+func (*Nat44SessionCleanupReply) GetMessageName() string { return "nat44_session_cleanup_reply" }
+func (*Nat44SessionCleanupReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44SessionCleanupReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44SessionCleanupReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44SessionCleanupReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44SessionCleanupReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44SetSessionLimit defines message 'nat44_set_session_limit'.
+type Nat44SetSessionLimit struct {
+ SessionLimit uint32 `binapi:"u32,name=session_limit" json:"session_limit,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+}
+
+func (m *Nat44SetSessionLimit) Reset() { *m = Nat44SetSessionLimit{} }
+func (*Nat44SetSessionLimit) GetMessageName() string { return "nat44_set_session_limit" }
+func (*Nat44SetSessionLimit) GetCrcString() string { return "8899bbb1" }
+func (*Nat44SetSessionLimit) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44SetSessionLimit) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.SessionLimit
+ size += 4 // m.VrfID
+ return size
+}
+func (m *Nat44SetSessionLimit) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.SessionLimit)
+ buf.EncodeUint32(m.VrfID)
+ return buf.Bytes(), nil
+}
+func (m *Nat44SetSessionLimit) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.SessionLimit = buf.DecodeUint32()
+ m.VrfID = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44SetSessionLimitReply defines message 'nat44_set_session_limit_reply'.
+type Nat44SetSessionLimitReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *Nat44SetSessionLimitReply) Reset() { *m = Nat44SetSessionLimitReply{} }
+func (*Nat44SetSessionLimitReply) GetMessageName() string { return "nat44_set_session_limit_reply" }
+func (*Nat44SetSessionLimitReply) GetCrcString() string { return "e8d4e804" }
+func (*Nat44SetSessionLimitReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44SetSessionLimitReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *Nat44SetSessionLimitReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *Nat44SetSessionLimitReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// Nat44ShowRunningConfig defines message 'nat44_show_running_config'.
+// InProgress: the message form may change in the future versions
+type Nat44ShowRunningConfig struct{}
+
+func (m *Nat44ShowRunningConfig) Reset() { *m = Nat44ShowRunningConfig{} }
+func (*Nat44ShowRunningConfig) GetMessageName() string { return "nat44_show_running_config" }
+func (*Nat44ShowRunningConfig) GetCrcString() string { return "51077d14" }
+func (*Nat44ShowRunningConfig) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44ShowRunningConfig) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44ShowRunningConfig) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44ShowRunningConfig) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44ShowRunningConfigReply defines message 'nat44_show_running_config_reply'.
+// InProgress: the message form may change in the future versions
+type Nat44ShowRunningConfigReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ InsideVrf uint32 `binapi:"u32,name=inside_vrf" json:"inside_vrf,omitempty"`
+ OutsideVrf uint32 `binapi:"u32,name=outside_vrf" json:"outside_vrf,omitempty"`
+ Users uint32 `binapi:"u32,name=users" json:"users,omitempty"`
+ Sessions uint32 `binapi:"u32,name=sessions" json:"sessions,omitempty"`
+ UserSessions uint32 `binapi:"u32,name=user_sessions" json:"user_sessions,omitempty"`
+ UserBuckets uint32 `binapi:"u32,name=user_buckets" json:"user_buckets,omitempty"`
+ TranslationBuckets uint32 `binapi:"u32,name=translation_buckets" json:"translation_buckets,omitempty"`
+ ForwardingEnabled bool `binapi:"bool,name=forwarding_enabled" json:"forwarding_enabled,omitempty"`
+ IpfixLoggingEnabled bool `binapi:"bool,name=ipfix_logging_enabled" json:"ipfix_logging_enabled,omitempty"`
+ Timeouts nat_types.NatTimeouts `binapi:"nat_timeouts,name=timeouts" json:"timeouts,omitempty"`
+ LogLevel nat_types.NatLogLevel `binapi:"nat_log_level,name=log_level" json:"log_level,omitempty"`
+ Flags Nat44ConfigFlags `binapi:"nat44_config_flags,name=flags" json:"flags,omitempty"`
+}
+
+func (m *Nat44ShowRunningConfigReply) Reset() { *m = Nat44ShowRunningConfigReply{} }
+func (*Nat44ShowRunningConfigReply) GetMessageName() string { return "nat44_show_running_config_reply" }
+func (*Nat44ShowRunningConfigReply) GetCrcString() string { return "93d8e267" }
+func (*Nat44ShowRunningConfigReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44ShowRunningConfigReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 4 // m.InsideVrf
+ size += 4 // m.OutsideVrf
+ size += 4 // m.Users
+ size += 4 // m.Sessions
+ size += 4 // m.UserSessions
+ size += 4 // m.UserBuckets
+ size += 4 // m.TranslationBuckets
+ size += 1 // m.ForwardingEnabled
+ size += 1 // m.IpfixLoggingEnabled
+ size += 4 // m.Timeouts.UDP
+ size += 4 // m.Timeouts.TCPEstablished
+ size += 4 // m.Timeouts.TCPTransitory
+ size += 4 // m.Timeouts.ICMP
+ size += 1 // m.LogLevel
+ size += 1 // m.Flags
+ return size
+}
+func (m *Nat44ShowRunningConfigReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint32(m.InsideVrf)
+ buf.EncodeUint32(m.OutsideVrf)
+ buf.EncodeUint32(m.Users)
+ buf.EncodeUint32(m.Sessions)
+ buf.EncodeUint32(m.UserSessions)
+ buf.EncodeUint32(m.UserBuckets)
+ buf.EncodeUint32(m.TranslationBuckets)
+ buf.EncodeBool(m.ForwardingEnabled)
+ buf.EncodeBool(m.IpfixLoggingEnabled)
+ buf.EncodeUint32(m.Timeouts.UDP)
+ buf.EncodeUint32(m.Timeouts.TCPEstablished)
+ buf.EncodeUint32(m.Timeouts.TCPTransitory)
+ buf.EncodeUint32(m.Timeouts.ICMP)
+ buf.EncodeUint8(uint8(m.LogLevel))
+ buf.EncodeUint8(uint8(m.Flags))
+ return buf.Bytes(), nil
+}
+func (m *Nat44ShowRunningConfigReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.InsideVrf = buf.DecodeUint32()
+ m.OutsideVrf = buf.DecodeUint32()
+ m.Users = buf.DecodeUint32()
+ m.Sessions = buf.DecodeUint32()
+ m.UserSessions = buf.DecodeUint32()
+ m.UserBuckets = buf.DecodeUint32()
+ m.TranslationBuckets = buf.DecodeUint32()
+ m.ForwardingEnabled = buf.DecodeBool()
+ m.IpfixLoggingEnabled = buf.DecodeBool()
+ m.Timeouts.UDP = buf.DecodeUint32()
+ m.Timeouts.TCPEstablished = buf.DecodeUint32()
+ m.Timeouts.TCPTransitory = buf.DecodeUint32()
+ m.Timeouts.ICMP = buf.DecodeUint32()
+ m.LogLevel = nat_types.NatLogLevel(buf.DecodeUint8())
+ m.Flags = Nat44ConfigFlags(buf.DecodeUint8())
+ return nil
+}
+
+// Nat44StaticMappingDetails defines message 'nat44_static_mapping_details'.
+type Nat44StaticMappingDetails struct {
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ LocalIPAddress ip_types.IP4Address `binapi:"ip4_address,name=local_ip_address" json:"local_ip_address,omitempty"`
+ ExternalIPAddress ip_types.IP4Address `binapi:"ip4_address,name=external_ip_address" json:"external_ip_address,omitempty"`
+ Protocol uint8 `binapi:"u8,name=protocol" json:"protocol,omitempty"`
+ LocalPort uint16 `binapi:"u16,name=local_port" json:"local_port,omitempty"`
+ ExternalPort uint16 `binapi:"u16,name=external_port" json:"external_port,omitempty"`
+ ExternalSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=external_sw_if_index" json:"external_sw_if_index,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ Tag string `binapi:"string[64],name=tag" json:"tag,omitempty"`
+}
+
+func (m *Nat44StaticMappingDetails) Reset() { *m = Nat44StaticMappingDetails{} }
+func (*Nat44StaticMappingDetails) GetMessageName() string { return "nat44_static_mapping_details" }
+func (*Nat44StaticMappingDetails) GetCrcString() string { return "06cb40b2" }
+func (*Nat44StaticMappingDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44StaticMappingDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Flags
+ size += 1 * 4 // m.LocalIPAddress
+ size += 1 * 4 // m.ExternalIPAddress
+ size += 1 // m.Protocol
+ size += 2 // m.LocalPort
+ size += 2 // m.ExternalPort
+ size += 4 // m.ExternalSwIfIndex
+ size += 4 // m.VrfID
+ size += 64 // m.Tag
+ return size
+}
+func (m *Nat44StaticMappingDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeBytes(m.LocalIPAddress[:], 4)
+ buf.EncodeBytes(m.ExternalIPAddress[:], 4)
+ buf.EncodeUint8(m.Protocol)
+ buf.EncodeUint16(m.LocalPort)
+ buf.EncodeUint16(m.ExternalPort)
+ buf.EncodeUint32(uint32(m.ExternalSwIfIndex))
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeString(m.Tag, 64)
+ return buf.Bytes(), nil
+}
+func (m *Nat44StaticMappingDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ copy(m.LocalIPAddress[:], buf.DecodeBytes(4))
+ copy(m.ExternalIPAddress[:], buf.DecodeBytes(4))
+ m.Protocol = buf.DecodeUint8()
+ m.LocalPort = buf.DecodeUint16()
+ m.ExternalPort = buf.DecodeUint16()
+ m.ExternalSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
+ m.VrfID = buf.DecodeUint32()
+ m.Tag = buf.DecodeString(64)
+ return nil
+}
+
+// Nat44StaticMappingDump defines message 'nat44_static_mapping_dump'.
+type Nat44StaticMappingDump struct{}
+
+func (m *Nat44StaticMappingDump) Reset() { *m = Nat44StaticMappingDump{} }
+func (*Nat44StaticMappingDump) GetMessageName() string { return "nat44_static_mapping_dump" }
+func (*Nat44StaticMappingDump) GetCrcString() string { return "51077d14" }
+func (*Nat44StaticMappingDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44StaticMappingDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44StaticMappingDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44StaticMappingDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44UserDetails defines message 'nat44_user_details'.
+type Nat44UserDetails struct {
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Nsessions uint32 `binapi:"u32,name=nsessions" json:"nsessions,omitempty"`
+ Nstaticsessions uint32 `binapi:"u32,name=nstaticsessions" json:"nstaticsessions,omitempty"`
+}
+
+func (m *Nat44UserDetails) Reset() { *m = Nat44UserDetails{} }
+func (*Nat44UserDetails) GetMessageName() string { return "nat44_user_details" }
+func (*Nat44UserDetails) GetCrcString() string { return "355896c2" }
+func (*Nat44UserDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44UserDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.VrfID
+ size += 1 * 4 // m.IPAddress
+ size += 4 // m.Nsessions
+ size += 4 // m.Nstaticsessions
+ return size
+}
+func (m *Nat44UserDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.VrfID)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint32(m.Nsessions)
+ buf.EncodeUint32(m.Nstaticsessions)
+ return buf.Bytes(), nil
+}
+func (m *Nat44UserDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.VrfID = buf.DecodeUint32()
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Nsessions = buf.DecodeUint32()
+ m.Nstaticsessions = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44UserDump defines message 'nat44_user_dump'.
+type Nat44UserDump struct{}
+
+func (m *Nat44UserDump) Reset() { *m = Nat44UserDump{} }
+func (*Nat44UserDump) GetMessageName() string { return "nat44_user_dump" }
+func (*Nat44UserDump) GetCrcString() string { return "51077d14" }
+func (*Nat44UserDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44UserDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *Nat44UserDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *Nat44UserDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+// Nat44UserSessionDetails defines message 'nat44_user_session_details'.
+type Nat44UserSessionDetails struct {
+ OutsideIPAddress ip_types.IP4Address `binapi:"ip4_address,name=outside_ip_address" json:"outside_ip_address,omitempty"`
+ OutsidePort uint16 `binapi:"u16,name=outside_port" json:"outside_port,omitempty"`
+ InsideIPAddress ip_types.IP4Address `binapi:"ip4_address,name=inside_ip_address" json:"inside_ip_address,omitempty"`
+ InsidePort uint16 `binapi:"u16,name=inside_port" json:"inside_port,omitempty"`
+ Protocol uint16 `binapi:"u16,name=protocol" json:"protocol,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ LastHeard uint64 `binapi:"u64,name=last_heard" json:"last_heard,omitempty"`
+ TotalBytes uint64 `binapi:"u64,name=total_bytes" json:"total_bytes,omitempty"`
+ TotalPkts uint32 `binapi:"u32,name=total_pkts" json:"total_pkts,omitempty"`
+ ExtHostAddress ip_types.IP4Address `binapi:"ip4_address,name=ext_host_address" json:"ext_host_address,omitempty"`
+ ExtHostPort uint16 `binapi:"u16,name=ext_host_port" json:"ext_host_port,omitempty"`
+ ExtHostNatAddress ip_types.IP4Address `binapi:"ip4_address,name=ext_host_nat_address" json:"ext_host_nat_address,omitempty"`
+ ExtHostNatPort uint16 `binapi:"u16,name=ext_host_nat_port" json:"ext_host_nat_port,omitempty"`
+}
+
+func (m *Nat44UserSessionDetails) Reset() { *m = Nat44UserSessionDetails{} }
+func (*Nat44UserSessionDetails) GetMessageName() string { return "nat44_user_session_details" }
+func (*Nat44UserSessionDetails) GetCrcString() string { return "2cf6e16d" }
+func (*Nat44UserSessionDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44UserSessionDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.OutsideIPAddress
+ size += 2 // m.OutsidePort
+ size += 1 * 4 // m.InsideIPAddress
+ size += 2 // m.InsidePort
+ size += 2 // m.Protocol
+ size += 1 // m.Flags
+ size += 8 // m.LastHeard
+ size += 8 // m.TotalBytes
+ size += 4 // m.TotalPkts
+ size += 1 * 4 // m.ExtHostAddress
+ size += 2 // m.ExtHostPort
+ size += 1 * 4 // m.ExtHostNatAddress
+ size += 2 // m.ExtHostNatPort
+ return size
+}
+func (m *Nat44UserSessionDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.OutsideIPAddress[:], 4)
+ buf.EncodeUint16(m.OutsidePort)
+ buf.EncodeBytes(m.InsideIPAddress[:], 4)
+ buf.EncodeUint16(m.InsidePort)
+ buf.EncodeUint16(m.Protocol)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint64(m.LastHeard)
+ buf.EncodeUint64(m.TotalBytes)
+ buf.EncodeUint32(m.TotalPkts)
+ buf.EncodeBytes(m.ExtHostAddress[:], 4)
+ buf.EncodeUint16(m.ExtHostPort)
+ buf.EncodeBytes(m.ExtHostNatAddress[:], 4)
+ buf.EncodeUint16(m.ExtHostNatPort)
+ return buf.Bytes(), nil
+}
+func (m *Nat44UserSessionDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.OutsideIPAddress[:], buf.DecodeBytes(4))
+ m.OutsidePort = buf.DecodeUint16()
+ copy(m.InsideIPAddress[:], buf.DecodeBytes(4))
+ m.InsidePort = buf.DecodeUint16()
+ m.Protocol = buf.DecodeUint16()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.LastHeard = buf.DecodeUint64()
+ m.TotalBytes = buf.DecodeUint64()
+ m.TotalPkts = buf.DecodeUint32()
+ copy(m.ExtHostAddress[:], buf.DecodeBytes(4))
+ m.ExtHostPort = buf.DecodeUint16()
+ copy(m.ExtHostNatAddress[:], buf.DecodeBytes(4))
+ m.ExtHostNatPort = buf.DecodeUint16()
+ return nil
+}
+
+// Nat44UserSessionDump defines message 'nat44_user_session_dump'.
+type Nat44UserSessionDump struct {
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+}
+
+func (m *Nat44UserSessionDump) Reset() { *m = Nat44UserSessionDump{} }
+func (*Nat44UserSessionDump) GetMessageName() string { return "nat44_user_session_dump" }
+func (*Nat44UserSessionDump) GetCrcString() string { return "e1899c98" }
+func (*Nat44UserSessionDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44UserSessionDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.IPAddress
+ size += 4 // m.VrfID
+ return size
+}
+func (m *Nat44UserSessionDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint32(m.VrfID)
+ return buf.Bytes(), nil
+}
+func (m *Nat44UserSessionDump) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.VrfID = buf.DecodeUint32()
+ return nil
+}
+
+// Nat44UserSessionV2Details defines message 'nat44_user_session_v2_details'.
+// InProgress: the message form may change in the future versions
+type Nat44UserSessionV2Details struct {
+ OutsideIPAddress ip_types.IP4Address `binapi:"ip4_address,name=outside_ip_address" json:"outside_ip_address,omitempty"`
+ OutsidePort uint16 `binapi:"u16,name=outside_port" json:"outside_port,omitempty"`
+ InsideIPAddress ip_types.IP4Address `binapi:"ip4_address,name=inside_ip_address" json:"inside_ip_address,omitempty"`
+ InsidePort uint16 `binapi:"u16,name=inside_port" json:"inside_port,omitempty"`
+ Protocol uint16 `binapi:"u16,name=protocol" json:"protocol,omitempty"`
+ Flags nat_types.NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
+ LastHeard uint64 `binapi:"u64,name=last_heard" json:"last_heard,omitempty"`
+ TotalBytes uint64 `binapi:"u64,name=total_bytes" json:"total_bytes,omitempty"`
+ TotalPkts uint32 `binapi:"u32,name=total_pkts" json:"total_pkts,omitempty"`
+ ExtHostAddress ip_types.IP4Address `binapi:"ip4_address,name=ext_host_address" json:"ext_host_address,omitempty"`
+ ExtHostPort uint16 `binapi:"u16,name=ext_host_port" json:"ext_host_port,omitempty"`
+ ExtHostNatAddress ip_types.IP4Address `binapi:"ip4_address,name=ext_host_nat_address" json:"ext_host_nat_address,omitempty"`
+ ExtHostNatPort uint16 `binapi:"u16,name=ext_host_nat_port" json:"ext_host_nat_port,omitempty"`
+ IsTimedOut bool `binapi:"bool,name=is_timed_out" json:"is_timed_out,omitempty"`
+}
+
+func (m *Nat44UserSessionV2Details) Reset() { *m = Nat44UserSessionV2Details{} }
+func (*Nat44UserSessionV2Details) GetMessageName() string { return "nat44_user_session_v2_details" }
+func (*Nat44UserSessionV2Details) GetCrcString() string { return "fd42b729" }
+func (*Nat44UserSessionV2Details) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *Nat44UserSessionV2Details) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.OutsideIPAddress
+ size += 2 // m.OutsidePort
+ size += 1 * 4 // m.InsideIPAddress
+ size += 2 // m.InsidePort
+ size += 2 // m.Protocol
+ size += 1 // m.Flags
+ size += 8 // m.LastHeard
+ size += 8 // m.TotalBytes
+ size += 4 // m.TotalPkts
+ size += 1 * 4 // m.ExtHostAddress
+ size += 2 // m.ExtHostPort
+ size += 1 * 4 // m.ExtHostNatAddress
+ size += 2 // m.ExtHostNatPort
+ size += 1 // m.IsTimedOut
+ return size
+}
+func (m *Nat44UserSessionV2Details) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.OutsideIPAddress[:], 4)
+ buf.EncodeUint16(m.OutsidePort)
+ buf.EncodeBytes(m.InsideIPAddress[:], 4)
+ buf.EncodeUint16(m.InsidePort)
+ buf.EncodeUint16(m.Protocol)
+ buf.EncodeUint8(uint8(m.Flags))
+ buf.EncodeUint64(m.LastHeard)
+ buf.EncodeUint64(m.TotalBytes)
+ buf.EncodeUint32(m.TotalPkts)
+ buf.EncodeBytes(m.ExtHostAddress[:], 4)
+ buf.EncodeUint16(m.ExtHostPort)
+ buf.EncodeBytes(m.ExtHostNatAddress[:], 4)
+ buf.EncodeUint16(m.ExtHostNatPort)
+ buf.EncodeBool(m.IsTimedOut)
+ return buf.Bytes(), nil
+}
+func (m *Nat44UserSessionV2Details) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.OutsideIPAddress[:], buf.DecodeBytes(4))
+ m.OutsidePort = buf.DecodeUint16()
+ copy(m.InsideIPAddress[:], buf.DecodeBytes(4))
+ m.InsidePort = buf.DecodeUint16()
+ m.Protocol = buf.DecodeUint16()
+ m.Flags = nat_types.NatConfigFlags(buf.DecodeUint8())
+ m.LastHeard = buf.DecodeUint64()
+ m.TotalBytes = buf.DecodeUint64()
+ m.TotalPkts = buf.DecodeUint32()
+ copy(m.ExtHostAddress[:], buf.DecodeBytes(4))
+ m.ExtHostPort = buf.DecodeUint16()
+ copy(m.ExtHostNatAddress[:], buf.DecodeBytes(4))
+ m.ExtHostNatPort = buf.DecodeUint16()
+ m.IsTimedOut = buf.DecodeBool()
+ return nil
+}
+
+// Nat44UserSessionV2Dump defines message 'nat44_user_session_v2_dump'.
+// InProgress: the message form may change in the future versions
+type Nat44UserSessionV2Dump struct {
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ VrfID uint32 `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
+}
+
+func (m *Nat44UserSessionV2Dump) Reset() { *m = Nat44UserSessionV2Dump{} }
+func (*Nat44UserSessionV2Dump) GetMessageName() string { return "nat44_user_session_v2_dump" }
+func (*Nat44UserSessionV2Dump) GetCrcString() string { return "e1899c98" }
+func (*Nat44UserSessionV2Dump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *Nat44UserSessionV2Dump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.IPAddress
+ size += 4 // m.VrfID
+ return size
+}
+func (m *Nat44UserSessionV2Dump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint32(m.VrfID)
+ return buf.Bytes(), nil
+}
+func (m *Nat44UserSessionV2Dump) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.VrfID = buf.DecodeUint32()
+ return nil
+}
+
+// NatControlPing defines message 'nat_control_ping'.
+// Deprecated: the message will be removed in the future versions
+type NatControlPing struct{}
+
+func (m *NatControlPing) Reset() { *m = NatControlPing{} }
+func (*NatControlPing) GetMessageName() string { return "nat_control_ping" }
+func (*NatControlPing) GetCrcString() string { return "51077d14" }
+func (*NatControlPing) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatControlPing) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatControlPing) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatControlPing) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatControlPingReply defines message 'nat_control_ping_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatControlPingReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ ClientIndex uint32 `binapi:"u32,name=client_index" json:"client_index,omitempty"`
+ VpePID uint32 `binapi:"u32,name=vpe_pid" json:"vpe_pid,omitempty"`
+}
+
+func (m *NatControlPingReply) Reset() { *m = NatControlPingReply{} }
+func (*NatControlPingReply) GetMessageName() string { return "nat_control_ping_reply" }
+func (*NatControlPingReply) GetCrcString() string { return "f6b0b8ca" }
+func (*NatControlPingReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatControlPingReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 4 // m.ClientIndex
+ size += 4 // m.VpePID
+ return size
+}
+func (m *NatControlPingReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint32(m.ClientIndex)
+ buf.EncodeUint32(m.VpePID)
+ return buf.Bytes(), nil
+}
+func (m *NatControlPingReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.ClientIndex = buf.DecodeUint32()
+ m.VpePID = buf.DecodeUint32()
+ return nil
+}
+
+// NatGetAddrAndPortAllocAlg defines message 'nat_get_addr_and_port_alloc_alg'.
+type NatGetAddrAndPortAllocAlg struct{}
+
+func (m *NatGetAddrAndPortAllocAlg) Reset() { *m = NatGetAddrAndPortAllocAlg{} }
+func (*NatGetAddrAndPortAllocAlg) GetMessageName() string { return "nat_get_addr_and_port_alloc_alg" }
+func (*NatGetAddrAndPortAllocAlg) GetCrcString() string { return "51077d14" }
+func (*NatGetAddrAndPortAllocAlg) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatGetAddrAndPortAllocAlg) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatGetAddrAndPortAllocAlg) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatGetAddrAndPortAllocAlg) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatGetAddrAndPortAllocAlgReply defines message 'nat_get_addr_and_port_alloc_alg_reply'.
+type NatGetAddrAndPortAllocAlgReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ Alg uint8 `binapi:"u8,name=alg" json:"alg,omitempty"`
+ PsidOffset uint8 `binapi:"u8,name=psid_offset" json:"psid_offset,omitempty"`
+ PsidLength uint8 `binapi:"u8,name=psid_length" json:"psid_length,omitempty"`
+ Psid uint16 `binapi:"u16,name=psid" json:"psid,omitempty"`
+ StartPort uint16 `binapi:"u16,name=start_port" json:"start_port,omitempty"`
+ EndPort uint16 `binapi:"u16,name=end_port" json:"end_port,omitempty"`
+}
+
+func (m *NatGetAddrAndPortAllocAlgReply) Reset() { *m = NatGetAddrAndPortAllocAlgReply{} }
+func (*NatGetAddrAndPortAllocAlgReply) GetMessageName() string {
+ return "nat_get_addr_and_port_alloc_alg_reply"
+}
+func (*NatGetAddrAndPortAllocAlgReply) GetCrcString() string { return "3607a7d0" }
+func (*NatGetAddrAndPortAllocAlgReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatGetAddrAndPortAllocAlgReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 1 // m.Alg
+ size += 1 // m.PsidOffset
+ size += 1 // m.PsidLength
+ size += 2 // m.Psid
+ size += 2 // m.StartPort
+ size += 2 // m.EndPort
+ return size
+}
+func (m *NatGetAddrAndPortAllocAlgReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint8(m.Alg)
+ buf.EncodeUint8(m.PsidOffset)
+ buf.EncodeUint8(m.PsidLength)
+ buf.EncodeUint16(m.Psid)
+ buf.EncodeUint16(m.StartPort)
+ buf.EncodeUint16(m.EndPort)
+ return buf.Bytes(), nil
+}
+func (m *NatGetAddrAndPortAllocAlgReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.Alg = buf.DecodeUint8()
+ m.PsidOffset = buf.DecodeUint8()
+ m.PsidLength = buf.DecodeUint8()
+ m.Psid = buf.DecodeUint16()
+ m.StartPort = buf.DecodeUint16()
+ m.EndPort = buf.DecodeUint16()
+ return nil
+}
+
+// NatGetMssClamping defines message 'nat_get_mss_clamping'.
+type NatGetMssClamping struct{}
+
+func (m *NatGetMssClamping) Reset() { *m = NatGetMssClamping{} }
+func (*NatGetMssClamping) GetMessageName() string { return "nat_get_mss_clamping" }
+func (*NatGetMssClamping) GetCrcString() string { return "51077d14" }
+func (*NatGetMssClamping) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatGetMssClamping) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatGetMssClamping) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatGetMssClamping) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatGetMssClampingReply defines message 'nat_get_mss_clamping_reply'.
+type NatGetMssClampingReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ MssValue uint16 `binapi:"u16,name=mss_value" json:"mss_value,omitempty"`
+ Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
+}
+
+func (m *NatGetMssClampingReply) Reset() { *m = NatGetMssClampingReply{} }
+func (*NatGetMssClampingReply) GetMessageName() string { return "nat_get_mss_clamping_reply" }
+func (*NatGetMssClampingReply) GetCrcString() string { return "1c0b2a78" }
+func (*NatGetMssClampingReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatGetMssClampingReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 2 // m.MssValue
+ size += 1 // m.Enable
+ return size
+}
+func (m *NatGetMssClampingReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint16(m.MssValue)
+ buf.EncodeBool(m.Enable)
+ return buf.Bytes(), nil
+}
+func (m *NatGetMssClampingReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.MssValue = buf.DecodeUint16()
+ m.Enable = buf.DecodeBool()
+ return nil
+}
+
+// NatGetTimeouts defines message 'nat_get_timeouts'.
+// Deprecated: the message will be removed in the future versions
+type NatGetTimeouts struct{}
+
+func (m *NatGetTimeouts) Reset() { *m = NatGetTimeouts{} }
+func (*NatGetTimeouts) GetMessageName() string { return "nat_get_timeouts" }
+func (*NatGetTimeouts) GetCrcString() string { return "51077d14" }
+func (*NatGetTimeouts) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatGetTimeouts) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatGetTimeouts) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatGetTimeouts) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatGetTimeoutsReply defines message 'nat_get_timeouts_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatGetTimeoutsReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ UDP uint32 `binapi:"u32,name=udp" json:"udp,omitempty"`
+ TCPEstablished uint32 `binapi:"u32,name=tcp_established" json:"tcp_established,omitempty"`
+ TCPTransitory uint32 `binapi:"u32,name=tcp_transitory" json:"tcp_transitory,omitempty"`
+ ICMP uint32 `binapi:"u32,name=icmp" json:"icmp,omitempty"`
+}
+
+func (m *NatGetTimeoutsReply) Reset() { *m = NatGetTimeoutsReply{} }
+func (*NatGetTimeoutsReply) GetMessageName() string { return "nat_get_timeouts_reply" }
+func (*NatGetTimeoutsReply) GetCrcString() string { return "3c4df4e1" }
+func (*NatGetTimeoutsReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatGetTimeoutsReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 4 // m.UDP
+ size += 4 // m.TCPEstablished
+ size += 4 // m.TCPTransitory
+ size += 4 // m.ICMP
+ return size
+}
+func (m *NatGetTimeoutsReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeUint32(m.UDP)
+ buf.EncodeUint32(m.TCPEstablished)
+ buf.EncodeUint32(m.TCPTransitory)
+ buf.EncodeUint32(m.ICMP)
+ return buf.Bytes(), nil
+}
+func (m *NatGetTimeoutsReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.UDP = buf.DecodeUint32()
+ m.TCPEstablished = buf.DecodeUint32()
+ m.TCPTransitory = buf.DecodeUint32()
+ m.ICMP = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaFlush defines message 'nat_ha_flush'.
+type NatHaFlush struct{}
+
+func (m *NatHaFlush) Reset() { *m = NatHaFlush{} }
+func (*NatHaFlush) GetMessageName() string { return "nat_ha_flush" }
+func (*NatHaFlush) GetCrcString() string { return "51077d14" }
+func (*NatHaFlush) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatHaFlush) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatHaFlush) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatHaFlush) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatHaFlushReply defines message 'nat_ha_flush_reply'.
+type NatHaFlushReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatHaFlushReply) Reset() { *m = NatHaFlushReply{} }
+func (*NatHaFlushReply) GetMessageName() string { return "nat_ha_flush_reply" }
+func (*NatHaFlushReply) GetCrcString() string { return "e8d4e804" }
+func (*NatHaFlushReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatHaFlushReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatHaFlushReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatHaFlushReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatHaGetFailover defines message 'nat_ha_get_failover'.
+type NatHaGetFailover struct{}
+
+func (m *NatHaGetFailover) Reset() { *m = NatHaGetFailover{} }
+func (*NatHaGetFailover) GetMessageName() string { return "nat_ha_get_failover" }
+func (*NatHaGetFailover) GetCrcString() string { return "51077d14" }
+func (*NatHaGetFailover) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatHaGetFailover) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatHaGetFailover) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatHaGetFailover) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatHaGetFailoverReply defines message 'nat_ha_get_failover_reply'.
+type NatHaGetFailoverReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ SessionRefreshInterval uint32 `binapi:"u32,name=session_refresh_interval" json:"session_refresh_interval,omitempty"`
+}
+
+func (m *NatHaGetFailoverReply) Reset() { *m = NatHaGetFailoverReply{} }
+func (*NatHaGetFailoverReply) GetMessageName() string { return "nat_ha_get_failover_reply" }
+func (*NatHaGetFailoverReply) GetCrcString() string { return "a67d8752" }
+func (*NatHaGetFailoverReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatHaGetFailoverReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 1 * 4 // m.IPAddress
+ size += 2 // m.Port
+ size += 4 // m.SessionRefreshInterval
+ return size
+}
+func (m *NatHaGetFailoverReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(m.SessionRefreshInterval)
+ return buf.Bytes(), nil
+}
+func (m *NatHaGetFailoverReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Port = buf.DecodeUint16()
+ m.SessionRefreshInterval = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaGetListener defines message 'nat_ha_get_listener'.
+type NatHaGetListener struct{}
+
+func (m *NatHaGetListener) Reset() { *m = NatHaGetListener{} }
+func (*NatHaGetListener) GetMessageName() string { return "nat_ha_get_listener" }
+func (*NatHaGetListener) GetCrcString() string { return "51077d14" }
+func (*NatHaGetListener) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatHaGetListener) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatHaGetListener) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatHaGetListener) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatHaGetListenerReply defines message 'nat_ha_get_listener_reply'.
+type NatHaGetListenerReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ PathMtu uint32 `binapi:"u32,name=path_mtu" json:"path_mtu,omitempty"`
+}
+
+func (m *NatHaGetListenerReply) Reset() { *m = NatHaGetListenerReply{} }
+func (*NatHaGetListenerReply) GetMessageName() string { return "nat_ha_get_listener_reply" }
+func (*NatHaGetListenerReply) GetCrcString() string { return "123ea41f" }
+func (*NatHaGetListenerReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatHaGetListenerReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 1 * 4 // m.IPAddress
+ size += 2 // m.Port
+ size += 4 // m.PathMtu
+ return size
+}
+func (m *NatHaGetListenerReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(m.PathMtu)
+ return buf.Bytes(), nil
+}
+func (m *NatHaGetListenerReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Port = buf.DecodeUint16()
+ m.PathMtu = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaResync defines message 'nat_ha_resync'.
+type NatHaResync struct {
+ WantResyncEvent uint8 `binapi:"u8,name=want_resync_event" json:"want_resync_event,omitempty"`
+ PID uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
+}
+
+func (m *NatHaResync) Reset() { *m = NatHaResync{} }
+func (*NatHaResync) GetMessageName() string { return "nat_ha_resync" }
+func (*NatHaResync) GetCrcString() string { return "c8ab9e03" }
+func (*NatHaResync) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatHaResync) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.WantResyncEvent
+ size += 4 // m.PID
+ return size
+}
+func (m *NatHaResync) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(m.WantResyncEvent)
+ buf.EncodeUint32(m.PID)
+ return buf.Bytes(), nil
+}
+func (m *NatHaResync) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.WantResyncEvent = buf.DecodeUint8()
+ m.PID = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaResyncCompletedEvent defines message 'nat_ha_resync_completed_event'.
+type NatHaResyncCompletedEvent struct {
+ PID uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
+ MissedCount uint32 `binapi:"u32,name=missed_count" json:"missed_count,omitempty"`
+}
+
+func (m *NatHaResyncCompletedEvent) Reset() { *m = NatHaResyncCompletedEvent{} }
+func (*NatHaResyncCompletedEvent) GetMessageName() string { return "nat_ha_resync_completed_event" }
+func (*NatHaResyncCompletedEvent) GetCrcString() string { return "fdc598fb" }
+func (*NatHaResyncCompletedEvent) GetMessageType() api.MessageType {
+ return api.EventMessage
+}
+
+func (m *NatHaResyncCompletedEvent) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.PID
+ size += 4 // m.MissedCount
+ return size
+}
+func (m *NatHaResyncCompletedEvent) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.PID)
+ buf.EncodeUint32(m.MissedCount)
+ return buf.Bytes(), nil
+}
+func (m *NatHaResyncCompletedEvent) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.PID = buf.DecodeUint32()
+ m.MissedCount = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaResyncReply defines message 'nat_ha_resync_reply'.
+type NatHaResyncReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatHaResyncReply) Reset() { *m = NatHaResyncReply{} }
+func (*NatHaResyncReply) GetMessageName() string { return "nat_ha_resync_reply" }
+func (*NatHaResyncReply) GetCrcString() string { return "e8d4e804" }
+func (*NatHaResyncReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatHaResyncReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatHaResyncReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatHaResyncReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatHaSetFailover defines message 'nat_ha_set_failover'.
+type NatHaSetFailover struct {
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ SessionRefreshInterval uint32 `binapi:"u32,name=session_refresh_interval" json:"session_refresh_interval,omitempty"`
+}
+
+func (m *NatHaSetFailover) Reset() { *m = NatHaSetFailover{} }
+func (*NatHaSetFailover) GetMessageName() string { return "nat_ha_set_failover" }
+func (*NatHaSetFailover) GetCrcString() string { return "718246af" }
+func (*NatHaSetFailover) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatHaSetFailover) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.IPAddress
+ size += 2 // m.Port
+ size += 4 // m.SessionRefreshInterval
+ return size
+}
+func (m *NatHaSetFailover) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(m.SessionRefreshInterval)
+ return buf.Bytes(), nil
+}
+func (m *NatHaSetFailover) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Port = buf.DecodeUint16()
+ m.SessionRefreshInterval = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaSetFailoverReply defines message 'nat_ha_set_failover_reply'.
+type NatHaSetFailoverReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatHaSetFailoverReply) Reset() { *m = NatHaSetFailoverReply{} }
+func (*NatHaSetFailoverReply) GetMessageName() string { return "nat_ha_set_failover_reply" }
+func (*NatHaSetFailoverReply) GetCrcString() string { return "e8d4e804" }
+func (*NatHaSetFailoverReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatHaSetFailoverReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatHaSetFailoverReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatHaSetFailoverReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatHaSetListener defines message 'nat_ha_set_listener'.
+type NatHaSetListener struct {
+ IPAddress ip_types.IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
+ Port uint16 `binapi:"u16,name=port" json:"port,omitempty"`
+ PathMtu uint32 `binapi:"u32,name=path_mtu" json:"path_mtu,omitempty"`
+}
+
+func (m *NatHaSetListener) Reset() { *m = NatHaSetListener{} }
+func (*NatHaSetListener) GetMessageName() string { return "nat_ha_set_listener" }
+func (*NatHaSetListener) GetCrcString() string { return "e4a8cb4e" }
+func (*NatHaSetListener) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatHaSetListener) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 * 4 // m.IPAddress
+ size += 2 // m.Port
+ size += 4 // m.PathMtu
+ return size
+}
+func (m *NatHaSetListener) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeBytes(m.IPAddress[:], 4)
+ buf.EncodeUint16(m.Port)
+ buf.EncodeUint32(m.PathMtu)
+ return buf.Bytes(), nil
+}
+func (m *NatHaSetListener) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ copy(m.IPAddress[:], buf.DecodeBytes(4))
+ m.Port = buf.DecodeUint16()
+ m.PathMtu = buf.DecodeUint32()
+ return nil
+}
+
+// NatHaSetListenerReply defines message 'nat_ha_set_listener_reply'.
+type NatHaSetListenerReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatHaSetListenerReply) Reset() { *m = NatHaSetListenerReply{} }
+func (*NatHaSetListenerReply) GetMessageName() string { return "nat_ha_set_listener_reply" }
+func (*NatHaSetListenerReply) GetCrcString() string { return "e8d4e804" }
+func (*NatHaSetListenerReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatHaSetListenerReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatHaSetListenerReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatHaSetListenerReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatIpfixEnableDisable defines message 'nat_ipfix_enable_disable'.
+// Deprecated: the message will be removed in the future versions
+type NatIpfixEnableDisable struct {
+ DomainID uint32 `binapi:"u32,name=domain_id" json:"domain_id,omitempty"`
+ SrcPort uint16 `binapi:"u16,name=src_port" json:"src_port,omitempty"`
+ Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
+}
+
+func (m *NatIpfixEnableDisable) Reset() { *m = NatIpfixEnableDisable{} }
+func (*NatIpfixEnableDisable) GetMessageName() string { return "nat_ipfix_enable_disable" }
+func (*NatIpfixEnableDisable) GetCrcString() string { return "9af4a2d2" }
+func (*NatIpfixEnableDisable) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatIpfixEnableDisable) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.DomainID
+ size += 2 // m.SrcPort
+ size += 1 // m.Enable
+ return size
+}
+func (m *NatIpfixEnableDisable) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.DomainID)
+ buf.EncodeUint16(m.SrcPort)
+ buf.EncodeBool(m.Enable)
+ return buf.Bytes(), nil
+}
+func (m *NatIpfixEnableDisable) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.DomainID = buf.DecodeUint32()
+ m.SrcPort = buf.DecodeUint16()
+ m.Enable = buf.DecodeBool()
+ return nil
+}
+
+// NatIpfixEnableDisableReply defines message 'nat_ipfix_enable_disable_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatIpfixEnableDisableReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatIpfixEnableDisableReply) Reset() { *m = NatIpfixEnableDisableReply{} }
+func (*NatIpfixEnableDisableReply) GetMessageName() string { return "nat_ipfix_enable_disable_reply" }
+func (*NatIpfixEnableDisableReply) GetCrcString() string { return "e8d4e804" }
+func (*NatIpfixEnableDisableReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatIpfixEnableDisableReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatIpfixEnableDisableReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatIpfixEnableDisableReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatSetAddrAndPortAllocAlg defines message 'nat_set_addr_and_port_alloc_alg'.
+type NatSetAddrAndPortAllocAlg struct {
+ Alg uint8 `binapi:"u8,name=alg" json:"alg,omitempty"`
+ PsidOffset uint8 `binapi:"u8,name=psid_offset" json:"psid_offset,omitempty"`
+ PsidLength uint8 `binapi:"u8,name=psid_length" json:"psid_length,omitempty"`
+ Psid uint16 `binapi:"u16,name=psid" json:"psid,omitempty"`
+ StartPort uint16 `binapi:"u16,name=start_port" json:"start_port,omitempty"`
+ EndPort uint16 `binapi:"u16,name=end_port" json:"end_port,omitempty"`
+}
+
+func (m *NatSetAddrAndPortAllocAlg) Reset() { *m = NatSetAddrAndPortAllocAlg{} }
+func (*NatSetAddrAndPortAllocAlg) GetMessageName() string { return "nat_set_addr_and_port_alloc_alg" }
+func (*NatSetAddrAndPortAllocAlg) GetCrcString() string { return "deeb746f" }
+func (*NatSetAddrAndPortAllocAlg) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatSetAddrAndPortAllocAlg) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.Alg
+ size += 1 // m.PsidOffset
+ size += 1 // m.PsidLength
+ size += 2 // m.Psid
+ size += 2 // m.StartPort
+ size += 2 // m.EndPort
+ return size
+}
+func (m *NatSetAddrAndPortAllocAlg) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(m.Alg)
+ buf.EncodeUint8(m.PsidOffset)
+ buf.EncodeUint8(m.PsidLength)
+ buf.EncodeUint16(m.Psid)
+ buf.EncodeUint16(m.StartPort)
+ buf.EncodeUint16(m.EndPort)
+ return buf.Bytes(), nil
+}
+func (m *NatSetAddrAndPortAllocAlg) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Alg = buf.DecodeUint8()
+ m.PsidOffset = buf.DecodeUint8()
+ m.PsidLength = buf.DecodeUint8()
+ m.Psid = buf.DecodeUint16()
+ m.StartPort = buf.DecodeUint16()
+ m.EndPort = buf.DecodeUint16()
+ return nil
+}
+
+// NatSetAddrAndPortAllocAlgReply defines message 'nat_set_addr_and_port_alloc_alg_reply'.
+type NatSetAddrAndPortAllocAlgReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatSetAddrAndPortAllocAlgReply) Reset() { *m = NatSetAddrAndPortAllocAlgReply{} }
+func (*NatSetAddrAndPortAllocAlgReply) GetMessageName() string {
+ return "nat_set_addr_and_port_alloc_alg_reply"
+}
+func (*NatSetAddrAndPortAllocAlgReply) GetCrcString() string { return "e8d4e804" }
+func (*NatSetAddrAndPortAllocAlgReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatSetAddrAndPortAllocAlgReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatSetAddrAndPortAllocAlgReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatSetAddrAndPortAllocAlgReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatSetLogLevel defines message 'nat_set_log_level'.
+// Deprecated: the message will be removed in the future versions
+type NatSetLogLevel struct {
+ LogLevel nat_types.NatLogLevel `binapi:"nat_log_level,name=log_level" json:"log_level,omitempty"`
+}
+
+func (m *NatSetLogLevel) Reset() { *m = NatSetLogLevel{} }
+func (*NatSetLogLevel) GetMessageName() string { return "nat_set_log_level" }
+func (*NatSetLogLevel) GetCrcString() string { return "70076bfe" }
+func (*NatSetLogLevel) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatSetLogLevel) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 1 // m.LogLevel
+ return size
+}
+func (m *NatSetLogLevel) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint8(uint8(m.LogLevel))
+ return buf.Bytes(), nil
+}
+func (m *NatSetLogLevel) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.LogLevel = nat_types.NatLogLevel(buf.DecodeUint8())
+ return nil
+}
+
+// NatSetLogLevelReply defines message 'nat_set_log_level_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatSetLogLevelReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatSetLogLevelReply) Reset() { *m = NatSetLogLevelReply{} }
+func (*NatSetLogLevelReply) GetMessageName() string { return "nat_set_log_level_reply" }
+func (*NatSetLogLevelReply) GetCrcString() string { return "e8d4e804" }
+func (*NatSetLogLevelReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatSetLogLevelReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatSetLogLevelReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatSetLogLevelReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatSetMssClamping defines message 'nat_set_mss_clamping'.
+type NatSetMssClamping struct {
+ MssValue uint16 `binapi:"u16,name=mss_value" json:"mss_value,omitempty"`
+ Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
+}
+
+func (m *NatSetMssClamping) Reset() { *m = NatSetMssClamping{} }
+func (*NatSetMssClamping) GetMessageName() string { return "nat_set_mss_clamping" }
+func (*NatSetMssClamping) GetCrcString() string { return "25e90abb" }
+func (*NatSetMssClamping) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatSetMssClamping) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 2 // m.MssValue
+ size += 1 // m.Enable
+ return size
+}
+func (m *NatSetMssClamping) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint16(m.MssValue)
+ buf.EncodeBool(m.Enable)
+ return buf.Bytes(), nil
+}
+func (m *NatSetMssClamping) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.MssValue = buf.DecodeUint16()
+ m.Enable = buf.DecodeBool()
+ return nil
+}
+
+// NatSetMssClampingReply defines message 'nat_set_mss_clamping_reply'.
+type NatSetMssClampingReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatSetMssClampingReply) Reset() { *m = NatSetMssClampingReply{} }
+func (*NatSetMssClampingReply) GetMessageName() string { return "nat_set_mss_clamping_reply" }
+func (*NatSetMssClampingReply) GetCrcString() string { return "e8d4e804" }
+func (*NatSetMssClampingReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatSetMssClampingReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatSetMssClampingReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatSetMssClampingReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatSetTimeouts defines message 'nat_set_timeouts'.
+// Deprecated: the message will be removed in the future versions
+type NatSetTimeouts struct {
+ UDP uint32 `binapi:"u32,name=udp" json:"udp,omitempty"`
+ TCPEstablished uint32 `binapi:"u32,name=tcp_established" json:"tcp_established,omitempty"`
+ TCPTransitory uint32 `binapi:"u32,name=tcp_transitory" json:"tcp_transitory,omitempty"`
+ ICMP uint32 `binapi:"u32,name=icmp" json:"icmp,omitempty"`
+}
+
+func (m *NatSetTimeouts) Reset() { *m = NatSetTimeouts{} }
+func (*NatSetTimeouts) GetMessageName() string { return "nat_set_timeouts" }
+func (*NatSetTimeouts) GetCrcString() string { return "d4746b16" }
+func (*NatSetTimeouts) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatSetTimeouts) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.UDP
+ size += 4 // m.TCPEstablished
+ size += 4 // m.TCPTransitory
+ size += 4 // m.ICMP
+ return size
+}
+func (m *NatSetTimeouts) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.UDP)
+ buf.EncodeUint32(m.TCPEstablished)
+ buf.EncodeUint32(m.TCPTransitory)
+ buf.EncodeUint32(m.ICMP)
+ return buf.Bytes(), nil
+}
+func (m *NatSetTimeouts) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.UDP = buf.DecodeUint32()
+ m.TCPEstablished = buf.DecodeUint32()
+ m.TCPTransitory = buf.DecodeUint32()
+ m.ICMP = buf.DecodeUint32()
+ return nil
+}
+
+// NatSetTimeoutsReply defines message 'nat_set_timeouts_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatSetTimeoutsReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatSetTimeoutsReply) Reset() { *m = NatSetTimeoutsReply{} }
+func (*NatSetTimeoutsReply) GetMessageName() string { return "nat_set_timeouts_reply" }
+func (*NatSetTimeoutsReply) GetCrcString() string { return "e8d4e804" }
+func (*NatSetTimeoutsReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatSetTimeoutsReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatSetTimeoutsReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatSetTimeoutsReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatSetWorkers defines message 'nat_set_workers'.
+type NatSetWorkers struct {
+ WorkerMask uint64 `binapi:"u64,name=worker_mask" json:"worker_mask,omitempty"`
+}
+
+func (m *NatSetWorkers) Reset() { *m = NatSetWorkers{} }
+func (*NatSetWorkers) GetMessageName() string { return "nat_set_workers" }
+func (*NatSetWorkers) GetCrcString() string { return "da926638" }
+func (*NatSetWorkers) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatSetWorkers) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 8 // m.WorkerMask
+ return size
+}
+func (m *NatSetWorkers) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint64(m.WorkerMask)
+ return buf.Bytes(), nil
+}
+func (m *NatSetWorkers) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.WorkerMask = buf.DecodeUint64()
+ return nil
+}
+
+// NatSetWorkersReply defines message 'nat_set_workers_reply'.
+type NatSetWorkersReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+}
+
+func (m *NatSetWorkersReply) Reset() { *m = NatSetWorkersReply{} }
+func (*NatSetWorkersReply) GetMessageName() string { return "nat_set_workers_reply" }
+func (*NatSetWorkersReply) GetCrcString() string { return "e8d4e804" }
+func (*NatSetWorkersReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatSetWorkersReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ return size
+}
+func (m *NatSetWorkersReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ return buf.Bytes(), nil
+}
+func (m *NatSetWorkersReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ return nil
+}
+
+// NatShowConfig defines message 'nat_show_config'.
+// Deprecated: the message will be removed in the future versions
+type NatShowConfig struct{}
+
+func (m *NatShowConfig) Reset() { *m = NatShowConfig{} }
+func (*NatShowConfig) GetMessageName() string { return "nat_show_config" }
+func (*NatShowConfig) GetCrcString() string { return "51077d14" }
+func (*NatShowConfig) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatShowConfig) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatShowConfig) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatShowConfig) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatShowConfig2 defines message 'nat_show_config_2'.
+// Deprecated: the message will be removed in the future versions
+type NatShowConfig2 struct{}
+
+func (m *NatShowConfig2) Reset() { *m = NatShowConfig2{} }
+func (*NatShowConfig2) GetMessageName() string { return "nat_show_config_2" }
+func (*NatShowConfig2) GetCrcString() string { return "51077d14" }
+func (*NatShowConfig2) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatShowConfig2) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatShowConfig2) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatShowConfig2) Unmarshal(b []byte) error {
+ return nil
+}
+
+// NatShowConfig2Reply defines message 'nat_show_config_2_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatShowConfig2Reply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ StaticMappingOnly bool `binapi:"bool,name=static_mapping_only" json:"static_mapping_only,omitempty"`
+ StaticMappingConnectionTracking bool `binapi:"bool,name=static_mapping_connection_tracking" json:"static_mapping_connection_tracking,omitempty"`
+ Deterministic bool `binapi:"bool,name=deterministic" json:"deterministic,omitempty"`
+ EndpointDependent bool `binapi:"bool,name=endpoint_dependent" json:"endpoint_dependent,omitempty"`
+ Out2inDpo bool `binapi:"bool,name=out2in_dpo" json:"out2in_dpo,omitempty"`
+ DsliteCe bool `binapi:"bool,name=dslite_ce" json:"dslite_ce,omitempty"`
+ TranslationBuckets uint32 `binapi:"u32,name=translation_buckets" json:"translation_buckets,omitempty"`
+ TranslationMemorySize uint64 `binapi:"u64,name=translation_memory_size" json:"translation_memory_size,omitempty"`
+ UserBuckets uint32 `binapi:"u32,name=user_buckets" json:"user_buckets,omitempty"`
+ UserMemorySize uint64 `binapi:"u64,name=user_memory_size" json:"user_memory_size,omitempty"`
+ MaxTranslationsPerUser uint32 `binapi:"u32,name=max_translations_per_user" json:"max_translations_per_user,omitempty"`
+ OutsideVrfID uint32 `binapi:"u32,name=outside_vrf_id" json:"outside_vrf_id,omitempty"`
+ InsideVrfID uint32 `binapi:"u32,name=inside_vrf_id" json:"inside_vrf_id,omitempty"`
+ Nat64BibBuckets uint32 `binapi:"u32,name=nat64_bib_buckets" json:"nat64_bib_buckets,omitempty"`
+ Nat64BibMemorySize uint64 `binapi:"u64,name=nat64_bib_memory_size" json:"nat64_bib_memory_size,omitempty"`
+ Nat64StBuckets uint32 `binapi:"u32,name=nat64_st_buckets" json:"nat64_st_buckets,omitempty"`
+ Nat64StMemorySize uint64 `binapi:"u64,name=nat64_st_memory_size" json:"nat64_st_memory_size,omitempty"`
+ MaxTranslationsPerThread uint32 `binapi:"u32,name=max_translations_per_thread" json:"max_translations_per_thread,omitempty"`
+ MaxUsersPerThread uint32 `binapi:"u32,name=max_users_per_thread" json:"max_users_per_thread,omitempty"`
+}
+
+func (m *NatShowConfig2Reply) Reset() { *m = NatShowConfig2Reply{} }
+func (*NatShowConfig2Reply) GetMessageName() string { return "nat_show_config_2_reply" }
+func (*NatShowConfig2Reply) GetCrcString() string { return "0404a5b4" }
+func (*NatShowConfig2Reply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatShowConfig2Reply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 1 // m.StaticMappingOnly
+ size += 1 // m.StaticMappingConnectionTracking
+ size += 1 // m.Deterministic
+ size += 1 // m.EndpointDependent
+ size += 1 // m.Out2inDpo
+ size += 1 // m.DsliteCe
+ size += 4 // m.TranslationBuckets
+ size += 8 // m.TranslationMemorySize
+ size += 4 // m.UserBuckets
+ size += 8 // m.UserMemorySize
+ size += 4 // m.MaxTranslationsPerUser
+ size += 4 // m.OutsideVrfID
+ size += 4 // m.InsideVrfID
+ size += 4 // m.Nat64BibBuckets
+ size += 8 // m.Nat64BibMemorySize
+ size += 4 // m.Nat64StBuckets
+ size += 8 // m.Nat64StMemorySize
+ size += 4 // m.MaxTranslationsPerThread
+ size += 4 // m.MaxUsersPerThread
+ return size
+}
+func (m *NatShowConfig2Reply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeBool(m.StaticMappingOnly)
+ buf.EncodeBool(m.StaticMappingConnectionTracking)
+ buf.EncodeBool(m.Deterministic)
+ buf.EncodeBool(m.EndpointDependent)
+ buf.EncodeBool(m.Out2inDpo)
+ buf.EncodeBool(m.DsliteCe)
+ buf.EncodeUint32(m.TranslationBuckets)
+ buf.EncodeUint64(m.TranslationMemorySize)
+ buf.EncodeUint32(m.UserBuckets)
+ buf.EncodeUint64(m.UserMemorySize)
+ buf.EncodeUint32(m.MaxTranslationsPerUser)
+ buf.EncodeUint32(m.OutsideVrfID)
+ buf.EncodeUint32(m.InsideVrfID)
+ buf.EncodeUint32(m.Nat64BibBuckets)
+ buf.EncodeUint64(m.Nat64BibMemorySize)
+ buf.EncodeUint32(m.Nat64StBuckets)
+ buf.EncodeUint64(m.Nat64StMemorySize)
+ buf.EncodeUint32(m.MaxTranslationsPerThread)
+ buf.EncodeUint32(m.MaxUsersPerThread)
+ return buf.Bytes(), nil
+}
+func (m *NatShowConfig2Reply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.StaticMappingOnly = buf.DecodeBool()
+ m.StaticMappingConnectionTracking = buf.DecodeBool()
+ m.Deterministic = buf.DecodeBool()
+ m.EndpointDependent = buf.DecodeBool()
+ m.Out2inDpo = buf.DecodeBool()
+ m.DsliteCe = buf.DecodeBool()
+ m.TranslationBuckets = buf.DecodeUint32()
+ m.TranslationMemorySize = buf.DecodeUint64()
+ m.UserBuckets = buf.DecodeUint32()
+ m.UserMemorySize = buf.DecodeUint64()
+ m.MaxTranslationsPerUser = buf.DecodeUint32()
+ m.OutsideVrfID = buf.DecodeUint32()
+ m.InsideVrfID = buf.DecodeUint32()
+ m.Nat64BibBuckets = buf.DecodeUint32()
+ m.Nat64BibMemorySize = buf.DecodeUint64()
+ m.Nat64StBuckets = buf.DecodeUint32()
+ m.Nat64StMemorySize = buf.DecodeUint64()
+ m.MaxTranslationsPerThread = buf.DecodeUint32()
+ m.MaxUsersPerThread = buf.DecodeUint32()
+ return nil
+}
+
+// NatShowConfigReply defines message 'nat_show_config_reply'.
+// Deprecated: the message will be removed in the future versions
+type NatShowConfigReply struct {
+ Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
+ StaticMappingOnly bool `binapi:"bool,name=static_mapping_only" json:"static_mapping_only,omitempty"`
+ StaticMappingConnectionTracking bool `binapi:"bool,name=static_mapping_connection_tracking" json:"static_mapping_connection_tracking,omitempty"`
+ Deterministic bool `binapi:"bool,name=deterministic" json:"deterministic,omitempty"`
+ EndpointDependent bool `binapi:"bool,name=endpoint_dependent" json:"endpoint_dependent,omitempty"`
+ Out2inDpo bool `binapi:"bool,name=out2in_dpo" json:"out2in_dpo,omitempty"`
+ DsliteCe bool `binapi:"bool,name=dslite_ce" json:"dslite_ce,omitempty"`
+ TranslationBuckets uint32 `binapi:"u32,name=translation_buckets" json:"translation_buckets,omitempty"`
+ TranslationMemorySize uint32 `binapi:"u32,name=translation_memory_size" json:"translation_memory_size,omitempty"`
+ UserBuckets uint32 `binapi:"u32,name=user_buckets" json:"user_buckets,omitempty"`
+ UserMemorySize uint64 `binapi:"u64,name=user_memory_size" json:"user_memory_size,omitempty"`
+ MaxTranslationsPerUser uint32 `binapi:"u32,name=max_translations_per_user" json:"max_translations_per_user,omitempty"`
+ OutsideVrfID uint32 `binapi:"u32,name=outside_vrf_id" json:"outside_vrf_id,omitempty"`
+ InsideVrfID uint32 `binapi:"u32,name=inside_vrf_id" json:"inside_vrf_id,omitempty"`
+ Nat64BibBuckets uint32 `binapi:"u32,name=nat64_bib_buckets" json:"nat64_bib_buckets,omitempty"`
+ Nat64BibMemorySize uint64 `binapi:"u64,name=nat64_bib_memory_size" json:"nat64_bib_memory_size,omitempty"`
+ Nat64StBuckets uint32 `binapi:"u32,name=nat64_st_buckets" json:"nat64_st_buckets,omitempty"`
+ Nat64StMemorySize uint64 `binapi:"u64,name=nat64_st_memory_size" json:"nat64_st_memory_size,omitempty"`
+}
+
+func (m *NatShowConfigReply) Reset() { *m = NatShowConfigReply{} }
+func (*NatShowConfigReply) GetMessageName() string { return "nat_show_config_reply" }
+func (*NatShowConfigReply) GetCrcString() string { return "7903ef06" }
+func (*NatShowConfigReply) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatShowConfigReply) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.Retval
+ size += 1 // m.StaticMappingOnly
+ size += 1 // m.StaticMappingConnectionTracking
+ size += 1 // m.Deterministic
+ size += 1 // m.EndpointDependent
+ size += 1 // m.Out2inDpo
+ size += 1 // m.DsliteCe
+ size += 4 // m.TranslationBuckets
+ size += 4 // m.TranslationMemorySize
+ size += 4 // m.UserBuckets
+ size += 8 // m.UserMemorySize
+ size += 4 // m.MaxTranslationsPerUser
+ size += 4 // m.OutsideVrfID
+ size += 4 // m.InsideVrfID
+ size += 4 // m.Nat64BibBuckets
+ size += 8 // m.Nat64BibMemorySize
+ size += 4 // m.Nat64StBuckets
+ size += 8 // m.Nat64StMemorySize
+ return size
+}
+func (m *NatShowConfigReply) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeInt32(m.Retval)
+ buf.EncodeBool(m.StaticMappingOnly)
+ buf.EncodeBool(m.StaticMappingConnectionTracking)
+ buf.EncodeBool(m.Deterministic)
+ buf.EncodeBool(m.EndpointDependent)
+ buf.EncodeBool(m.Out2inDpo)
+ buf.EncodeBool(m.DsliteCe)
+ buf.EncodeUint32(m.TranslationBuckets)
+ buf.EncodeUint32(m.TranslationMemorySize)
+ buf.EncodeUint32(m.UserBuckets)
+ buf.EncodeUint64(m.UserMemorySize)
+ buf.EncodeUint32(m.MaxTranslationsPerUser)
+ buf.EncodeUint32(m.OutsideVrfID)
+ buf.EncodeUint32(m.InsideVrfID)
+ buf.EncodeUint32(m.Nat64BibBuckets)
+ buf.EncodeUint64(m.Nat64BibMemorySize)
+ buf.EncodeUint32(m.Nat64StBuckets)
+ buf.EncodeUint64(m.Nat64StMemorySize)
+ return buf.Bytes(), nil
+}
+func (m *NatShowConfigReply) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.Retval = buf.DecodeInt32()
+ m.StaticMappingOnly = buf.DecodeBool()
+ m.StaticMappingConnectionTracking = buf.DecodeBool()
+ m.Deterministic = buf.DecodeBool()
+ m.EndpointDependent = buf.DecodeBool()
+ m.Out2inDpo = buf.DecodeBool()
+ m.DsliteCe = buf.DecodeBool()
+ m.TranslationBuckets = buf.DecodeUint32()
+ m.TranslationMemorySize = buf.DecodeUint32()
+ m.UserBuckets = buf.DecodeUint32()
+ m.UserMemorySize = buf.DecodeUint64()
+ m.MaxTranslationsPerUser = buf.DecodeUint32()
+ m.OutsideVrfID = buf.DecodeUint32()
+ m.InsideVrfID = buf.DecodeUint32()
+ m.Nat64BibBuckets = buf.DecodeUint32()
+ m.Nat64BibMemorySize = buf.DecodeUint64()
+ m.Nat64StBuckets = buf.DecodeUint32()
+ m.Nat64StMemorySize = buf.DecodeUint64()
+ return nil
+}
+
+// NatWorkerDetails defines message 'nat_worker_details'.
+type NatWorkerDetails struct {
+ WorkerIndex uint32 `binapi:"u32,name=worker_index" json:"worker_index,omitempty"`
+ LcoreID uint32 `binapi:"u32,name=lcore_id" json:"lcore_id,omitempty"`
+ Name string `binapi:"string[64],name=name" json:"name,omitempty"`
+}
+
+func (m *NatWorkerDetails) Reset() { *m = NatWorkerDetails{} }
+func (*NatWorkerDetails) GetMessageName() string { return "nat_worker_details" }
+func (*NatWorkerDetails) GetCrcString() string { return "84bf06fc" }
+func (*NatWorkerDetails) GetMessageType() api.MessageType {
+ return api.ReplyMessage
+}
+
+func (m *NatWorkerDetails) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ size += 4 // m.WorkerIndex
+ size += 4 // m.LcoreID
+ size += 64 // m.Name
+ return size
+}
+func (m *NatWorkerDetails) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ buf.EncodeUint32(m.WorkerIndex)
+ buf.EncodeUint32(m.LcoreID)
+ buf.EncodeString(m.Name, 64)
+ return buf.Bytes(), nil
+}
+func (m *NatWorkerDetails) Unmarshal(b []byte) error {
+ buf := codec.NewBuffer(b)
+ m.WorkerIndex = buf.DecodeUint32()
+ m.LcoreID = buf.DecodeUint32()
+ m.Name = buf.DecodeString(64)
+ return nil
+}
+
+// NatWorkerDump defines message 'nat_worker_dump'.
+type NatWorkerDump struct{}
+
+func (m *NatWorkerDump) Reset() { *m = NatWorkerDump{} }
+func (*NatWorkerDump) GetMessageName() string { return "nat_worker_dump" }
+func (*NatWorkerDump) GetCrcString() string { return "51077d14" }
+func (*NatWorkerDump) GetMessageType() api.MessageType {
+ return api.RequestMessage
+}
+
+func (m *NatWorkerDump) Size() (size int) {
+ if m == nil {
+ return 0
+ }
+ return size
+}
+func (m *NatWorkerDump) Marshal(b []byte) ([]byte, error) {
+ if b == nil {
+ b = make([]byte, m.Size())
+ }
+ buf := codec.NewBuffer(b)
+ return buf.Bytes(), nil
+}
+func (m *NatWorkerDump) Unmarshal(b []byte) error {
+ return nil
+}
+
+func init() { file_nat44_ed_binapi_init() }
+func file_nat44_ed_binapi_init() {
+ api.RegisterMessage((*Nat44AddDelAddressRange)(nil), "nat44_add_del_address_range_6f2b8055")
+ api.RegisterMessage((*Nat44AddDelAddressRangeReply)(nil), "nat44_add_del_address_range_reply_e8d4e804")
+ api.RegisterMessage((*Nat44AddDelIdentityMapping)(nil), "nat44_add_del_identity_mapping_02faaa22")
+ api.RegisterMessage((*Nat44AddDelIdentityMappingReply)(nil), "nat44_add_del_identity_mapping_reply_e8d4e804")
+ api.RegisterMessage((*Nat44AddDelInterfaceAddr)(nil), "nat44_add_del_interface_addr_4aed50c0")
+ api.RegisterMessage((*Nat44AddDelInterfaceAddrReply)(nil), "nat44_add_del_interface_addr_reply_e8d4e804")
+ api.RegisterMessage((*Nat44AddDelLbStaticMapping)(nil), "nat44_add_del_lb_static_mapping_4f68ee9d")
+ api.RegisterMessage((*Nat44AddDelLbStaticMappingReply)(nil), "nat44_add_del_lb_static_mapping_reply_e8d4e804")
+ api.RegisterMessage((*Nat44AddDelStaticMapping)(nil), "nat44_add_del_static_mapping_5ae5f03e")
+ api.RegisterMessage((*Nat44AddDelStaticMappingReply)(nil), "nat44_add_del_static_mapping_reply_e8d4e804")
+ api.RegisterMessage((*Nat44AddDelStaticMappingV2)(nil), "nat44_add_del_static_mapping_v2_5e205f1a")
+ api.RegisterMessage((*Nat44AddDelStaticMappingV2Reply)(nil), "nat44_add_del_static_mapping_v2_reply_e8d4e804")
+ api.RegisterMessage((*Nat44AddressDetails)(nil), "nat44_address_details_0d1beac1")
+ api.RegisterMessage((*Nat44AddressDump)(nil), "nat44_address_dump_51077d14")
+ api.RegisterMessage((*Nat44DelSession)(nil), "nat44_del_session_15a5bf8c")
+ api.RegisterMessage((*Nat44DelSessionReply)(nil), "nat44_del_session_reply_e8d4e804")
+ api.RegisterMessage((*Nat44DelUser)(nil), "nat44_del_user_99a9f998")
+ api.RegisterMessage((*Nat44DelUserReply)(nil), "nat44_del_user_reply_e8d4e804")
+ api.RegisterMessage((*Nat44EdAddDelOutputInterface)(nil), "nat44_ed_add_del_output_interface_47d6e753")
+ api.RegisterMessage((*Nat44EdAddDelOutputInterfaceReply)(nil), "nat44_ed_add_del_output_interface_reply_e8d4e804")
+ api.RegisterMessage((*Nat44EdOutputInterfaceDetails)(nil), "nat44_ed_output_interface_details_0b45011c")
+ api.RegisterMessage((*Nat44EdOutputInterfaceGet)(nil), "nat44_ed_output_interface_get_f75ba505")
+ api.RegisterMessage((*Nat44EdOutputInterfaceGetReply)(nil), "nat44_ed_output_interface_get_reply_53b48f5d")
+ api.RegisterMessage((*Nat44EdPluginEnableDisable)(nil), "nat44_ed_plugin_enable_disable_be17f8dd")
+ api.RegisterMessage((*Nat44EdPluginEnableDisableReply)(nil), "nat44_ed_plugin_enable_disable_reply_e8d4e804")
+ api.RegisterMessage((*Nat44EdSetFqOptions)(nil), "nat44_ed_set_fq_options_2399bd71")
+ api.RegisterMessage((*Nat44EdSetFqOptionsReply)(nil), "nat44_ed_set_fq_options_reply_e8d4e804")
+ api.RegisterMessage((*Nat44EdShowFqOptions)(nil), "nat44_ed_show_fq_options_51077d14")
+ api.RegisterMessage((*Nat44EdShowFqOptionsReply)(nil), "nat44_ed_show_fq_options_reply_7213b545")
+ api.RegisterMessage((*Nat44ForwardingEnableDisable)(nil), "nat44_forwarding_enable_disable_b3e225d2")
+ api.RegisterMessage((*Nat44ForwardingEnableDisableReply)(nil), "nat44_forwarding_enable_disable_reply_e8d4e804")
+ api.RegisterMessage((*Nat44ForwardingIsEnabled)(nil), "nat44_forwarding_is_enabled_51077d14")
+ api.RegisterMessage((*Nat44ForwardingIsEnabledReply)(nil), "nat44_forwarding_is_enabled_reply_46924a06")
+ api.RegisterMessage((*Nat44IdentityMappingDetails)(nil), "nat44_identity_mapping_details_2a52a030")
+ api.RegisterMessage((*Nat44IdentityMappingDump)(nil), "nat44_identity_mapping_dump_51077d14")
+ api.RegisterMessage((*Nat44InterfaceAddDelFeature)(nil), "nat44_interface_add_del_feature_f3699b83")
+ api.RegisterMessage((*Nat44InterfaceAddDelFeatureReply)(nil), "nat44_interface_add_del_feature_reply_e8d4e804")
+ api.RegisterMessage((*Nat44InterfaceAddDelOutputFeature)(nil), "nat44_interface_add_del_output_feature_f3699b83")
+ api.RegisterMessage((*Nat44InterfaceAddDelOutputFeatureReply)(nil), "nat44_interface_add_del_output_feature_reply_e8d4e804")
+ api.RegisterMessage((*Nat44InterfaceAddrDetails)(nil), "nat44_interface_addr_details_e4aca9ca")
+ api.RegisterMessage((*Nat44InterfaceAddrDump)(nil), "nat44_interface_addr_dump_51077d14")
+ api.RegisterMessage((*Nat44InterfaceDetails)(nil), "nat44_interface_details_5d286289")
+ api.RegisterMessage((*Nat44InterfaceDump)(nil), "nat44_interface_dump_51077d14")
+ api.RegisterMessage((*Nat44InterfaceOutputFeatureDetails)(nil), "nat44_interface_output_feature_details_5d286289")
+ api.RegisterMessage((*Nat44InterfaceOutputFeatureDump)(nil), "nat44_interface_output_feature_dump_51077d14")
+ api.RegisterMessage((*Nat44LbStaticMappingAddDelLocal)(nil), "nat44_lb_static_mapping_add_del_local_7ca47547")
+ api.RegisterMessage((*Nat44LbStaticMappingAddDelLocalReply)(nil), "nat44_lb_static_mapping_add_del_local_reply_e8d4e804")
+ api.RegisterMessage((*Nat44LbStaticMappingDetails)(nil), "nat44_lb_static_mapping_details_ed5ce876")
+ api.RegisterMessage((*Nat44LbStaticMappingDump)(nil), "nat44_lb_static_mapping_dump_51077d14")
+ api.RegisterMessage((*Nat44PluginEnableDisable)(nil), "nat44_plugin_enable_disable_dea0d501")
+ api.RegisterMessage((*Nat44PluginEnableDisableReply)(nil), "nat44_plugin_enable_disable_reply_e8d4e804")
+ api.RegisterMessage((*Nat44SessionCleanup)(nil), "nat44_session_cleanup_51077d14")
+ api.RegisterMessage((*Nat44SessionCleanupReply)(nil), "nat44_session_cleanup_reply_e8d4e804")
+ api.RegisterMessage((*Nat44SetSessionLimit)(nil), "nat44_set_session_limit_8899bbb1")
+ api.RegisterMessage((*Nat44SetSessionLimitReply)(nil), "nat44_set_session_limit_reply_e8d4e804")
+ api.RegisterMessage((*Nat44ShowRunningConfig)(nil), "nat44_show_running_config_51077d14")
+ api.RegisterMessage((*Nat44ShowRunningConfigReply)(nil), "nat44_show_running_config_reply_93d8e267")
+ api.RegisterMessage((*Nat44StaticMappingDetails)(nil), "nat44_static_mapping_details_06cb40b2")
+ api.RegisterMessage((*Nat44StaticMappingDump)(nil), "nat44_static_mapping_dump_51077d14")
+ api.RegisterMessage((*Nat44UserDetails)(nil), "nat44_user_details_355896c2")
+ api.RegisterMessage((*Nat44UserDump)(nil), "nat44_user_dump_51077d14")
+ api.RegisterMessage((*Nat44UserSessionDetails)(nil), "nat44_user_session_details_2cf6e16d")
+ api.RegisterMessage((*Nat44UserSessionDump)(nil), "nat44_user_session_dump_e1899c98")
+ api.RegisterMessage((*Nat44UserSessionV2Details)(nil), "nat44_user_session_v2_details_fd42b729")
+ api.RegisterMessage((*Nat44UserSessionV2Dump)(nil), "nat44_user_session_v2_dump_e1899c98")
+ api.RegisterMessage((*NatControlPing)(nil), "nat_control_ping_51077d14")
+ api.RegisterMessage((*NatControlPingReply)(nil), "nat_control_ping_reply_f6b0b8ca")
+ api.RegisterMessage((*NatGetAddrAndPortAllocAlg)(nil), "nat_get_addr_and_port_alloc_alg_51077d14")
+ api.RegisterMessage((*NatGetAddrAndPortAllocAlgReply)(nil), "nat_get_addr_and_port_alloc_alg_reply_3607a7d0")
+ api.RegisterMessage((*NatGetMssClamping)(nil), "nat_get_mss_clamping_51077d14")
+ api.RegisterMessage((*NatGetMssClampingReply)(nil), "nat_get_mss_clamping_reply_1c0b2a78")
+ api.RegisterMessage((*NatGetTimeouts)(nil), "nat_get_timeouts_51077d14")
+ api.RegisterMessage((*NatGetTimeoutsReply)(nil), "nat_get_timeouts_reply_3c4df4e1")
+ api.RegisterMessage((*NatHaFlush)(nil), "nat_ha_flush_51077d14")
+ api.RegisterMessage((*NatHaFlushReply)(nil), "nat_ha_flush_reply_e8d4e804")
+ api.RegisterMessage((*NatHaGetFailover)(nil), "nat_ha_get_failover_51077d14")
+ api.RegisterMessage((*NatHaGetFailoverReply)(nil), "nat_ha_get_failover_reply_a67d8752")
+ api.RegisterMessage((*NatHaGetListener)(nil), "nat_ha_get_listener_51077d14")
+ api.RegisterMessage((*NatHaGetListenerReply)(nil), "nat_ha_get_listener_reply_123ea41f")
+ api.RegisterMessage((*NatHaResync)(nil), "nat_ha_resync_c8ab9e03")
+ api.RegisterMessage((*NatHaResyncCompletedEvent)(nil), "nat_ha_resync_completed_event_fdc598fb")
+ api.RegisterMessage((*NatHaResyncReply)(nil), "nat_ha_resync_reply_e8d4e804")
+ api.RegisterMessage((*NatHaSetFailover)(nil), "nat_ha_set_failover_718246af")
+ api.RegisterMessage((*NatHaSetFailoverReply)(nil), "nat_ha_set_failover_reply_e8d4e804")
+ api.RegisterMessage((*NatHaSetListener)(nil), "nat_ha_set_listener_e4a8cb4e")
+ api.RegisterMessage((*NatHaSetListenerReply)(nil), "nat_ha_set_listener_reply_e8d4e804")
+ api.RegisterMessage((*NatIpfixEnableDisable)(nil), "nat_ipfix_enable_disable_9af4a2d2")
+ api.RegisterMessage((*NatIpfixEnableDisableReply)(nil), "nat_ipfix_enable_disable_reply_e8d4e804")
+ api.RegisterMessage((*NatSetAddrAndPortAllocAlg)(nil), "nat_set_addr_and_port_alloc_alg_deeb746f")
+ api.RegisterMessage((*NatSetAddrAndPortAllocAlgReply)(nil), "nat_set_addr_and_port_alloc_alg_reply_e8d4e804")
+ api.RegisterMessage((*NatSetLogLevel)(nil), "nat_set_log_level_70076bfe")
+ api.RegisterMessage((*NatSetLogLevelReply)(nil), "nat_set_log_level_reply_e8d4e804")
+ api.RegisterMessage((*NatSetMssClamping)(nil), "nat_set_mss_clamping_25e90abb")
+ api.RegisterMessage((*NatSetMssClampingReply)(nil), "nat_set_mss_clamping_reply_e8d4e804")
+ api.RegisterMessage((*NatSetTimeouts)(nil), "nat_set_timeouts_d4746b16")
+ api.RegisterMessage((*NatSetTimeoutsReply)(nil), "nat_set_timeouts_reply_e8d4e804")
+ api.RegisterMessage((*NatSetWorkers)(nil), "nat_set_workers_da926638")
+ api.RegisterMessage((*NatSetWorkersReply)(nil), "nat_set_workers_reply_e8d4e804")
+ api.RegisterMessage((*NatShowConfig)(nil), "nat_show_config_51077d14")
+ api.RegisterMessage((*NatShowConfig2)(nil), "nat_show_config_2_51077d14")
+ api.RegisterMessage((*NatShowConfig2Reply)(nil), "nat_show_config_2_reply_0404a5b4")
+ api.RegisterMessage((*NatShowConfigReply)(nil), "nat_show_config_reply_7903ef06")
+ api.RegisterMessage((*NatWorkerDetails)(nil), "nat_worker_details_84bf06fc")
+ api.RegisterMessage((*NatWorkerDump)(nil), "nat_worker_dump_51077d14")
+}
+
+// Messages returns list of all messages in this module.
+func AllMessages() []api.Message {
+ return []api.Message{
+ (*Nat44AddDelAddressRange)(nil),
+ (*Nat44AddDelAddressRangeReply)(nil),
+ (*Nat44AddDelIdentityMapping)(nil),
+ (*Nat44AddDelIdentityMappingReply)(nil),
+ (*Nat44AddDelInterfaceAddr)(nil),
+ (*Nat44AddDelInterfaceAddrReply)(nil),
+ (*Nat44AddDelLbStaticMapping)(nil),
+ (*Nat44AddDelLbStaticMappingReply)(nil),
+ (*Nat44AddDelStaticMapping)(nil),
+ (*Nat44AddDelStaticMappingReply)(nil),
+ (*Nat44AddDelStaticMappingV2)(nil),
+ (*Nat44AddDelStaticMappingV2Reply)(nil),
+ (*Nat44AddressDetails)(nil),
+ (*Nat44AddressDump)(nil),
+ (*Nat44DelSession)(nil),
+ (*Nat44DelSessionReply)(nil),
+ (*Nat44DelUser)(nil),
+ (*Nat44DelUserReply)(nil),
+ (*Nat44EdAddDelOutputInterface)(nil),
+ (*Nat44EdAddDelOutputInterfaceReply)(nil),
+ (*Nat44EdOutputInterfaceDetails)(nil),
+ (*Nat44EdOutputInterfaceGet)(nil),
+ (*Nat44EdOutputInterfaceGetReply)(nil),
+ (*Nat44EdPluginEnableDisable)(nil),
+ (*Nat44EdPluginEnableDisableReply)(nil),
+ (*Nat44EdSetFqOptions)(nil),
+ (*Nat44EdSetFqOptionsReply)(nil),
+ (*Nat44EdShowFqOptions)(nil),
+ (*Nat44EdShowFqOptionsReply)(nil),
+ (*Nat44ForwardingEnableDisable)(nil),
+ (*Nat44ForwardingEnableDisableReply)(nil),
+ (*Nat44ForwardingIsEnabled)(nil),
+ (*Nat44ForwardingIsEnabledReply)(nil),
+ (*Nat44IdentityMappingDetails)(nil),
+ (*Nat44IdentityMappingDump)(nil),
+ (*Nat44InterfaceAddDelFeature)(nil),
+ (*Nat44InterfaceAddDelFeatureReply)(nil),
+ (*Nat44InterfaceAddDelOutputFeature)(nil),
+ (*Nat44InterfaceAddDelOutputFeatureReply)(nil),
+ (*Nat44InterfaceAddrDetails)(nil),
+ (*Nat44InterfaceAddrDump)(nil),
+ (*Nat44InterfaceDetails)(nil),
+ (*Nat44InterfaceDump)(nil),
+ (*Nat44InterfaceOutputFeatureDetails)(nil),
+ (*Nat44InterfaceOutputFeatureDump)(nil),
+ (*Nat44LbStaticMappingAddDelLocal)(nil),
+ (*Nat44LbStaticMappingAddDelLocalReply)(nil),
+ (*Nat44LbStaticMappingDetails)(nil),
+ (*Nat44LbStaticMappingDump)(nil),
+ (*Nat44PluginEnableDisable)(nil),
+ (*Nat44PluginEnableDisableReply)(nil),
+ (*Nat44SessionCleanup)(nil),
+ (*Nat44SessionCleanupReply)(nil),
+ (*Nat44SetSessionLimit)(nil),
+ (*Nat44SetSessionLimitReply)(nil),
+ (*Nat44ShowRunningConfig)(nil),
+ (*Nat44ShowRunningConfigReply)(nil),
+ (*Nat44StaticMappingDetails)(nil),
+ (*Nat44StaticMappingDump)(nil),
+ (*Nat44UserDetails)(nil),
+ (*Nat44UserDump)(nil),
+ (*Nat44UserSessionDetails)(nil),
+ (*Nat44UserSessionDump)(nil),
+ (*Nat44UserSessionV2Details)(nil),
+ (*Nat44UserSessionV2Dump)(nil),
+ (*NatControlPing)(nil),
+ (*NatControlPingReply)(nil),
+ (*NatGetAddrAndPortAllocAlg)(nil),
+ (*NatGetAddrAndPortAllocAlgReply)(nil),
+ (*NatGetMssClamping)(nil),
+ (*NatGetMssClampingReply)(nil),
+ (*NatGetTimeouts)(nil),
+ (*NatGetTimeoutsReply)(nil),
+ (*NatHaFlush)(nil),
+ (*NatHaFlushReply)(nil),
+ (*NatHaGetFailover)(nil),
+ (*NatHaGetFailoverReply)(nil),
+ (*NatHaGetListener)(nil),
+ (*NatHaGetListenerReply)(nil),
+ (*NatHaResync)(nil),
+ (*NatHaResyncCompletedEvent)(nil),
+ (*NatHaResyncReply)(nil),
+ (*NatHaSetFailover)(nil),
+ (*NatHaSetFailoverReply)(nil),
+ (*NatHaSetListener)(nil),
+ (*NatHaSetListenerReply)(nil),
+ (*NatIpfixEnableDisable)(nil),
+ (*NatIpfixEnableDisableReply)(nil),
+ (*NatSetAddrAndPortAllocAlg)(nil),
+ (*NatSetAddrAndPortAllocAlgReply)(nil),
+ (*NatSetLogLevel)(nil),
+ (*NatSetLogLevelReply)(nil),
+ (*NatSetMssClamping)(nil),
+ (*NatSetMssClampingReply)(nil),
+ (*NatSetTimeouts)(nil),
+ (*NatSetTimeoutsReply)(nil),
+ (*NatSetWorkers)(nil),
+ (*NatSetWorkersReply)(nil),
+ (*NatShowConfig)(nil),
+ (*NatShowConfig2)(nil),
+ (*NatShowConfig2Reply)(nil),
+ (*NatShowConfigReply)(nil),
+ (*NatWorkerDetails)(nil),
+ (*NatWorkerDump)(nil),
+ }
+}