6d443ba042
closes #24
190 lines
6.1 KiB
Go
190 lines
6.1 KiB
Go
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
// source: certificate.proto
|
|
|
|
package legacy_pb
|
|
|
|
import (
|
|
fmt "fmt"
|
|
proto "github.com/golang/protobuf/proto"
|
|
math "math"
|
|
)
|
|
|
|
// Reference imports to suppress errors if they are not otherwise used.
|
|
var _ = proto.Marshal
|
|
var _ = fmt.Errorf
|
|
var _ = math.Inf
|
|
|
|
// This is a compile-time assertion to ensure that this generated file
|
|
// is compatible with the proto package it is being compiled against.
|
|
// A compilation error at this line likely means your copy of the
|
|
// proto package needs to be updated.
|
|
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
|
|
|
|
type KeyType int32
|
|
|
|
const (
|
|
KeyType_UNKNOWN_PUBLIC_KEY_TYPE KeyType = 0
|
|
KeyType_NIST256p KeyType = 1
|
|
KeyType_NIST384p KeyType = 2
|
|
KeyType_SECP256k1 KeyType = 3
|
|
)
|
|
|
|
var KeyType_name = map[int32]string{
|
|
0: "UNKNOWN_PUBLIC_KEY_TYPE",
|
|
1: "NIST256p",
|
|
2: "NIST384p",
|
|
3: "SECP256k1",
|
|
}
|
|
|
|
var KeyType_value = map[string]int32{
|
|
"UNKNOWN_PUBLIC_KEY_TYPE": 0,
|
|
"NIST256p": 1,
|
|
"NIST384p": 2,
|
|
"SECP256k1": 3,
|
|
}
|
|
|
|
func (x KeyType) Enum() *KeyType {
|
|
p := new(KeyType)
|
|
*p = x
|
|
return p
|
|
}
|
|
|
|
func (x KeyType) String() string {
|
|
return proto.EnumName(KeyType_name, int32(x))
|
|
}
|
|
|
|
func (x *KeyType) UnmarshalJSON(data []byte) error {
|
|
value, err := proto.UnmarshalJSONEnum(KeyType_value, data, "KeyType")
|
|
if err != nil {
|
|
return err
|
|
}
|
|
*x = KeyType(value)
|
|
return nil
|
|
}
|
|
|
|
func (KeyType) EnumDescriptor() ([]byte, []int) {
|
|
return fileDescriptor_c0d34c34dd33be4b, []int{0}
|
|
}
|
|
|
|
type Certificate_Version int32
|
|
|
|
const (
|
|
Certificate_UNKNOWN_VERSION Certificate_Version = 0
|
|
Certificate__0_0_1 Certificate_Version = 1
|
|
)
|
|
|
|
var Certificate_Version_name = map[int32]string{
|
|
0: "UNKNOWN_VERSION",
|
|
1: "_0_0_1",
|
|
}
|
|
|
|
var Certificate_Version_value = map[string]int32{
|
|
"UNKNOWN_VERSION": 0,
|
|
"_0_0_1": 1,
|
|
}
|
|
|
|
func (x Certificate_Version) Enum() *Certificate_Version {
|
|
p := new(Certificate_Version)
|
|
*p = x
|
|
return p
|
|
}
|
|
|
|
func (x Certificate_Version) String() string {
|
|
return proto.EnumName(Certificate_Version_name, int32(x))
|
|
}
|
|
|
|
func (x *Certificate_Version) UnmarshalJSON(data []byte) error {
|
|
value, err := proto.UnmarshalJSONEnum(Certificate_Version_value, data, "Certificate_Version")
|
|
if err != nil {
|
|
return err
|
|
}
|
|
*x = Certificate_Version(value)
|
|
return nil
|
|
}
|
|
|
|
func (Certificate_Version) EnumDescriptor() ([]byte, []int) {
|
|
return fileDescriptor_c0d34c34dd33be4b, []int{0, 0}
|
|
}
|
|
|
|
type Certificate struct {
|
|
Version *Certificate_Version `protobuf:"varint,1,req,name=version,enum=legacy_pb.Certificate_Version" json:"version,omitempty"`
|
|
KeyType *KeyType `protobuf:"varint,2,req,name=keyType,enum=legacy_pb.KeyType" json:"keyType,omitempty"`
|
|
PublicKey []byte `protobuf:"bytes,4,req,name=publicKey" json:"publicKey,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *Certificate) Reset() { *m = Certificate{} }
|
|
func (m *Certificate) String() string { return proto.CompactTextString(m) }
|
|
func (*Certificate) ProtoMessage() {}
|
|
func (*Certificate) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_c0d34c34dd33be4b, []int{0}
|
|
}
|
|
|
|
func (m *Certificate) XXX_Unmarshal(b []byte) error {
|
|
return xxx_messageInfo_Certificate.Unmarshal(m, b)
|
|
}
|
|
func (m *Certificate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
return xxx_messageInfo_Certificate.Marshal(b, m, deterministic)
|
|
}
|
|
func (m *Certificate) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_Certificate.Merge(m, src)
|
|
}
|
|
func (m *Certificate) XXX_Size() int {
|
|
return xxx_messageInfo_Certificate.Size(m)
|
|
}
|
|
func (m *Certificate) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_Certificate.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_Certificate proto.InternalMessageInfo
|
|
|
|
func (m *Certificate) GetVersion() Certificate_Version {
|
|
if m != nil && m.Version != nil {
|
|
return *m.Version
|
|
}
|
|
return Certificate_UNKNOWN_VERSION
|
|
}
|
|
|
|
func (m *Certificate) GetKeyType() KeyType {
|
|
if m != nil && m.KeyType != nil {
|
|
return *m.KeyType
|
|
}
|
|
return KeyType_UNKNOWN_PUBLIC_KEY_TYPE
|
|
}
|
|
|
|
func (m *Certificate) GetPublicKey() []byte {
|
|
if m != nil {
|
|
return m.PublicKey
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func init() {
|
|
proto.RegisterEnum("legacy_pb.KeyType", KeyType_name, KeyType_value)
|
|
proto.RegisterEnum("legacy_pb.Certificate_Version", Certificate_Version_name, Certificate_Version_value)
|
|
proto.RegisterType((*Certificate)(nil), "legacy_pb.Certificate")
|
|
}
|
|
|
|
func init() { proto.RegisterFile("certificate.proto", fileDescriptor_c0d34c34dd33be4b) }
|
|
|
|
var fileDescriptor_c0d34c34dd33be4b = []byte{
|
|
// 245 bytes of a gzipped FileDescriptorProto
|
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0x4c, 0x4e, 0x2d, 0x2a,
|
|
0x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x83, 0x10, 0x0f, 0x17, 0x87, 0x9f, 0x67, 0x70, 0x88, 0x91, 0xa9, 0x59, 0x81, 0x00,
|
|
0x23, 0x8c, 0x67, 0x6c, 0x61, 0x52, 0x20, 0xc0, 0x24, 0xc4, 0xcb, 0xc5, 0x19, 0xec, 0xea, 0x1c,
|
|
0x60, 0x64, 0x6a, 0x96, 0x6d, 0x28, 0xc0, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x5a, 0x95, 0x46,
|
|
0xe4, 0x33, 0x01, 0x00, 0x00,
|
|
}
|