proto

package
v0.0.0-...-40c8b04 Latest Latest
Warning

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

Go to latest
Published: May 4, 2021 License: BSD-2-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Admin_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "keybox.Admin",
	HandlerType: (*AdminServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "RegisterKey",
			Handler:    _Admin_RegisterKey_Handler,
		},
		{
			MethodName: "DeregisterKey",
			Handler:    _Admin_DeregisterKey_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/admin.proto",
}

Admin_ServiceDesc is the grpc.ServiceDesc for Admin service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var Encrypt_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "keybox.Encrypt",
	HandlerType: (*EncryptServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Encrypt",
			Handler:    _Encrypt_Encrypt_Handler,
		},
		{
			MethodName: "Decrypt",
			Handler:    _Encrypt_Decrypt_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/encrypt.proto",
}

Encrypt_ServiceDesc is the grpc.ServiceDesc for Encrypt service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_proto_admin_proto protoreflect.FileDescriptor
View Source
var File_proto_encrypt_proto protoreflect.FileDescriptor

Functions

func RegisterAdminServer

func RegisterAdminServer(s grpc.ServiceRegistrar, srv AdminServer)

func RegisterEncryptServer

func RegisterEncryptServer(s grpc.ServiceRegistrar, srv EncryptServer)

Types

type AdminClient

type AdminClient interface {
	RegisterKey(ctx context.Context, in *RegisterRequest, opts ...grpc.CallOption) (*RegisterReply, error)
	DeregisterKey(ctx context.Context, in *DeregisterRequest, opts ...grpc.CallOption) (*DeregisterReply, error)
}

AdminClient is the client API for Admin service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewAdminClient

func NewAdminClient(cc grpc.ClientConnInterface) AdminClient

type AdminServer

type AdminServer interface {
	RegisterKey(context.Context, *RegisterRequest) (*RegisterReply, error)
	DeregisterKey(context.Context, *DeregisterRequest) (*DeregisterReply, error)
	// contains filtered or unexported methods
}

AdminServer is the server API for Admin service. All implementations must embed UnimplementedAdminServer for forward compatibility

type DecryptReply

type DecryptReply struct {
	Plaintexts []string `protobuf:"bytes,1,rep,name=plaintexts,proto3" json:"plaintexts,omitempty"`
	// contains filtered or unexported fields
}

func (*DecryptReply) Descriptor deprecated

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

Deprecated: Use DecryptReply.ProtoReflect.Descriptor instead.

func (*DecryptReply) GetPlaintexts

func (x *DecryptReply) GetPlaintexts() []string

func (*DecryptReply) ProtoMessage

func (*DecryptReply) ProtoMessage()

func (*DecryptReply) ProtoReflect

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

func (*DecryptReply) Reset

func (x *DecryptReply) Reset()

func (*DecryptReply) String

func (x *DecryptReply) String() string

type DecryptRequest

