headers.pb.go 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.35.1
  4. // protoc v5.28.2
  5. // source: common/protocol/headers.proto
  6. package protocol
  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 SecurityType int32
  20. const (
  21. SecurityType_UNKNOWN SecurityType = 0
  22. SecurityType_AUTO SecurityType = 2
  23. SecurityType_AES128_GCM SecurityType = 3
  24. SecurityType_CHACHA20_POLY1305 SecurityType = 4
  25. SecurityType_NONE SecurityType = 5 // [DEPRECATED 2023-06]
  26. SecurityType_ZERO SecurityType = 6
  27. )
  28. // Enum value maps for SecurityType.
  29. var (
  30. SecurityType_name = map[int32]string{
  31. 0: "UNKNOWN",
  32. 2: "AUTO",
  33. 3: "AES128_GCM",
  34. 4: "CHACHA20_POLY1305",
  35. 5: "NONE",
  36. 6: "ZERO",
  37. }
  38. SecurityType_value = map[string]int32{
  39. "UNKNOWN": 0,
  40. "AUTO": 2,
  41. "AES128_GCM": 3,
  42. "CHACHA20_POLY1305": 4,
  43. "NONE": 5,
  44. "ZERO": 6,
  45. }
  46. )
  47. func (x SecurityType) Enum() *SecurityType {
  48. p := new(SecurityType)
  49. *p = x
  50. return p
  51. }
  52. func (x SecurityType) String() string {
  53. return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
  54. }
  55. func (SecurityType) Descriptor() protoreflect.EnumDescriptor {
  56. return file_common_protocol_headers_proto_enumTypes[0].Descriptor()
  57. }
  58. func (SecurityType) Type() protoreflect.EnumType {
  59. return &file_common_protocol_headers_proto_enumTypes[0]
  60. }
  61. func (x SecurityType) Number() protoreflect.EnumNumber {
  62. return protoreflect.EnumNumber(x)
  63. }
  64. // Deprecated: Use SecurityType.Descriptor instead.
  65. func (SecurityType) EnumDescriptor() ([]byte, []int) {
  66. return file_common_protocol_headers_proto_rawDescGZIP(), []int{0}
  67. }
  68. type SecurityConfig struct {
  69. state protoimpl.MessageState
  70. sizeCache protoimpl.SizeCache
  71. unknownFields protoimpl.UnknownFields
  72. Type SecurityType `protobuf:"varint,1,opt,name=type,proto3,enum=xray.common.protocol.SecurityType" json:"type,omitempty"`
  73. }
  74. func (x *SecurityConfig) Reset() {
  75. *x = SecurityConfig{}
  76. mi := &file_common_protocol_headers_proto_msgTypes[0]
  77. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  78. ms.StoreMessageInfo(mi)
  79. }
  80. func (x *SecurityConfig) String() string {
  81. return protoimpl.X.MessageStringOf(x)
  82. }
  83. func (*SecurityConfig) ProtoMessage() {}
  84. func (x *SecurityConfig) ProtoReflect() protoreflect.Message {
  85. mi := &file_common_protocol_headers_proto_msgTypes[0]
  86. if x != nil {
  87. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  88. if ms.LoadMessageInfo() == nil {
  89. ms.StoreMessageInfo(mi)
  90. }
  91. return ms
  92. }
  93. return mi.MessageOf(x)
  94. }
  95. // Deprecated: Use SecurityConfig.ProtoReflect.Descriptor instead.
  96. func (*SecurityConfig) Descriptor() ([]byte, []int) {
  97. return file_common_protocol_headers_proto_rawDescGZIP(), []int{0}
  98. }
  99. func (x *SecurityConfig) GetType() SecurityType {
  100. if x != nil {
  101. return x.Type
  102. }
  103. return SecurityType_UNKNOWN
  104. }
  105. var File_common_protocol_headers_proto protoreflect.FileDescriptor
  106. var file_common_protocol_headers_proto_rawDesc = []byte{
  107. 0x0a, 0x1d, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f,
  108. 0x6c, 0x2f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12,
  109. 0x14, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f,
  110. 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x22, 0x48, 0x0a, 0x0e, 0x53, 0x65, 0x63, 0x75, 0x72, 0x69, 0x74,
  111. 0x79, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x36, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18,
  112. 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x22, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d,
  113. 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2e, 0x53, 0x65, 0x63,
  114. 0x75, 0x72, 0x69, 0x74, 0x79, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x2a,
  115. 0x60, 0x0a, 0x0c, 0x53, 0x65, 0x63, 0x75, 0x72, 0x69, 0x74, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12,
  116. 0x0b, 0x0a, 0x07, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04,
  117. 0x41, 0x55, 0x54, 0x4f, 0x10, 0x02, 0x12, 0x0e, 0x0a, 0x0a, 0x41, 0x45, 0x53, 0x31, 0x32, 0x38,
  118. 0x5f, 0x47, 0x43, 0x4d, 0x10, 0x03, 0x12, 0x15, 0x0a, 0x11, 0x43, 0x48, 0x41, 0x43, 0x48, 0x41,
  119. 0x32, 0x30, 0x5f, 0x50, 0x4f, 0x4c, 0x59, 0x31, 0x33, 0x30, 0x35, 0x10, 0x04, 0x12, 0x08, 0x0a,
  120. 0x04, 0x4e, 0x4f, 0x4e, 0x45, 0x10, 0x05, 0x12, 0x08, 0x0a, 0x04, 0x5a, 0x45, 0x52, 0x4f, 0x10,
  121. 0x06, 0x42, 0x5e, 0x0a, 0x18, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f,
  122. 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x50, 0x01, 0x5a,
  123. 0x29, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x74, 0x6c, 0x73,
  124. 0x2f, 0x78, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
  125. 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0xaa, 0x02, 0x14, 0x58, 0x72, 0x61,
  126. 0x79, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f,
  127. 0x6c, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
  128. }
  129. var (
  130. file_common_protocol_headers_proto_rawDescOnce sync.Once
  131. file_common_protocol_headers_proto_rawDescData = file_common_protocol_headers_proto_rawDesc
  132. )
  133. func file_common_protocol_headers_proto_rawDescGZIP() []byte {
  134. file_common_protocol_headers_proto_rawDescOnce.Do(func() {
  135. file_common_protocol_headers_proto_rawDescData = protoimpl.X.CompressGZIP(file_common_protocol_headers_proto_rawDescData)
  136. })
  137. return file_common_protocol_headers_proto_rawDescData
  138. }
  139. var file_common_protocol_headers_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
  140. var file_common_protocol_headers_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
  141. var file_common_protocol_headers_proto_goTypes = []any{
  142. (SecurityType)(0), // 0: xray.common.protocol.SecurityType
  143. (*SecurityConfig)(nil), // 1: xray.common.protocol.SecurityConfig
  144. }
  145. var file_common_protocol_headers_proto_depIdxs = []int32{
  146. 0, // 0: xray.common.protocol.SecurityConfig.type:type_name -> xray.common.protocol.SecurityType
  147. 1, // [1:1] is the sub-list for method output_type
  148. 1, // [1:1] is the sub-list for method input_type
  149. 1, // [1:1] is the sub-list for extension type_name
  150. 1, // [1:1] is the sub-list for extension extendee
  151. 0, // [0:1] is the sub-list for field type_name
  152. }
  153. func init() { file_common_protocol_headers_proto_init() }
  154. func file_common_protocol_headers_proto_init() {
  155. if File_common_protocol_headers_proto != nil {
  156. return
  157. }
  158. type x struct{}
  159. out := protoimpl.TypeBuilder{
  160. File: protoimpl.DescBuilder{
  161. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  162. RawDescriptor: file_common_protocol_headers_proto_rawDesc,
  163. NumEnums: 1,
  164. NumMessages: 1,
  165. NumExtensions: 0,
  166. NumServices: 0,
  167. },
  168. GoTypes: file_common_protocol_headers_proto_goTypes,
  169. DependencyIndexes: file_common_protocol_headers_proto_depIdxs,
  170. EnumInfos: file_common_protocol_headers_proto_enumTypes,
  171. MessageInfos: file_common_protocol_headers_proto_msgTypes,
  172. }.Build()
  173. File_common_protocol_headers_proto = out.File
  174. file_common_protocol_headers_proto_rawDesc = nil
  175. file_common_protocol_headers_proto_goTypes = nil
  176. file_common_protocol_headers_proto_depIdxs = nil
  177. }