1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-11-18 10:26:01 -05:00
v2fly/app/dns/config.proto

69 lines
1.8 KiB
Protocol Buffer
Raw Normal View History

2016-09-20 10:05:35 -04:00
syntax = "proto3";
2016-09-26 09:14:16 -04:00
package v2ray.core.app.dns;
2016-12-22 18:24:28 -05:00
option csharp_namespace = "V2Ray.Core.App.Dns";
option go_package = "v2ray.com/core/app/dns";
2016-09-26 09:14:16 -04:00
option java_package = "com.v2ray.core.app.dns";
2017-02-03 17:15:10 -05:00
option java_multiple_files = true;
2016-09-20 10:05:35 -04:00
import "common/net/address.proto";
import "common/net/destination.proto";
import "app/router/config.proto";
2016-09-20 10:05:35 -04:00
message NameServer {
v2ray.core.common.net.Endpoint address = 1;
message PriorityDomain {
DomainMatchingType type = 1;
string domain = 2;
}
message OriginalRule {
string rule = 1;
uint32 size = 2;
}
repeated PriorityDomain prioritized_domain = 2;
2019-11-18 10:46:56 -05:00
repeated v2ray.core.app.router.GeoIP geoip = 3;
repeated OriginalRule original_rules = 4;
}
enum DomainMatchingType {
Full = 0;
Subdomain = 1;
Keyword = 2;
2018-09-19 10:10:42 -04:00
Regex = 3;
}
2016-09-20 10:05:35 -04:00
message Config {
2016-10-18 04:31:39 -04:00
// Nameservers used by this DNS. Only traditional UDP servers are support at the moment.
// A special value 'localhost' as a domain address can be set to use DNS on local system.
repeated v2ray.core.common.net.Endpoint NameServers = 1 [deprecated = true];
// NameServer list used by this DNS client.
repeated NameServer name_server = 5;
2016-10-18 04:31:39 -04:00
// Static hosts. Domain to IP.
// Deprecated. Use static_hosts.
map<string, v2ray.core.common.net.IPOrDomain> Hosts = 2 [deprecated = true];
2018-06-26 11:14:51 -04:00
2019-11-18 10:46:56 -05:00
// Client IP for EDNS client subnet. Must be 4 bytes (IPv4) or 16 bytes (IPv6).
2018-06-26 17:23:59 -04:00
bytes client_ip = 3;
message HostMapping {
DomainMatchingType type = 1;
string domain = 2;
repeated bytes ip = 3;
// ProxiedDomain indicates the mapped domain has the same IP address on this domain. V2Ray will use this domain for IP queries.
// This field is only effective if ip is empty.
string proxied_domain = 4;
}
repeated HostMapping static_hosts = 4;
2019-01-16 14:32:41 -05:00
// Tag is the inbound tag of DNS client.
string tag = 6;
2016-09-20 10:05:35 -04:00
}