config.pb.go 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.28.1
  4. // protoc v3.21.12
  5. // source: proxy/freedom/config.proto
  6. package freedom
  7. import (
  8. protocol "github.com/xtls/xray-core/common/protocol"
  9. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  10. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  11. reflect "reflect"
  12. sync "sync"
  13. )
  14. const (
  15. // Verify that this generated code is sufficiently up-to-date.
  16. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  17. // Verify that runtime/protoimpl is sufficiently up-to-date.
  18. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  19. )
  20. type Config_DomainStrategy int32
  21. const (
  22. Config_AS_IS Config_DomainStrategy = 0
  23. Config_USE_IP Config_DomainStrategy = 1
  24. Config_USE_IP4 Config_DomainStrategy = 2
  25. Config_USE_IP6 Config_DomainStrategy = 3
  26. )
  27. // Enum value maps for Config_DomainStrategy.
  28. var (
  29. Config_DomainStrategy_name = map[int32]string{
  30. 0: "AS_IS",
  31. 1: "USE_IP",
  32. 2: "USE_IP4",
  33. 3: "USE_IP6",
  34. }
  35. Config_DomainStrategy_value = map[string]int32{
  36. "AS_IS": 0,
  37. "USE_IP": 1,
  38. "USE_IP4": 2,
  39. "USE_IP6": 3,
  40. }
  41. )
  42. func (x Config_DomainStrategy) Enum() *Config_DomainStrategy {
  43. p := new(Config_DomainStrategy)
  44. *p = x
  45. return p
  46. }
  47. func (x Config_DomainStrategy) String() string {
  48. return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
  49. }
  50. func (Config_DomainStrategy) Descriptor() protoreflect.EnumDescriptor {
  51. return file_proxy_freedom_config_proto_enumTypes[0].Descriptor()
  52. }
  53. func (Config_DomainStrategy) Type() protoreflect.EnumType {
  54. return &file_proxy_freedom_config_proto_enumTypes[0]
  55. }
  56. func (x Config_DomainStrategy) Number() protoreflect.EnumNumber {
  57. return protoreflect.EnumNumber(x)
  58. }
  59. // Deprecated: Use Config_DomainStrategy.Descriptor instead.
  60. func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int) {
  61. return file_proxy_freedom_config_proto_rawDescGZIP(), []int{1, 0}
  62. }
  63. type DestinationOverride struct {
  64. state protoimpl.MessageState
  65. sizeCache protoimpl.SizeCache
  66. unknownFields protoimpl.UnknownFields
  67. Server *protocol.ServerEndpoint `protobuf:"bytes,1,opt,name=server,proto3" json:"server,omitempty"`
  68. }
  69. func (x *DestinationOverride) Reset() {
  70. *x = DestinationOverride{}
  71. if protoimpl.UnsafeEnabled {
  72. mi := &file_proxy_freedom_config_proto_msgTypes[0]
  73. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  74. ms.StoreMessageInfo(mi)
  75. }
  76. }
  77. func (x *DestinationOverride) String() string {
  78. return protoimpl.X.MessageStringOf(x)
  79. }
  80. func (*DestinationOverride) ProtoMessage() {}
  81. func (x *DestinationOverride) ProtoReflect() protoreflect.Message {
  82. mi := &file_proxy_freedom_config_proto_msgTypes[0]
  83. if protoimpl.UnsafeEnabled && x != nil {
  84. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  85. if ms.LoadMessageInfo() == nil {
  86. ms.StoreMessageInfo(mi)
  87. }
  88. return ms
  89. }
  90. return mi.MessageOf(x)
  91. }
  92. // Deprecated: Use DestinationOverride.ProtoReflect.Descriptor instead.
  93. func (*DestinationOverride) Descriptor() ([]byte, []int) {
  94. return file_proxy_freedom_config_proto_rawDescGZIP(), []int{0}
  95. }
  96. func (x *DestinationOverride) GetServer() *protocol.ServerEndpoint {
  97. if x != nil {
  98. return x.Server
  99. }
  100. return nil
  101. }
  102. type Config struct {
  103. state protoimpl.MessageState
  104. sizeCache protoimpl.SizeCache
  105. unknownFields protoimpl.UnknownFields
  106. DomainStrategy Config_DomainStrategy `protobuf:"varint,1,opt,name=domain_strategy,json=domainStrategy,proto3,enum=xray.proxy.freedom.Config_DomainStrategy" json:"domain_strategy,omitempty"`
  107. // Deprecated: Do not use.
  108. Timeout uint32 `protobuf:"varint,2,opt,name=timeout,proto3" json:"timeout,omitempty"`
  109. DestinationOverride *DestinationOverride `protobuf:"bytes,3,opt,name=destination_override,json=destinationOverride,proto3" json:"destination_override,omitempty"`
  110. UserLevel uint32 `protobuf:"varint,4,opt,name=user_level,json=userLevel,proto3" json:"user_level,omitempty"`
  111. }
  112. func (x *Config) Reset() {
  113. *x = Config{}
  114. if protoimpl.UnsafeEnabled {
  115. mi := &file_proxy_freedom_config_proto_msgTypes[1]
  116. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  117. ms.StoreMessageInfo(mi)
  118. }
  119. }
  120. func (x *Config) String() string {
  121. return protoimpl.X.MessageStringOf(x)
  122. }
  123. func (*Config) ProtoMessage() {}
  124. func (x *Config) ProtoReflect() protoreflect.Message {
  125. mi := &file_proxy_freedom_config_proto_msgTypes[1]
  126. if protoimpl.UnsafeEnabled && x != nil {
  127. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  128. if ms.LoadMessageInfo() == nil {
  129. ms.StoreMessageInfo(mi)
  130. }
  131. return ms
  132. }
  133. return mi.MessageOf(x)
  134. }
  135. // Deprecated: Use Config.ProtoReflect.Descriptor instead.
  136. func (*Config) Descriptor() ([]byte, []int) {
  137. return file_proxy_freedom_config_proto_rawDescGZIP(), []int{1}
  138. }
  139. func (x *Config) GetDomainStrategy() Config_DomainStrategy {
  140. if x != nil {
  141. return x.DomainStrategy
  142. }
  143. return Config_AS_IS
  144. }
  145. // Deprecated: Do not use.
  146. func (x *Config) GetTimeout() uint32 {
  147. if x != nil {
  148. return x.Timeout
  149. }
  150. return 0
  151. }
  152. func (x *Config) GetDestinationOverride() *DestinationOverride {
  153. if x != nil {
  154. return x.DestinationOverride
  155. }
  156. return nil
  157. }
  158. func (x *Config) GetUserLevel() uint32 {
  159. if x != nil {
  160. return x.UserLevel
  161. }
  162. return 0
  163. }
  164. var File_proxy_freedom_config_proto protoreflect.FileDescriptor
  165. var file_proxy_freedom_config_proto_rawDesc = []byte{
  166. 0x0a, 0x1a, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2f, 0x66, 0x72, 0x65, 0x65, 0x64, 0x6f, 0x6d, 0x2f,
  167. 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x78, 0x72,
  168. 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x66, 0x72, 0x65, 0x65, 0x64, 0x6f, 0x6d,
  169. 0x1a, 0x21, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f,
  170. 0x6c, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, 0x73, 0x70, 0x65, 0x63, 0x2e, 0x70, 0x72,
  171. 0x6f, 0x74, 0x6f, 0x22, 0x53, 0x0a, 0x13, 0x44, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69,
  172. 0x6f, 0x6e, 0x4f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x12, 0x3c, 0x0a, 0x06, 0x73, 0x65,
  173. 0x72, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x78, 0x72, 0x61,
  174. 0x79, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f,
  175. 0x6c, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x45, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74,
  176. 0x52, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x22, 0xb8, 0x02, 0x0a, 0x06, 0x43, 0x6f, 0x6e,
  177. 0x66, 0x69, 0x67, 0x12, 0x52, 0x0a, 0x0f, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x73, 0x74,
  178. 0x72, 0x61, 0x74, 0x65, 0x67, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x78,
  179. 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x66, 0x72, 0x65, 0x65, 0x64, 0x6f,
  180. 0x6d, 0x2e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x53,
  181. 0x74, 0x72, 0x61, 0x74, 0x65, 0x67, 0x79, 0x52, 0x0e, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x53,
  182. 0x74, 0x72, 0x61, 0x74, 0x65, 0x67, 0x79, 0x12, 0x1c, 0x0a, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f,
  183. 0x75, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x42, 0x02, 0x18, 0x01, 0x52, 0x07, 0x74, 0x69,
  184. 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x12, 0x5a, 0x0a, 0x14, 0x64, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61,
  185. 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x18, 0x03, 0x20,
  186. 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79,
  187. 0x2e, 0x66, 0x72, 0x65, 0x65, 0x64, 0x6f, 0x6d, 0x2e, 0x44, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61,
  188. 0x74, 0x69, 0x6f, 0x6e, 0x4f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x52, 0x13, 0x64, 0x65,
  189. 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64,
  190. 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18,
  191. 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x75, 0x73, 0x65, 0x72, 0x4c, 0x65, 0x76, 0x65, 0x6c,
  192. 0x22, 0x41, 0x0a, 0x0e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x53, 0x74, 0x72, 0x61, 0x74, 0x65,
  193. 0x67, 0x79, 0x12, 0x09, 0x0a, 0x05, 0x41, 0x53, 0x5f, 0x49, 0x53, 0x10, 0x00, 0x12, 0x0a, 0x0a,
  194. 0x06, 0x55, 0x53, 0x45, 0x5f, 0x49, 0x50, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x55, 0x53, 0x45,
  195. 0x5f, 0x49, 0x50, 0x34, 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x55, 0x53, 0x45, 0x5f, 0x49, 0x50,
  196. 0x36, 0x10, 0x03, 0x42, 0x58, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e,
  197. 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x66, 0x72, 0x65, 0x65, 0x64, 0x6f, 0x6d, 0x50, 0x01, 0x5a,
  198. 0x27, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x74, 0x6c, 0x73,
  199. 0x2f, 0x78, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x78, 0x79,
  200. 0x2f, 0x66, 0x72, 0x65, 0x65, 0x64, 0x6f, 0x6d, 0xaa, 0x02, 0x12, 0x58, 0x72, 0x61, 0x79, 0x2e,
  201. 0x50, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x46, 0x72, 0x65, 0x65, 0x64, 0x6f, 0x6d, 0x62, 0x06, 0x70,
  202. 0x72, 0x6f, 0x74, 0x6f, 0x33,
  203. }
  204. var (
  205. file_proxy_freedom_config_proto_rawDescOnce sync.Once
  206. file_proxy_freedom_config_proto_rawDescData = file_proxy_freedom_config_proto_rawDesc
  207. )
  208. func file_proxy_freedom_config_proto_rawDescGZIP() []byte {
  209. file_proxy_freedom_config_proto_rawDescOnce.Do(func() {
  210. file_proxy_freedom_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_proxy_freedom_config_proto_rawDescData)
  211. })
  212. return file_proxy_freedom_config_proto_rawDescData
  213. }
  214. var file_proxy_freedom_config_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
  215. var file_proxy_freedom_config_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
  216. var file_proxy_freedom_config_proto_goTypes = []interface{}{
  217. (Config_DomainStrategy)(0), // 0: xray.proxy.freedom.Config.DomainStrategy
  218. (*DestinationOverride)(nil), // 1: xray.proxy.freedom.DestinationOverride
  219. (*Config)(nil), // 2: xray.proxy.freedom.Config
  220. (*protocol.ServerEndpoint)(nil), // 3: xray.common.protocol.ServerEndpoint
  221. }
  222. var file_proxy_freedom_config_proto_depIdxs = []int32{
  223. 3, // 0: xray.proxy.freedom.DestinationOverride.server:type_name -> xray.common.protocol.ServerEndpoint
  224. 0, // 1: xray.proxy.freedom.Config.domain_strategy:type_name -> xray.proxy.freedom.Config.DomainStrategy
  225. 1, // 2: xray.proxy.freedom.Config.destination_override:type_name -> xray.proxy.freedom.DestinationOverride
  226. 3, // [3:3] is the sub-list for method output_type
  227. 3, // [3:3] is the sub-list for method input_type
  228. 3, // [3:3] is the sub-list for extension type_name
  229. 3, // [3:3] is the sub-list for extension extendee
  230. 0, // [0:3] is the sub-list for field type_name
  231. }
  232. func init() { file_proxy_freedom_config_proto_init() }
  233. func file_proxy_freedom_config_proto_init() {
  234. if File_proxy_freedom_config_proto != nil {
  235. return
  236. }
  237. if !protoimpl.UnsafeEnabled {
  238. file_proxy_freedom_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  239. switch v := v.(*DestinationOverride); i {
  240. case 0:
  241. return &v.state
  242. case 1:
  243. return &v.sizeCache
  244. case 2:
  245. return &v.unknownFields
  246. default:
  247. return nil
  248. }
  249. }
  250. file_proxy_freedom_config_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
  251. switch v := v.(*Config); i {
  252. case 0:
  253. return &v.state
  254. case 1:
  255. return &v.sizeCache
  256. case 2:
  257. return &v.unknownFields
  258. default:
  259. return nil
  260. }
  261. }
  262. }
  263. type x struct{}
  264. out := protoimpl.TypeBuilder{
  265. File: protoimpl.DescBuilder{
  266. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  267. RawDescriptor: file_proxy_freedom_config_proto_rawDesc,
  268. NumEnums: 1,
  269. NumMessages: 2,
  270. NumExtensions: 0,
  271. NumServices: 0,
  272. },
  273. GoTypes: file_proxy_freedom_config_proto_goTypes,
  274. DependencyIndexes: file_proxy_freedom_config_proto_depIdxs,
  275. EnumInfos: file_proxy_freedom_config_proto_enumTypes,
  276. MessageInfos: file_proxy_freedom_config_proto_msgTypes,
  277. }.Build()
  278. File_proxy_freedom_config_proto = out.File
  279. file_proxy_freedom_config_proto_rawDesc = nil
  280. file_proxy_freedom_config_proto_goTypes = nil
  281. file_proxy_freedom_config_proto_depIdxs = nil
  282. }