updatecfg

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2019 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Protocol_name = map[int32]string{
	0:     "UNKNOWN",
	6:     "TCP",
	17:    "UDP",
	65536: "IPv6_Flag",
	65542: "TCP6",
	65553: "UDP6",
}
View Source
var Protocol_value = map[string]int32{
	"UNKNOWN":   0,
	"TCP":       6,
	"UDP":       17,
	"IPv6_Flag": 65536,
	"TCP6":      65542,
	"UDP6":      65553,
}
View Source
var TraceType_name = map[int32]string{
	0: "DUMP_DROP",
	1: "DUMP_TRANSLATE",
	2: "DUMP_KNI",
}
View Source
var TraceType_value = map[string]int32{
	"DUMP_DROP":      0,
	"DUMP_TRANSLATE": 1,
	"DUMP_KNI":       2,
}

Functions

func RegisterUpdaterServer

func RegisterUpdaterServer(s *grpc.Server, srv UpdaterServer)

Types

type DumpControlRequest

type DumpControlRequest struct {
	EnableTrace          bool      `protobuf:"varint,1,opt,name=enable_trace,json=enableTrace,proto3" json:"enable_trace,omitempty"`
	TraceType            TraceType `protobuf:"varint,2,opt,name=trace_type,json=traceType,proto3,enum=updatecfg.TraceType" json:"trace_type,omitempty"`
	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
	XXX_unrecognized     []byte    `json:"-"`
	XXX_sizecache        int32     `json:"-"`
}

func (*DumpControlRequest) Descriptor

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

func (*DumpControlRequest) GetEnableTrace

func (m *DumpControlRequest) GetEnableTrace() bool

func (*DumpControlRequest) GetTraceType

func (m *DumpControlRequest) GetTraceType() TraceType

func (*DumpControlRequest) ProtoMessage

func (*DumpControlRequest) ProtoMessage()

func (*DumpControlRequest) Reset

func (m *DumpControlRequest) Reset()

func (*DumpControlRequest) String

func (m *DumpControlRequest) String() string

func (*DumpControlRequest) XXX_DiscardUnknown

func (m *DumpControlRequest) XXX_DiscardUnknown()

func (*DumpControlRequest) XXX_Marshal

func (m *DumpControlRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DumpControlRequest) XXX_Merge

func (dst *DumpControlRequest) XXX_Merge(src proto.Message)

func (*DumpControlRequest) XXX_Size

func (m *DumpControlRequest) XXX_Size() int

func (*DumpControlRequest) XXX_Unmarshal

func (m *DumpControlRequest) XXX_Unmarshal(b []byte) error

type ForwardedPort

type ForwardedPort struct {
	SourcePortNumber     uint32     `protobuf:"varint,1,opt,name=source_port_number,json=sourcePortNumber,proto3" json:"source_port_number,omitempty"`
	TargetAddress        *IPAddress `protobuf:"bytes,2,opt,name=target_address,json=targetAddress,proto3" json:"target_address,omitempty"`
	TargetPortNumber     uint32     `protobuf:"varint,3,opt,name=target_port_number,json=targetPortNumber,proto3" json:"target_port_number,omitempty"`
	Protocol             Protocol   `protobuf:"varint,4,opt,name=protocol,proto3,enum=updatecfg.Protocol" json:"protocol,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*ForwardedPort) Descriptor

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

func (*ForwardedPort) GetProtocol

func (m *ForwardedPort) GetProtocol() Protocol

func (*ForwardedPort) GetSourcePortNumber

func (m *ForwardedPort) GetSourcePortNumber() uint32

func (*ForwardedPort) GetTargetAddress

func (m *ForwardedPort) GetTargetAddress() *IPAddress

func (*ForwardedPort) GetTargetPortNumber

func (m *ForwardedPort) GetTargetPortNumber() uint32

func (*ForwardedPort) ProtoMessage

func (*ForwardedPort) ProtoMessage()

func (*ForwardedPort) Reset

func (m *ForwardedPort) Reset()

func (*ForwardedPort) String

func (m *ForwardedPort) String() string

func (*ForwardedPort) XXX_DiscardUnknown

func (m *ForwardedPort) XXX_DiscardUnknown()

func (*ForwardedPort) XXX_Marshal

func (m *ForwardedPort) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ForwardedPort) XXX_Merge

func (dst *ForwardedPort) XXX_Merge(src proto.Message)

func (*ForwardedPort) XXX_Size

func (m *ForwardedPort) XXX_Size() int

func (*ForwardedPort) XXX_Unmarshal

func (m *ForwardedPort) XXX_Unmarshal(b []byte) error

type IPAddress

type IPAddress struct {
	Address              []byte   `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*IPAddress) Descriptor

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

