forked from 33cn/plugin
-
Notifications
You must be signed in to change notification settings - Fork 1
/
cert.pb.go
502 lines (441 loc) · 14.9 KB
/
cert.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: cert.proto
package types
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
)
// 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.ProtoPackageIsVersion2 // please upgrade the proto package
type Cert struct {
CertId []byte `protobuf:"bytes,1,opt,name=certId,proto3" json:"certId,omitempty"`
CreateTime int64 `protobuf:"varint,2,opt,name=createTime,proto3" json:"createTime,omitempty"`
Key string `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"`
Value []byte `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Cert) Reset() { *m = Cert{} }
func (m *Cert) String() string { return proto.CompactTextString(m) }
func (*Cert) ProtoMessage() {}
func (*Cert) Descriptor() ([]byte, []int) {
return fileDescriptor_a142e29cbef9b1cf, []int{0}
}
func (m *Cert) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Cert.Unmarshal(m, b)
}
func (m *Cert) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Cert.Marshal(b, m, deterministic)
}
func (m *Cert) XXX_Merge(src proto.Message) {
xxx_messageInfo_Cert.Merge(m, src)
}
func (m *Cert) XXX_Size() int {
return xxx_messageInfo_Cert.Size(m)
}
func (m *Cert) XXX_DiscardUnknown() {
xxx_messageInfo_Cert.DiscardUnknown(m)
}
var xxx_messageInfo_Cert proto.InternalMessageInfo
func (m *Cert) GetCertId() []byte {
if m != nil {
return m.CertId
}
return nil
}
func (m *Cert) GetCreateTime() int64 {
if m != nil {
return m.CreateTime
}
return 0
}
func (m *Cert) GetKey() string {
if m != nil {
return m.Key
}
return ""
}
func (m *Cert) GetValue() []byte {
if m != nil {
return m.Value
}
return nil
}
type CertAction struct {
// Types that are valid to be assigned to Value:
// *CertAction_New
// *CertAction_Update
// *CertAction_Normal
Value isCertAction_Value `protobuf_oneof:"value"`
Ty int32 `protobuf:"varint,4,opt,name=ty,proto3" json:"ty,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CertAction) Reset() { *m = CertAction{} }
func (m *CertAction) String() string { return proto.CompactTextString(m) }
func (*CertAction) ProtoMessage() {}
func (*CertAction) Descriptor() ([]byte, []int) {
return fileDescriptor_a142e29cbef9b1cf, []int{1}
}
func (m *CertAction) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CertAction.Unmarshal(m, b)
}
func (m *CertAction) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CertAction.Marshal(b, m, deterministic)
}
func (m *CertAction) XXX_Merge(src proto.Message) {
xxx_messageInfo_CertAction.Merge(m, src)
}
func (m *CertAction) XXX_Size() int {
return xxx_messageInfo_CertAction.Size(m)
}
func (m *CertAction) XXX_DiscardUnknown() {
xxx_messageInfo_CertAction.DiscardUnknown(m)
}
var xxx_messageInfo_CertAction proto.InternalMessageInfo
type isCertAction_Value interface {
isCertAction_Value()
}
type CertAction_New struct {
New *CertNew `protobuf:"bytes,1,opt,name=new,proto3,oneof"`
}
type CertAction_Update struct {
Update *CertUpdate `protobuf:"bytes,2,opt,name=update,proto3,oneof"`
}
type CertAction_Normal struct {
Normal *CertNormal `protobuf:"bytes,3,opt,name=normal,proto3,oneof"`
}
func (*CertAction_New) isCertAction_Value() {}
func (*CertAction_Update) isCertAction_Value() {}
func (*CertAction_Normal) isCertAction_Value() {}
func (m *CertAction) GetValue() isCertAction_Value {
if m != nil {
return m.Value
}
return nil
}
func (m *CertAction) GetNew() *CertNew {
if x, ok := m.GetValue().(*CertAction_New); ok {
return x.New
}
return nil
}
func (m *CertAction) GetUpdate() *CertUpdate {
if x, ok := m.GetValue().(*CertAction_Update); ok {
return x.Update
}
return nil
}
func (m *CertAction) GetNormal() *CertNormal {
if x, ok := m.GetValue().(*CertAction_Normal); ok {
return x.Normal
}
return nil
}
func (m *CertAction) GetTy() int32 {
if m != nil {
return m.Ty
}
return 0
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*CertAction) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _CertAction_OneofMarshaler, _CertAction_OneofUnmarshaler, _CertAction_OneofSizer, []interface{}{
(*CertAction_New)(nil),
(*CertAction_Update)(nil),
(*CertAction_Normal)(nil),
}
}
func _CertAction_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*CertAction)
// value
switch x := m.Value.(type) {
case *CertAction_New:
b.EncodeVarint(1<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.New); err != nil {
return err
}
case *CertAction_Update:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Update); err != nil {
return err
}
case *CertAction_Normal:
b.EncodeVarint(3<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Normal); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("CertAction.Value has unexpected type %T", x)
}
return nil
}
func _CertAction_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*CertAction)
switch tag {
case 1: // value.new
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(CertNew)
err := b.DecodeMessage(msg)
m.Value = &CertAction_New{msg}
return true, err
case 2: // value.update
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(CertUpdate)
err := b.DecodeMessage(msg)
m.Value = &CertAction_Update{msg}
return true, err
case 3: // value.normal
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(CertNormal)
err := b.DecodeMessage(msg)
m.Value = &CertAction_Normal{msg}
return true, err
default:
return false, nil
}
}
func _CertAction_OneofSizer(msg proto.Message) (n int) {
m := msg.(*CertAction)
// value
switch x := m.Value.(type) {
case *CertAction_New:
s := proto.Size(x.New)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *CertAction_Update:
s := proto.Size(x.Update)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *CertAction_Normal:
s := proto.Size(x.Normal)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
type CertNew struct {
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CertNew) Reset() { *m = CertNew{} }
func (m *CertNew) String() string { return proto.CompactTextString(m) }
func (*CertNew) ProtoMessage() {}
func (*CertNew) Descriptor() ([]byte, []int) {
return fileDescriptor_a142e29cbef9b1cf, []int{2}
}
func (m *CertNew) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CertNew.Unmarshal(m, b)
}
func (m *CertNew) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CertNew.Marshal(b, m, deterministic)
}
func (m *CertNew) XXX_Merge(src proto.Message) {
xxx_messageInfo_CertNew.Merge(m, src)
}
func (m *CertNew) XXX_Size() int {
return xxx_messageInfo_CertNew.Size(m)
}
func (m *CertNew) XXX_DiscardUnknown() {
xxx_messageInfo_CertNew.DiscardUnknown(m)
}
var xxx_messageInfo_CertNew proto.InternalMessageInfo
func (m *CertNew) GetKey() string {
if m != nil {
return m.Key
}
return ""
}
func (m *CertNew) GetValue() []byte {
if m != nil {
return m.Value
}
return nil
}
type CertUpdate struct {
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CertUpdate) Reset() { *m = CertUpdate{} }
func (m *CertUpdate) String() string { return proto.CompactTextString(m) }
func (*CertUpdate) ProtoMessage() {}
func (*CertUpdate) Descriptor() ([]byte, []int) {
return fileDescriptor_a142e29cbef9b1cf, []int{3}
}
func (m *CertUpdate) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CertUpdate.Unmarshal(m, b)
}
func (m *CertUpdate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CertUpdate.Marshal(b, m, deterministic)
}
func (m *CertUpdate) XXX_Merge(src proto.Message) {
xxx_messageInfo_CertUpdate.Merge(m, src)
}
func (m *CertUpdate) XXX_Size() int {
return xxx_messageInfo_CertUpdate.Size(m)
}
func (m *CertUpdate) XXX_DiscardUnknown() {
xxx_messageInfo_CertUpdate.DiscardUnknown(m)
}
var xxx_messageInfo_CertUpdate proto.InternalMessageInfo
func (m *CertUpdate) GetKey() string {
if m != nil {
return m.Key
}
return ""
}
func (m *CertUpdate) GetValue() []byte {
if m != nil {
return m.Value
}
return nil
}
type CertNormal struct {
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CertNormal) Reset() { *m = CertNormal{} }
func (m *CertNormal) String() string { return proto.CompactTextString(m) }
func (*CertNormal) ProtoMessage() {}
func (*CertNormal) Descriptor() ([]byte, []int) {
return fileDescriptor_a142e29cbef9b1cf, []int{4}
}
func (m *CertNormal) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CertNormal.Unmarshal(m, b)
}
func (m *CertNormal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CertNormal.Marshal(b, m, deterministic)
}
func (m *CertNormal) XXX_Merge(src proto.Message) {
xxx_messageInfo_CertNormal.Merge(m, src)
}
func (m *CertNormal) XXX_Size() int {
return xxx_messageInfo_CertNormal.Size(m)
}
func (m *CertNormal) XXX_DiscardUnknown() {
xxx_messageInfo_CertNormal.DiscardUnknown(m)
}
var xxx_messageInfo_CertNormal proto.InternalMessageInfo
func (m *CertNormal) GetKey() string {
if m != nil {
return m.Key
}
return ""
}
func (m *CertNormal) GetValue() []byte {
if m != nil {
return m.Value
}
return nil
}
type Authority struct {
Enable bool `protobuf:"varint,1,opt,name=enable,proto3" json:"enable,omitempty"`
CryptoPath string `protobuf:"bytes,2,opt,name=cryptoPath,proto3" json:"cryptoPath,omitempty"`
SignType string `protobuf:"bytes,3,opt,name=signType,proto3" json:"signType,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Authority) Reset() { *m = Authority{} }
func (m *Authority) String() string { return proto.CompactTextString(m) }
func (*Authority) ProtoMessage() {}
func (*Authority) Descriptor() ([]byte, []int) {
return fileDescriptor_a142e29cbef9b1cf, []int{5}
}
func (m *Authority) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Authority.Unmarshal(m, b)
}
func (m *Authority) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Authority.Marshal(b, m, deterministic)
}
func (m *Authority) XXX_Merge(src proto.Message) {
xxx_messageInfo_Authority.Merge(m, src)
}
func (m *Authority) XXX_Size() int {
return xxx_messageInfo_Authority.Size(m)
}
func (m *Authority) XXX_DiscardUnknown() {
xxx_messageInfo_Authority.DiscardUnknown(m)
}
var xxx_messageInfo_Authority proto.InternalMessageInfo
func (m *Authority) GetEnable() bool {
if m != nil {
return m.Enable
}
return false
}
func (m *Authority) GetCryptoPath() string {
if m != nil {
return m.CryptoPath
}
return ""
}
func (m *Authority) GetSignType() string {
if m != nil {
return m.SignType
}
return ""
}
func init() {
proto.RegisterType((*Cert)(nil), "types.Cert")
proto.RegisterType((*CertAction)(nil), "types.CertAction")
proto.RegisterType((*CertNew)(nil), "types.CertNew")
proto.RegisterType((*CertUpdate)(nil), "types.CertUpdate")
proto.RegisterType((*CertNormal)(nil), "types.CertNormal")
proto.RegisterType((*Authority)(nil), "types.Authority")
}
func init() { proto.RegisterFile("cert.proto", fileDescriptor_a142e29cbef9b1cf) }
var fileDescriptor_a142e29cbef9b1cf = []byte{
// 300 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x52, 0xcd, 0x4a, 0xf3, 0x40,
0x14, 0xed, 0x24, 0xfd, 0xbd, 0xfd, 0x28, 0x9f, 0x83, 0x48, 0x70, 0x21, 0x25, 0xab, 0x82, 0x10,
0xb0, 0xfa, 0x02, 0xd5, 0x4d, 0xdd, 0x14, 0x19, 0xea, 0x5a, 0xa6, 0xe9, 0xd5, 0x06, 0xd3, 0x4c,
0x98, 0xde, 0x58, 0xe6, 0x79, 0x7c, 0x51, 0x99, 0x1f, 0x25, 0x82, 0x0b, 0xdd, 0xe5, 0xdc, 0x73,
0x4e, 0xee, 0x39, 0xdc, 0x01, 0xc8, 0x51, 0x53, 0x56, 0x6b, 0x45, 0x8a, 0xf7, 0xc8, 0xd4, 0x78,
0x48, 0x9f, 0xa1, 0x7b, 0x87, 0x9a, 0xf8, 0x19, 0xf4, 0x2d, 0x79, 0xbf, 0x4d, 0xd8, 0x94, 0xcd,
0xfe, 0x89, 0x80, 0xf8, 0x05, 0x40, 0xae, 0x51, 0x12, 0xae, 0x8b, 0x3d, 0x26, 0xd1, 0x94, 0xcd,
0x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