parent
713228e52e
commit
d68bb0c614
@ -384,16 +384,21 @@ o.validate = function(self, value, t)
|
|||||||
return value
|
return value
|
||||||
end
|
end
|
||||||
|
|
||||||
o = s:taboption("DNS", ListValue, "chinadns_ng_default_tag", translate("ChinaDNS-NG Domain Default Tag"))
|
o = s:taboption("DNS", ListValue, "chinadns_ng_default_tag", translate("Default DNS"))
|
||||||
o.default = "none"
|
o.default = "none"
|
||||||
o:value("none", translate("Default"))
|
|
||||||
o:value("gfw", translate("Remote DNS"))
|
o:value("gfw", translate("Remote DNS"))
|
||||||
o:value("chn", translate("Direct DNS"))
|
o:value("chn", translate("Direct DNS"))
|
||||||
o.description = "<ul>"
|
o:value("none", translate("Smart, Do not accept no-ip reply from Direct DNS"))
|
||||||
|
o:value("none_noip", translate("Smart, Accept no-ip reply from Direct DNS"))
|
||||||
|
local desc = "<ul>"
|
||||||
.. "<li>" .. translate("When not matching any domain name list:") .. "</li>"
|
.. "<li>" .. translate("When not matching any domain name list:") .. "</li>"
|
||||||
.. "<li>" .. translate("Default: Forward to both direct and remote DNS, if the direct DNS resolution result is a mainland China ip, then use the direct result, otherwise use the remote result.") .. "</li>"
|
|
||||||
.. "<li>" .. translate("Remote DNS: Can avoid more DNS leaks, but some domestic domain names maybe to proxy!") .. "</li>"
|
.. "<li>" .. translate("Remote DNS: Can avoid more DNS leaks, but some domestic domain names maybe to proxy!") .. "</li>"
|
||||||
.. "<li>" .. translate("Direct DNS: Internet experience may be better, but DNS will be leaked!") .. "</li>"
|
.. "<li>" .. translate("Direct DNS: Internet experience may be better, but DNS will be leaked!") .. "</li>"
|
||||||
|
o.description = desc
|
||||||
|
.. "<li>" .. translate("Smart: Forward to both direct and remote DNS, if the direct DNS resolution result is a mainland China IP, then use the direct result, otherwise use the remote result.") .. "</li>
|
||||||
|
.. "<li>" .. translate("In smart mode, no-ip reply from Direct DNS:") .. "</li>"
|
||||||
|
.. "<li>" .. translate("Do not accept: Wait and use Remote DNS Reply.") .. "</li>"
|
||||||
|
.. "<li>" .. translate("Accept: Trust the Reply, using this option can improve DNS resolution speeds for some mainland IPv4-only sites.") .. "</li>"
|
||||||
.. "</ul>"
|
.. "</ul>"
|
||||||
o:depends({dns_shunt = "chinadns-ng", tcp_proxy_mode = "proxy", chn_list = "direct"})
|
o:depends({dns_shunt = "chinadns-ng", tcp_proxy_mode = "proxy", chn_list = "direct"})
|
||||||
|
|
||||||
@ -401,11 +406,7 @@ o = s:taboption("DNS", ListValue, "use_default_dns", translate("Default DNS"))
|
|||||||
o.default = "direct"
|
o.default = "direct"
|
||||||
o:value("remote", translate("Remote DNS"))
|
o:value("remote", translate("Remote DNS"))
|
||||||
o:value("direct", translate("Direct DNS"))
|
o:value("direct", translate("Direct DNS"))
|
||||||
o.description = "<ul>"
|
o.description = desc .. "</ul>"
|
||||||
.. "<li>" .. translate("When not matching any domain name list:") .. "</li>"
|
|
||||||
.. "<li>" .. translate("Remote DNS: Can avoid more DNS leaks, but some domestic domain names maybe to proxy!") .. "</li>"
|
|
||||||
.. "<li>" .. translate("Direct DNS: Internet experience may be better, but DNS will be leaked!") .. "</li>"
|
|
||||||
.. "</ul>"
|
|
||||||
o:depends({dns_shunt = "dnsmasq", tcp_proxy_mode = "proxy", chn_list = "direct"})
|
o:depends({dns_shunt = "dnsmasq", tcp_proxy_mode = "proxy", chn_list = "direct"})
|
||||||
|
|
||||||
o = s:taboption("DNS", Flag, "dns_redirect", "DNS " .. translate("Redirect"), translate("Force Router DNS server to all local devices."))
|
o = s:taboption("DNS", Flag, "dns_redirect", "DNS " .. translate("Redirect"), translate("Force Router DNS server to all local devices."))
|
||||||
|
@ -172,11 +172,23 @@ msgstr "远程DNS:可以避免更多的DNS泄露,但会导致规则列表外
|
|||||||
msgid "Direct DNS: Internet experience may be better, but DNS will be leaked!"
|
msgid "Direct DNS: Internet experience may be better, but DNS will be leaked!"
|
||||||
msgstr "直连DNS:上网体验可能会更佳,但是会泄露DNS!"
|
msgstr "直连DNS:上网体验可能会更佳,但是会泄露DNS!"
|
||||||
|
|
||||||
msgid "ChinaDNS-NG Domain Default Tag"
|
msgid "Smart, Do not accept no-ip reply from Direct DNS"
|
||||||
msgstr "ChinaDNS-NG 域名默认标签"
|
msgstr "智能,不接受直连 DNS 空响应"
|
||||||
|
|
||||||
msgid "Default: Forward to both direct and remote DNS, if the direct DNS resolution result is a mainland China ip, then use the direct result, otherwise use the remote result."
|
msgid "Smart, Accept no-ip reply from Direct DNS"
|
||||||
msgstr "默认:同时转发给直连和远程DNS,如果直连DNS解析结果是大陆ip,则使用直连结果,否则使用远程结果。"
|
msgstr "智能,接受直连 DNS 空响应"
|
||||||
|
|
||||||
|
msgid "Smart: Forward to both direct and remote DNS, if the direct DNS resolution result is a mainland China IP, then use the direct result, otherwise use the remote result."
|
||||||
|
msgstr "智能:同时转发给直连和远程 DNS,如果直连 DNS 解析结果是大陆 IP,则使用直连结果,否则使用远程结果。"
|
||||||
|
|
||||||
|
msgid "In smart mode, no-ip reply from Direct DNS:"
|
||||||
|
msgstr "使用智能模式,直连 DNS 返回空响应时:"
|
||||||
|
|
||||||
|
msgid "Do not accept: Wait and use Remote DNS Reply."
|
||||||
|
msgstr "不接受:等待并使用远程 DNS 的响应。"
|
||||||
|
|
||||||
|
msgid "Accept: Trust the Reply, using this option can improve DNS resolution speeds for some mainland IPv4-only sites."
|
||||||
|
msgstr "接受:信任空响应,使用此选项可以提升部分大陆仅 IPv4 站点的 DNS 解析速度。"
|
||||||
|
|
||||||
msgid "Filter Proxy Host IPv6"
|
msgid "Filter Proxy Host IPv6"
|
||||||
msgstr "过滤代理域名 IPv6"
|
msgstr "过滤代理域名 IPv6"
|
||||||
|
@ -585,7 +585,10 @@ run_chinadns_ng() {
|
|||||||
[ "${_no_ipv6_trust}" = "1" ] && echo "no-ipv6" >> ${_CONF_FILE}
|
[ "${_no_ipv6_trust}" = "1" ] && echo "no-ipv6" >> ${_CONF_FILE}
|
||||||
}
|
}
|
||||||
|
|
||||||
([ -z "${_default_tag}" ] || [ "${_default_tag}" = "smart" ]) && _default_tag="none"
|
# 是否接受直连 DNS 空响应
|
||||||
|
[ "${_default_tag}" = "none_noip" ] && echo "noip-as-chnip" >> ${_CONF_FILE}
|
||||||
|
|
||||||
|
([ -z "${_default_tag}" ] || [ "${_default_tag}" = "smart" ] || [ "${_default_tag}" = "none_noip" ]) && _default_tag="none"
|
||||||
echo "default-tag ${_default_tag}" >> ${_CONF_FILE}
|
echo "default-tag ${_default_tag}" >> ${_CONF_FILE}
|
||||||
|
|
||||||
ln_run "$(first_type chinadns-ng)" chinadns-ng "${_LOG_FILE}" -C ${_CONF_FILE}
|
ln_run "$(first_type chinadns-ng)" chinadns-ng "${_LOG_FILE}" -C ${_CONF_FILE}
|
||||||
|
@ -24,7 +24,7 @@ index 1440118..be9dd12 100644
|
|||||||
if code ~= 0 then
|
if code ~= 0 then
|
||||||
local use_time = luci.sys.exec("echo -n '" .. result .. "' | awk -F ':' '{print $2}'")
|
local use_time = luci.sys.exec("echo -n '" .. result .. "' | awk -F ':' '{print $2}'")
|
||||||
diff --git a/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua b/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
|
diff --git a/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua b/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
|
||||||
index 13bd889..dcd414b 100644
|
index 521c8ff..5ca99e2 100644
|
||||||
--- a/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
|
--- a/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
|
||||||
+++ b/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
|
+++ b/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
|
||||||
@@ -332,6 +332,12 @@ o:value("9.9.9.9", "9.9.9.9 (Quad9-Recommended)")
|
@@ -332,6 +332,12 @@ o:value("9.9.9.9", "9.9.9.9 (Quad9-Recommended)")
|
||||||
|
Loading…
Reference in New Issue
Block a user