func (*IPAddress) GetAddress

func (m *IPAddress) GetAddress() []byte

func (*IPAddress) ProtoMessage

func (*IPAddress) ProtoMessage()

func (*IPAddress) Reset

func (m *IPAddress) Reset()

func (*IPAddress) String

func (m *IPAddress) String() string

func (*IPAddress) XXX_DiscardUnknown

func (m *IPAddress) XXX_DiscardUnknown()

func (*IPAddress) XXX_Marshal

func (m *IPAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*IPAddress) XXX_Merge

func (dst *IPAddress) XXX_Merge(src proto.Message)

func (*IPAddress) XXX_Size

func (m *IPAddress) XXX_Size() int

func (*IPAddress) XXX_Unmarshal

func (m *IPAddress) XXX_Unmarshal(b []byte) error

type InterfaceAddressChangeRequest

type InterfaceAddressChangeRequest struct {
	InterfaceId          uint32   `protobuf:"varint,1,opt,name=interface_id,json=interfaceId,proto3" json:"interface_id,omitempty"`
	PortSubnet           *Subnet  `protobuf:"bytes,2,opt,name=port_subnet,json=portSubnet,proto3" json:"port_subnet,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InterfaceAddressChangeRequest) Descriptor

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

func (*InterfaceAddressChangeRequest) GetInterfaceId

func (m *InterfaceAddressChangeRequest) GetInterfaceId() uint32

func (*InterfaceAddressChangeRequest) GetPortSubnet

func (m *InterfaceAddressChangeRequest) GetPortSubnet() *Subnet

func (*InterfaceAddressChangeRequest) ProtoMessage

func (*InterfaceAddressChangeRequest) ProtoMessage()

func (*InterfaceAddressChangeRequest) Reset

func (m *InterfaceAddressChangeRequest) Reset()

func (*InterfaceAddressChangeRequest) String

func (*InterfaceAddressChangeRequest) XXX_DiscardUnknown

func (m *InterfaceAddressChangeRequest) XXX_DiscardUnknown()

func (*InterfaceAddressChangeRequest) XXX_Marshal

func (m *InterfaceAddressChangeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InterfaceAddressChangeRequest) XXX_Merge

func (dst *InterfaceAddressChangeRequest) XXX_Merge(src proto.Message)

func (*InterfaceAddressChangeRequest) XXX_Size

func (m *InterfaceAddressChangeRequest) XXX_Size() int

func (*InterfaceAddressChangeRequest) XXX_Unmarshal

func (m *InterfaceAddressChangeRequest) XXX_Unmarshal(b []byte) error

type PortForwardingChangeRequest

type PortForwardingChangeRequest struct {
	EnableForwarding     bool           `protobuf:"varint,1,opt,name=enable_forwarding,json=enableForwarding,proto3" json:"enable_forwarding,omitempty"`
	InterfaceId          uint32         `protobuf:"varint,2,opt,name=interface_id,json=interfaceId,proto3" json:"interface_id,omitempty"`
	Port                 *ForwardedPort `protobuf:"bytes,3,opt,name=port,proto3" json:"port,omitempty"`
	XXX_NoUnkeyedLiteral struct{}       `json:"-"`
	XXX_unrecognized     []byte         `json:"-"`
	XXX_sizecache        int32          `json:"-"`
}

func (*PortForwardingChangeRequest) Descriptor

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

func (*PortForwardingChangeRequest) GetEnableForwarding

func (m *PortForwardingChangeRequest) GetEnableForwarding() bool

func (*PortForwardingChangeRequest) GetInterfaceId

func (m *PortForwardingChangeRequest) GetInterfaceId() uint32

func (*PortForwardingChangeRequest) GetPort

func (*PortForwardingChangeRequest) ProtoMessage

func (*PortForwardingChangeRequest) ProtoMessage()

func (*PortForwardingChangeRequest) Reset

func (m *PortForwardingChangeRequest) Reset()

func (*PortForwardingChangeRequest) String

func (m *PortForwardingChangeRequest) String() string

func (*PortForwardingChangeRequest) XXX_DiscardUnknown

func (m *PortForwardingChangeRequest) XXX_DiscardUnknown()

func (*PortForwardingChangeRequest) XXX_Marshal

func (m *PortForwardingChangeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PortForwardingChangeRequest) XXX_Merge

func (dst *PortForwardingChangeRequest) XXX_Merge(src proto.Message)

func (*PortForwardingChangeRequest) XXX_Size

func (m *PortForwardingChangeRequest) XXX_Size() int

func (*PortForwardingChangeRequest) XXX_Unmarshal

func (m *PortForwardingChangeRequest) XXX_Unmarshal(b []byte) error

type Protocol

type Protocol int32
const (
	Protocol_UNKNOWN   Protocol = 0
	Protocol_TCP       Protocol = 6
	Protocol_UDP       Protocol = 17
	Protocol_IPv6_Flag Protocol = 65536
	Protocol_TCP6      Protocol = 65542
	Protocol_UDP6      Protocol = 65553
)

func (Protocol) EnumDescriptor

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

func (Protocol) String

func (x Protocol) String() string

type Reply

type Reply struct {
	Msg                  string   `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Reply) Descriptor

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

