1498 lines
52 KiB
Go
1498 lines
52 KiB
Go
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
// versions:
|
|
// protoc-gen-go v1.34.2
|
|
// protoc v3.19.4
|
|
// source: generate/protobuf/permission.proto
|
|
|
|
package permission
|
|
|
|
import (
|
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
reflect "reflect"
|
|
sync "sync"
|
|
)
|
|
|
|
const (
|
|
// Verify that this generated code is sufficiently up-to-date.
|
|
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
)
|
|
|
|
// OKResp
|
|
type OKResp struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
}
|
|
|
|
func (x *OKResp) Reset() {
|
|
*x = OKResp{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[0]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *OKResp) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*OKResp) ProtoMessage() {}
|
|
|
|
func (x *OKResp) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[0]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use OKResp.ProtoReflect.Descriptor instead.
|
|
func (*OKResp) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{0}
|
|
}
|
|
|
|
// NoneReq
|
|
type NoneReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
}
|
|
|
|
func (x *NoneReq) Reset() {
|
|
*x = NoneReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[1]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *NoneReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*NoneReq) ProtoMessage() {}
|
|
|
|
func (x *NoneReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[1]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use NoneReq.ProtoReflect.Descriptor instead.
|
|
func (*NoneReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{1}
|
|
}
|
|
|
|
// AuthorizationReq 定義授權請求的結構
|
|
type AuthorizationReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
// grant_type 表示授權類型
|
|
GrantType string `protobuf:"bytes,1,opt,name=grant_type,json=grantType,proto3" json:"grant_type,omitempty"`
|
|
// device_id 表示設備 ID
|
|
DeviceId string `protobuf:"bytes,2,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"`
|
|
// scope 表示授權範圍
|
|
Scope string `protobuf:"bytes,3,opt,name=scope,proto3" json:"scope,omitempty"`
|
|
// data 是一個通用的 key-value 結構,用於存儲額外數據
|
|
Data map[string]string `protobuf:"bytes,4,rep,name=data,proto3" json:"data,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
|
|
// expires 表示過期時間
|
|
Expires int32 `protobuf:"varint,5,opt,name=expires,proto3" json:"expires,omitempty"`
|
|
// is_refresh_token 表示是否為刷新令牌
|
|
IsRefreshToken bool `protobuf:"varint,6,opt,name=is_refresh_token,json=isRefreshToken,proto3" json:"is_refresh_token,omitempty"`
|
|
}
|
|
|
|
func (x *AuthorizationReq) Reset() {
|
|
*x = AuthorizationReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[2]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *AuthorizationReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*AuthorizationReq) ProtoMessage() {}
|
|
|
|
func (x *AuthorizationReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[2]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use AuthorizationReq.ProtoReflect.Descriptor instead.
|
|
func (*AuthorizationReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{2}
|
|
}
|
|
|
|
func (x *AuthorizationReq) GetGrantType() string {
|
|
if x != nil {
|
|
return x.GrantType
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AuthorizationReq) GetDeviceId() string {
|
|
if x != nil {
|
|
return x.DeviceId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AuthorizationReq) GetScope() string {
|
|
if x != nil {
|
|
return x.Scope
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AuthorizationReq) GetData() map[string]string {
|
|
if x != nil {
|
|
return x.Data
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *AuthorizationReq) GetExpires() int32 {
|
|
if x != nil {
|
|
return x.Expires
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *AuthorizationReq) GetIsRefreshToken() bool {
|
|
if x != nil {
|
|
return x.IsRefreshToken
|
|
}
|
|
return false
|
|
}
|
|
|
|
// TokenResp 定義訪問令牌響應的結構
|
|
type TokenResp struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
// access_token 表示訪問令牌
|
|
AccessToken string `protobuf:"bytes,1,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
|
|
// token_type 表示令牌類型
|
|
TokenType string `protobuf:"bytes,2,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
|
|
// expires_in 表示令牌過期時間
|
|
ExpiresIn int32 `protobuf:"varint,3,opt,name=expires_in,json=expiresIn,proto3" json:"expires_in,omitempty"`
|
|
// refresh_token 表示刷新令牌
|
|
RefreshToken string `protobuf:"bytes,4,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"`
|
|
}
|
|
|
|
func (x *TokenResp) Reset() {
|
|
*x = TokenResp{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[3]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *TokenResp) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*TokenResp) ProtoMessage() {}
|
|
|
|
func (x *TokenResp) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[3]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use TokenResp.ProtoReflect.Descriptor instead.
|
|
func (*TokenResp) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{3}
|
|
}
|
|
|
|
func (x *TokenResp) GetAccessToken() string {
|
|
if x != nil {
|
|
return x.AccessToken
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *TokenResp) GetTokenType() string {
|
|
if x != nil {
|
|
return x.TokenType
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *TokenResp) GetExpiresIn() int32 {
|
|
if x != nil {
|
|
return x.ExpiresIn
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *TokenResp) GetRefreshToken() string {
|
|
if x != nil {
|
|
return x.RefreshToken
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// CreateOneTimeTokenReq 建立一次性使用的 token,
|
|
// 要帶比較長久的 token 來,驗證後才可以
|
|
type CreateOneTimeTokenReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
}
|
|
|
|
func (x *CreateOneTimeTokenReq) Reset() {
|
|
*x = CreateOneTimeTokenReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[4]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *CreateOneTimeTokenReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateOneTimeTokenReq) ProtoMessage() {}
|
|
|
|
func (x *CreateOneTimeTokenReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[4]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CreateOneTimeTokenReq.ProtoReflect.Descriptor instead.
|
|
func (*CreateOneTimeTokenReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{4}
|
|
}
|
|
|
|
func (x *CreateOneTimeTokenReq) GetToken() string {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type CreateOneTimeTokenResp struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
OneTimeToken string `protobuf:"bytes,1,opt,name=one_time_token,json=oneTimeToken,proto3" json:"one_time_token,omitempty"`
|
|
}
|
|
|
|
func (x *CreateOneTimeTokenResp) Reset() {
|
|
*x = CreateOneTimeTokenResp{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[5]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *CreateOneTimeTokenResp) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateOneTimeTokenResp) ProtoMessage() {}
|
|
|
|
func (x *CreateOneTimeTokenResp) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[5]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CreateOneTimeTokenResp.ProtoReflect.Descriptor instead.
|
|
func (*CreateOneTimeTokenResp) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{5}
|
|
}
|
|
|
|
func (x *CreateOneTimeTokenResp) GetOneTimeToken() string {
|
|
if x != nil {
|
|
return x.OneTimeToken
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// RefreshTokenReq 更新 Token
|
|
type RefreshTokenReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
Scope string `protobuf:"bytes,2,opt,name=scope,proto3" json:"scope,omitempty"`
|
|
Expires int64 `protobuf:"varint,3,opt,name=expires,proto3" json:"expires,omitempty"`
|
|
DeviceId string `protobuf:"bytes,4,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"`
|
|
}
|
|
|
|
func (x *RefreshTokenReq) Reset() {
|
|
*x = RefreshTokenReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[6]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *RefreshTokenReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*RefreshTokenReq) ProtoMessage() {}
|
|
|
|
func (x *RefreshTokenReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[6]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use RefreshTokenReq.ProtoReflect.Descriptor instead.
|
|
func (*RefreshTokenReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{6}
|
|
}
|
|
|
|
func (x *RefreshTokenReq) GetToken() string {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *RefreshTokenReq) GetScope() string {
|
|
if x != nil {
|
|
return x.Scope
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *RefreshTokenReq) GetExpires() int64 {
|
|
if x != nil {
|
|
return x.Expires
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *RefreshTokenReq) GetDeviceId() string {
|
|
if x != nil {
|
|
return x.DeviceId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// https://datatracker.ietf.org/doc/html/rfc6749#section-4.3.3
|
|
type RefreshTokenResp struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
OneTimeToken string `protobuf:"bytes,2,opt,name=one_time_token,json=oneTimeToken,proto3" json:"one_time_token,omitempty"`
|
|
ExpiresIn int64 `protobuf:"varint,3,opt,name=expires_in,json=expiresIn,proto3" json:"expires_in,omitempty"`
|
|
TokenType string `protobuf:"bytes,4,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
|
|
}
|
|
|
|
func (x *RefreshTokenResp) Reset() {
|
|
*x = RefreshTokenResp{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[7]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *RefreshTokenResp) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*RefreshTokenResp) ProtoMessage() {}
|
|
|
|
func (x *RefreshTokenResp) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[7]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use RefreshTokenResp.ProtoReflect.Descriptor instead.
|
|
func (*RefreshTokenResp) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{7}
|
|
}
|
|
|
|
func (x *RefreshTokenResp) GetToken() string {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *RefreshTokenResp) GetOneTimeToken() string {
|
|
if x != nil {
|
|
return x.OneTimeToken
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *RefreshTokenResp) GetExpiresIn() int64 {
|
|
if x != nil {
|
|
return x.ExpiresIn
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *RefreshTokenResp) GetTokenType() string {
|
|
if x != nil {
|
|
return x.TokenType
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// CancelTokenReq 註銷這個 Token
|
|
type CancelTokenReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
}
|
|
|
|
func (x *CancelTokenReq) Reset() {
|
|
*x = CancelTokenReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[8]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *CancelTokenReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CancelTokenReq) ProtoMessage() {}
|
|
|
|
func (x *CancelTokenReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[8]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CancelTokenReq.ProtoReflect.Descriptor instead.
|
|
func (*CancelTokenReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{8}
|
|
}
|
|
|
|
func (x *CancelTokenReq) GetToken() string {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// CancelTokenReq 註銷這個 Token
|
|
type DoTokenByUIDReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Ids []string `protobuf:"bytes,1,rep,name=ids,proto3" json:"ids,omitempty"`
|
|
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"`
|
|
}
|
|
|
|
func (x *DoTokenByUIDReq) Reset() {
|
|
*x = DoTokenByUIDReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[9]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *DoTokenByUIDReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*DoTokenByUIDReq) ProtoMessage() {}
|
|
|
|
func (x *DoTokenByUIDReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[9]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use DoTokenByUIDReq.ProtoReflect.Descriptor instead.
|
|
func (*DoTokenByUIDReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{9}
|
|
}
|
|
|
|
func (x *DoTokenByUIDReq) GetIds() []string {
|
|
if x != nil {
|
|
return x.Ids
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *DoTokenByUIDReq) GetUid() string {
|
|
if x != nil {
|
|
return x.Uid
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// QueryTokenByUIDReq 拿這個UID 找 Token
|
|
type QueryTokenByUIDReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"`
|
|
}
|
|
|
|
func (x *QueryTokenByUIDReq) Reset() {
|
|
*x = QueryTokenByUIDReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[10]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *QueryTokenByUIDReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*QueryTokenByUIDReq) ProtoMessage() {}
|
|
|
|
func (x *QueryTokenByUIDReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[10]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use QueryTokenByUIDReq.ProtoReflect.Descriptor instead.
|
|
func (*QueryTokenByUIDReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{10}
|
|
}
|
|
|
|
func (x *QueryTokenByUIDReq) GetUid() string {
|
|
if x != nil {
|
|
return x.Uid
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// ValidationTokenReq 驗證這個 Token
|
|
type ValidationTokenReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
}
|
|
|
|
func (x *ValidationTokenReq) Reset() {
|
|
*x = ValidationTokenReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[11]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *ValidationTokenReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ValidationTokenReq) ProtoMessage() {}
|
|
|
|
func (x *ValidationTokenReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[11]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ValidationTokenReq.ProtoReflect.Descriptor instead.
|
|
func (*ValidationTokenReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{11}
|
|
}
|
|
|
|
func (x *ValidationTokenReq) GetToken() string {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// ValidationTokenResp 驗證以及取得 Token 詳情
|
|
type ValidationTokenResp struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token *Token `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
Data map[string]string `protobuf:"bytes,2,rep,name=data,proto3" json:"data,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
|
|
}
|
|
|
|
func (x *ValidationTokenResp) Reset() {
|
|
*x = ValidationTokenResp{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[12]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *ValidationTokenResp) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ValidationTokenResp) ProtoMessage() {}
|
|
|
|
func (x *ValidationTokenResp) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[12]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ValidationTokenResp.ProtoReflect.Descriptor instead.
|
|
func (*ValidationTokenResp) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{12}
|
|
}
|
|
|
|
func (x *ValidationTokenResp) GetToken() *Token {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *ValidationTokenResp) GetData() map[string]string {
|
|
if x != nil {
|
|
return x.Data
|
|
}
|
|
return nil
|
|
}
|
|
|
|
// Token 定義令牌的結構
|
|
type Token struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
// ID 表示令牌的唯一標識符
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
|
// client_id 表示客戶端 ID
|
|
ClientId int32 `protobuf:"varint,2,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"`
|
|
// uid 表示用戶 ID
|
|
Uid string `protobuf:"bytes,3,opt,name=uid,proto3" json:"uid,omitempty"`
|
|
// device_id 表示設備 ID
|
|
DeviceId string `protobuf:"bytes,4,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"`
|
|
// access_token 表示訪問令牌
|
|
AccessToken string `protobuf:"bytes,5,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
|
|
// expires_in 表示訪問令牌的過期時間(秒)
|
|
ExpiresIn int32 `protobuf:"varint,6,opt,name=expires_in,json=expiresIn,proto3" json:"expires_in,omitempty"`
|
|
// access_create_at 表示訪問令牌的創建時間
|
|
AccessCreateAt int64 `protobuf:"varint,7,opt,name=access_create_at,json=accessCreateAt,proto3" json:"access_create_at,omitempty"`
|
|
// refresh_token 表示刷新令牌
|
|
RefreshToken string `protobuf:"bytes,8,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"`
|
|
// refresh_expires_in 表示刷新令牌的過期時間(秒)
|
|
RefreshExpiresIn int32 `protobuf:"varint,9,opt,name=refresh_expires_in,json=refreshExpiresIn,proto3" json:"refresh_expires_in,omitempty"`
|
|
// refresh_create_at 表示刷新令牌的創建時間
|
|
RefreshCreateAt int64 `protobuf:"varint,10,opt,name=refresh_create_at,json=refreshCreateAt,proto3" json:"refresh_create_at,omitempty"`
|
|
}
|
|
|
|
func (x *Token) Reset() {
|
|
*x = Token{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[13]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *Token) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*Token) ProtoMessage() {}
|
|
|
|
func (x *Token) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[13]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use Token.ProtoReflect.Descriptor instead.
|
|
func (*Token) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{13}
|
|
}
|
|
|
|
func (x *Token) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Token) GetClientId() int32 {
|
|
if x != nil {
|
|
return x.ClientId
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Token) GetUid() string {
|
|
if x != nil {
|
|
return x.Uid
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Token) GetDeviceId() string {
|
|
if x != nil {
|
|
return x.DeviceId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Token) GetAccessToken() string {
|
|
if x != nil {
|
|
return x.AccessToken
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Token) GetExpiresIn() int32 {
|
|
if x != nil {
|
|
return x.ExpiresIn
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Token) GetAccessCreateAt() int64 {
|
|
if x != nil {
|
|
return x.AccessCreateAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Token) GetRefreshToken() string {
|
|
if x != nil {
|
|
return x.RefreshToken
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Token) GetRefreshExpiresIn() int32 {
|
|
if x != nil {
|
|
return x.RefreshExpiresIn
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Token) GetRefreshCreateAt() int64 {
|
|
if x != nil {
|
|
return x.RefreshCreateAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
// DoTokenByDeviceIDReq 用DeviceID 來做事的
|
|
type DoTokenByDeviceIDReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
DeviceId string `protobuf:"bytes,1,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"`
|
|
}
|
|
|
|
func (x *DoTokenByDeviceIDReq) Reset() {
|
|
*x = DoTokenByDeviceIDReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[14]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *DoTokenByDeviceIDReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*DoTokenByDeviceIDReq) ProtoMessage() {}
|
|
|
|
func (x *DoTokenByDeviceIDReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[14]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use DoTokenByDeviceIDReq.ProtoReflect.Descriptor instead.
|
|
func (*DoTokenByDeviceIDReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{14}
|
|
}
|
|
|
|
func (x *DoTokenByDeviceIDReq) GetDeviceId() string {
|
|
if x != nil {
|
|
return x.DeviceId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type Tokens struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token []*TokenResp `protobuf:"bytes,1,rep,name=token,proto3" json:"token,omitempty"`
|
|
}
|
|
|
|
func (x *Tokens) Reset() {
|
|
*x = Tokens{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[15]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *Tokens) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*Tokens) ProtoMessage() {}
|
|
|
|
func (x *Tokens) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[15]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use Tokens.ProtoReflect.Descriptor instead.
|
|
func (*Tokens) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{15}
|
|
}
|
|
|
|
func (x *Tokens) GetToken() []*TokenResp {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type CancelOneTimeTokenReq struct {
|
|
state protoimpl.MessageState
|
|
sizeCache protoimpl.SizeCache
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
Token []string `protobuf:"bytes,1,rep,name=token,proto3" json:"token,omitempty"`
|
|
}
|
|
|
|
func (x *CancelOneTimeTokenReq) Reset() {
|
|
*x = CancelOneTimeTokenReq{}
|
|
if protoimpl.UnsafeEnabled {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[16]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
}
|
|
|
|
func (x *CancelOneTimeTokenReq) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CancelOneTimeTokenReq) ProtoMessage() {}
|
|
|
|
func (x *CancelOneTimeTokenReq) ProtoReflect() protoreflect.Message {
|
|
mi := &file_generate_protobuf_permission_proto_msgTypes[16]
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CancelOneTimeTokenReq.ProtoReflect.Descriptor instead.
|
|
func (*CancelOneTimeTokenReq) Descriptor() ([]byte, []int) {
|
|
return file_generate_protobuf_permission_proto_rawDescGZIP(), []int{16}
|
|
}
|
|
|
|
func (x *CancelOneTimeTokenReq) GetToken() []string {
|
|
if x != nil {
|
|
return x.Token
|
|
}
|
|
return nil
|
|
}
|
|
|
|
var File_generate_protobuf_permission_proto protoreflect.FileDescriptor
|
|
|
|
var file_generate_protobuf_permission_proto_rawDesc = []byte{
|
|
0x0a, 0x22, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
|
0x62, 0x75, 0x66, 0x2f, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x70,
|
|
0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0a, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e,
|
|
0x22, 0x08, 0x0a, 0x06, 0x4f, 0x4b, 0x52, 0x65, 0x73, 0x70, 0x22, 0x09, 0x0a, 0x07, 0x4e, 0x6f,
|
|
0x6e, 0x65, 0x52, 0x65, 0x71, 0x22, 0x9d, 0x02, 0x0a, 0x10, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72,
|
|
0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x12, 0x1d, 0x0a, 0x0a, 0x67, 0x72,
|
|
0x61, 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09,
|
|
0x67, 0x72, 0x61, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x65, 0x76,
|
|
0x69, 0x63, 0x65, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x64, 0x65,
|
|
0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x18,
|
|
0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x12, 0x3a, 0x0a, 0x04,
|
|
0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x70, 0x65, 0x72,
|
|
0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a,
|
|
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74,
|
|
0x72, 0x79, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x78, 0x70, 0x69,
|
|
0x72, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x78, 0x70, 0x69, 0x72,
|
|
0x65, 0x73, 0x12, 0x28, 0x0a, 0x10, 0x69, 0x73, 0x5f, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68,
|
|
0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x69, 0x73,
|
|
0x52, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x1a, 0x37, 0x0a, 0x09,
|
|
0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79,
|
|
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76,
|
|
0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
|
|
0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x91, 0x01, 0x0a, 0x09, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52,
|
|
0x65, 0x73, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x74, 0x6f,
|
|
0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x63, 0x63, 0x65, 0x73,
|
|
0x73, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x5f,
|
|
0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x74, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65, 0x73,
|
|
0x5f, 0x69, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x65, 0x78, 0x70, 0x69, 0x72,
|
|
0x65, 0x73, 0x49, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x5f,
|
|
0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x66,
|
|
0x72, 0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x2d, 0x0a, 0x15, 0x43, 0x72, 0x65,
|
|
0x61, 0x74, 0x65, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52,
|
|
0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x3e, 0x0a, 0x16, 0x43, 0x72, 0x65, 0x61,
|
|
0x74, 0x65, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65,
|
|
0x73, 0x70, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x6e, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x74,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x6e, 0x65, 0x54,
|
|
0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x74, 0x0a, 0x0f, 0x52, 0x65, 0x66, 0x72,
|
|
0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x74,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
|
|
0x52, 0x05, 0x73, 0x63, 0x6f, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x78, 0x70, 0x69, 0x72,
|
|
0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65,
|
|
0x73, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x69, 0x64, 0x18, 0x04,
|
|
0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x22, 0x8c,
|
|
0x01, 0x0a, 0x10, 0x52, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52,
|
|
0x65, 0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01,
|
|
0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x6e, 0x65,
|
|
0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28,
|
|
0x09, 0x52, 0x0c, 0x6f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12,
|
|
0x1d, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65, 0x73, 0x5f, 0x69, 0x6e, 0x18, 0x03, 0x20,
|
|
0x01, 0x28, 0x03, 0x52, 0x09, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65, 0x73, 0x49, 0x6e, 0x12, 0x1d,
|
|
0x0a, 0x0a, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01,
|
|
0x28, 0x09, 0x52, 0x09, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x22, 0x26, 0x0a,
|
|
0x0e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x12,
|
|
0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
|
|
0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x35, 0x0a, 0x0f, 0x44, 0x6f, 0x54, 0x6f, 0x6b, 0x65, 0x6e,
|
|
0x42, 0x79, 0x55, 0x49, 0x44, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x69, 0x64, 0x73, 0x18,
|
|
0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x03, 0x69, 0x64, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69,
|
|
0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x22, 0x26, 0x0a, 0x12,
|
|
0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x55, 0x49, 0x44, 0x52,
|
|
0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
|
|
0x03, 0x75, 0x69, 0x64, 0x22, 0x2a, 0x0a, 0x12, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69,
|
|
0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f,
|
|
0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e,
|
|
0x22, 0xb6, 0x01, 0x0a, 0x13, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x27, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73,
|
|
0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x12, 0x3d, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32,
|
|
0x29, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x56, 0x61, 0x6c,
|
|
0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70,
|
|
0x2e, 0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61,
|
|
0x1a, 0x37, 0x0a, 0x09, 0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
|
|
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
|
|
0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
|
|
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xce, 0x02, 0x0a, 0x05, 0x54, 0x6f,
|
|
0x6b, 0x65, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
|
|
0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64,
|
|
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64,
|
|
0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75,
|
|
0x69, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x69, 0x64, 0x18,
|
|
0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x12,
|
|
0x21, 0x0a, 0x0c, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18,
|
|
0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x6f, 0x6b,
|
|
0x65, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65, 0x73, 0x5f, 0x69, 0x6e,
|
|
0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65, 0x73, 0x49,
|
|
0x6e, 0x12, 0x28, 0x0a, 0x10, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x63, 0x72, 0x65, 0x61,
|
|
0x74, 0x65, 0x5f, 0x61, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x61, 0x63, 0x63,
|
|
0x65, 0x73, 0x73, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x72,
|
|
0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x08, 0x20, 0x01,
|
|
0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e,
|
|
0x12, 0x2c, 0x0a, 0x12, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x5f, 0x65, 0x78, 0x70, 0x69,
|
|
0x72, 0x65, 0x73, 0x5f, 0x69, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52, 0x10, 0x72, 0x65,
|
|
0x66, 0x72, 0x65, 0x73, 0x68, 0x45, 0x78, 0x70, 0x69, 0x72, 0x65, 0x73, 0x49, 0x6e, 0x12, 0x2a,
|
|
0x0a, 0x11, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x5f, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65,
|
|
0x5f, 0x61, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x72, 0x65, 0x66, 0x72, 0x65,
|
|
0x73, 0x68, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x74, 0x22, 0x33, 0x0a, 0x14, 0x44, 0x6f,
|
|
0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x44, 0x52,
|
|
0x65, 0x71, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x69, 0x64, 0x18,
|
|
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x22,
|
|
0x35, 0x0a, 0x06, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x12, 0x2b, 0x0a, 0x05, 0x74, 0x6f, 0x6b,
|
|
0x65, 0x6e, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69,
|
|
0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x52,
|
|
0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x2d, 0x0a, 0x15, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c,
|
|
0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x12,
|
|
0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x05,
|
|
0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x32, 0xff, 0x05, 0x0a, 0x0c, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x53,
|
|
0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x3f, 0x0a, 0x08, 0x4e, 0x65, 0x77, 0x54, 0x6f, 0x6b,
|
|
0x65, 0x6e, 0x12, 0x1c, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e,
|
|
0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71,
|
|
0x1a, 0x15, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x54, 0x6f,
|
|
0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x49, 0x0a, 0x0c, 0x52, 0x65, 0x66, 0x72, 0x65,
|
|
0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1b, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73,
|
|
0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x52, 0x65, 0x71, 0x1a, 0x1c, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f,
|
|
0x6e, 0x2e, 0x52, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65,
|
|
0x73, 0x70, 0x12, 0x3d, 0x0a, 0x0b, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x54, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x12, 0x1a, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x43,
|
|
0x61, 0x6e, 0x63, 0x65, 0x6c, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x12, 0x2e,
|
|
0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x4f, 0x4b, 0x52, 0x65, 0x73,
|
|
0x70, 0x12, 0x52, 0x0a, 0x0f, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f,
|
|
0x6e, 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x52, 0x65, 0x71, 0x1a, 0x1f, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f,
|
|
0x6e, 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65,
|
|
0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x3f, 0x0a, 0x0c, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x54,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x12, 0x1b, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69,
|
|
0x6f, 0x6e, 0x2e, 0x44, 0x6f, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x55, 0x49, 0x44, 0x52,
|
|
0x65, 0x71, 0x1a, 0x12, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e,
|
|
0x4f, 0x4b, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4d, 0x0a, 0x15, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c,
|
|
0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x12,
|
|
0x20, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x44, 0x6f, 0x54,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x44, 0x52, 0x65,
|
|
0x71, 0x1a, 0x12, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x4f,
|
|
0x4b, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4f, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72,
|
|
0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x42, 0x79, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64,
|
|
0x12, 0x20, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x44, 0x6f,
|
|
0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x49, 0x44, 0x52,
|
|
0x65, 0x71, 0x1a, 0x12, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e,
|
|
0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x12, 0x48, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65,
|
|
0x72, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x42, 0x79, 0x55, 0x69, 0x64, 0x12, 0x1e, 0x2e, 0x70,
|
|
0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54,
|
|
0x6f, 0x6b, 0x65, 0x6e, 0x42, 0x79, 0x55, 0x49, 0x44, 0x52, 0x65, 0x71, 0x1a, 0x12, 0x2e, 0x70,
|
|
0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73,
|
|
0x12, 0x58, 0x0a, 0x0f, 0x4e, 0x65, 0x77, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f,
|
|
0x6b, 0x65, 0x6e, 0x12, 0x21, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e,
|
|
0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f,
|
|
0x6b, 0x65, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x22, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73,
|
|
0x69, 0x6f, 0x6e, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d,
|
|
0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4b, 0x0a, 0x12, 0x43, 0x61,
|
|
0x6e, 0x63, 0x65, 0x6c, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e,
|
|
0x12, 0x21, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x43, 0x61,
|
|
0x6e, 0x63, 0x65, 0x6c, 0x4f, 0x6e, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e,
|
|
0x52, 0x65, 0x71, 0x1a, 0x12, 0x2e, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e,
|
|
0x2e, 0x4f, 0x4b, 0x52, 0x65, 0x73, 0x70, 0x42, 0x0e, 0x5a, 0x0c, 0x2e, 0x2f, 0x70, 0x65, 0x72,
|
|
0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
}
|
|
|
|
var (
|
|
file_generate_protobuf_permission_proto_rawDescOnce sync.Once
|
|
file_generate_protobuf_permission_proto_rawDescData = file_generate_protobuf_permission_proto_rawDesc
|
|
)
|
|
|
|
func file_generate_protobuf_permission_proto_rawDescGZIP() []byte {
|
|
file_generate_protobuf_permission_proto_rawDescOnce.Do(func() {
|
|
file_generate_protobuf_permission_proto_rawDescData = protoimpl.X.CompressGZIP(file_generate_protobuf_permission_proto_rawDescData)
|
|
})
|
|
return file_generate_protobuf_permission_proto_rawDescData
|
|
}
|
|
|
|
var file_generate_protobuf_permission_proto_msgTypes = make([]protoimpl.MessageInfo, 19)
|
|
var file_generate_protobuf_permission_proto_goTypes = []any{
|
|
(*OKResp)(nil), // 0: permission.OKResp
|
|
(*NoneReq)(nil), // 1: permission.NoneReq
|
|
(*AuthorizationReq)(nil), // 2: permission.AuthorizationReq
|
|
(*TokenResp)(nil), // 3: permission.TokenResp
|
|
(*CreateOneTimeTokenReq)(nil), // 4: permission.CreateOneTimeTokenReq
|
|
(*CreateOneTimeTokenResp)(nil), // 5: permission.CreateOneTimeTokenResp
|
|
(*RefreshTokenReq)(nil), // 6: permission.RefreshTokenReq
|
|
(*RefreshTokenResp)(nil), // 7: permission.RefreshTokenResp
|
|
(*CancelTokenReq)(nil), // 8: permission.CancelTokenReq
|
|
(*DoTokenByUIDReq)(nil), // 9: permission.DoTokenByUIDReq
|
|
(*QueryTokenByUIDReq)(nil), // 10: permission.QueryTokenByUIDReq
|
|
(*ValidationTokenReq)(nil), // 11: permission.ValidationTokenReq
|
|
(*ValidationTokenResp)(nil), // 12: permission.ValidationTokenResp
|
|
(*Token)(nil), // 13: permission.Token
|
|
(*DoTokenByDeviceIDReq)(nil), // 14: permission.DoTokenByDeviceIDReq
|
|
(*Tokens)(nil), // 15: permission.Tokens
|
|
(*CancelOneTimeTokenReq)(nil), // 16: permission.CancelOneTimeTokenReq
|
|
nil, // 17: permission.AuthorizationReq.DataEntry
|
|
nil, // 18: permission.ValidationTokenResp.DataEntry
|
|
}
|
|
var file_generate_protobuf_permission_proto_depIdxs = []int32{
|
|
17, // 0: permission.AuthorizationReq.data:type_name -> permission.AuthorizationReq.DataEntry
|
|
13, // 1: permission.ValidationTokenResp.token:type_name -> permission.Token
|
|
18, // 2: permission.ValidationTokenResp.data:type_name -> permission.ValidationTokenResp.DataEntry
|
|
3, // 3: permission.Tokens.token:type_name -> permission.TokenResp
|
|
2, // 4: permission.TokenService.NewToken:input_type -> permission.AuthorizationReq
|
|
6, // 5: permission.TokenService.RefreshToken:input_type -> permission.RefreshTokenReq
|
|
8, // 6: permission.TokenService.CancelToken:input_type -> permission.CancelTokenReq
|
|
11, // 7: permission.TokenService.ValidationToken:input_type -> permission.ValidationTokenReq
|
|
9, // 8: permission.TokenService.CancelTokens:input_type -> permission.DoTokenByUIDReq
|
|
14, // 9: permission.TokenService.CancelTokenByDeviceId:input_type -> permission.DoTokenByDeviceIDReq
|
|
14, // 10: permission.TokenService.GetUserTokensByDeviceId:input_type -> permission.DoTokenByDeviceIDReq
|
|
10, // 11: permission.TokenService.GetUserTokensByUid:input_type -> permission.QueryTokenByUIDReq
|
|
4, // 12: permission.TokenService.NewOneTimeToken:input_type -> permission.CreateOneTimeTokenReq
|
|
16, // 13: permission.TokenService.CancelOneTimeToken:input_type -> permission.CancelOneTimeTokenReq
|
|
3, // 14: permission.TokenService.NewToken:output_type -> permission.TokenResp
|
|
7, // 15: permission.TokenService.RefreshToken:output_type -> permission.RefreshTokenResp
|
|
0, // 16: permission.TokenService.CancelToken:output_type -> permission.OKResp
|
|
12, // 17: permission.TokenService.ValidationToken:output_type -> permission.ValidationTokenResp
|
|
0, // 18: permission.TokenService.CancelTokens:output_type -> permission.OKResp
|
|
0, // 19: permission.TokenService.CancelTokenByDeviceId:output_type -> permission.OKResp
|
|
15, // 20: permission.TokenService.GetUserTokensByDeviceId:output_type -> permission.Tokens
|
|
15, // 21: permission.TokenService.GetUserTokensByUid:output_type -> permission.Tokens
|
|
5, // 22: permission.TokenService.NewOneTimeToken:output_type -> permission.CreateOneTimeTokenResp
|
|
0, // 23: permission.TokenService.CancelOneTimeToken:output_type -> permission.OKResp
|
|
14, // [14:24] is the sub-list for method output_type
|
|
4, // [4:14] is the sub-list for method input_type
|
|
4, // [4:4] is the sub-list for extension type_name
|
|
4, // [4:4] is the sub-list for extension extendee
|
|
0, // [0:4] is the sub-list for field type_name
|
|
}
|
|
|
|
func init() { file_generate_protobuf_permission_proto_init() }
|
|
func file_generate_protobuf_permission_proto_init() {
|
|
if File_generate_protobuf_permission_proto != nil {
|
|
return
|
|
}
|
|
if !protoimpl.UnsafeEnabled {
|
|
file_generate_protobuf_permission_proto_msgTypes[0].Exporter = func(v any, i int) any {
|
|
switch v := v.(*OKResp); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[1].Exporter = func(v any, i int) any {
|
|
switch v := v.(*NoneReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[2].Exporter = func(v any, i int) any {
|
|
switch v := v.(*AuthorizationReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[3].Exporter = func(v any, i int) any {
|
|
switch v := v.(*TokenResp); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[4].Exporter = func(v any, i int) any {
|
|
switch v := v.(*CreateOneTimeTokenReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[5].Exporter = func(v any, i int) any {
|
|
switch v := v.(*CreateOneTimeTokenResp); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[6].Exporter = func(v any, i int) any {
|
|
switch v := v.(*RefreshTokenReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[7].Exporter = func(v any, i int) any {
|
|
switch v := v.(*RefreshTokenResp); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[8].Exporter = func(v any, i int) any {
|
|
switch v := v.(*CancelTokenReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[9].Exporter = func(v any, i int) any {
|
|
switch v := v.(*DoTokenByUIDReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[10].Exporter = func(v any, i int) any {
|
|
switch v := v.(*QueryTokenByUIDReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[11].Exporter = func(v any, i int) any {
|
|
switch v := v.(*ValidationTokenReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[12].Exporter = func(v any, i int) any {
|
|
switch v := v.(*ValidationTokenResp); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[13].Exporter = func(v any, i int) any {
|
|
switch v := v.(*Token); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[14].Exporter = func(v any, i int) any {
|
|
switch v := v.(*DoTokenByDeviceIDReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[15].Exporter = func(v any, i int) any {
|
|
switch v := v.(*Tokens); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
file_generate_protobuf_permission_proto_msgTypes[16].Exporter = func(v any, i int) any {
|
|
switch v := v.(*CancelOneTimeTokenReq); i {
|
|
case 0:
|
|
return &v.state
|
|
case 1:
|
|
return &v.sizeCache
|
|
case 2:
|
|
return &v.unknownFields
|
|
default:
|
|
return nil
|
|
}
|
|
}
|
|
}
|
|
type x struct{}
|
|
out := protoimpl.TypeBuilder{
|
|
File: protoimpl.DescBuilder{
|
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
RawDescriptor: file_generate_protobuf_permission_proto_rawDesc,
|
|
NumEnums: 0,
|
|
NumMessages: 19,
|
|
NumExtensions: 0,
|
|
NumServices: 1,
|
|
},
|
|
GoTypes: file_generate_protobuf_permission_proto_goTypes,
|
|
DependencyIndexes: file_generate_protobuf_permission_proto_depIdxs,
|
|
MessageInfos: file_generate_protobuf_permission_proto_msgTypes,
|
|
}.Build()
|
|
File_generate_protobuf_permission_proto = out.File
|
|
file_generate_protobuf_permission_proto_rawDesc = nil
|
|
file_generate_protobuf_permission_proto_goTypes = nil
|
|
file_generate_protobuf_permission_proto_depIdxs = nil
|
|
}
|