config.pb.go 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.27.1
  4. // protoc v3.18.0
  5. // source: app/dns/config.proto
  6. package dns
  7. import (
  8. router "github.com/xtls/xray-core/app/router"
  9. net "github.com/xtls/xray-core/common/net"
  10. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  11. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  12. reflect "reflect"
  13. sync "sync"
  14. )
  15. const (
  16. // Verify that this generated code is sufficiently up-to-date.
  17. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  18. // Verify that runtime/protoimpl is sufficiently up-to-date.
  19. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  20. )
  21. type DomainMatchingType int32
  22. const (
  23. DomainMatchingType_Full DomainMatchingType = 0
  24. DomainMatchingType_Subdomain DomainMatchingType = 1
  25. DomainMatchingType_Keyword DomainMatchingType = 2
  26. DomainMatchingType_Regex DomainMatchingType = 3
  27. )
  28. // Enum value maps for DomainMatchingType.
  29. var (
  30. DomainMatchingType_name = map[int32]string{
  31. 0: "Full",
  32. 1: "Subdomain",
  33. 2: "Keyword",
  34. 3: "Regex",
  35. }
  36. DomainMatchingType_value = map[string]int32{
  37. "Full": 0,
  38. "Subdomain": 1,
  39. "Keyword": 2,
  40. "Regex": 3,
  41. }
  42. )
  43. func (x DomainMatchingType) Enum() *DomainMatchingType {
  44. p := new(DomainMatchingType)
  45. *p = x
  46. return p
  47. }
  48. func (x DomainMatchingType) String() string {
  49. return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
  50. }
  51. func (DomainMatchingType) Descriptor() protoreflect.EnumDescriptor {
  52. return file_app_dns_config_proto_enumTypes[0].Descriptor()
  53. }
  54. func (DomainMatchingType) Type() protoreflect.EnumType {
  55. return &file_app_dns_config_proto_enumTypes[0]
  56. }
  57. func (x DomainMatchingType) Number() protoreflect.EnumNumber {
  58. return protoreflect.EnumNumber(x)
  59. }
  60. // Deprecated: Use DomainMatchingType.Descriptor instead.
  61. func (DomainMatchingType) EnumDescriptor() ([]byte, []int) {
  62. return file_app_dns_config_proto_rawDescGZIP(), []int{0}
  63. }
  64. type NameServer struct {
  65. state protoimpl.MessageState
  66. sizeCache protoimpl.SizeCache
  67. unknownFields protoimpl.UnknownFields
  68. Address *net.Endpoint `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
  69. PrioritizedDomain []*NameServer_PriorityDomain `protobuf:"bytes,2,rep,name=prioritized_domain,json=prioritizedDomain,proto3" json:"prioritized_domain,omitempty"`
  70. Geoip []*router.GeoIP `protobuf:"bytes,3,rep,name=geoip,proto3" json:"geoip,omitempty"`
  71. OriginalRules []*NameServer_OriginalRule `protobuf:"bytes,4,rep,name=original_rules,json=originalRules,proto3" json:"original_rules,omitempty"`
  72. }
  73. func (x *NameServer) Reset() {
  74. *x = NameServer{}
  75. if protoimpl.UnsafeEnabled {
  76. mi := &file_app_dns_config_proto_msgTypes[0]
  77. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  78. ms.StoreMessageInfo(mi)
  79. }
  80. }
  81. func (x *NameServer) String() string {
  82. return protoimpl.X.MessageStringOf(x)
  83. }
  84. func (*NameServer) ProtoMessage() {}
  85. func (x *NameServer) ProtoReflect() protoreflect.Message {
  86. mi := &file_app_dns_config_proto_msgTypes[0]
  87. if protoimpl.UnsafeEnabled && x != nil {
  88. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  89. if ms.LoadMessageInfo() == nil {
  90. ms.StoreMessageInfo(mi)
  91. }
  92. return ms
  93. }
  94. return mi.MessageOf(x)
  95. }
  96. // Deprecated: Use NameServer.ProtoReflect.Descriptor instead.
  97. func (*NameServer) Descriptor() ([]byte, []int) {
  98. return file_app_dns_config_proto_rawDescGZIP(), []int{0}
  99. }
  100. func (x *NameServer) GetAddress() *net.Endpoint {
  101. if x != nil {
  102. return x.Address
  103. }
  104. return nil
  105. }
  106. func (x *NameServer) GetPrioritizedDomain() []*NameServer_PriorityDomain {
  107. if x != nil {
  108. return x.PrioritizedDomain
  109. }
  110. return nil
  111. }
  112. func (x *NameServer) GetGeoip() []*router.GeoIP {
  113. if x != nil {
  114. return x.Geoip
  115. }
  116. return nil
  117. }
  118. func (x *NameServer) GetOriginalRules() []*NameServer_OriginalRule {
  119. if x != nil {
  120. return x.OriginalRules
  121. }
  122. return nil
  123. }
  124. type Config struct {
  125. state protoimpl.MessageState
  126. sizeCache protoimpl.SizeCache
  127. unknownFields protoimpl.UnknownFields
  128. // Nameservers used by this DNS. Only traditional UDP servers are support at
  129. // the moment. A special value 'localhost' as a domain address can be set to
  130. // use DNS on local system.
  131. //
  132. // Deprecated: Do not use.
  133. NameServers []*net.Endpoint `protobuf:"bytes,1,rep,name=NameServers,proto3" json:"NameServers,omitempty"`
  134. // NameServer list used by this DNS client.
  135. NameServer []*NameServer `protobuf:"bytes,5,rep,name=name_server,json=nameServer,proto3" json:"name_server,omitempty"`
  136. // Static hosts. Domain to IP.
  137. // Deprecated. Use static_hosts.
  138. //
  139. // Deprecated: Do not use.
  140. Hosts map[string]*net.IPOrDomain `protobuf:"bytes,2,rep,name=Hosts,proto3" json:"Hosts,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  141. // Client IP for EDNS client subnet. Must be 4 bytes (IPv4) or 16 bytes
  142. // (IPv6).
  143. ClientIp []byte `protobuf:"bytes,3,opt,name=client_ip,json=clientIp,proto3" json:"client_ip,omitempty"`
  144. StaticHosts []*Config_HostMapping `protobuf:"bytes,4,rep,name=static_hosts,json=staticHosts,proto3" json:"static_hosts,omitempty"`
  145. // Tag is the inbound tag of DNS client.
  146. Tag string `protobuf:"bytes,6,opt,name=tag,proto3" json:"tag,omitempty"`
  147. }
  148. func (x *Config) Reset() {
  149. *x = Config{}
  150. if protoimpl.UnsafeEnabled {
  151. mi := &file_app_dns_config_proto_msgTypes[1]
  152. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  153. ms.StoreMessageInfo(mi)
  154. }
  155. }
  156. func (x *Config) String() string {
  157. return protoimpl.X.MessageStringOf(x)
  158. }
  159. func (*Config) ProtoMessage() {}
  160. func (x *Config) ProtoReflect() protoreflect.Message {
  161. mi := &file_app_dns_config_proto_msgTypes[1]
  162. if protoimpl.UnsafeEnabled && x != nil {
  163. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  164. if ms.LoadMessageInfo() == nil {
  165. ms.StoreMessageInfo(mi)
  166. }
  167. return ms
  168. }
  169. return mi.MessageOf(x)
  170. }
  171. // Deprecated: Use Config.ProtoReflect.Descriptor instead.
  172. func (*Config) Descriptor() ([]byte, []int) {
  173. return file_app_dns_config_proto_rawDescGZIP(), []int{1}
  174. }
  175. // Deprecated: Do not use.
  176. func (x *Config) GetNameServers() []*net.Endpoint {
  177. if x != nil {
  178. return x.NameServers
  179. }
  180. return nil
  181. }
  182. func (x *Config) GetNameServer() []*NameServer {
  183. if x != nil {
  184. return x.NameServer
  185. }
  186. return nil
  187. }
  188. // Deprecated: Do not use.
  189. func (x *Config) GetHosts() map[string]*net.IPOrDomain {
  190. if x != nil {
  191. return x.Hosts
  192. }
  193. return nil
  194. }
  195. func (x *Config) GetClientIp() []byte {
  196. if x != nil {
  197. return x.ClientIp
  198. }
  199. return nil
  200. }
  201. func (x *Config) GetStaticHosts() []*Config_HostMapping {
  202. if x != nil {
  203. return x.StaticHosts
  204. }
  205. return nil
  206. }
  207. func (x *Config) GetTag() string {
  208. if x != nil {
  209. return x.Tag
  210. }
  211. return ""
  212. }
  213. type NameServer_PriorityDomain struct {
  214. state protoimpl.MessageState
  215. sizeCache protoimpl.SizeCache
  216. unknownFields protoimpl.UnknownFields
  217. Type DomainMatchingType `protobuf:"varint,1,opt,name=type,proto3,enum=xray.app.dns.DomainMatchingType" json:"type,omitempty"`
  218. Domain string `protobuf:"bytes,2,opt,name=domain,proto3" json:"domain,omitempty"`
  219. }
  220. func (x *NameServer_PriorityDomain) Reset() {
  221. *x = NameServer_PriorityDomain{}
  222. if protoimpl.UnsafeEnabled {
  223. mi := &file_app_dns_config_proto_msgTypes[2]
  224. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  225. ms.StoreMessageInfo(mi)
  226. }
  227. }
  228. func (x *NameServer_PriorityDomain) String() string {
  229. return protoimpl.X.MessageStringOf(x)
  230. }
  231. func (*NameServer_PriorityDomain) ProtoMessage() {}
  232. func (x *NameServer_PriorityDomain) ProtoReflect() protoreflect.Message {
  233. mi := &file_app_dns_config_proto_msgTypes[2]
  234. if protoimpl.UnsafeEnabled && x != nil {
  235. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  236. if ms.LoadMessageInfo() == nil {
  237. ms.StoreMessageInfo(mi)
  238. }
  239. return ms
  240. }
  241. return mi.MessageOf(x)
  242. }
  243. // Deprecated: Use NameServer_PriorityDomain.ProtoReflect.Descriptor instead.
  244. func (*NameServer_PriorityDomain) Descriptor() ([]byte, []int) {
  245. return file_app_dns_config_proto_rawDescGZIP(), []int{0, 0}
  246. }
  247. func (x *NameServer_PriorityDomain) GetType() DomainMatchingType {
  248. if x != nil {
  249. return x.Type
  250. }
  251. return DomainMatchingType_Full
  252. }
  253. func (x *NameServer_PriorityDomain) GetDomain() string {
  254. if x != nil {
  255. return x.Domain
  256. }
  257. return ""
  258. }
  259. type NameServer_OriginalRule struct {
  260. state protoimpl.MessageState
  261. sizeCache protoimpl.SizeCache
  262. unknownFields protoimpl.UnknownFields
  263. Rule string `protobuf:"bytes,1,opt,name=rule,proto3" json:"rule,omitempty"`
  264. Size uint32 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"`
  265. }
  266. func (x *NameServer_OriginalRule) Reset() {
  267. *x = NameServer_OriginalRule{}
  268. if protoimpl.UnsafeEnabled {
  269. mi := &file_app_dns_config_proto_msgTypes[3]
  270. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  271. ms.StoreMessageInfo(mi)
  272. }
  273. }
  274. func (x *NameServer_OriginalRule) String() string {
  275. return protoimpl.X.MessageStringOf(x)
  276. }
  277. func (*NameServer_OriginalRule) ProtoMessage() {}
  278. func (x *NameServer_OriginalRule) ProtoReflect() protoreflect.Message {
  279. mi := &file_app_dns_config_proto_msgTypes[3]
  280. if protoimpl.UnsafeEnabled && x != nil {
  281. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  282. if ms.LoadMessageInfo() == nil {
  283. ms.StoreMessageInfo(mi)
  284. }
  285. return ms
  286. }
  287. return mi.MessageOf(x)
  288. }
  289. // Deprecated: Use NameServer_OriginalRule.ProtoReflect.Descriptor instead.
  290. func (*NameServer_OriginalRule) Descriptor() ([]byte, []int) {
  291. return file_app_dns_config_proto_rawDescGZIP(), []int{0, 1}
  292. }
  293. func (x *NameServer_OriginalRule) GetRule() string {
  294. if x != nil {
  295. return x.Rule
  296. }
  297. return ""
  298. }
  299. func (x *NameServer_OriginalRule) GetSize() uint32 {
  300. if x != nil {
  301. return x.Size
  302. }
  303. return 0
  304. }
  305. type Config_HostMapping struct {
  306. state protoimpl.MessageState
  307. sizeCache protoimpl.SizeCache
  308. unknownFields protoimpl.UnknownFields
  309. Type DomainMatchingType `protobuf:"varint,1,opt,name=type,proto3,enum=xray.app.dns.DomainMatchingType" json:"type,omitempty"`
  310. Domain string `protobuf:"bytes,2,opt,name=domain,proto3" json:"domain,omitempty"`
  311. Ip [][]byte `protobuf:"bytes,3,rep,name=ip,proto3" json:"ip,omitempty"`
  312. // ProxiedDomain indicates the mapped domain has the same IP address on this
  313. // domain. Xray will use this domain for IP queries. This field is only
  314. // effective if ip is empty.
  315. ProxiedDomain string `protobuf:"bytes,4,opt,name=proxied_domain,json=proxiedDomain,proto3" json:"proxied_domain,omitempty"`
  316. }
  317. func (x *Config_HostMapping) Reset() {
  318. *x = Config_HostMapping{}
  319. if protoimpl.UnsafeEnabled {
  320. mi := &file_app_dns_config_proto_msgTypes[5]
  321. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  322. ms.StoreMessageInfo(mi)
  323. }
  324. }
  325. func (x *Config_HostMapping) String() string {
  326. return protoimpl.X.MessageStringOf(x)
  327. }
  328. func (*Config_HostMapping) ProtoMessage() {}
  329. func (x *Config_HostMapping) ProtoReflect() protoreflect.Message {
  330. mi := &file_app_dns_config_proto_msgTypes[5]
  331. if protoimpl.UnsafeEnabled && x != nil {
  332. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  333. if ms.LoadMessageInfo() == nil {
  334. ms.StoreMessageInfo(mi)
  335. }
  336. return ms
  337. }
  338. return mi.MessageOf(x)
  339. }
  340. // Deprecated: Use Config_HostMapping.ProtoReflect.Descriptor instead.
  341. func (*Config_HostMapping) Descriptor() ([]byte, []int) {
  342. return file_app_dns_config_proto_rawDescGZIP(), []int{1, 1}
  343. }
  344. func (x *Config_HostMapping) GetType() DomainMatchingType {
  345. if x != nil {
  346. return x.Type
  347. }
  348. return DomainMatchingType_Full
  349. }
  350. func (x *Config_HostMapping) GetDomain() string {
  351. if x != nil {
  352. return x.Domain
  353. }
  354. return ""
  355. }
  356. func (x *Config_HostMapping) GetIp() [][]byte {
  357. if x != nil {
  358. return x.Ip
  359. }
  360. return nil
  361. }
  362. func (x *Config_HostMapping) GetProxiedDomain() string {
  363. if x != nil {
  364. return x.ProxiedDomain
  365. }
  366. return ""
  367. }
  368. var File_app_dns_config_proto protoreflect.FileDescriptor
  369. var file_app_dns_config_proto_rawDesc = []byte{
  370. 0x0a, 0x14, 0x61, 0x70, 0x70, 0x2f, 0x64, 0x6e, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67,
  371. 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0c, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70,
  372. 0x2e, 0x64, 0x6e, 0x73, 0x1a, 0x18, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x6e, 0x65, 0x74,
  373. 0x2f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c,
  374. 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x6e, 0x65, 0x74, 0x2f, 0x64, 0x65, 0x73, 0x74, 0x69,
  375. 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x61, 0x70,
  376. 0x70, 0x2f, 0x72, 0x6f, 0x75, 0x74, 0x65, 0x72, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e,
  377. 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xad, 0x03, 0x0a, 0x0a, 0x4e, 0x61, 0x6d, 0x65, 0x53, 0x65,
  378. 0x72, 0x76, 0x65, 0x72, 0x12, 0x33, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18,
  379. 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d,
  380. 0x6d, 0x6f, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2e, 0x45, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74,
  381. 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x56, 0x0a, 0x12, 0x70, 0x72, 0x69,
  382. 0x6f, 0x72, 0x69, 0x74, 0x69, 0x7a, 0x65, 0x64, 0x5f, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x18,
  383. 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70,
  384. 0x2e, 0x64, 0x6e, 0x73, 0x2e, 0x4e, 0x61, 0x6d, 0x65, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e,
  385. 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x52, 0x11,
  386. 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x69, 0x7a, 0x65, 0x64, 0x44, 0x6f, 0x6d, 0x61, 0x69,
  387. 0x6e, 0x12, 0x2c, 0x0a, 0x05, 0x67, 0x65, 0x6f, 0x69, 0x70, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b,
  388. 0x32, 0x16, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x72, 0x6f, 0x75, 0x74,
  389. 0x65, 0x72, 0x2e, 0x47, 0x65, 0x6f, 0x49, 0x50, 0x52, 0x05, 0x67, 0x65, 0x6f, 0x69, 0x70, 0x12,
  390. 0x4c, 0x0a, 0x0e, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x5f, 0x72, 0x75, 0x6c, 0x65,
  391. 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61,
  392. 0x70, 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x2e, 0x4e, 0x61, 0x6d, 0x65, 0x53, 0x65, 0x72, 0x76, 0x65,
  393. 0x72, 0x2e, 0x4f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x0d,
  394. 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x1a, 0x5e, 0x0a,
  395. 0x0e, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x12,
  396. 0x34, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x20, 0x2e,
  397. 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x2e, 0x44, 0x6f, 0x6d,
  398. 0x61, 0x69, 0x6e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x69, 0x6e, 0x67, 0x54, 0x79, 0x70, 0x65, 0x52,
  399. 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x18,
  400. 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x1a, 0x36, 0x0a,
  401. 0x0c, 0x4f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x52, 0x75, 0x6c, 0x65, 0x12, 0x12, 0x0a,
  402. 0x04, 0x72, 0x75, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x72, 0x75, 0x6c,
  403. 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52,
  404. 0x04, 0x73, 0x69, 0x7a, 0x65, 0x22, 0xa5, 0x04, 0x0a, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67,
  405. 0x12, 0x3f, 0x0a, 0x0b, 0x4e, 0x61, 0x6d, 0x65, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x73, 0x18,
  406. 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d,
  407. 0x6d, 0x6f, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2e, 0x45, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74,
  408. 0x42, 0x02, 0x18, 0x01, 0x52, 0x0b, 0x4e, 0x61, 0x6d, 0x65, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72,
  409. 0x73, 0x12, 0x39, 0x0a, 0x0b, 0x6e, 0x61, 0x6d, 0x65, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72,
  410. 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70,
  411. 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x2e, 0x4e, 0x61, 0x6d, 0x65, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72,
  412. 0x52, 0x0a, 0x6e, 0x61, 0x6d, 0x65, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x39, 0x0a, 0x05,
  413. 0x48, 0x6f, 0x73, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x78, 0x72,
  414. 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x66, 0x69,
  415. 0x67, 0x2e, 0x48, 0x6f, 0x73, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x42, 0x02, 0x18, 0x01,
  416. 0x52, 0x05, 0x48, 0x6f, 0x73, 0x74, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e,
  417. 0x74, 0x5f, 0x69, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65,
  418. 0x6e, 0x74, 0x49, 0x70, 0x12, 0x43, 0x0a, 0x0c, 0x73, 0x74, 0x61, 0x74, 0x69, 0x63, 0x5f, 0x68,
  419. 0x6f, 0x73, 0x74, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x78, 0x72, 0x61,
  420. 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67,
  421. 0x2e, 0x48, 0x6f, 0x73, 0x74, 0x4d, 0x61, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x52, 0x0b, 0x73, 0x74,
  422. 0x61, 0x74, 0x69, 0x63, 0x48, 0x6f, 0x73, 0x74, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x61, 0x67,
  423. 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x74, 0x61, 0x67, 0x1a, 0x55, 0x0a, 0x0a, 0x48,
  424. 0x6f, 0x73, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79,
  425. 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x31, 0x0a, 0x05, 0x76,
  426. 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x78, 0x72, 0x61,
  427. 0x79, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2e, 0x49, 0x50, 0x4f,
  428. 0x72, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02,
  429. 0x38, 0x01, 0x1a, 0x92, 0x01, 0x0a, 0x0b, 0x48, 0x6f, 0x73, 0x74, 0x4d, 0x61, 0x70, 0x70, 0x69,
  430. 0x6e, 0x67, 0x12, 0x34, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e,
  431. 0x32, 0x20, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x2e,
  432. 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x69, 0x6e, 0x67, 0x54, 0x79,
  433. 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x6f, 0x6d, 0x61,
  434. 0x69, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e,
  435. 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x70, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x02, 0x69, 0x70,
  436. 0x12, 0x25, 0x0a, 0x0e, 0x70, 0x72, 0x6f, 0x78, 0x69, 0x65, 0x64, 0x5f, 0x64, 0x6f, 0x6d, 0x61,
  437. 0x69, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x70, 0x72, 0x6f, 0x78, 0x69, 0x65,
  438. 0x64, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4a, 0x04, 0x08, 0x07, 0x10, 0x08, 0x2a, 0x45, 0x0a,
  439. 0x12, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x69, 0x6e, 0x67, 0x54,
  440. 0x79, 0x70, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x46, 0x75, 0x6c, 0x6c, 0x10, 0x00, 0x12, 0x0d, 0x0a,
  441. 0x09, 0x53, 0x75, 0x62, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07,
  442. 0x4b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, 0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, 0x52, 0x65, 0x67,
  443. 0x65, 0x78, 0x10, 0x03, 0x42, 0x46, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x72, 0x61, 0x79,
  444. 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x64, 0x6e, 0x73, 0x50, 0x01, 0x5a, 0x21, 0x67, 0x69, 0x74, 0x68,
  445. 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x74, 0x6c, 0x73, 0x2f, 0x78, 0x72, 0x61, 0x79,
  446. 0x2d, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x64, 0x6e, 0x73, 0xaa, 0x02, 0x0c,
  447. 0x58, 0x72, 0x61, 0x79, 0x2e, 0x41, 0x70, 0x70, 0x2e, 0x44, 0x6e, 0x73, 0x62, 0x06, 0x70, 0x72,
  448. 0x6f, 0x74, 0x6f, 0x33,
  449. }
  450. var (
  451. file_app_dns_config_proto_rawDescOnce sync.Once
  452. file_app_dns_config_proto_rawDescData = file_app_dns_config_proto_rawDesc
  453. )
  454. func file_app_dns_config_proto_rawDescGZIP() []byte {
  455. file_app_dns_config_proto_rawDescOnce.Do(func() {
  456. file_app_dns_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_app_dns_config_proto_rawDescData)
  457. })
  458. return file_app_dns_config_proto_rawDescData
  459. }
  460. var file_app_dns_config_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
  461. var file_app_dns_config_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
  462. var file_app_dns_config_proto_goTypes = []interface{}{
  463. (DomainMatchingType)(0), // 0: xray.app.dns.DomainMatchingType
  464. (*NameServer)(nil), // 1: xray.app.dns.NameServer
  465. (*Config)(nil), // 2: xray.app.dns.Config
  466. (*NameServer_PriorityDomain)(nil), // 3: xray.app.dns.NameServer.PriorityDomain
  467. (*NameServer_OriginalRule)(nil), // 4: xray.app.dns.NameServer.OriginalRule
  468. nil, // 5: xray.app.dns.Config.HostsEntry
  469. (*Config_HostMapping)(nil), // 6: xray.app.dns.Config.HostMapping
  470. (*net.Endpoint)(nil), // 7: xray.common.net.Endpoint
  471. (*router.GeoIP)(nil), // 8: xray.app.router.GeoIP
  472. (*net.IPOrDomain)(nil), // 9: xray.common.net.IPOrDomain
  473. }
  474. var file_app_dns_config_proto_depIdxs = []int32{
  475. 7, // 0: xray.app.dns.NameServer.address:type_name -> xray.common.net.Endpoint
  476. 3, // 1: xray.app.dns.NameServer.prioritized_domain:type_name -> xray.app.dns.NameServer.PriorityDomain
  477. 8, // 2: xray.app.dns.NameServer.geoip:type_name -> xray.app.router.GeoIP
  478. 4, // 3: xray.app.dns.NameServer.original_rules:type_name -> xray.app.dns.NameServer.OriginalRule
  479. 7, // 4: xray.app.dns.Config.NameServers:type_name -> xray.common.net.Endpoint
  480. 1, // 5: xray.app.dns.Config.name_server:type_name -> xray.app.dns.NameServer
  481. 5, // 6: xray.app.dns.Config.Hosts:type_name -> xray.app.dns.Config.HostsEntry
  482. 6, // 7: xray.app.dns.Config.static_hosts:type_name -> xray.app.dns.Config.HostMapping
  483. 0, // 8: xray.app.dns.NameServer.PriorityDomain.type:type_name -> xray.app.dns.DomainMatchingType
  484. 9, // 9: xray.app.dns.Config.HostsEntry.value:type_name -> xray.common.net.IPOrDomain
  485. 0, // 10: xray.app.dns.Config.HostMapping.type:type_name -> xray.app.dns.DomainMatchingType
  486. 11, // [11:11] is the sub-list for method output_type
  487. 11, // [11:11] is the sub-list for method input_type
  488. 11, // [11:11] is the sub-list for extension type_name
  489. 11, // [11:11] is the sub-list for extension extendee
  490. 0, // [0:11] is the sub-list for field type_name
  491. }
  492. func init() { file_app_dns_config_proto_init() }
  493. func file_app_dns_config_proto_init() {
  494. if File_app_dns_config_proto != nil {
  495. return
  496. }
  497. if !protoimpl.UnsafeEnabled {
  498. file_app_dns_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  499. switch v := v.(*NameServer); i {
  500. case 0:
  501. return &v.state
  502. case 1:
  503. return &v.sizeCache
  504. case 2:
  505. return &v.unknownFields
  506. default:
  507. return nil
  508. }
  509. }
  510. file_app_dns_config_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
  511. switch v := v.(*Config); i {
  512. case 0:
  513. return &v.state
  514. case 1:
  515. return &v.sizeCache
  516. case 2:
  517. return &v.unknownFields
  518. default:
  519. return nil
  520. }
  521. }
  522. file_app_dns_config_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
  523. switch v := v.(*NameServer_PriorityDomain); i {
  524. case 0:
  525. return &v.state
  526. case 1:
  527. return &v.sizeCache
  528. case 2:
  529. return &v.unknownFields
  530. default:
  531. return nil
  532. }
  533. }
  534. file_app_dns_config_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
  535. switch v := v.(*NameServer_OriginalRule); i {
  536. case 0:
  537. return &v.state
  538. case 1:
  539. return &v.sizeCache
  540. case 2:
  541. return &v.unknownFields
  542. default:
  543. return nil
  544. }
  545. }
  546. file_app_dns_config_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
  547. switch v := v.(*Config_HostMapping); i {
  548. case 0:
  549. return &v.state
  550. case 1:
  551. return &v.sizeCache
  552. case 2:
  553. return &v.unknownFields
  554. default:
  555. return nil
  556. }
  557. }
  558. }
  559. type x struct{}
  560. out := protoimpl.TypeBuilder{
  561. File: protoimpl.DescBuilder{
  562. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  563. RawDescriptor: file_app_dns_config_proto_rawDesc,
  564. NumEnums: 1,
  565. NumMessages: 6,
  566. NumExtensions: 0,
  567. NumServices: 0,
  568. },
  569. GoTypes: file_app_dns_config_proto_goTypes,
  570. DependencyIndexes: file_app_dns_config_proto_depIdxs,
  571. EnumInfos: file_app_dns_config_proto_enumTypes,
  572. MessageInfos: file_app_dns_config_proto_msgTypes,
  573. }.Build()
  574. File_app_dns_config_proto = out.File
  575. file_app_dns_config_proto_rawDesc = nil
  576. file_app_dns_config_proto_goTypes = nil
  577. file_app_dns_config_proto_depIdxs = nil
  578. }