type DecryptRequest struct {
	UserId      string   `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	KeyId       string   `protobuf:"bytes,2,opt,name=key_id,json=keyId,proto3" json:"key_id,omitempty"`
	Ciphertexts []string `protobuf:"bytes,3,rep,name=ciphertexts,proto3" json:"ciphertexts,omitempty"`
	// contains filtered or unexported fields
}

func (*DecryptRequest) Descriptor deprecated

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

Deprecated: Use DecryptRequest.ProtoReflect.Descriptor instead.

func (*DecryptRequest) GetCiphertexts

func (x *DecryptRequest) GetCiphertexts() []string

func (*DecryptRequest) GetKeyId

func (x *DecryptRequest) GetKeyId() string

func (*DecryptRequest) GetUserId

func (x *DecryptRequest) GetUserId() string

func (*DecryptRequest) ProtoMessage

func (*DecryptRequest) ProtoMessage()

func (*DecryptRequest) ProtoReflect

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

func (*DecryptRequest) Reset

func (x *DecryptRequest) Reset()

func (*DecryptRequest) String

func (x *DecryptRequest) String() string

type DeregisterReply

type DeregisterReply struct {
	// contains filtered or unexported fields
}

func (*DeregisterReply) Descriptor deprecated

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

Deprecated: Use DeregisterReply.ProtoReflect.Descriptor instead.

func (*DeregisterReply) ProtoMessage

func (*DeregisterReply) ProtoMessage()

func (*DeregisterReply) ProtoReflect

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

func (*DeregisterReply) Reset

func (x *DeregisterReply) Reset()

func (*DeregisterReply) String

func (x *DeregisterReply) String() string

type DeregisterRequest

type DeregisterRequest struct {
	UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	KeyId  string `protobuf:"bytes,2,opt,name=key_id,json=keyId,proto3" json:"key_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeregisterRequest) Descriptor deprecated

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

Deprecated: Use DeregisterRequest.ProtoReflect.Descriptor instead.

func (*DeregisterRequest) GetKeyId

func (x *DeregisterRequest) GetKeyId() string

func (*DeregisterRequest) GetUserId

func (x *DeregisterRequest) GetUserId() string

func (*DeregisterRequest) ProtoMessage

func (*DeregisterRequest) ProtoMessage()

func (*DeregisterRequest) ProtoReflect

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

func (*DeregisterRequest) Reset

func (x *DeregisterRequest) Reset()

func (*DeregisterRequest) String

func (x *DeregisterRequest) String() string

type EncryptClient

type EncryptClient interface {
	Encrypt(ctx context.Context, in *EncryptRequest, opts ...grpc.CallOption) (*EncryptReply, error)
	Decrypt(ctx context.Context, in *DecryptRequest, opts ...grpc.CallOption) (*DecryptReply, error)
}

EncryptClient is the client API for Encrypt service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewEncryptClient

func NewEncryptClient(cc grpc.ClientConnInterface) EncryptClient

type EncryptReply

type EncryptReply struct {
	Ciphertexts []string `protobuf:"bytes,1,rep,name=ciphertexts,proto3" json:"ciphertexts,omitempty"`
	// contains filtered or unexported fields
}

func (*EncryptReply) Descriptor deprecated

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

Deprecated: Use EncryptReply.ProtoReflect.Descriptor instead.

func (*EncryptReply) GetCiphertexts

func (x *EncryptReply) GetCiphertexts() []string

func (*EncryptReply) ProtoMessage

func (*EncryptReply) ProtoMessage()

func (*EncryptReply) ProtoReflect

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

func (*EncryptReply) Reset

func (x *EncryptReply) Reset()

func (*EncryptReply) String

func (x *EncryptReply) String() string

type EncryptRequest

type EncryptRequest struct {
	UserId     string   `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	KeyId      string   `protobuf:"bytes,2,opt,name=key_id,json=keyId,proto3" json:"key_id,omitempty"`
	Plaintexts []string `protobuf:"bytes,3,rep,name=plaintexts,proto3" json:"plaintexts,omitempty"`
	// contains filtered or unexported fields
}

func (*EncryptRequest) Descriptor deprecated

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

Deprecated: Use EncryptRequest.ProtoReflect.Descriptor instead.

func (*EncryptRequest) GetKeyId

func (x *EncryptRequest) GetKeyId() string

func (*EncryptRequest) GetPlaintexts

func (x *EncryptRequest) GetPlaintexts() []string

func (*EncryptRequest) GetUserId

func (x *EncryptRequest) GetUserId() string

func (*EncryptRequest) ProtoMessage

func (*EncryptRequest) ProtoMessage()

func (*EncryptRequest) ProtoReflect

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

func (*EncryptRequest) Reset

func (x *EncryptRequest) Reset()

func (*EncryptRequest) String

func (x *EncryptRequest) String() string

type EncryptServer

type EncryptServer interface {
	Encrypt(context.Context, *EncryptRequest) (*EncryptReply, error)
	Decrypt(context.Context, *DecryptRequest) (*DecryptReply, error)
	// contains filtered or unexported methods
}

EncryptServer is the server API for Encrypt service. All implementations must embed UnimplementedEncryptServer for forward compatibility

type RegisterReply

type RegisterReply struct {
	KeyId string `protobuf:"bytes,1,opt,name=key_id,json=keyId,proto3" json:"key_id,omitempty"`
	// contains filtered or unexported fields
}

func (*RegisterReply) Descriptor deprecated

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

Deprecated: Use RegisterReply.ProtoReflect.Descriptor instead.

func (*RegisterReply) GetKeyId

func (x *RegisterReply) GetKeyId() string

func (*RegisterReply) ProtoMessage

func (*RegisterReply) ProtoMessage()

func (*RegisterReply) ProtoReflect

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

func (*RegisterReply) Reset

func (x *RegisterReply) Reset()

func (*RegisterReply) String

func (x *RegisterReply) String() string

type RegisterRequest

type RegisterRequest struct {
	UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*RegisterRequest) Descriptor deprecated

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

Deprecated: Use RegisterRequest.ProtoReflect.Descriptor instead.

func (*RegisterRequest) GetUserId

func (x *RegisterRequest) GetUserId() string

func (*RegisterRequest) ProtoMessage

func (*RegisterRequest) ProtoMessage()

func (*RegisterRequest) ProtoReflect

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

func (*RegisterRequest) Reset

func (x *RegisterRequest) Reset()

func (*RegisterRequest) String

func (x *RegisterRequest) String() string

type UnimplementedAdminServer

type UnimplementedAdminServer struct {
}

UnimplementedAdminServer must be embedded to have forward compatible implementations.

func (UnimplementedAdminServer) DeregisterKey

func (UnimplementedAdminServer) RegisterKey

type UnimplementedEncryptServer

type UnimplementedEncryptServer struct {
}

UnimplementedEncryptServer must be embedded to have forward compatible implementations.

func (UnimplementedEncryptServer) Decrypt

func (UnimplementedEncryptServer) Encrypt

type UnsafeAdminServer

type UnsafeAdminServer interface {
	// contains filtered or unexported methods
}

UnsafeAdminServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AdminServer will result in compilation errors.

type UnsafeEncryptServer

type UnsafeEncryptServer interface {
	// contains filtered or unexported methods
}

UnsafeEncryptServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EncryptServer will result in compilation errors.

Jump to

Keyboard shortcuts

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