func (*Reply) GetMsg

func (m *Reply) GetMsg() string

func (*Reply) ProtoMessage

func (*Reply) ProtoMessage()

func (*Reply) Reset

func (m *Reply) Reset()

func (*Reply) String

func (m *Reply) String() string

func (*Reply) XXX_DiscardUnknown

func (m *Reply) XXX_DiscardUnknown()

func (*Reply) XXX_Marshal

func (m *Reply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Reply) XXX_Merge

func (dst *Reply) XXX_Merge(src proto.Message)

func (*Reply) XXX_Size

func (m *Reply) XXX_Size() int

func (*Reply) XXX_Unmarshal

func (m *Reply) XXX_Unmarshal(b []byte) error

type Subnet

type Subnet struct {
	Address              *IPAddress `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	MaskBitsNumber       uint32     `protobuf:"varint,2,opt,name=mask_bits_number,json=maskBitsNumber,proto3" json:"mask_bits_number,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*Subnet) Descriptor

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

func (*Subnet) GetAddress

func (m *Subnet) GetAddress() *IPAddress

func (*Subnet) GetMaskBitsNumber

func (m *Subnet) GetMaskBitsNumber() uint32

func (*Subnet) ProtoMessage

func (*Subnet) ProtoMessage()

func (*Subnet) Reset

func (m *Subnet) Reset()

func (*Subnet) String

func (m *Subnet) String() string

func (*Subnet) XXX_DiscardUnknown

func (m *Subnet) XXX_DiscardUnknown()

func (*Subnet) XXX_Marshal

func (m *Subnet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Subnet) XXX_Merge

func (dst *Subnet) XXX_Merge(src proto.Message)

func (*Subnet) XXX_Size

func (m *Subnet) XXX_Size() int

func (*Subnet) XXX_Unmarshal

func (m *Subnet) XXX_Unmarshal(b []byte) error

type TraceType

type TraceType int32
const (
	TraceType_DUMP_DROP      TraceType = 0
	TraceType_DUMP_TRANSLATE TraceType = 1
	TraceType_DUMP_KNI       TraceType = 2
)

func (TraceType) EnumDescriptor

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

func (TraceType) String

func (x TraceType) String() string

type UpdaterClient

type UpdaterClient interface {
	ControlDump(ctx context.Context, in *DumpControlRequest, opts ...grpc.CallOption) (*Reply, error)
	ChangeInterfaceAddress(ctx context.Context, in *InterfaceAddressChangeRequest, opts ...grpc.CallOption) (*Reply, error)
	ChangePortForwarding(ctx context.Context, in *PortForwardingChangeRequest, opts ...grpc.CallOption) (*Reply, error)
}

UpdaterClient is the client API for Updater service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewUpdaterClient

func NewUpdaterClient(cc *grpc.ClientConn) UpdaterClient

type UpdaterServer

type UpdaterServer interface {
	ControlDump(context.Context, *DumpControlRequest) (*Reply, error)
	ChangeInterfaceAddress(context.Context, *InterfaceAddressChangeRequest) (*Reply, error)
	ChangePortForwarding(context.Context, *PortForwardingChangeRequest) (*Reply, error)
}

UpdaterServer is the server API for Updater service.

Jump to

Keyboard shortcuts

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