cert.pb.go 9.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.28.0
  4. // protoc v3.20.0
  5. // source: cert.proto
  6. package cert
  7. import (
  8. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  9. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  10. reflect "reflect"
  11. sync "sync"
  12. )
  13. const (
  14. // Verify that this generated code is sufficiently up-to-date.
  15. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  16. // Verify that runtime/protoimpl is sufficiently up-to-date.
  17. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  18. )
  19. type RawNebulaCertificate struct {
  20. state protoimpl.MessageState
  21. sizeCache protoimpl.SizeCache
  22. unknownFields protoimpl.UnknownFields
  23. Details *RawNebulaCertificateDetails `protobuf:"bytes,1,opt,name=Details,proto3" json:"Details,omitempty"`
  24. Signature []byte `protobuf:"bytes,2,opt,name=Signature,proto3" json:"Signature,omitempty"`
  25. }
  26. func (x *RawNebulaCertificate) Reset() {
  27. *x = RawNebulaCertificate{}
  28. if protoimpl.UnsafeEnabled {
  29. mi := &file_cert_proto_msgTypes[0]
  30. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  31. ms.StoreMessageInfo(mi)
  32. }
  33. }
  34. func (x *RawNebulaCertificate) String() string {
  35. return protoimpl.X.MessageStringOf(x)
  36. }
  37. func (*RawNebulaCertificate) ProtoMessage() {}
  38. func (x *RawNebulaCertificate) ProtoReflect() protoreflect.Message {
  39. mi := &file_cert_proto_msgTypes[0]
  40. if protoimpl.UnsafeEnabled && x != nil {
  41. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  42. if ms.LoadMessageInfo() == nil {
  43. ms.StoreMessageInfo(mi)
  44. }
  45. return ms
  46. }
  47. return mi.MessageOf(x)
  48. }
  49. // Deprecated: Use RawNebulaCertificate.ProtoReflect.Descriptor instead.
  50. func (*RawNebulaCertificate) Descriptor() ([]byte, []int) {
  51. return file_cert_proto_rawDescGZIP(), []int{0}
  52. }
  53. func (x *RawNebulaCertificate) GetDetails() *RawNebulaCertificateDetails {
  54. if x != nil {
  55. return x.Details
  56. }
  57. return nil
  58. }
  59. func (x *RawNebulaCertificate) GetSignature() []byte {
  60. if x != nil {
  61. return x.Signature
  62. }
  63. return nil
  64. }
  65. type RawNebulaCertificateDetails struct {
  66. state protoimpl.MessageState
  67. sizeCache protoimpl.SizeCache
  68. unknownFields protoimpl.UnknownFields
  69. Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"`
  70. // Ips and Subnets are in big endian 32 bit pairs, 1st the ip, 2nd the mask
  71. Ips []uint32 `protobuf:"varint,2,rep,packed,name=Ips,proto3" json:"Ips,omitempty"`
  72. Subnets []uint32 `protobuf:"varint,3,rep,packed,name=Subnets,proto3" json:"Subnets,omitempty"`
  73. Groups []string `protobuf:"bytes,4,rep,name=Groups,proto3" json:"Groups,omitempty"`
  74. NotBefore int64 `protobuf:"varint,5,opt,name=NotBefore,proto3" json:"NotBefore,omitempty"`
  75. NotAfter int64 `protobuf:"varint,6,opt,name=NotAfter,proto3" json:"NotAfter,omitempty"`
  76. PublicKey []byte `protobuf:"bytes,7,opt,name=PublicKey,proto3" json:"PublicKey,omitempty"`
  77. IsCA bool `protobuf:"varint,8,opt,name=IsCA,proto3" json:"IsCA,omitempty"`
  78. // sha-256 of the issuer certificate, if this field is blank the cert is self-signed
  79. Issuer []byte `protobuf:"bytes,9,opt,name=Issuer,proto3" json:"Issuer,omitempty"`
  80. }
  81. func (x *RawNebulaCertificateDetails) Reset() {
  82. *x = RawNebulaCertificateDetails{}
  83. if protoimpl.UnsafeEnabled {
  84. mi := &file_cert_proto_msgTypes[1]
  85. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  86. ms.StoreMessageInfo(mi)
  87. }
  88. }
  89. func (x *RawNebulaCertificateDetails) String() string {
  90. return protoimpl.X.MessageStringOf(x)
  91. }
  92. func (*RawNebulaCertificateDetails) ProtoMessage() {}
  93. func (x *RawNebulaCertificateDetails) ProtoReflect() protoreflect.Message {
  94. mi := &file_cert_proto_msgTypes[1]
  95. if protoimpl.UnsafeEnabled && x != nil {
  96. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  97. if ms.LoadMessageInfo() == nil {
  98. ms.StoreMessageInfo(mi)
  99. }
  100. return ms
  101. }
  102. return mi.MessageOf(x)
  103. }
  104. // Deprecated: Use RawNebulaCertificateDetails.ProtoReflect.Descriptor instead.
  105. func (*RawNebulaCertificateDetails) Descriptor() ([]byte, []int) {
  106. return file_cert_proto_rawDescGZIP(), []int{1}
  107. }
  108. func (x *RawNebulaCertificateDetails) GetName() string {
  109. if x != nil {
  110. return x.Name
  111. }
  112. return ""
  113. }
  114. func (x *RawNebulaCertificateDetails) GetIps() []uint32 {
  115. if x != nil {
  116. return x.Ips
  117. }
  118. return nil
  119. }
  120. func (x *RawNebulaCertificateDetails) GetSubnets() []uint32 {
  121. if x != nil {
  122. return x.Subnets
  123. }
  124. return nil
  125. }
  126. func (x *RawNebulaCertificateDetails) GetGroups() []string {
  127. if x != nil {
  128. return x.Groups
  129. }
  130. return nil
  131. }
  132. func (x *RawNebulaCertificateDetails) GetNotBefore() int64 {
  133. if x != nil {
  134. return x.NotBefore
  135. }
  136. return 0
  137. }
  138. func (x *RawNebulaCertificateDetails) GetNotAfter() int64 {
  139. if x != nil {
  140. return x.NotAfter
  141. }
  142. return 0
  143. }
  144. func (x *RawNebulaCertificateDetails) GetPublicKey() []byte {
  145. if x != nil {
  146. return x.PublicKey
  147. }
  148. return nil
  149. }
  150. func (x *RawNebulaCertificateDetails) GetIsCA() bool {
  151. if x != nil {
  152. return x.IsCA
  153. }
  154. return false
  155. }
  156. func (x *RawNebulaCertificateDetails) GetIssuer() []byte {
  157. if x != nil {
  158. return x.Issuer
  159. }
  160. return nil
  161. }
  162. var File_cert_proto protoreflect.FileDescriptor
  163. var file_cert_proto_rawDesc = []byte{
  164. 0x0a, 0x0a, 0x63, 0x65, 0x72, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x04, 0x63, 0x65,
  165. 0x72, 0x74, 0x22, 0x71, 0x0a, 0x14, 0x52, 0x61, 0x77, 0x4e, 0x65, 0x62, 0x75, 0x6c, 0x61, 0x43,
  166. 0x65, 0x72, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x65, 0x12, 0x3b, 0x0a, 0x07, 0x44, 0x65,
  167. 0x74, 0x61, 0x69, 0x6c, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x65,
  168. 0x72, 0x74, 0x2e, 0x52, 0x61, 0x77, 0x4e, 0x65, 0x62, 0x75, 0x6c, 0x61, 0x43, 0x65, 0x72, 0x74,
  169. 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x65, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x52, 0x07,
  170. 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61,
  171. 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e,
  172. 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0xf9, 0x01, 0x0a, 0x1b, 0x52, 0x61, 0x77, 0x4e, 0x65, 0x62,
  173. 0x75, 0x6c, 0x61, 0x43, 0x65, 0x72, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x65, 0x44, 0x65,
  174. 0x74, 0x61, 0x69, 0x6c, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20,
  175. 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x49, 0x70, 0x73,
  176. 0x18, 0x02, 0x20, 0x03, 0x28, 0x0d, 0x52, 0x03, 0x49, 0x70, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x53,
  177. 0x75, 0x62, 0x6e, 0x65, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0d, 0x52, 0x07, 0x53, 0x75,
  178. 0x62, 0x6e, 0x65, 0x74, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x18,
  179. 0x04, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x12, 0x1c, 0x0a,
  180. 0x09, 0x4e, 0x6f, 0x74, 0x42, 0x65, 0x66, 0x6f, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03,
  181. 0x52, 0x09, 0x4e, 0x6f, 0x74, 0x42, 0x65, 0x66, 0x6f, 0x72, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x4e,
  182. 0x6f, 0x74, 0x41, 0x66, 0x74, 0x65, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x4e,
  183. 0x6f, 0x74, 0x41, 0x66, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x50, 0x75, 0x62, 0x6c, 0x69,
  184. 0x63, 0x4b, 0x65, 0x79, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x50, 0x75, 0x62, 0x6c,
  185. 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x49, 0x73, 0x43, 0x41, 0x18, 0x08, 0x20,
  186. 0x01, 0x28, 0x08, 0x52, 0x04, 0x49, 0x73, 0x43, 0x41, 0x12, 0x16, 0x0a, 0x06, 0x49, 0x73, 0x73,
  187. 0x75, 0x65, 0x72, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x49, 0x73, 0x73, 0x75, 0x65,
  188. 0x72, 0x42, 0x20, 0x5a, 0x1e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
  189. 0x73, 0x6c, 0x61, 0x63, 0x6b, 0x68, 0x71, 0x2f, 0x6e, 0x65, 0x62, 0x75, 0x6c, 0x61, 0x2f, 0x63,
  190. 0x65, 0x72, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
  191. }
  192. var (
  193. file_cert_proto_rawDescOnce sync.Once
  194. file_cert_proto_rawDescData = file_cert_proto_rawDesc
  195. )
  196. func file_cert_proto_rawDescGZIP() []byte {
  197. file_cert_proto_rawDescOnce.Do(func() {
  198. file_cert_proto_rawDescData = protoimpl.X.CompressGZIP(file_cert_proto_rawDescData)
  199. })
  200. return file_cert_proto_rawDescData
  201. }
  202. var file_cert_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
  203. var file_cert_proto_goTypes = []interface{}{
  204. (*RawNebulaCertificate)(nil), // 0: cert.RawNebulaCertificate
  205. (*RawNebulaCertificateDetails)(nil), // 1: cert.RawNebulaCertificateDetails
  206. }
  207. var file_cert_proto_depIdxs = []int32{
  208. 1, // 0: cert.RawNebulaCertificate.Details:type_name -> cert.RawNebulaCertificateDetails
  209. 1, // [1:1] is the sub-list for method output_type
  210. 1, // [1:1] is the sub-list for method input_type
  211. 1, // [1:1] is the sub-list for extension type_name
  212. 1, // [1:1] is the sub-list for extension extendee
  213. 0, // [0:1] is the sub-list for field type_name
  214. }
  215. func init() { file_cert_proto_init() }
  216. func file_cert_proto_init() {
  217. if File_cert_proto != nil {
  218. return
  219. }
  220. if !protoimpl.UnsafeEnabled {
  221. file_cert_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  222. switch v := v.(*RawNebulaCertificate); i {
  223. case 0:
  224. return &v.state
  225. case 1:
  226. return &v.sizeCache
  227. case 2:
  228. return &v.unknownFields
  229. default:
  230. return nil
  231. }
  232. }
  233. file_cert_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
  234. switch v := v.(*RawNebulaCertificateDetails); i {
  235. case 0:
  236. return &v.state
  237. case 1:
  238. return &v.sizeCache
  239. case 2:
  240. return &v.unknownFields
  241. default:
  242. return nil
  243. }
  244. }
  245. }
  246. type x struct{}
  247. out := protoimpl.TypeBuilder{
  248. File: protoimpl.DescBuilder{
  249. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  250. RawDescriptor: file_cert_proto_rawDesc,
  251. NumEnums: 0,
  252. NumMessages: 2,
  253. NumExtensions: 0,
  254. NumServices: 0,
  255. },
  256. GoTypes: file_cert_proto_goTypes,
  257. DependencyIndexes: file_cert_proto_depIdxs,
  258. MessageInfos: file_cert_proto_msgTypes,
  259. }.Build()
  260. File_cert_proto = out.File
  261. file_cert_proto_rawDesc = nil
  262. file_cert_proto_goTypes = nil
  263. file_cert_proto_depIdxs = nil
  264. }