decodeGoogleOTP/migrationpayload/migrationpayload.pb.go

419 lines
15 KiB
Go

// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.28.0
// protoc v3.19.1
// source: migrationpayload.proto
package migrationpayload
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)
)
type MigrationPayload_Algorithm int32
const (
MigrationPayload_ALGO_INVALID MigrationPayload_Algorithm = 0
MigrationPayload_ALGO_SHA1 MigrationPayload_Algorithm = 1
)
// Enum value maps for MigrationPayload_Algorithm.
var (
MigrationPayload_Algorithm_name = map[int32]string{
0: "ALGO_INVALID",
1: "ALGO_SHA1",
}
MigrationPayload_Algorithm_value = map[string]int32{
"ALGO_INVALID": 0,
"ALGO_SHA1": 1,
}
)
func (x MigrationPayload_Algorithm) Enum() *MigrationPayload_Algorithm {
p := new(MigrationPayload_Algorithm)
*p = x
return p
}
func (x MigrationPayload_Algorithm) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (MigrationPayload_Algorithm) Descriptor() protoreflect.EnumDescriptor {
return file_migrationpayload_proto_enumTypes[0].Descriptor()
}
func (MigrationPayload_Algorithm) Type() protoreflect.EnumType {
return &file_migrationpayload_proto_enumTypes[0]
}
func (x MigrationPayload_Algorithm) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use MigrationPayload_Algorithm.Descriptor instead.
func (MigrationPayload_Algorithm) EnumDescriptor() ([]byte, []int) {
return file_migrationpayload_proto_rawDescGZIP(), []int{0, 0}
}
type MigrationPayload_OtpType int32
const (
MigrationPayload_OTP_INVALID MigrationPayload_OtpType = 0
MigrationPayload_OTP_HOTP MigrationPayload_OtpType = 1
MigrationPayload_OTP_TOTP MigrationPayload_OtpType = 2
)
// Enum value maps for MigrationPayload_OtpType.
var (
MigrationPayload_OtpType_name = map[int32]string{
0: "OTP_INVALID",
1: "OTP_HOTP",
2: "OTP_TOTP",
}
MigrationPayload_OtpType_value = map[string]int32{
"OTP_INVALID": 0,
"OTP_HOTP": 1,
"OTP_TOTP": 2,
}
)
func (x MigrationPayload_OtpType) Enum() *MigrationPayload_OtpType {
p := new(MigrationPayload_OtpType)
*p = x
return p
}
func (x MigrationPayload_OtpType) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (MigrationPayload_OtpType) Descriptor() protoreflect.EnumDescriptor {
return file_migrationpayload_proto_enumTypes[1].Descriptor()
}
func (MigrationPayload_OtpType) Type() protoreflect.EnumType {
return &file_migrationpayload_proto_enumTypes[1]
}
func (x MigrationPayload_OtpType) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use MigrationPayload_OtpType.Descriptor instead.
func (MigrationPayload_OtpType) EnumDescriptor() ([]byte, []int) {
return file_migrationpayload_proto_rawDescGZIP(), []int{0, 1}
}
type MigrationPayload struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
OtpParameters []*MigrationPayload_OtpParameters `protobuf:"bytes,1,rep,name=otp_parameters,json=otpParameters,proto3" json:"otp_parameters,omitempty"`
Version int32 `protobuf:"varint,2,opt,name=version,proto3" json:"version,omitempty"`
BatchSize int32 `protobuf:"varint,3,opt,name=batch_size,json=batchSize,proto3" json:"batch_size,omitempty"`
BatchIndex int32 `protobuf:"varint,4,opt,name=batch_index,json=batchIndex,proto3" json:"batch_index,omitempty"`
BatchId int32 `protobuf:"varint,5,opt,name=batch_id,json=batchId,proto3" json:"batch_id,omitempty"`
}
func (x *MigrationPayload) Reset() {
*x = MigrationPayload{}
if protoimpl.UnsafeEnabled {
mi := &file_migrationpayload_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *MigrationPayload) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*MigrationPayload) ProtoMessage() {}
func (x *MigrationPayload) ProtoReflect() protoreflect.Message {
mi := &file_migrationpayload_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 MigrationPayload.ProtoReflect.Descriptor instead.
func (*MigrationPayload) Descriptor() ([]byte, []int) {
return file_migrationpayload_proto_rawDescGZIP(), []int{0}
}
func (x *MigrationPayload) GetOtpParameters() []*MigrationPayload_OtpParameters {
if x != nil {
return x.OtpParameters
}
return nil
}
func (x *MigrationPayload) GetVersion() int32 {
if x != nil {
return x.Version
}
return 0
}
func (x *MigrationPayload) GetBatchSize() int32 {
if x != nil {
return x.BatchSize
}
return 0
}
func (x *MigrationPayload) GetBatchIndex() int32 {
if x != nil {
return x.BatchIndex
}
return 0
}
func (x *MigrationPayload) GetBatchId() int32 {
if x != nil {
return x.BatchId
}
return 0
}
type MigrationPayload_OtpParameters struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Secret []byte `protobuf:"bytes,1,opt,name=secret,proto3" json:"secret,omitempty"`
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
Issuer string `protobuf:"bytes,3,opt,name=issuer,proto3" json:"issuer,omitempty"`
Algorithm MigrationPayload_Algorithm `protobuf:"varint,4,opt,name=algorithm,proto3,enum=MigrationPayload_Algorithm" json:"algorithm,omitempty"`
Digits int32 `protobuf:"varint,5,opt,name=digits,proto3" json:"digits,omitempty"`
Type MigrationPayload_OtpType `protobuf:"varint,6,opt,name=type,proto3,enum=MigrationPayload_OtpType" json:"type,omitempty"`
Counter int64 `protobuf:"varint,7,opt,name=counter,proto3" json:"counter,omitempty"`
}
func (x *MigrationPayload_OtpParameters) Reset() {
*x = MigrationPayload_OtpParameters{}
if protoimpl.UnsafeEnabled {
mi := &file_migrationpayload_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *MigrationPayload_OtpParameters) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*MigrationPayload_OtpParameters) ProtoMessage() {}
func (x *MigrationPayload_OtpParameters) ProtoReflect() protoreflect.Message {
mi := &file_migrationpayload_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 MigrationPayload_OtpParameters.ProtoReflect.Descriptor instead.
func (*MigrationPayload_OtpParameters) Descriptor() ([]byte, []int) {
return file_migrationpayload_proto_rawDescGZIP(), []int{0, 0}
}
func (x *MigrationPayload_OtpParameters) GetSecret() []byte {
if x != nil {
return x.Secret
}
return nil
}
func (x *MigrationPayload_OtpParameters) GetName() string {
if x != nil {
return x.Name
}
return ""
}
func (x *MigrationPayload_OtpParameters) GetIssuer() string {
if x != nil {
return x.Issuer
}
return ""
}
func (x *MigrationPayload_OtpParameters) GetAlgorithm() MigrationPayload_Algorithm {
if x != nil {
return x.Algorithm
}
return MigrationPayload_ALGO_INVALID
}
func (x *MigrationPayload_OtpParameters) GetDigits() int32 {
if x != nil {
return x.Digits
}
return 0
}
func (x *MigrationPayload_OtpParameters) GetType() MigrationPayload_OtpType {
if x != nil {
return x.Type
}
return MigrationPayload_OTP_INVALID
}
func (x *MigrationPayload_OtpParameters) GetCounter() int64 {
if x != nil {
return x.Counter
}
return 0
}
var File_migrationpayload_proto protoreflect.FileDescriptor
var file_migrationpayload_proto_rawDesc = []byte{
0x0a, 0x16, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x70, 0x61, 0x79, 0x6c, 0x6f,
0x61, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa7, 0x04, 0x0a, 0x10, 0x4d, 0x69, 0x67,
0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x46, 0x0a,
0x0e, 0x6f, 0x74, 0x70, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18,
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f,
0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x2e, 0x4f, 0x74, 0x70, 0x50, 0x61, 0x72, 0x61,
0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x52, 0x0d, 0x6f, 0x74, 0x70, 0x50, 0x61, 0x72, 0x61, 0x6d,
0x65, 0x74, 0x65, 0x72, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e,
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12,
0x1d, 0x0a, 0x0a, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20,
0x01, 0x28, 0x05, 0x52, 0x09, 0x62, 0x61, 0x74, 0x63, 0x68, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1f,
0x0a, 0x0b, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x04, 0x20,
0x01, 0x28, 0x05, 0x52, 0x0a, 0x62, 0x61, 0x74, 0x63, 0x68, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12,
0x19, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28,
0x05, 0x52, 0x07, 0x62, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x1a, 0xef, 0x01, 0x0a, 0x0d, 0x4f,
0x74, 0x70, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x12, 0x16, 0x0a, 0x06,
0x73, 0x65, 0x63, 0x72, 0x65, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x73, 0x65,
0x63, 0x72, 0x65, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75,
0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x65, 0x72,
0x12, 0x39, 0x0a, 0x09, 0x61, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x18, 0x04, 0x20,
0x01, 0x28, 0x0e, 0x32, 0x1b, 0x2e, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50,
0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x2e, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d,
0x52, 0x09, 0x61, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x12, 0x16, 0x0a, 0x06, 0x64,
0x69, 0x67, 0x69, 0x74, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x64, 0x69, 0x67,
0x69, 0x74, 0x73, 0x12, 0x2d, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28,
0x0e, 0x32, 0x19, 0x2e, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79,
0x6c, 0x6f, 0x61, 0x64, 0x2e, 0x4f, 0x74, 0x70, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79,
0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x07, 0x20,
0x01, 0x28, 0x03, 0x52, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x22, 0x2c, 0x0a, 0x09,
0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x12, 0x10, 0x0a, 0x0c, 0x41, 0x4c, 0x47,
0x4f, 0x5f, 0x49, 0x4e, 0x56, 0x41, 0x4c, 0x49, 0x44, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x41,
0x4c, 0x47, 0x4f, 0x5f, 0x53, 0x48, 0x41, 0x31, 0x10, 0x01, 0x22, 0x36, 0x0a, 0x07, 0x4f, 0x74,
0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x4f, 0x54, 0x50, 0x5f, 0x49, 0x4e, 0x56,
0x41, 0x4c, 0x49, 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x4f, 0x54, 0x50, 0x5f, 0x48, 0x4f,
0x54, 0x50, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x4f, 0x54, 0x50, 0x5f, 0x54, 0x4f, 0x54, 0x50,
0x10, 0x02, 0x42, 0x38, 0x5a, 0x36, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d,
0x2f, 0x6b, 0x75, 0x69, 0x6e, 0x67, 0x73, 0x6d, 0x69, 0x6c, 0x65, 0x2f, 0x64, 0x65, 0x63, 0x6f,
0x64, 0x65, 0x47, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x4f, 0x54, 0x50, 0x2f, 0x6d, 0x69, 0x67, 0x72,
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x62, 0x06, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x33,
}
var (
file_migrationpayload_proto_rawDescOnce sync.Once
file_migrationpayload_proto_rawDescData = file_migrationpayload_proto_rawDesc
)
func file_migrationpayload_proto_rawDescGZIP() []byte {
file_migrationpayload_proto_rawDescOnce.Do(func() {
file_migrationpayload_proto_rawDescData = protoimpl.X.CompressGZIP(file_migrationpayload_proto_rawDescData)
})
return file_migrationpayload_proto_rawDescData
}
var file_migrationpayload_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
var file_migrationpayload_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_migrationpayload_proto_goTypes = []interface{}{
(MigrationPayload_Algorithm)(0), // 0: MigrationPayload.Algorithm
(MigrationPayload_OtpType)(0), // 1: MigrationPayload.OtpType
(*MigrationPayload)(nil), // 2: MigrationPayload
(*MigrationPayload_OtpParameters)(nil), // 3: MigrationPayload.OtpParameters
}
var file_migrationpayload_proto_depIdxs = []int32{
3, // 0: MigrationPayload.otp_parameters:type_name -> MigrationPayload.OtpParameters
0, // 1: MigrationPayload.OtpParameters.algorithm:type_name -> MigrationPayload.Algorithm
1, // 2: MigrationPayload.OtpParameters.type:type_name -> MigrationPayload.OtpType
3, // [3:3] is the sub-list for method output_type
3, // [3:3] is the sub-list for method input_type
3, // [3:3] is the sub-list for extension type_name
3, // [3:3] is the sub-list for extension extendee
0, // [0:3] is the sub-list for field type_name
}
func init() { file_migrationpayload_proto_init() }
func file_migrationpayload_proto_init() {
if File_migrationpayload_proto != nil {
return
}
if !protoimpl.UnsafeEnabled {
file_migrationpayload_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*MigrationPayload); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_migrationpayload_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*MigrationPayload_OtpParameters); 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_migrationpayload_proto_rawDesc,
NumEnums: 2,
NumMessages: 2,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_migrationpayload_proto_goTypes,
DependencyIndexes: file_migrationpayload_proto_depIdxs,
EnumInfos: file_migrationpayload_proto_enumTypes,
MessageInfos: file_migrationpayload_proto_msgTypes,
}.Build()
File_migrationpayload_proto = out.File
file_migrationpayload_proto_rawDesc = nil
file_migrationpayload_proto_goTypes = nil
file_migrationpayload_proto_depIdxs = nil
}