Commit 8c450884 authored by Max Lv's avatar Max Lv

Refine DNS resolution

parent 79acf140
Subproject commit 698275907b0c038b4eb40acbc067c8bf143e548f
Subproject commit eb5c47e5bd6b81ac048686b9826b8e0cda7aa9d4
......@@ -181,7 +181,7 @@ class ShadowsocksNatService extends BaseService {
val conf = profile.route match {
case Route.BYPASS_CHN | Route.BYPASS_LAN_CHN | Route.GFWLIST => {
ConfigUtils.PDNSD_DIRECT.formatLocal(Locale.ENGLISH, getApplicationInfo.dataDir,
"127.0.0.1", profile.localPort + 53, "1.2.4.8, 114.114.114.114, 208.67.222.222", "", profile.localPort + 63, "")
"127.0.0.1", profile.localPort + 53, "1.2.4.8, 114.114.114.114", "", profile.localPort + 63, "")
}
case Route.CHINALIST => {
ConfigUtils.PDNSD_DIRECT.formatLocal(Locale.ENGLISH, getApplicationInfo.dataDir,
......
......@@ -282,7 +282,6 @@ class ShadowsocksVpnService extends VpnService with BaseService {
})
val cmd = ArrayBuffer[String](getApplicationInfo.dataDir + "/ss-tunnel"
, "-V"
, "-u"
, "-t", "10"
, "-b", "127.0.0.1"
, "-L", "8.8.8.8:53"
......@@ -301,7 +300,7 @@ class ShadowsocksVpnService extends VpnService with BaseService {
val conf = profile.route match {
case Route.BYPASS_CHN | Route.BYPASS_LAN_CHN | Route.GFWLIST => {
ConfigUtils.PDNSD_DIRECT.formatLocal(Locale.ENGLISH, getApplicationInfo.dataDir,
"0.0.0.0", profile.localPort + 53, "1.2.4.8, 114.114.114.114, 208.67.222.222", ipv6, profile.localPort + 63, ipv6)
"0.0.0.0", profile.localPort + 53, "1.2.4.8, 114.114.114.114", ipv6, profile.localPort + 63, ipv6)
}
case Route.CHINALIST => {
ConfigUtils.PDNSD_DIRECT.formatLocal(Locale.ENGLISH, getApplicationInfo.dataDir,
......
......@@ -73,7 +73,6 @@ object ConfigUtils {
| server_ip = %s;
| server_port = %d;
| query_method = tcp_only;
| run_ipv4 = on;
| min_ttl = 15m;
| max_ttl = 1w;
| timeout = 10;
......@@ -87,7 +86,6 @@ object ConfigUtils {
| %s
| reject_policy = negate;
| reject_recursively = on;
| timeout = 5;
|}
|
|rr {
......@@ -106,28 +104,32 @@ object ConfigUtils {
| cache_dir = "%s";
| server_ip = %s;
| server_port = %d;
| query_method = tcp_only;
| run_ipv4 = on;
| query_method = udp_only;
| min_ttl = 15m;
| max_ttl = 1w;
| timeout = 10;
| daemon = off;
| par_queries = 4;
|}
|
|server {
| label = "remote-servers";
| ip = %s;
| timeout = 3;
| uptest = none;
| preset = on;
| query_method = udp_only;
| %s
| reject_policy = negate;
| reject_recursively = on;
|}
|
|server {
| label = "local-server";
| ip = 127.0.0.1;
| query_method = tcp_only;
| port = %d;
| %s
| reject_policy = negate;
| reject_recursively = on;
|}
|
|rr {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment