Documentation ¶
Overview ¶
Package auth is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterAuthHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterAuthHandlerClient(ctx context.Context, mux *runtime.ServeMux, client AuthClient) error
- func RegisterAuthHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterAuthHandlerServer(ctx context.Context, mux *runtime.ServeMux, server AuthServer) error
- func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
- type AuthClient
- type AuthServer
- type AuthorizationRequest
- func (*AuthorizationRequest) Descriptor() ([]byte, []int)deprecated
- func (x *AuthorizationRequest) GetPassword() string
- func (x *AuthorizationRequest) GetUsername() string
- func (*AuthorizationRequest) ProtoMessage()
- func (x *AuthorizationRequest) ProtoReflect() protoreflect.Message
- func (x *AuthorizationRequest) Reset()
- func (x *AuthorizationRequest) String() string
- type AuthorizationResponse
- func (*AuthorizationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *AuthorizationResponse) GetAccountId() int64
- func (x *AuthorizationResponse) GetActorId() int64
- func (x *AuthorizationResponse) GetAuthorizationToken() string
- func (x *AuthorizationResponse) GetCode() string
- func (x *AuthorizationResponse) GetDeviceId() int64
- func (x *AuthorizationResponse) GetMail() string
- func (x *AuthorizationResponse) GetStatus() string
- func (*AuthorizationResponse) ProtoMessage()
- func (x *AuthorizationResponse) ProtoReflect() protoreflect.Message
- func (x *AuthorizationResponse) Reset()
- func (x *AuthorizationResponse) String() string
- type GetDHResponse
- func (*GetDHResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetDHResponse) GetDeviceId() int64
- func (x *GetDHResponse) GetIv() string
- func (x *GetDHResponse) GetPublicKey() string
- func (*GetDHResponse) ProtoMessage()
- func (x *GetDHResponse) ProtoReflect() protoreflect.Message
- func (x *GetDHResponse) Reset()
- func (x *GetDHResponse) String() string
- type GetPrivateKeyRequest
- func (*GetPrivateKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetPrivateKeyRequest) GetDeviceId() int64
- func (x *GetPrivateKeyRequest) GetIv() string
- func (x *GetPrivateKeyRequest) GetPublicKey() string
- func (*GetPrivateKeyRequest) ProtoMessage()
- func (x *GetPrivateKeyRequest) ProtoReflect() protoreflect.Message
- func (x *GetPrivateKeyRequest) Reset()
- func (x *GetPrivateKeyRequest) String() string
- type GetPrivateKeyResponse
- func (*GetPrivateKeyResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetPrivateKeyResponse) GetCode() string
- func (x *GetPrivateKeyResponse) GetStatus() string
- func (*GetPrivateKeyResponse) ProtoMessage()
- func (x *GetPrivateKeyResponse) ProtoReflect() protoreflect.Message
- func (x *GetPrivateKeyResponse) Reset()
- func (x *GetPrivateKeyResponse) String() string
- type GetPrivateResponse
- func (*GetPrivateResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetPrivateResponse) GetCode() string
- func (x *GetPrivateResponse) GetPrivate() string
- func (*GetPrivateResponse) ProtoMessage()
- func (x *GetPrivateResponse) ProtoReflect() protoreflect.Message
- func (x *GetPrivateResponse) Reset()
- func (x *GetPrivateResponse) String() string
- type GetPublicKeyRequest
- func (*GetPublicKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetPublicKeyRequest) GetAccountId() string
- func (*GetPublicKeyRequest) ProtoMessage()
- func (x *GetPublicKeyRequest) ProtoReflect() protoreflect.Message
- func (x *GetPublicKeyRequest) Reset()
- func (x *GetPublicKeyRequest) String() string
- type GetPublicKeyResponse
- func (*GetPublicKeyResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetPublicKeyResponse) GetPublicKey() string
- func (*GetPublicKeyResponse) ProtoMessage()
- func (x *GetPublicKeyResponse) ProtoReflect() protoreflect.Message
- func (x *GetPublicKeyResponse) Reset()
- func (x *GetPublicKeyResponse) String() string
- type SendPrivateKeyRequest
- func (*SendPrivateKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SendPrivateKeyRequest) GetDeviceId() int64
- func (x *SendPrivateKeyRequest) GetPrivateKey() string
- func (x *SendPrivateKeyRequest) GetPublicKey() string
- func (*SendPrivateKeyRequest) ProtoMessage()
- func (x *SendPrivateKeyRequest) ProtoReflect() protoreflect.Message
- func (x *SendPrivateKeyRequest) Reset()
- func (x *SendPrivateKeyRequest) String() string
- type SendPrivateKeyResponse
- func (*SendPrivateKeyResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SendPrivateKeyResponse) GetCode() string
- func (x *SendPrivateKeyResponse) GetStatus() string
- func (*SendPrivateKeyResponse) ProtoMessage()
- func (x *SendPrivateKeyResponse) ProtoReflect() protoreflect.Message
- func (x *SendPrivateKeyResponse) Reset()
- func (x *SendPrivateKeyResponse) String() string
- type SetPublicKeyRequest
- func (*SetPublicKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SetPublicKeyRequest) GetAccountId() int64
- func (x *SetPublicKeyRequest) GetPublicKey() string
- func (*SetPublicKeyRequest) ProtoMessage()
- func (x *SetPublicKeyRequest) ProtoReflect() protoreflect.Message
- func (x *SetPublicKeyRequest) Reset()
- func (x *SetPublicKeyRequest) String() string
- type SetPublicKeyResponse
- func (*SetPublicKeyResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SetPublicKeyResponse) GetCode() string
- func (x *SetPublicKeyResponse) GetStatus() string
- func (*SetPublicKeyResponse) ProtoMessage()
- func (x *SetPublicKeyResponse) ProtoReflect() protoreflect.Message
- func (x *SetPublicKeyResponse) Reset()
- func (x *SetPublicKeyResponse) String() string
- type UnimplementedAuthServer
- func (UnimplementedAuthServer) Authorization(context.Context, *AuthorizationRequest) (*AuthorizationResponse, error)
- func (UnimplementedAuthServer) GetDH(context.Context, *emptypb.Empty) (*GetDHResponse, error)
- func (UnimplementedAuthServer) GetPrivateKey(context.Context, *GetPrivateKeyRequest) (*GetPrivateKeyResponse, error)
- func (UnimplementedAuthServer) GetPublicKey(context.Context, *GetPublicKeyRequest) (*GetPublicKeyResponse, error)
- func (UnimplementedAuthServer) SendPrivateKey(context.Context, *SendPrivateKeyRequest) (*SendPrivateKeyResponse, error)
- func (UnimplementedAuthServer) SetPublicKey(context.Context, *SetPublicKeyRequest) (*SetPublicKeyResponse, error)
- func (UnimplementedAuthServer) WaitPrivateKey(context.Context, *emptypb.Empty) (*WaitPrivateKeyResponse, error)
- type UnsafeAuthServer
- type WaitPrivateKeyResponse
- func (*WaitPrivateKeyResponse) Descriptor() ([]byte, []int)deprecated
- func (x *WaitPrivateKeyResponse) GetDeviceId() int64
- func (x *WaitPrivateKeyResponse) GetPrivate() string
- func (x *WaitPrivateKeyResponse) GetPublicKey() string
- func (*WaitPrivateKeyResponse) ProtoMessage()
- func (x *WaitPrivateKeyResponse) ProtoReflect() protoreflect.Message
- func (x *WaitPrivateKeyResponse) Reset()
- func (x *WaitPrivateKeyResponse) String() string
Constants ¶
This section is empty.
Variables ¶
var Auth_ServiceDesc = grpc.ServiceDesc{ ServiceName: "hvx.api.v1alpha1.auth.proto.Auth", HandlerType: (*AuthServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Authorization", Handler: _Auth_Authorization_Handler, }, { MethodName: "SetPublicKey", Handler: _Auth_SetPublicKey_Handler, }, { MethodName: "GetPublicKey", Handler: _Auth_GetPublicKey_Handler, }, { MethodName: "GetPrivateKey", Handler: _Auth_GetPrivateKey_Handler, }, { MethodName: "GetDH", Handler: _Auth_GetDH_Handler, }, { MethodName: "SendPrivateKey", Handler: _Auth_SendPrivateKey_Handler, }, { MethodName: "WaitPrivateKey", Handler: _Auth_WaitPrivateKey_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proto/v1alpha1/auth/auth.proto", }
Auth_ServiceDesc is the grpc.ServiceDesc for Auth service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_proto_v1alpha1_auth_auth_proto protoreflect.FileDescriptor
Functions ¶
func RegisterAuthHandler ¶
RegisterAuthHandler registers the http handlers for service Auth to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterAuthHandlerClient ¶
RegisterAuthHandlerClient registers the http handlers for service Auth to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "AuthClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "AuthClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "AuthClient" to call the correct interceptors.
func RegisterAuthHandlerFromEndpoint ¶
func RegisterAuthHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterAuthHandlerFromEndpoint is same as RegisterAuthHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterAuthHandlerServer ¶
RegisterAuthHandlerServer registers the http handlers for service Auth to "mux". UnaryRPC :call AuthServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterAuthHandlerFromEndpoint instead.
func RegisterAuthServer ¶
func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
Types ¶
type AuthClient ¶
type AuthClient interface { // Verify authentication Login with a valid user. // After successful authentication. The client must be registered to the device table for functions such as TOKEN checksum, managing devices, etc. // So you must submit a UA identifier in addition to the username and password when logging in. // A valid Token is returned and must be carried in subsequent API access operations. // https://datatracker.ietf.org/doc/html/rfc9068 Authorization(ctx context.Context, in *AuthorizationRequest, opts ...grpc.CallOption) (*AuthorizationResponse, error) // SetPublicKey unlike activitypub, his private key is inaccessible to the server. // The public key is used for hvxahv privacy-related asymmetric encryption key. SetPublicKey(ctx context.Context, in *SetPublicKeyRequest, opts ...grpc.CallOption) (*SetPublicKeyResponse, error) // GetPublicKey Use the account id to get the account public key. // Not activitypub public key. GetPublicKey(ctx context.Context, in *GetPublicKeyRequest, opts ...grpc.CallOption) (*GetPublicKeyResponse, error) // GetPrivateKey First, initiate a request to obtain the private key from the logged-in client. GetPrivateKey(ctx context.Context, in *GetPrivateKeyRequest, opts ...grpc.CallOption) (*GetPrivateKeyResponse, error) // GetDH Get the dh parameter. GetDH(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*GetDHResponse, error) // SendPrivateKey Send the encrypted private key. SendPrivateKey(ctx context.Context, in *SendPrivateKeyRequest, opts ...grpc.CallOption) (*SendPrivateKeyResponse, error) // WaitPrivateKey Wait for the other client to send the encrypted private key. WaitPrivateKey(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*WaitPrivateKeyResponse, error) }
AuthClient is the client API for Auth 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 NewAuthClient ¶
func NewAuthClient(cc grpc.ClientConnInterface) AuthClient
type AuthServer ¶
type AuthServer interface { // Verify authentication Login with a valid user. // After successful authentication. The client must be registered to the device table for functions such as TOKEN checksum, managing devices, etc. // So you must submit a UA identifier in addition to the username and password when logging in. // A valid Token is returned and must be carried in subsequent API access operations. // https://datatracker.ietf.org/doc/html/rfc9068 Authorization(context.Context, *AuthorizationRequest) (*AuthorizationResponse, error) // SetPublicKey unlike activitypub, his private key is inaccessible to the server. // The public key is used for hvxahv privacy-related asymmetric encryption key. SetPublicKey(context.Context, *SetPublicKeyRequest) (*SetPublicKeyResponse, error) // GetPublicKey Use the account id to get the account public key. // Not activitypub public key. GetPublicKey(context.Context, *GetPublicKeyRequest) (*GetPublicKeyResponse, error) // GetPrivateKey First, initiate a request to obtain the private key from the logged-in client. GetPrivateKey(context.Context, *GetPrivateKeyRequest) (*GetPrivateKeyResponse, error) // GetDH Get the dh parameter. GetDH(context.Context, *emptypb.Empty) (*GetDHResponse, error) // SendPrivateKey Send the encrypted private key. SendPrivateKey(context.Context, *SendPrivateKeyRequest) (*SendPrivateKeyResponse, error) // WaitPrivateKey Wait for the other client to send the encrypted private key. WaitPrivateKey(context.Context, *emptypb.Empty) (*WaitPrivateKeyResponse, error) }
AuthServer is the server API for Auth service. All implementations should embed UnimplementedAuthServer for forward compatibility
type AuthorizationRequest ¶
type AuthorizationRequest struct { Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` // contains filtered or unexported fields }
func (*AuthorizationRequest) Descriptor
deprecated
func (*AuthorizationRequest) Descriptor() ([]byte, []int)
Deprecated: Use AuthorizationRequest.ProtoReflect.Descriptor instead.
func (*AuthorizationRequest) GetPassword ¶
func (x *AuthorizationRequest) GetPassword() string
func (*AuthorizationRequest) GetUsername ¶
func (x *AuthorizationRequest) GetUsername() string
func (*AuthorizationRequest) ProtoMessage ¶
func (*AuthorizationRequest) ProtoMessage()
func (*AuthorizationRequest) ProtoReflect ¶
func (x *AuthorizationRequest) ProtoReflect() protoreflect.Message
func (*AuthorizationRequest) Reset ¶
func (x *AuthorizationRequest) Reset()
func (*AuthorizationRequest) String ¶
func (x *AuthorizationRequest) String() string
type AuthorizationResponse ¶
type AuthorizationResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` AccountId int64 `protobuf:"varint,3,opt,name=accountId,proto3" json:"accountId,omitempty"` // authorizationToken The TOKEN will be returned to the client after successful login, // and the client will carry the TOKEN when accessing . AuthorizationToken string `protobuf:"bytes,4,opt,name=authorizationToken,proto3" json:"authorizationToken,omitempty"` ActorId int64 `protobuf:"varint,5,opt,name=actorId,proto3" json:"actorId,omitempty"` Mail string `protobuf:"bytes,6,opt,name=mail,proto3" json:"mail,omitempty"` DeviceId int64 `protobuf:"varint,7,opt,name=deviceId,proto3" json:"deviceId,omitempty"` // contains filtered or unexported fields }
func (*AuthorizationResponse) Descriptor
deprecated
func (*AuthorizationResponse) Descriptor() ([]byte, []int)
Deprecated: Use AuthorizationResponse.ProtoReflect.Descriptor instead.
func (*AuthorizationResponse) GetAccountId ¶
func (x *AuthorizationResponse) GetAccountId() int64
func (*AuthorizationResponse) GetActorId ¶
func (x *AuthorizationResponse) GetActorId() int64
func (*AuthorizationResponse) GetAuthorizationToken ¶
func (x *AuthorizationResponse) GetAuthorizationToken() string
func (*AuthorizationResponse) GetCode ¶
func (x *AuthorizationResponse) GetCode() string
func (*AuthorizationResponse) GetDeviceId ¶
func (x *AuthorizationResponse) GetDeviceId() int64
func (*AuthorizationResponse) GetMail ¶
func (x *AuthorizationResponse) GetMail() string
func (*AuthorizationResponse) GetStatus ¶
func (x *AuthorizationResponse) GetStatus() string
func (*AuthorizationResponse) ProtoMessage ¶
func (*AuthorizationResponse) ProtoMessage()
func (*AuthorizationResponse) ProtoReflect ¶
func (x *AuthorizationResponse) ProtoReflect() protoreflect.Message
func (*AuthorizationResponse) Reset ¶
func (x *AuthorizationResponse) Reset()
func (*AuthorizationResponse) String ¶
func (x *AuthorizationResponse) String() string
type GetDHResponse ¶
type GetDHResponse struct { DeviceId int64 `protobuf:"varint,1,opt,name=deviceId,proto3" json:"deviceId,omitempty"` PublicKey string `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` Iv string `protobuf:"bytes,3,opt,name=iv,proto3" json:"iv,omitempty"` // contains filtered or unexported fields }
func (*GetDHResponse) Descriptor
deprecated
func (*GetDHResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetDHResponse.ProtoReflect.Descriptor instead.
func (*GetDHResponse) GetDeviceId ¶
func (x *GetDHResponse) GetDeviceId() int64
func (*GetDHResponse) GetIv ¶
func (x *GetDHResponse) GetIv() string
func (*GetDHResponse) GetPublicKey ¶
func (x *GetDHResponse) GetPublicKey() string
func (*GetDHResponse) ProtoMessage ¶
func (*GetDHResponse) ProtoMessage()
func (*GetDHResponse) ProtoReflect ¶
func (x *GetDHResponse) ProtoReflect() protoreflect.Message
func (*GetDHResponse) Reset ¶
func (x *GetDHResponse) Reset()
func (*GetDHResponse) String ¶
func (x *GetDHResponse) String() string
type GetPrivateKeyRequest ¶
type GetPrivateKeyRequest struct { DeviceId int64 `protobuf:"varint,1,opt,name=deviceId,proto3" json:"deviceId,omitempty"` PublicKey string `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` Iv string `protobuf:"bytes,3,opt,name=iv,proto3" json:"iv,omitempty"` // contains filtered or unexported fields }
DH
func (*GetPrivateKeyRequest) Descriptor
deprecated
func (*GetPrivateKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetPrivateKeyRequest.ProtoReflect.Descriptor instead.
func (*GetPrivateKeyRequest) GetDeviceId ¶
func (x *GetPrivateKeyRequest) GetDeviceId() int64
func (*GetPrivateKeyRequest) GetIv ¶
func (x *GetPrivateKeyRequest) GetIv() string
func (*GetPrivateKeyRequest) GetPublicKey ¶
func (x *GetPrivateKeyRequest) GetPublicKey() string
func (*GetPrivateKeyRequest) ProtoMessage ¶
func (*GetPrivateKeyRequest) ProtoMessage()
func (*GetPrivateKeyRequest) ProtoReflect ¶
func (x *GetPrivateKeyRequest) ProtoReflect() protoreflect.Message
func (*GetPrivateKeyRequest) Reset ¶
func (x *GetPrivateKeyRequest) Reset()
func (*GetPrivateKeyRequest) String ¶
func (x *GetPrivateKeyRequest) String() string
type GetPrivateKeyResponse ¶
type GetPrivateKeyResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*GetPrivateKeyResponse) Descriptor
deprecated
func (*GetPrivateKeyResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetPrivateKeyResponse.ProtoReflect.Descriptor instead.
func (*GetPrivateKeyResponse) GetCode ¶
func (x *GetPrivateKeyResponse) GetCode() string
func (*GetPrivateKeyResponse) GetStatus ¶
func (x *GetPrivateKeyResponse) GetStatus() string
func (*GetPrivateKeyResponse) ProtoMessage ¶
func (*GetPrivateKeyResponse) ProtoMessage()
func (*GetPrivateKeyResponse) ProtoReflect ¶
func (x *GetPrivateKeyResponse) ProtoReflect() protoreflect.Message
func (*GetPrivateKeyResponse) Reset ¶
func (x *GetPrivateKeyResponse) Reset()
func (*GetPrivateKeyResponse) String ¶
func (x *GetPrivateKeyResponse) String() string
type GetPrivateResponse ¶
type GetPrivateResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Private string `protobuf:"bytes,2,opt,name=private,proto3" json:"private,omitempty"` // contains filtered or unexported fields }
func (*GetPrivateResponse) Descriptor
deprecated
func (*GetPrivateResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetPrivateResponse.ProtoReflect.Descriptor instead.
func (*GetPrivateResponse) GetCode ¶
func (x *GetPrivateResponse) GetCode() string
func (*GetPrivateResponse) GetPrivate ¶
func (x *GetPrivateResponse) GetPrivate() string
func (*GetPrivateResponse) ProtoMessage ¶
func (*GetPrivateResponse) ProtoMessage()
func (*GetPrivateResponse) ProtoReflect ¶
func (x *GetPrivateResponse) ProtoReflect() protoreflect.Message
func (*GetPrivateResponse) Reset ¶
func (x *GetPrivateResponse) Reset()
func (*GetPrivateResponse) String ¶
func (x *GetPrivateResponse) String() string
type GetPublicKeyRequest ¶
type GetPublicKeyRequest struct { AccountId string `protobuf:"bytes,1,opt,name=accountId,proto3" json:"accountId,omitempty"` // contains filtered or unexported fields }
func (*GetPublicKeyRequest) Descriptor
deprecated
func (*GetPublicKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetPublicKeyRequest.ProtoReflect.Descriptor instead.
func (*GetPublicKeyRequest) GetAccountId ¶
func (x *GetPublicKeyRequest) GetAccountId() string
func (*GetPublicKeyRequest) ProtoMessage ¶
func (*GetPublicKeyRequest) ProtoMessage()
func (*GetPublicKeyRequest) ProtoReflect ¶
func (x *GetPublicKeyRequest) ProtoReflect() protoreflect.Message
func (*GetPublicKeyRequest) Reset ¶
func (x *GetPublicKeyRequest) Reset()
func (*GetPublicKeyRequest) String ¶
func (x *GetPublicKeyRequest) String() string
type GetPublicKeyResponse ¶
type GetPublicKeyResponse struct { PublicKey string `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` // contains filtered or unexported fields }
func (*GetPublicKeyResponse) Descriptor
deprecated
func (*GetPublicKeyResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetPublicKeyResponse.ProtoReflect.Descriptor instead.
func (*GetPublicKeyResponse) GetPublicKey ¶
func (x *GetPublicKeyResponse) GetPublicKey() string
func (*GetPublicKeyResponse) ProtoMessage ¶
func (*GetPublicKeyResponse) ProtoMessage()
func (*GetPublicKeyResponse) ProtoReflect ¶
func (x *GetPublicKeyResponse) ProtoReflect() protoreflect.Message
func (*GetPublicKeyResponse) Reset ¶
func (x *GetPublicKeyResponse) Reset()
func (*GetPublicKeyResponse) String ¶
func (x *GetPublicKeyResponse) String() string
type SendPrivateKeyRequest ¶
type SendPrivateKeyRequest struct { DeviceId int64 `protobuf:"varint,1,opt,name=deviceId,proto3" json:"deviceId,omitempty"` PublicKey string `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` // Use the request iv encryption key . PrivateKey string `protobuf:"bytes,3,opt,name=privateKey,proto3" json:"privateKey,omitempty"` // contains filtered or unexported fields }
func (*SendPrivateKeyRequest) Descriptor
deprecated
func (*SendPrivateKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use SendPrivateKeyRequest.ProtoReflect.Descriptor instead.
func (*SendPrivateKeyRequest) GetDeviceId ¶
func (x *SendPrivateKeyRequest) GetDeviceId() int64
func (*SendPrivateKeyRequest) GetPrivateKey ¶
func (x *SendPrivateKeyRequest) GetPrivateKey() string
func (*SendPrivateKeyRequest) GetPublicKey ¶
func (x *SendPrivateKeyRequest) GetPublicKey() string
func (*SendPrivateKeyRequest) ProtoMessage ¶
func (*SendPrivateKeyRequest) ProtoMessage()
func (*SendPrivateKeyRequest) ProtoReflect ¶
func (x *SendPrivateKeyRequest) ProtoReflect() protoreflect.Message
func (*SendPrivateKeyRequest) Reset ¶
func (x *SendPrivateKeyRequest) Reset()
func (*SendPrivateKeyRequest) String ¶
func (x *SendPrivateKeyRequest) String() string
type SendPrivateKeyResponse ¶
type SendPrivateKeyResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*SendPrivateKeyResponse) Descriptor
deprecated
func (*SendPrivateKeyResponse) Descriptor() ([]byte, []int)
Deprecated: Use SendPrivateKeyResponse.ProtoReflect.Descriptor instead.
func (*SendPrivateKeyResponse) GetCode ¶
func (x *SendPrivateKeyResponse) GetCode() string
func (*SendPrivateKeyResponse) GetStatus ¶
func (x *SendPrivateKeyResponse) GetStatus() string
func (*SendPrivateKeyResponse) ProtoMessage ¶
func (*SendPrivateKeyResponse) ProtoMessage()
func (*SendPrivateKeyResponse) ProtoReflect ¶
func (x *SendPrivateKeyResponse) ProtoReflect() protoreflect.Message
func (*SendPrivateKeyResponse) Reset ¶
func (x *SendPrivateKeyResponse) Reset()
func (*SendPrivateKeyResponse) String ¶
func (x *SendPrivateKeyResponse) String() string
type SetPublicKeyRequest ¶
type SetPublicKeyRequest struct { AccountId int64 `protobuf:"varint,1,opt,name=accountId,proto3" json:"accountId,omitempty"` PublicKey string `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` // contains filtered or unexported fields }
func (*SetPublicKeyRequest) Descriptor
deprecated
func (*SetPublicKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use SetPublicKeyRequest.ProtoReflect.Descriptor instead.
func (*SetPublicKeyRequest) GetAccountId ¶
func (x *SetPublicKeyRequest) GetAccountId() int64
func (*SetPublicKeyRequest) GetPublicKey ¶
func (x *SetPublicKeyRequest) GetPublicKey() string
func (*SetPublicKeyRequest) ProtoMessage ¶
func (*SetPublicKeyRequest) ProtoMessage()
func (*SetPublicKeyRequest) ProtoReflect ¶
func (x *SetPublicKeyRequest) ProtoReflect() protoreflect.Message
func (*SetPublicKeyRequest) Reset ¶
func (x *SetPublicKeyRequest) Reset()
func (*SetPublicKeyRequest) String ¶
func (x *SetPublicKeyRequest) String() string
type SetPublicKeyResponse ¶
type SetPublicKeyResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*SetPublicKeyResponse) Descriptor
deprecated
func (*SetPublicKeyResponse) Descriptor() ([]byte, []int)
Deprecated: Use SetPublicKeyResponse.ProtoReflect.Descriptor instead.
func (*SetPublicKeyResponse) GetCode ¶
func (x *SetPublicKeyResponse) GetCode() string
func (*SetPublicKeyResponse) GetStatus ¶
func (x *SetPublicKeyResponse) GetStatus() string
func (*SetPublicKeyResponse) ProtoMessage ¶
func (*SetPublicKeyResponse) ProtoMessage()
func (*SetPublicKeyResponse) ProtoReflect ¶
func (x *SetPublicKeyResponse) ProtoReflect() protoreflect.Message
func (*SetPublicKeyResponse) Reset ¶
func (x *SetPublicKeyResponse) Reset()
func (*SetPublicKeyResponse) String ¶
func (x *SetPublicKeyResponse) String() string
type UnimplementedAuthServer ¶
type UnimplementedAuthServer struct { }
UnimplementedAuthServer should be embedded to have forward compatible implementations.
func (UnimplementedAuthServer) Authorization ¶
func (UnimplementedAuthServer) Authorization(context.Context, *AuthorizationRequest) (*AuthorizationResponse, error)
func (UnimplementedAuthServer) GetDH ¶
func (UnimplementedAuthServer) GetDH(context.Context, *emptypb.Empty) (*GetDHResponse, error)
func (UnimplementedAuthServer) GetPrivateKey ¶
func (UnimplementedAuthServer) GetPrivateKey(context.Context, *GetPrivateKeyRequest) (*GetPrivateKeyResponse, error)
func (UnimplementedAuthServer) GetPublicKey ¶
func (UnimplementedAuthServer) GetPublicKey(context.Context, *GetPublicKeyRequest) (*GetPublicKeyResponse, error)
func (UnimplementedAuthServer) SendPrivateKey ¶
func (UnimplementedAuthServer) SendPrivateKey(context.Context, *SendPrivateKeyRequest) (*SendPrivateKeyResponse, error)
func (UnimplementedAuthServer) SetPublicKey ¶
func (UnimplementedAuthServer) SetPublicKey(context.Context, *SetPublicKeyRequest) (*SetPublicKeyResponse, error)
func (UnimplementedAuthServer) WaitPrivateKey ¶
func (UnimplementedAuthServer) WaitPrivateKey(context.Context, *emptypb.Empty) (*WaitPrivateKeyResponse, error)
type UnsafeAuthServer ¶
type UnsafeAuthServer interface {
// contains filtered or unexported methods
}
UnsafeAuthServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AuthServer will result in compilation errors.
type WaitPrivateKeyResponse ¶
type WaitPrivateKeyResponse struct { DeviceId int64 `protobuf:"varint,1,opt,name=deviceId,proto3" json:"deviceId,omitempty"` PublicKey string `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` Private string `protobuf:"bytes,3,opt,name=private,proto3" json:"private,omitempty"` // contains filtered or unexported fields }
func (*WaitPrivateKeyResponse) Descriptor
deprecated
func (*WaitPrivateKeyResponse) Descriptor() ([]byte, []int)
Deprecated: Use WaitPrivateKeyResponse.ProtoReflect.Descriptor instead.
func (*WaitPrivateKeyResponse) GetDeviceId ¶
func (x *WaitPrivateKeyResponse) GetDeviceId() int64
func (*WaitPrivateKeyResponse) GetPrivate ¶
func (x *WaitPrivateKeyResponse) GetPrivate() string
func (*WaitPrivateKeyResponse) GetPublicKey ¶
func (x *WaitPrivateKeyResponse) GetPublicKey() string
func (*WaitPrivateKeyResponse) ProtoMessage ¶
func (*WaitPrivateKeyResponse) ProtoMessage()
func (*WaitPrivateKeyResponse) ProtoReflect ¶
func (x *WaitPrivateKeyResponse) ProtoReflect() protoreflect.Message
func (*WaitPrivateKeyResponse) Reset ¶
func (x *WaitPrivateKeyResponse) Reset()
func (*WaitPrivateKeyResponse) String ¶
func (x *WaitPrivateKeyResponse) String() string