| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333 |
- // Code generated by protoc-gen-go. DO NOT EDIT.
- // source: vpn.proto
- package pb
- import proto "github.com/golang/protobuf/proto"
- import fmt "fmt"
- import math "math"
- import _ "google.golang.org/genproto/googleapis/api/annotations"
- import (
- context "golang.org/x/net/context"
- grpc "google.golang.org/grpc"
- )
- // Reference imports to suppress errors if they are not otherwise used.
- var _ = proto.Marshal
- var _ = fmt.Errorf
- var _ = math.Inf
- type VPNProto int32
- const (
- VPNProto_NOPREF VPNProto = 0
- VPNProto_UDP VPNProto = 1
- VPNProto_TCP VPNProto = 2
- )
- var VPNProto_name = map[int32]string{
- 0: "NOPREF",
- 1: "UDP",
- 2: "TCP",
- }
- var VPNProto_value = map[string]int32{
- "NOPREF": 0,
- "UDP": 1,
- "TCP": 2,
- }
- func (x VPNProto) String() string {
- return proto.EnumName(VPNProto_name, int32(x))
- }
- func (VPNProto) EnumDescriptor() ([]byte, []int) { return fileDescriptor1, []int{0} }
- type VPNStatusRequest struct {
- }
- func (m *VPNStatusRequest) Reset() { *m = VPNStatusRequest{} }
- func (m *VPNStatusRequest) String() string { return proto.CompactTextString(m) }
- func (*VPNStatusRequest) ProtoMessage() {}
- func (*VPNStatusRequest) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{0} }
- type VPNInitRequest struct {
- Hostname string `protobuf:"bytes,1,opt,name=Hostname" json:"Hostname,omitempty"`
- Port string `protobuf:"bytes,2,opt,name=Port" json:"Port,omitempty"`
- Protopref VPNProto `protobuf:"varint,3,opt,name=Protopref,enum=pb.VPNProto" json:"Protopref,omitempty"`
- IPBlock string `protobuf:"bytes,4,opt,name=IPBlock" json:"IPBlock,omitempty"`
- }
- func (m *VPNInitRequest) Reset() { *m = VPNInitRequest{} }
- func (m *VPNInitRequest) String() string { return proto.CompactTextString(m) }
- func (*VPNInitRequest) ProtoMessage() {}
- func (*VPNInitRequest) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{1} }
- func (m *VPNInitRequest) GetHostname() string {
- if m != nil {
- return m.Hostname
- }
- return ""
- }
- func (m *VPNInitRequest) GetPort() string {
- if m != nil {
- return m.Port
- }
- return ""
- }
- func (m *VPNInitRequest) GetProtopref() VPNProto {
- if m != nil {
- return m.Protopref
- }
- return VPNProto_NOPREF
- }
- func (m *VPNInitRequest) GetIPBlock() string {
- if m != nil {
- return m.IPBlock
- }
- return ""
- }
- type VPNStatusResponse struct {
- Name string `protobuf:"bytes,1,opt,name=Name" json:"Name,omitempty"`
- SerialNumber string `protobuf:"bytes,2,opt,name=SerialNumber" json:"SerialNumber,omitempty"`
- Hostname string `protobuf:"bytes,3,opt,name=Hostname" json:"Hostname,omitempty"`
- Port string `protobuf:"bytes,4,opt,name=Port" json:"Port,omitempty"`
- Cert string `protobuf:"bytes,5,opt,name=Cert" json:"Cert,omitempty"`
- CACert string `protobuf:"bytes,6,opt,name=CACert" json:"CACert,omitempty"`
- Net string `protobuf:"bytes,7,opt,name=Net" json:"Net,omitempty"`
- Mask string `protobuf:"bytes,8,opt,name=Mask" json:"Mask,omitempty"`
- CreatedAt string `protobuf:"bytes,9,opt,name=CreatedAt" json:"CreatedAt,omitempty"`
- Proto string `protobuf:"bytes,10,opt,name=Proto" json:"Proto,omitempty"`
- }
- func (m *VPNStatusResponse) Reset() { *m = VPNStatusResponse{} }
- func (m *VPNStatusResponse) String() string { return proto.CompactTextString(m) }
- func (*VPNStatusResponse) ProtoMessage() {}
- func (*VPNStatusResponse) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{2} }
- func (m *VPNStatusResponse) GetName() string {
- if m != nil {
- return m.Name
- }
- return ""
- }
- func (m *VPNStatusResponse) GetSerialNumber() string {
- if m != nil {
- return m.SerialNumber
- }
- return ""
- }
- func (m *VPNStatusResponse) GetHostname() string {
- if m != nil {
- return m.Hostname
- }
- return ""
- }
- func (m *VPNStatusResponse) GetPort() string {
- if m != nil {
- return m.Port
- }
- return ""
- }
- func (m *VPNStatusResponse) GetCert() string {
- if m != nil {
- return m.Cert
- }
- return ""
- }
- func (m *VPNStatusResponse) GetCACert() string {
- if m != nil {
- return m.CACert
- }
- return ""
- }
- func (m *VPNStatusResponse) GetNet() string {
- if m != nil {
- return m.Net
- }
- return ""
- }
- func (m *VPNStatusResponse) GetMask() string {
- if m != nil {
- return m.Mask
- }
- return ""
- }
- func (m *VPNStatusResponse) GetCreatedAt() string {
- if m != nil {
- return m.CreatedAt
- }
- return ""
- }
- func (m *VPNStatusResponse) GetProto() string {
- if m != nil {
- return m.Proto
- }
- return ""
- }
- type VPNInitResponse struct {
- }
- func (m *VPNInitResponse) Reset() { *m = VPNInitResponse{} }
- func (m *VPNInitResponse) String() string { return proto.CompactTextString(m) }
- func (*VPNInitResponse) ProtoMessage() {}
- func (*VPNInitResponse) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{3} }
- func init() {
- proto.RegisterType((*VPNStatusRequest)(nil), "pb.VPNStatusRequest")
- proto.RegisterType((*VPNInitRequest)(nil), "pb.VPNInitRequest")
- proto.RegisterType((*VPNStatusResponse)(nil), "pb.VPNStatusResponse")
- proto.RegisterType((*VPNInitResponse)(nil), "pb.VPNInitResponse")
- proto.RegisterEnum("pb.VPNProto", VPNProto_name, VPNProto_value)
- }
- // Reference imports to suppress errors if they are not otherwise used.
- var _ context.Context
- var _ grpc.ClientConn
- // This is a compile-time assertion to ensure that this generated file
- // is compatible with the grpc package it is being compiled against.
- const _ = grpc.SupportPackageIsVersion4
- // Client API for VPNService service
- type VPNServiceClient interface {
- Status(ctx context.Context, in *VPNStatusRequest, opts ...grpc.CallOption) (*VPNStatusResponse, error)
- Init(ctx context.Context, in *VPNInitRequest, opts ...grpc.CallOption) (*VPNInitResponse, error)
- }
- type vPNServiceClient struct {
- cc *grpc.ClientConn
- }
- func NewVPNServiceClient(cc *grpc.ClientConn) VPNServiceClient {
- return &vPNServiceClient{cc}
- }
- func (c *vPNServiceClient) Status(ctx context.Context, in *VPNStatusRequest, opts ...grpc.CallOption) (*VPNStatusResponse, error) {
- out := new(VPNStatusResponse)
- err := grpc.Invoke(ctx, "/pb.VPNService/Status", in, out, c.cc, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *vPNServiceClient) Init(ctx context.Context, in *VPNInitRequest, opts ...grpc.CallOption) (*VPNInitResponse, error) {
- out := new(VPNInitResponse)
- err := grpc.Invoke(ctx, "/pb.VPNService/Init", in, out, c.cc, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- // Server API for VPNService service
- type VPNServiceServer interface {
- Status(context.Context, *VPNStatusRequest) (*VPNStatusResponse, error)
- Init(context.Context, *VPNInitRequest) (*VPNInitResponse, error)
- }
- func RegisterVPNServiceServer(s *grpc.Server, srv VPNServiceServer) {
- s.RegisterService(&_VPNService_serviceDesc, srv)
- }
- func _VPNService_Status_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(VPNStatusRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(VPNServiceServer).Status(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.VPNService/Status",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(VPNServiceServer).Status(ctx, req.(*VPNStatusRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _VPNService_Init_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(VPNInitRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(VPNServiceServer).Init(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.VPNService/Init",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(VPNServiceServer).Init(ctx, req.(*VPNInitRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- var _VPNService_serviceDesc = grpc.ServiceDesc{
- ServiceName: "pb.VPNService",
- HandlerType: (*VPNServiceServer)(nil),
- Methods: []grpc.MethodDesc{
- {
- MethodName: "Status",
- Handler: _VPNService_Status_Handler,
- },
- {
- MethodName: "Init",
- Handler: _VPNService_Init_Handler,
- },
- },
- Streams: []grpc.StreamDesc{},
- Metadata: "vpn.proto",
- }
- func init() { proto.RegisterFile("vpn.proto", fileDescriptor1) }
- var fileDescriptor1 = []byte{
- // 423 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x92, 0xcf, 0x72, 0xd3, 0x30,
- 0x10, 0xc6, 0xb1, 0xe3, 0x3a, 0xf1, 0x4e, 0x26, 0x38, 0xdb, 0x02, 0x22, 0xd3, 0x43, 0x47, 0xa7,
- 0x4c, 0x0e, 0xf1, 0x50, 0x6e, 0xbd, 0x95, 0x00, 0xd3, 0x1e, 0x30, 0x9a, 0x14, 0x72, 0x57, 0x8a,
- 0xe8, 0x78, 0x9a, 0x4a, 0x42, 0x52, 0x72, 0x87, 0x03, 0x2f, 0xc0, 0x4b, 0xf0, 0x3e, 0xbc, 0x02,
- 0x0f, 0xc2, 0x48, 0x76, 0xfe, 0x98, 0x99, 0xde, 0xbe, 0xfd, 0xad, 0x77, 0xbd, 0xfb, 0xad, 0x20,
- 0xdb, 0x68, 0x39, 0xd5, 0x46, 0x39, 0x85, 0xb1, 0x5e, 0x8e, 0x4e, 0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