OpenClash: bump to v0.36.5-beta

This commit is contained in:
CN_SZTL 2020-02-11 19:53:29 +08:00
parent c7991e6084
commit 84818d4cf1
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
25 changed files with 979 additions and 1639 deletions

View File

@ -1,7 +1,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-openclash
PKG_VERSION:=0.36.4
PKG_VERSION:=0.36.5
PKG_RELEASE:=beta
PKG_MAINTAINER:=vernesong <https://github.com/vernesong/OpenClash>
@ -26,7 +26,7 @@ define Package/$(PKG_NAME)/postinst
endef
define Build/Prepare
$(foreach po,$(wildcard ${CURDIR}/po/zh_Hans/*.po), \
$(foreach po,$(wildcard ${CURDIR}/i18n/zh_Hans/*.po), \
po2lmo $(po) $(PKG_BUILD_DIR)/$(patsubst %.po,%.lmo,$(notdir $(po)));)
chmod 0755 ${CURDIR}/files/etc/init.d/openclash
chmod -R 0755 ${CURDIR}/files/usr/share/openclash/
@ -153,7 +153,7 @@ endef
define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/usr/lib/lua/luci/i18n
$(INSTALL_DATA) $(PKG_BUILD_DIR)/*.lmo $(1)/usr/lib/lua/luci/i18n/openclash.zh-cn.lmo
$(INSTALL_DATA) $(PKG_BUILD_DIR)/*.*.lmo $(1)/usr/lib/lua/luci/i18n/
$(CP) ./files/* $(1)/
endef

View File

@ -156,10 +156,35 @@ yml_check()
sed -i "/^ \{1,\}dns:/c\dns:" "$3"
}
#处理provider位置
#位置检查
proxy_len=$(sed -n '/^Proxy:/=' "$3" 2>/dev/null)
group_len=$(sed -n '/^ \{0,\}Proxy Group:/=' "$3" 2>/dev/null)
provider_len=$(sed -n '/^proxy-provider:/=' "$3" 2>/dev/null)
dns_len=$(sed -n '/^ \{0,\}dns:/=' "$3" 2>/dev/null)
rule_len=$(sed -n '/^Rule:/=' "$3" 2>/dev/null)
if [ "$dns_len" -ge "$proxy_len" ] || [ "$dns_len" -ge "$rule_len" ] || [ "$dns_len" -ge "$group_len" ]; then
echo "错误: 不支持的配置文件, General 设置部分应位于开头,请根据模板修改后重试!" > $START_LOG
echo "${LOGTIME} Unsupported Config, Please Check The General Setting's location And Try-again!" >> $LOG_FILE
mv "$START_BACKUP" "$CONFIG_FILE"
exit 0
fi
if [ "$proxy_len" -ge "$rule_len" ] || [ "$provider_len" -ge "$rule_len" ]; then
echo "错误: 不支持的配置文件,服务器节点设置部分应位于规则之前,请根据模板修改后重试!" > $START_LOG
echo "${LOGTIME} Unsupported Config, Please Check The Proxy Setting's location And Try-again!" >> $LOG_FILE
mv "$START_BACKUP" "$CONFIG_FILE"
exit 0
fi
if [ "$group_len" -ge "$rule_len" ] || [ "$proxy_len" -ge "$group_len" ]; then
echo "错误: 不支持的配置文件,策略组设置部分应位于规则之前、节点之后,请根据模板修改后重试!" > $START_LOG
echo "${LOGTIME} Unsupported Config, Please Check The Group Setting's location And Try-again!" >> $LOG_FILE
mv "$START_BACKUP" "$CONFIG_FILE"
exit 0
fi
#处理provider位置
if [ ! -z "$provider_len" ]; then
if [ "$provider_len" -ge "$proxy_len" ] && [ "$provider_len" -le "$group_len" ]; then
awk '/^proxy-provider:/,/^Proxy Group:/{print}' "$3" | sed '/^Proxy Group:/d' >/tmp/backprovider.yaml 2>/dev/null
@ -591,6 +616,41 @@ elif [ -f "/tmp/yaml_servers.yaml" ]; then
fi
}
proxy_router()
{
ipset -! create router nethash && ipset flush router
rm -rf /tmp/openclash_pr_list.conf >/dev/null 2>&1
# github and some other site need to go proxy with redir-host mode
echo "#for router itself" >> /tmp/openclash_pr_list.conf
echo "server=/.google.com/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.google.com/router" >> /tmp/openclash_pr_list.conf
echo "server=/.google.com.tw/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.google.com.tw/router" >> /tmp/openclash_pr_list.conf
echo "server=/.google.com.hk/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.google.com.hk/router" >> /tmp/openclash_pr_list.conf
echo "server=/.google.com.jp/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.google.com.jp/router" >> /tmp/openclash_pr_list.conf
echo "server=/.github.com/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.github.com/router" >> /tmp/openclash_pr_list.conf
echo "server=/.github.io/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.github.io/router" >> /tmp/openclash_pr_list.conf
echo "server=/.githubusercontent.com/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.githubusercontent.com/router" >> /tmp/openclash_pr_list.conf
echo "server=/.shields.io/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.shields.io/router" >> /tmp/openclash_pr_list.conf
echo "server=/.shields.io/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.shields.io/router" >> /tmp/openclash_pr_list.conf
echo "server=/.s3.amazonaws.com/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.s3.amazonaws.com/router" >> /tmp/openclash_pr_list.conf
echo "server=/.openwrt.org/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.openwrt.org/router" >> /tmp/openclash_pr_list.conf
echo "server=/.s3-ap-northeast-1.amazonaws.com/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.s3-ap-northeast-1.amazonaws.com/router" >> /tmp/openclash_pr_list.conf
echo "server=/.s3-ap-southeast-2.amazonaws.com/127.0.0.1#$dns_port" >> /tmp/openclash_pr_list.conf
echo "ipset=/.s3-ap-southeast-2.amazonaws.com/router" >> /tmp/openclash_pr_list.conf
mv /tmp/openclash_pr_list.conf /tmp/dnsmasq.d/openclash_pr_list.conf
}
start()
{
#禁止多个实例
@ -707,7 +767,7 @@ if [ "$enable" -eq 1 ] && [ -f "$CONFIG_FILE" ]; then
rm -rf /tmp/yaml_* 2>/dev/null
echo "第七步: 设置控制面板..." >$START_LOG
ln -s /usr/share/openclash/yacd /www/openclash 2>/dev/null
ln -s /usr/share/openclash/yacd /www/luci-static/openclash 2>/dev/null
echo "第八步: 设置 OpenClash 防火墙规则..." >$START_LOG
if [ -z "$(uci get firewall.openclash 2>/dev/null)" ] || [ -z "$(uci get ucitrack.@openclash[-1].init 2>/dev/null)" ]; then
@ -732,6 +792,7 @@ mkdir -p /var/etc
cat > "/var/etc/openclash.include" <<-EOF
/etc/init.d/openclash restart
EOF
if [ -z "$en_mode_tun" ]; then
iptables -t nat -N openclash
iptables -t nat -A openclash -d 0.0.0.0/8 -j RETURN
@ -745,15 +806,24 @@ EOF
if [ ! -z "$wan_ip4" ]; then
iptables -t nat -A openclash -d "$wan_ip4" -j RETURN
fi
iptables -t nat -A openclash -p tcp -j REDIRECT --to-ports "$proxy_port"
iptables -t nat -A PREROUTING -p tcp -j openclash
iptables -t nat -A OUTPUT -p tcp -d 198.18.0.0/16 -j REDIRECT --to-ports "$proxy_port"
if [ "$en_mode" = "redir-host" ]; then
proxy_router
iptables -t nat -A OUTPUT -p tcp -m set --match-set router dst -j REDIRECT --to-ports "$proxy_port" >/dev/null 2>&1
else
iptables -t nat -A OUTPUT -p tcp -d 198.18.0.0/16 -j REDIRECT --to-ports "$proxy_port"
fi
if [ "$ipv6_enable" -eq 1 ]; then
ip6tables -t nat -N openclash
ip6tables -t nat -A openclash -p tcp -j REDIRECT --to-ports "$proxy_port"
ip6tables -t nat -A PREROUTING -p tcp -j openclash
if [ "$en_mode" = "redir-host" ]; then
ip6tables -t nat -A OUTPUT -p tcp -m set --match-set router dst -j REDIRECT --to-ports "$proxy_port" >/dev/null 2>&1
fi
fi
else
#TUN模式
@ -765,7 +835,7 @@ EOF
ipset add localnetwork 224.0.0.0/4
ipset add localnetwork 240.0.0.0/4
ipset add localnetwork 172.16.0.0/12
ipset add localnetwork "$wan_ip4"
ipset add localnetwork "$wan_ip4"
#启动TUN
if [ "$en_mode_tun" = "2" ]; then
ip tuntap add user root mode tun clash0
@ -778,13 +848,21 @@ EOF
#设置防火墙
iptables -t mangle -N openclash
iptables -t mangle -F openclash
iptables -t mangle -A openclash -d 198.18.0.0/16 -j MARK --set-mark "$PROXY_FWMARK"
if [ "$en_mode" = "redir-host" ]; then
proxy_router
iptables -t mangle -A openclash -p tcp -m set --match-set router dst -j MARK --set-mark "$PROXY_FWMARK" >/dev/null 2>&1
else
iptables -t mangle -A openclash -d 198.18.0.0/16 -j MARK --set-mark "$PROXY_FWMARK"
fi
iptables -t mangle -A openclash -m set --match-set localnetwork dst -j RETURN
iptables -t mangle -I OUTPUT -j openclash
iptables -t mangle -I PREROUTING -m set ! --match-set localnetwork dst -j MARK --set-mark "$PROXY_FWMARK"
#ipv6
if [ "$ipv6_enable" -eq 1 ]; then
ip6tables -t mangle -I PREROUTING -j MARK --set-mark "$PROXY_FWMARK"
if [ "$en_mode" = "redir-host" ]; then
ip6tables -t mangle -A OUTPUT -p tcp -m set --match-set router dst -j MARK --set-mark "$PROXY_FWMARK" >/dev/null 2>&1
fi
fi
fi
@ -799,16 +877,15 @@ EOF
/etc/init.d/dnsmasq restart >/dev/null 2>&1
if pidof clash >/dev/null; then
echo "第十步: 添加 OpenClash 计划任务,启动进程守护程序..." >$START_LOG
/usr/share/openclash/openclash_history_set.sh
add_cron
if [ -z "$(uci get dhcp.lan.dhcpv6 2>/dev/null)" ]; then
echo "OpenClash 启动成功,请等待服务器上线!" >$START_LOG
echo "${LOGTIME} OpenClash Start Successful" >> $LOG_FILE
/usr/share/openclash/openclash_history_set.sh
sleep 5
else
echo "OpenClash 启动成功检测到您启用了IPV6的DHCP服务可能会造成连接异常" >$START_LOG
echo "${LOGTIME} OpenClash Start Successful, Please Note That Network May Abnormal With IPV6's DHCP Server" >> $LOG_FILE
/usr/share/openclash/openclash_history_set.sh
sleep 10
fi
echo "" >$START_LOG
@ -824,16 +901,15 @@ EOF
nohup $CLASH -d "$CLASH_CONFIG" -f "$CONFIG_FILE" >> $LOG_FILE 2>&1 &
sleep 3
if pidof clash >/dev/null; then
/usr/share/openclash/openclash_history_set.sh
add_cron
if [ -z "$(uci get dhcp.lan.dhcpv6 2>/dev/null)" ]; then
echo "OpenClash 使用备份规则启动成功,请更新、检查变动的规则后重试!" >$START_LOG
echo "${LOGTIME} OpenClash Start Successful With Backup Rules Config, Please Check Or Update Other Rules And Retry" >> $LOG_FILE
/usr/share/openclash/openclash_history_set.sh
sleep 10
else
echo "OpenClash 使用备份规则启动成功,请更新、检查变动的规则后重试!" >$START_LOG
echo "${LOGTIME} OpenClash Start Successful With Backup Rules Config, Please Check Or Update Other Rules And Retry" >> $LOG_FILE
/usr/share/openclash/openclash_history_set.sh
sleep 5
echo "检测到您启用了IPV6的DHCP服务可能会造成连接异常" >$START_LOG
echo "${LOGTIME} OpenClash Start Successful, Please Note That Network May Abnormal With IPV6's DHCP Server" >> $LOG_FILE
@ -885,10 +961,12 @@ stop()
{
echo "OpenClash 开始关闭..." >$START_LOG
echo "第一步: 备份当前节点状态..." >$START_LOG
/usr/share/openclash/openclash_history_get.sh
/usr/share/openclash/openclash_history_get.sh &
wait
echo "第二步: 删除 OpenClash 防火墙规则..." >$START_LOG
rm -rf /var/etc/openclash.include 2>/dev/null
ipset -F router >/dev/null 2>&1 && ipset -X router >/dev/null 2>&1
rm -rf /tmp/dnsmasq.d/openclash_pr_list.conf
#ipv4
iptables -t nat -F openclash >/dev/null 2>&1
iptables -t nat -D PREROUTING -p tcp -j openclash >/dev/null 2>&1
@ -898,12 +976,22 @@ stop()
for out_line in $out_lines; do
iptables -t nat -D OUTPUT "$out_line" >/dev/null 2>&1
done
out_lines=$(iptables -nvL OUTPUT -t nat |sed 1,2d |sed -n '/router/=' 2>/dev/null |sort -rn)
for out_line in $out_lines; do
iptables -t nat -D OUTPUT "$out_line" >/dev/null 2>&1
done
#ipv6
ip6tables -t nat -F openclash >/dev/null 2>&1
ip6tables -t nat -D PREROUTING -p tcp -j openclash >/dev/null 2>&1
ip6tables -t nat -X openclash >/dev/null 2>&1
out_lines=$(ip6tables -nvL OUTPUT -t nat |sed 1,2d |sed -n '/router/=' 2>/dev/null |sort -rn)
for out_line in $out_lines; do
ip6tables -t nat -D OUTPUT "$out_line" >/dev/null 2>&1
done
#TUN
ip link set dev clash0 down >/dev/null 2>&1
ip tuntap del clash0 mode tun >/dev/null 2>&1
@ -914,6 +1002,7 @@ stop()
iptables -t mangle -D OUTPUT -j openclash >/dev/null 2>&1
iptables -t mangle -D PREROUTING -m set ! --match-set localnetwork dst -j MARK --set-mark "$PROXY_FWMARK" >/dev/null 2>&1
ip6tables -t mangle -D PREROUTING -j MARK --set-mark "$PROXY_FWMARK" >/dev/null 2>&1
ip6tables -t mangle -D OUTPUT -p tcp -m set --match-set router dst -j MARK --set-mark "$PROXY_FWMARK" >/dev/null 2>&1
iptables -t mangle -F openclash >/dev/null 2>&1
iptables -t mangle -X openclash >/dev/null 2>&1
ipset destroy localnetwork >/dev/null 2>&1
@ -938,7 +1027,7 @@ stop()
enable=$(uci get openclash.config.enable 2>/dev/null)
if [ "$enable" -eq 0 ]; then
rm -rf $LOG_FILE 2>/dev/null
rm -rf /www/openclash 2>/dev/null
rm -rf /www/luci-static/openclash 2>/dev/null
rm -rf /tmp/openclash_last_version 2>/dev/null
rm -rf /tmp/clash_last_version 2>/dev/null
rm -rf /tmp/Proxy_Group 2>/dev/null

View File

@ -56,6 +56,9 @@ dns: # 如订阅配置无包括此项的所有DNS设置OpenClash将自动添
listen: 0.0.0.0:53 # 端口为53时将被接管为7874
enhanced-mode: redir-host # or fake-ip # 此项将被接管
fake-ip-range: 198.18.0.1/16 # if you don't know what it is, don't change it # 此项将被接管
# fake-ip-filter: # fake ip white domain list
# - '*.lan'
# - localhost.ptlogin2.qq.com
nameserver:
- 114.114.114.114
- https://1.1.1.1/dns-query # dns over https
@ -69,7 +72,25 @@ dns: # 如订阅配置无包括此项的所有DNS设置OpenClash将自动添
# 以上设置您可直接覆盖到配置文件,无需更改
# Openclash 不会对下方服务器设置进行任何更改,请确保设置正确
Proxy: # 此参数必须保留,不能删除
proxy-provider: # 代理集设置此部分与Proxy两者不能同时删除
pro:
type: http
path: ./proxy_provider/pro.yaml
url: https://xxx
interval: 3600
health-check:
enable: true
url: http://www.gstatic.com/generate_204
interval: 300
iplc:
type: file
path: ./proxy_provider/iplc.yaml
health-check:
enable: true
url: http://www.gstatic.com/generate_204
interval: 300
Proxy: # 节点设置此部分与proxy-provider两者不能同时删除
# shadowsocks
# The supported ciphers(encrypt methods):

File diff suppressed because one or more lines are too long

View File

@ -88,6 +88,16 @@ if HTTP.formvalue("upload") then
end
end
local function i(e)
local t=0
local a={' KB',' MB',' GB',' TB'}
repeat
e=e/1024
t=t+1
until(e<=1024)
return string.format("%.1f",e)..a[t]
end
local e,a={}
for t,o in ipairs(fs.glob("/etc/openclash/config/*"))do
a=fs.stat(o)
@ -101,7 +111,7 @@ if string.sub(luci.sys.exec("uci get openclash.config.config_path"), 23, -2) ==
else
e[t].state=translate("Disable")
end
e[t].size=tostring(a.size)
e[t].size=i(a.size)
e[t].remove=0
e[t].enable=false
end
@ -197,7 +207,7 @@ if r then
p[x]={}
p[x].name=fs.basename(y)
p[x].mtime=os.date("%Y-%m-%d %H:%M:%S",r.mtime)
p[x].size=tostring(r.size)
p[x].size=i(r.size)
p[x].remove=0
p[x].enable=false
end
@ -271,7 +281,7 @@ local dconf = "/etc/openclash/default.yaml"
sev = s:option(Value, "user")
sev.template = "cbi/tvalue"
sev.description = translate("You Can Modify config file Here, Except The Settings That Were Taken Over")
sev.rows = 20
sev.rows = 40
sev.wrap = "off"
sev.cfgvalue = function(self, section)
return NXFS.readfile(conf) or NXFS.readfile(dconf) or ""
@ -286,7 +296,7 @@ end
def = s:option(Value, "default")
def.template = "cbi/tvalue"
def.description = translate("Default Config File With Correct General-Settings")
def.rows = 20
def.rows = 40
def.wrap = "off"
def.readonly = true
def.cfgvalue = function(self, section)

View File

@ -45,7 +45,7 @@ o:value("0", translate("Not Set"))
o.default=0
o = s:taboption("settings", ListValue, "en_mode", font_red..bold_on..translate("Select Mode")..bold_off..font_off)
o.description = translate("Select Mode For OpenClash Work, Network Error Try Flush DNS Cache")
o.description = translate("Select Mode For OpenClash Work, Try Flush DNS Cache If Network Error")
o:value("redir-host", translate("redir-host"))
o:value("fake-ip", translate("fake-ip"))
o:value("redir-host-tun", translate("redir-host(tun mode)"))
@ -330,7 +330,7 @@ o.title = translate("Dashboard Port")
o.default = 9090
o.datatype = "port"
o.rmempty = false
o.description = translate("Dashboard Address Example:").." "..font_green..bold_on..lan_ip.."/openclash、"..lan_ip..':'..cn_port..'/ui'..bold_off..font_off
o.description = translate("Dashboard Address Example:").." "..font_green..bold_on..lan_ip.."/luci-static/openclash、"..lan_ip..':'..cn_port..'/ui'..bold_off..font_off
o = s:taboption("dashboard", Value, "dashboard_password")
o.title = translate("Dashboard Secret")

View File

@ -1,11 +1,17 @@
<fieldset class="cbi-section">
<table>
<tr><td width="25%"> Clash 核心发布: </td><td width="25%" align="left" id="_binupdate"><%:Collecting data...%></td><td width="25%"> OpenClash 客户端发布: </td><td width="25%" align="left" id="_openupdate"><%:Collecting data...%></td></tr>
<tr><td width="25%"> Clash 核心: Dreamacro </td><td width="25%" align="left" id="_Dreamacro"><%:Collecting data...%></td><td width="25%"> OpenClash 客户端: vernesong </td><td width="25%" align="left" id="_vernesong"><%:Collecting data...%></td></tr>
<tr><td width="25%"> Clash 客户端: frainzy1477 </td><td width="25%" align="left" id="_frainzy1477"><%:Collecting data...%></td><td width="25%"> MyIP: SukkaW </td><td width="25%" align="left" id="_SukkaW"><%:Collecting data...%></td></tr>
<tr><td width="25%"> 第三方规则: lhie1 </td><td width="25%" align="left" id="_lhie1_dev"><%:Collecting data...%></td><td width="25%"> 第三方规则: ConnersHua </td><td width="25%" align="left" id="_ConnersHua_dev"><%:Collecting data...%></td></tr>
<tr><td width="25%"> Yacd 控制面板: haishanh </td><td width="25%" align="left" id="_haishanh"><%:Collecting data...%></td><td width="25%"> GEOIP 数据库MaxMind </td><td width="25%" align="left" id="_MaxMind"><%:Collecting data...%></td></tr>
<tr><td width="25%"> 游戏规则: FQrabbit </td><td width="25%" align="left" id="_FQrabbit"><%:Collecting data...%></td><td width="25%"> 订阅APIFndroid </td><td width="25%" align="left" id="_Fndroid"><%:Collecting data...%></td></tr>
<tr>
<td width="10%" align="center" id="_Dreamacro"><%:Collecting data...%></td>
<td width="10%" align="center" id="_vernesong"><%:Collecting data...%></td>
<td width="10%" align="center" id="_frainzy1477"><%:Collecting data...%></td>
<td width="10%" align="center" id="_SukkaW"><%:Collecting data...%></td>
<td width="10%" align="center" id="_lhie1_dev"><%:Collecting data...%></td>
<td width="10%" align="center" id="_ConnersHua_dev"><%:Collecting data...%></td>
<td width="10%" align="center" id="_haishanh"><%:Collecting data...%></td>
<td width="10%" align="center" id="_MaxMind"><%:Collecting data...%></td>
<td width="10%" align="center" id="_FQrabbit"><%:Collecting data...%></td>
<td width="10%" align="center" id="_Fndroid"><%:Collecting data...%></td>
</tr>
</table>
</fieldset>
@ -18,23 +24,18 @@
var ConnersHua_dev = document.getElementById('_ConnersHua_dev');
var MaxMind = document.getElementById('_MaxMind');
var haishanh = document.getElementById('_haishanh');
var binupdate = document.getElementById('_binupdate');
var openupdate = document.getElementById('_openupdate');
var FQrabbit = document.getElementById('_FQrabbit');
var Fndroid = document.getElementById('_Fndroid');
var github = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABiCAMAAACRZYZ7AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3FpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTQyIDc5LjE2MDkyNCwgMjAxNy8wNy8xMy0wMTowNjozOSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo1Y2NjZGI4My1kMGJiLWExNDUtYmYyNy03ZmRkMTJmY2EwYTQiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6RENEOUYxRjE5RjJDMTFFOUEwNjVGMTc0MUI4MUNFQzgiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6RENEOUYxRjA5RjJDMTFFOUEwNjVGMTc0MUI4MUNFQzgiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChXaW5kb3dzKSI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOjVjY2NkYjgzLWQwYmItYTE0NS1iZjI3LTdmZGQxMmZjYTBhNCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo1Y2NjZGI4My1kMGJiLWExNDUtYmYyNy03ZmRkMTJmY2EwYTQiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz4s6CIvAAACdlBMVEX+/v78/PzExMT9/f35+fn19fX4+Pj6+vrX19fy8vL7+/sICAjr6+vq6urd3d3x8fFDQ0Obm5vw8PDc3Nz29vYoKCi5ubnn5+cPDw/h4eHY2NiOjo6Dg4NLS0vs7OxFRUXv7+/t7e3u7u4vLy8JCQkQEBANDQ0DAwMGBgYEBARpaWnBwcGvr6/39/fQ0NDNzc3IyMh8fHy7u7uEhISjo6MrKytgYGCGhoZ6enqZmZnS0tI0NDShoaGxsbFlZWUgICAWFhYlJSVMTEwsLCwKCgo6OjqUlJQcHBwaGhr09PQpKSldXV2fn5+4uLiQkJACAgLo6Ojp6elGRkba2tqWlpYBAQHZ2dmnp6fFxcWSkpKurq5KSkqysrI9PT0FBQWYmJhnZ2e9vb1zc3NERETz8/N4eHh+fn5mZmbHx8eIiIiKioq1tbVhYWGoqKhXV1cTExMeHh6srKxqamqLi4ukpKTb29sqKirCwsKmpqbOzs5aWlo8PDyMjIzV1dWdnZ2zs7OFhYXl5eUXFxd0dHQHBweenp7W1tZ9fX0iIiLg4OAtLS2NjY3AwMCgoKCJiYmwsLCPj4/U1NRWVlYRERFPT0+Hh4dsbGxvb2/Pz8/Dw8MdHR0uLi5NTU2+vr4fHx/R0dE5OTm/v7+ioqJQUFDGxsbJyckUFBTKyso2NjZRUVEZGRmtra3i4uImJiZSUlLe3t6CgoJUVFRtbW3Ly8sYGBjMzMwwMDDT09NJSUkkJCRISEi2trZkZGRBQUEMDAy6uro/Pz9/f39ra2sODg4nJycSEhJ7e3s7OzsVFRVycnIyMjJcXFxbW1t2dnYbGxv///8AAAD///9H5/bkAAAA0nRSTlP//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////wD8iKrvAAAFUElEQVR42qya90PbOBTHZRKTQQgBMgoByipll00H0E1bRhfr2l6v+7r3uLbXvXvd19t777333svqf3SpTRzbT4ptyd/fkJ7ex9iK9PSe0B2L8lxeVx//qKO4PdJ3qHhXbXzlloOi1bHIilFJxs2X92CgT1adimY7Awnc2JyFqare0RbjhbhfWVuDTTT54RaRAyKunI0taVZbOSNk44k/sGVV7y9jgKDBSdiW7tsp2IWMhrBtffaxLYjnCmbS1LB1yOm5mFFnCq1C7sUcyrUEQfdjLvX4zSHuVZhTh3LMIA2/YG5VlaWHlE/ATuhyOognCzujHDpE+NIhBv6ugQaR5mPHdMZFgWzCDupNMmQQO6pcEiSgt/nzrM2XF9r0r74hCCFot87iSUmS3Ld2WSXU3nInBjTpG/0AslVvIEiyShdbQUxbpFgL+uYdRshSff8bUlKebjPEmEc1Xq7vmW6ALNB3D0gpuZuVtpn/nHq7zhsMBt8vzOgu6uhTWvtFjWm9YU9GOsjXhqfLl7QqmPve4OkGJOmVGVvXE5mua1pmcNOrhbiMcY9PYlKm8VW6NZBc0MkG8Rv9XExBwAPgTDaIABz5VMhh7NB/AiEfJCGuSvgADn0T5avchUyBXV42yFLoqXscMgd2tbJB2qCnhxSISPoZCywMRPKULUNIYVYNG2QhwdViGfIgocfP9rpcBFcLpATER+gYkhgVIDiLJSCvw+ZnJGath962JyDXsVO/d8oLW5uAwE9yVuLQMeBuD0JhGM8FeCBhwiRG+aBtgsQleJadgurgcYkPcgI4vIHGIJgPEgQOr6Mf4Svkg5QCh/3oqFPLPH25D6HVoC3MBxEmGx0+jS45tSuqEPCb+A/NchriP2d0uBvB89siTsgSo8OfURU8ijn94avQJKencA5cQgib2Tt8kGyYDUMR0HaVD3IcOJyJJoK2Ij7INeBwBtoH2tr5IMXAYTEiHKU8PAzXCPD3GDoJIYU8EEIQuQYdgY0dPBBCIiuKYk6Fj/TIy4tchKivix1yDyHNKqI7RwlsxAyphs7mJ0KilwiQ86yMBwjOWhOQUVIozrgS+0m+mhIQoYrQsYTthf1KchW+G9VvJuF/YKCgOSRPG+Sjw6fEZMYM2/NYWE10FJUhrnnknEmJPUYJJX+ZqZwZt9KSPzYWMc80WpJq/GCqyYh89XeF1qLF4onL0zJCyyHlJ5MF6p6yLDFA1KV6egOmMwAFhul5qtlqRuLzZNP38ihxg9bsdq83jzoJBN+Fm2mLOXUqRFJLGQPKczcbTOctf6QREi5MDFWaJNwSp1I1S5Q6pLxWKo//0Gid5SKsuOYFqVe1STXNTi9T0IiVsNJlxuiTtJA8TY/8zIYD2EXyJxkwgRToc5CtqZ5v5fH9OusyMkRMz/jGkOjUxsTKHv+XtihKm8dPpS2luox54QLNR1amf48mPKNN4X3pIEdgGn0byHYNfaH8+fuBBhokNw3jcUKuXmpXuyvU4Lnx6vFYuvxElM54SyJVHdwpgzyr62IGHeIj109Sn+USR3BiSKGDclMqcfAT73+yl14425naGEUuyLF0JcB4yu5aHjvkt/TFzBXaROj6w1u83iHvs80v2oN0mpVlD5BGFdmCPGpeYI7aiShJkJNWSuWF52ClzQbkCWv1+DwQpK2xDAmVWL6+0GUYOmwVEkc2LmIE9SWwFdYgFQft3fZAe7UxwhVLkHrB9uWYnHiN+RTWnEc6y5iu+WwcTkbJtTTI9nGDyv0FzBeWysdekH2M0iBKor+iq5zr6hVq7Iw8t42+eDW9G5n6vGDi5H8BBgCTacDsFxo/3wAAAABJRU5ErkJggg=="
Dreamacro.innerHTML = '<img src="https://avatars3.githubusercontent.com/u/8615343?s=460&v=4" alt="Dreamacro" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return Dreamacro_rediret()" />';
vernesong.innerHTML = '<img src="https://avatars2.githubusercontent.com/u/42875168?s=460&v=4" alt="vernesong" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return vernesong_rediret()" />';
frainzy1477.innerHTML = '<img src="https://avatars2.githubusercontent.com/u/49537471?s=460&v=4" alt="frainzy1477" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return frainzy1477_rediret()" />';
SukkaW.innerHTML = '<img src="https://avatars0.githubusercontent.com/u/40715044?s=460&v=4" alt="SukkaW" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return SukkaW_rediret()" />';
lhie1_dev.innerHTML = '<img src="https://avatars0.githubusercontent.com/u/11873197?s=460&v=4" alt="lhie1" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return lhie1_rediret()" />';
ConnersHua_dev.innerHTML = '<img src="https://avatars1.githubusercontent.com/u/11730838?s=460&v=4" alt="ConnersHua" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return ConnersHua_rediret()" />';
MaxMind.innerHTML = '<img src="https://avatars3.githubusercontent.com/u/1181834?s=200&v=4" alt="MaxMind" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return MaxMind_rediret()" />';
haishanh.innerHTML = '<img src="https://avatars1.githubusercontent.com/u/1166872?s=460&v=4" alt="haishanh" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return haishanh_rediret()" />';
binupdate.innerHTML = '<img src="'+github+'" alt="binupdate" width="30" height="30" onclick="return binupdate_rediret()" />';
openupdate.innerHTML = '<img src="'+github+'" alt="openupdate" width="30" height="30" onclick="return openupdate_rediret()" />';
FQrabbit.innerHTML = '<img src="https://avatars1.githubusercontent.com/u/29931248?s=460&v=4" alt="FQrabbit" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return FQrabbit_rediret()" />';
Fndroid.innerHTML = '<img src="https://avatars0.githubusercontent.com/u/16091562?s=400&v=4" alt="Fndroid" width="30" onerror="return imgerrorfun(this,this.src)" onclick="return Fndroid_rediret()" />';
Dreamacro.innerHTML = '<img src="https://avatars3.githubusercontent.com/u/8615343?s=460&v=4" style="border-radius:50%;" title="Dreamacro" alt="Dreamacro" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return Dreamacro_rediret()" />';
vernesong.innerHTML = '<img src="https://avatars2.githubusercontent.com/u/42875168?s=460&v=4" style="border-radius:50%;" title="vernesong" alt="vernesong" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return vernesong_rediret()" />';
frainzy1477.innerHTML = '<img src="https://avatars2.githubusercontent.com/u/49537471?s=460&v=4" style="border-radius:50%;" title="frainzy1477" alt="frainzy1477" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return frainzy1477_rediret()" />';
SukkaW.innerHTML = '<img src="https://avatars0.githubusercontent.com/u/40715044?s=460&v=4" style="border-radius:50%;" title="SukkaW" alt="SukkaW" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return SukkaW_rediret()" />';
lhie1_dev.innerHTML = '<img src="https://avatars0.githubusercontent.com/u/11873197?s=460&v=4" style="border-radius:50%;" title="lhie1" alt="lhie1" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return lhie1_rediret()" />';
ConnersHua_dev.innerHTML = '<img src="https://avatars1.githubusercontent.com/u/11730838?s=460&v=4" style="border-radius:50%;" title="ConnersHua" alt="ConnersHua" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return ConnersHua_rediret()" />';
MaxMind.innerHTML = '<img src="https://avatars3.githubusercontent.com/u/1181834?s=200&v=4" style="border-radius:50%;" title="MaxMind" alt="MaxMind" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return MaxMind_rediret()" />';
haishanh.innerHTML = '<img src="https://avatars1.githubusercontent.com/u/1166872?s=460&v=4" style="border-radius:50%;" title="haishanh" alt="haishanh" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return haishanh_rediret()" />';
FQrabbit.innerHTML = '<img src="https://avatars1.githubusercontent.com/u/29931248?s=460&v=4" style="border-radius:50%;" title="FQrabbit" alt="FQrabbit" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return FQrabbit_rediret()" />';
Fndroid.innerHTML = '<img src="https://avatars0.githubusercontent.com/u/16091562?s=400&v=4" style="border-radius:50%;" title="Fndroid" alt="Fndroid" width="50" onerror="return imgerrorfun(this,this.src)" onclick="return Fndroid_rediret()" />';
function Dreamacro_rediret()
{
url1='https://github.com/Dreamacro';
@ -65,16 +66,6 @@
url6='https://github.com/ConnersHua';
window.open(url6);
}
function binupdate_rediret()
{
url7='https://github.com/vernesong/OpenClash/releases/tag/Clash';
window.open(url7);
}
function openupdate_rediret()
{
url8='https://github.com/vernesong/OpenClash/releases';
window.open(url8);
}
function MaxMind_rediret()
{
url9='https://dev.maxmind.com/geoip/geoip2/geolite2/';

View File

@ -214,7 +214,7 @@
})
},
getIpipnetIP: () => {
IP.get(`https://myip.ipip.net/?z=${random}`, 'text')
IP.get(`http://myip.ipip.net/?z=${random}`, 'text')
.then((resp) => {
let data = resp.data.replace('当前 IP', '').split(' 来自于:');
$$.getElementById('ip-ipipnet').innerHTML = `${data[0]}`;

File diff suppressed because one or more lines are too long

View File

@ -3,7 +3,7 @@ CKTIME=$(date "+%Y-%m-%d-%H")
LAST_OPVER="/tmp/clash_last_version"
version_url="https://raw.githubusercontent.com/vernesong/OpenClash/master/core_version"
if [ "$CKTIME" != "$(grep "CheckTime" $LAST_OPVER 2>/dev/null |awk -F ':' '{print $2}')" ]; then
curl -sL -m 10 --retry 2 "$version_url" -o $LAST_OPVER >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 "$version_url" -o $LAST_OPVER >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ "$(ls -l $LAST_OPVER 2>/dev/null |awk '{print int($5)}')" -gt 0 ]; then
echo "CheckTime:$CKTIME" >>$LAST_OPVER
else

View File

@ -16,12 +16,12 @@ config_download()
{
if [ "$URL_TYPE" == "v2rayn" ]; then
subscribe_url=`echo $subscribe_url |sed 's/{/%7B/g;s/}/%7D/g;s/:/%3A/g;s/\"/%22/g;s/,/%2C/g;s/?/%3F/g;s/=/%3D/g;s/&/%26/g;s/\//%2F/g'`
curl -sL -m 10 --retry 2 https://tgbot.lbyczf.com/v2rayn2clash?url="$subscribe_url" -o /tmp/config.yaml >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 https://tgbot.lbyczf.com/v2rayn2clash?url="$subscribe_url" -o /tmp/config.yaml >/dev/null 2>&1
elif [ "$URL_TYPE" == "surge" ]; then
subscribe_url=`echo $subscribe_url |sed 's/{/%7B/g;s/}/%7D/g;s/:/%3A/g;s/\"/%22/g;s/,/%2C/g;s/?/%3F/g;s/=/%3D/g;s/&/%26/g;s/\//%2F/g'`
curl -sL -m 10 --retry 2 https://tgbot.lbyczf.com/surge2clash?url="$subscribe_url" -o /tmp/config.yaml >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 https://tgbot.lbyczf.com/surge2clash?url="$subscribe_url" -o /tmp/config.yaml >/dev/null 2>&1
else
curl -sL -m 10 --retry 2 "$subscribe_url" -o /tmp/config.yaml >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 "$subscribe_url" -o /tmp/config.yaml >/dev/null 2>&1
fi
}
@ -145,7 +145,7 @@ sub_info_get()
config_download
if [ "$?" -eq "0" ] && [ "$(ls -l /tmp/config.yaml |awk '{print int($5/1024)}')" -ne 0 ]; then
if [ "$?" -eq "0" ] && [ -s "/tmp/config.yaml" ]; then
config_su_check
else
if pidof clash >/dev/null; then
@ -166,7 +166,7 @@ sub_info_get()
config_download
if [ "$?" -eq "0" ] && [ "$(ls -l /tmp/config.yaml |awk '{print int($5/1024)}')" -ne 0 ]; then
if [ "$?" -eq "0" ] && [ -s "/tmp/config.yaml" ]; then
config_su_check
else
change_dns

View File

@ -11,8 +11,8 @@ CPU_MODEL=$(uci get openclash.config.core_version 2>/dev/null)
if [ "$(/etc/openclash/clash -v 2>/dev/null |awk -F ' ' '{print $2}')" != "$(sed -n 1p /tmp/clash_last_version 2>/dev/null)" ] || [ -z "$(/etc/openclash/clash -v 2>/dev/null |awk -F ' ' '{print $2}')" ] || [ ! -f /etc/openclash/clash ]; then
if [ "$CPU_MODEL" != 0 ]; then
echo "开始下载 OpenClash 内核..." >$START_LOG
curl -sL -m 10 --retry 2 https://github.com/vernesong/OpenClash/releases/download/Clash/clash-"$CPU_MODEL".tar.gz -o /tmp/clash.tar.gz >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ "$(ls -l /tmp/clash.tar.gz |awk '{print int($5/1024)}')" -ne 0 ]; then
curl -sL --connect-timeout 10 --retry 2 https://github.com/vernesong/OpenClash/releases/download/Clash/clash-"$CPU_MODEL".tar.gz -o /tmp/clash.tar.gz >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ -s "/tmp/clash.tar.gz" ]; then
tar zxvf /tmp/clash.tar.gz -C /tmp >/dev/null 2>&1\
&& rm -rf /tmp/clash.tar.gz >/dev/null 2>&1\
&& chmod 4755 /tmp/clash\

View File

@ -12,7 +12,7 @@
LOGTIME=$(date "+%Y-%m-%d %H:%M:%S")
LOG_FILE="/tmp/openclash.log"
echo "开始下载【$RULE_FILE_NAME】规则..." >$START_LOG
curl -sL -m 10 --retry 2 https://raw.githubusercontent.com/FQrabbit/SSTap-Rule/master/rules/"$DOWNLOAD_PATH" -o "$TMP_RULE_DIR" >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 https://raw.githubusercontent.com/FQrabbit/SSTap-Rule/master/rules/"$DOWNLOAD_PATH" -o "$TMP_RULE_DIR" >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ "$(ls -l $TMP_RULE_DIR |awk '{print $5}')" -ne 0 ]; then
echo "$RULE_FILE_NAME】规则下载成功,检查规则版本是否更新..." >$START_LOG
cmp -s $TMP_RULE_DIR $RULE_FILE_DIR

View File

@ -8,7 +8,7 @@ SECRET=$(uci get openclash.config.dashboard_password 2>/dev/null)
LAN_IP=$(uci get network.lan.ipaddr 2>/dev/null |awk -F '/' '{print $1}' 2>/dev/null)
PORT=$(uci get openclash.config.cn_port 2>/dev/null)
curl -w %{http_code}"\n" -H "Authorization: Bearer ${SECRET}" -H "Content-Type:application/json" -X GET http://"$LAN_IP":"$PORT"/proxies > "$CURL_CACHE" 2>/dev/null
curl --connect-timeout 5 --retry 2 -w %{http_code}"\n" -H "Authorization: Bearer ${SECRET}" -H "Content-Type:application/json" -X GET http://"$LAN_IP":"$PORT"/proxies > "$CURL_CACHE" 2>/dev/null
if [ "$(sed -n '$p' "$CURL_CACHE")" -eq "200" ]; then
cat "$CURL_CACHE" |jsonfilter -e '@["proxies"][@.type="Selector"]["name"]' > "$CURL_GROUP_CACHE" 2>/dev/null
cat "$CURL_CACHE" |jsonfilter -e '@["proxies"][@.type="Selector"]["now"]' > "$CURL_NOW_CACHE" 2>/dev/null

View File

@ -5,11 +5,13 @@ SECRET=$(uci get openclash.config.dashboard_password 2>/dev/null)
LAN_IP=$(uci get network.lan.ipaddr 2>/dev/null |awk -F '/' '{print $1}' 2>/dev/null)
PORT=$(uci get openclash.config.cn_port 2>/dev/null)
if [ ! -z "$(grep "#*#" "$HISTORY_PATH")" ]; then
cat $HISTORY_PATH |while read line
do
GORUP_NAME=$(echo $line |awk -F '#*#' '{print $1}')
NOW_NAME=$(echo $line |awk -F '#*#' '{print $3}')
curl -H "Authorization: Bearer ${SECRET}" -H "Content-Type:application/json" -X PUT -d '{"name":"'"$NOW_NAME"'"}' http://"$LAN_IP":"$PORT"/proxies/"$GORUP_NAME" >/dev/null 2>&1
done
fi
cat $HISTORY_PATH |while read line
do
if [ -z "$(echo $line |grep "#*#")" ]; then
continue
else
GORUP_NAME=$(echo $line |awk -F '#*#' '{print $1}')
NOW_NAME=$(echo $line |awk -F '#*#' '{print $3}')
curl --connect-timeout 5 --retry 2 -H "Authorization: Bearer ${SECRET}" -H "Content-Type:application/json" -X PUT -d '{"name":"'"$NOW_NAME"'"}' http://"$LAN_IP":"$PORT"/proxies/"$GORUP_NAME" >/dev/null 2>&1
fi
done >/dev/null 2>&1

View File

@ -3,8 +3,8 @@
LOGTIME=$(date "+%Y-%m-%d %H:%M:%S")
LOG_FILE="/tmp/openclash.log"
echo "开始下载 GEOIP 数据库..." >$START_LOG
curl -sL -m 10 --retry 2 https://static.clash.to/GeoIP2/GeoIP2-Country.mmdb -o /tmp/Country.mmdb >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ "$(ls -l /tmp/Country.mmdb |awk '{print int($5/1024)}')" -ne 0 ]; then
curl -sL --connect-timeout 10 --retry 2 https://static.clash.to/GeoIP2/GeoIP2-Country.mmdb -o /tmp/Country.mmdb >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ -s "/tmp/Country.mmdb" ]; then
echo "GEOIP 数据库下载成功,检查数据库版本是否更新..." >$START_LOG
cmp -s /tmp/Country.mmdb /etc/openclash/Country.mmdb
if [ "$?" -ne "0" ]; then

View File

@ -6,16 +6,16 @@
rule_source=$(uci get openclash.config.rule_source 2>/dev/null)
echo "开始下载使用中的第三方规则..." >$START_LOG
if [ "$rule_source" = "lhie1" ]; then
curl -sL -m 10 --retry 2 https://raw.githubusercontent.com/lhie1/Rules/master/Clash/Rule.yml -o /tmp/rules.yaml >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 https://raw.githubusercontent.com/lhie1/Rules/master/Clash/Rule.yml -o /tmp/rules.yaml >/dev/null 2>&1
sed -i '1i Rule:' /tmp/rules.yaml
elif [ "$rule_source" = "ConnersHua" ]; then
curl -sL -m 10 --retry 2 https://raw.githubusercontent.com/ConnersHua/Profiles/master/Clash/Pro.yaml -o /tmp/rules.yaml >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 https://raw.githubusercontent.com/ConnersHua/Profiles/master/Clash/Pro.yaml -o /tmp/rules.yaml >/dev/null 2>&1
sed -i -n '/^Rule:/,$p' /tmp/rules.yaml
elif [ "$rule_source" = "ConnersHua_return" ]; then
curl -sL -m 10 --retry 2 https://raw.githubusercontent.com/ConnersHua/Profiles/master/Clash/BacktoCN.yaml -o /tmp/rules.yaml >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 https://raw.githubusercontent.com/ConnersHua/Profiles/master/Clash/BacktoCN.yaml -o /tmp/rules.yaml >/dev/null 2>&1
sed -i -n '/^Rule:/,$p' /tmp/rules.yaml
fi
if [ "$?" -eq "0" ] && [ "$rule_source" != 0 ] && [ "$(ls -l /tmp/rules.yaml |awk '{print int($5/1024)}')" -ne 0 ]; then
if [ "$?" -eq "0" ] && [ "$rule_source" != 0 ] && [ -s "/tmp/rules.yaml" ]; then
echo "下载成功,开始预处理规则文件..." >$START_LOG
sed -i "/^Rule:/a\##source:${rule_source}" /tmp/rules.yaml >/dev/null 2>&1
echo "检查下载的规则文件是否有更新..." >$START_LOG

View File

@ -10,8 +10,8 @@ LAST_OPVER="/tmp/openclash_last_version"
LAST_VER=$(sed -n 1p "$LAST_OPVER" 2>/dev/null |sed "s/^v//g")
if [ "$(sed -n 1p /etc/openclash/openclash_version 2>/dev/null)" != "$(sed -n 1p $LAST_OPVER 2>/dev/null)" ] && [ -f "$LAST_OPVER" ]; then
echo "开始下载 OpenClash-$LAST_VER ..." >$START_LOG
curl -sL -m 10 --retry 5 https://github.com/vernesong/OpenClash/releases/download/v"$LAST_VER"/luci-app-openclash_"$LAST_VER"_all.ipk -o /tmp/openclash.ipk >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ "$(ls -l /tmp/openclash.ipk |awk '{print int($5/1024)}')" -ne 0 ]; then
curl -sL --connect-timeout 10 --retry 5 https://github.com/vernesong/OpenClash/releases/download/v"$LAST_VER"/luci-app-openclash_"$LAST_VER"_all.ipk -o /tmp/openclash.ipk >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ -s "/tmp/openclash.ipk" ]; then
echo "OpenClash-$LAST_VER 下载成功,开始更新,更新过程请不要刷新页面和进行其他操作..." >$START_LOG
cat > /tmp/openclash_update.sh <<"EOF"
#!/bin/sh

View File

@ -3,7 +3,7 @@ CKTIME=$(date "+%Y-%m-%d-%H")
LAST_OPVER="/tmp/openclash_last_version"
version_url="https://raw.githubusercontent.com/vernesong/OpenClash/master/version"
if [ "$CKTIME" != "$(grep "CheckTime" $LAST_OPVER 2>/dev/null |awk -F ':' '{print $2}')" ]; then
curl -sL -m 10 --retry 2 "$version_url" -o $LAST_OPVER >/dev/null 2>&1
curl -sL --connect-timeout 10 --retry 2 "$version_url" -o $LAST_OPVER >/dev/null 2>&1
if [ "$?" -eq "0" ] && [ "$(ls -l $LAST_OPVER 2>/dev/null |awk '{print int($5)}')" -gt 0 ]; then
if [ "$(sed -n 1p /etc/openclash/openclash_version 2>/dev/null)" = "$(sed -n 1p $LAST_OPVER 2>/dev/null)" ]; then
sed -i "/^https:/i\CheckTime:${CKTIME}" "$LAST_OPVER" 2>/dev/null

View File

@ -8,9 +8,9 @@ servers_update=$(uci get openclash.config.servers_update 2>/dev/null)
servers_if_update=$(uci get openclash.config.servers_if_update 2>/dev/null)
rulesource=$(uci get openclash.config.rule_source 2>/dev/null)
CONFIG_FILE=$(uci get openclash.config.config_path 2>/dev/null)
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_FILE=$(uci get openclash.config.config_update_path 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo $UPDATE_CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo "$UPDATE_CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
if [ ! -z "$UPDATE_CONFIG_FILE" ]; then
CONFIG_FILE="$UPDATE_CONFIG_FILE"
@ -19,7 +19,7 @@ fi
if [ -z "$CONFIG_FILE" ]; then
CONFIG_FILE="/etc/openclash/config/$(ls -lt /etc/openclash/config/ | grep -E '.yaml|.yml' | head -n 1 |awk '{print $9}')"
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
fi
if [ -z "$CONFIG_NAME" ]; then
@ -27,12 +27,12 @@ if [ -z "$CONFIG_NAME" ]; then
CONFIG_NAME="config.yaml"
fi
BACKUP_FILE="/etc/openclash/backup/$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)"
BACKUP_FILE="/etc/openclash/backup/$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)"
if [ ! -s $CONFIG_FILE ] && [ ! -s $BACKUP_FILE ]; then
if [ ! -s "$CONFIG_FILE" ] && [ ! -s "$BACKUP_FILE" ]; then
exit 0
elif [ ! -s $CONFIG_FILE ] && [ -s $BACKUP_FILE ]; then
mv $BACKUP_FILE $CONFIG_FILE
elif [ ! -s "$CONFIG_FILE" ] && [ -s "$BACKUP_FILE" ]; then
mv "$BACKUP_FILE" "$CONFIG_FILE"
fi
echo "开始更新【$CONFIG_NAME】的策略组配置..." >$START_LOG

View File

@ -10,9 +10,9 @@ CONFIG_GROUP_FILE="/tmp/yaml_group.yaml"
CFG_FILE="/etc/config/openclash"
servers_update=$(uci get openclash.config.servers_update 2>/dev/null)
CONFIG_FILE=$(uci get openclash.config.config_path 2>/dev/null)
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_FILE=$(uci get openclash.config.config_update_path 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo $UPDATE_CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo "$UPDATE_CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
if [ ! -z "$UPDATE_CONFIG_FILE" ]; then
CONFIG_FILE="$UPDATE_CONFIG_FILE"
@ -21,7 +21,7 @@ fi
if [ -z "$CONFIG_FILE" ]; then
CONFIG_FILE="/etc/openclash/config/$(ls -lt /etc/openclash/config/ | grep -E '.yaml|.yml' | head -n 1 |awk '{print $9}')"
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
fi
if [ -z "$CONFIG_NAME" ]; then
@ -167,9 +167,9 @@ yml_groups_set()
#名字变化时处理规则部分
if [ "$name" != "$old_name" ] && [ ! -z "$old_name" ]; then
sed -i "s/,${old_name}/,${name}#d/g" $CONFIG_FILE 2>/dev/null
sed -i "s/:${old_name}$/:${name}#d/g" $CONFIG_FILE 2>/dev/null #修改第三方规则分组对应标签
sed -i "s/\'${old_name}\'/\'${name}\'/g" $CFG_FILE 2>/dev/null
sed -i "s/,${old_name}/,${name}#d/g" "$CONFIG_FILE" 2>/dev/null
sed -i "s/:${old_name}$/:${name}#d/g" "$CONFIG_FILE" 2>/dev/null #修改第三方规则分组对应标签
sed -i "s/\'${old_name}\'/\'${name}\'/g" "$CFG_FILE" 2>/dev/null
config_load "openclash"
fi
@ -223,7 +223,7 @@ if [ "$create_config" = "0" ] || [ "$servers_if_update" = "1" ] || [ ! -z "$if_g
fi
config_load "openclash"
config_foreach yml_groups_set "groups"
sed -i "s/#d//g" $CONFIG_FILE 2>/dev/null
sed -i "s/#d//g" "$CONFIG_FILE" 2>/dev/null
echo "配置文件【$CONFIG_NAME】的策略组写入完成!" >$START_LOG
fi
fi

View File

@ -4,9 +4,9 @@ status=$(ps|grep -c /usr/share/openclash/yml_proxys_get.sh)
START_LOG="/tmp/openclash_start.log"
CONFIG_FILE=$(uci get openclash.config.config_path 2>/dev/null)
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_FILE=$(uci get openclash.config.config_update_path 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo $UPDATE_CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo "$UPDATE_CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
if [ ! -z "$UPDATE_CONFIG_FILE" ]; then
CONFIG_FILE="$UPDATE_CONFIG_FILE"
@ -15,7 +15,7 @@ fi
if [ -z "$CONFIG_FILE" ]; then
CONFIG_FILE="/etc/openclash/config/$(ls -lt /etc/openclash/config/ | grep -E '.yaml|.yml' | head -n 1 |awk '{print $9}')"
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
fi
if [ -z "$CONFIG_NAME" ]; then
@ -23,12 +23,12 @@ if [ -z "$CONFIG_NAME" ]; then
CONFIG_NAME="config.yaml"
fi
BACKUP_FILE="/etc/openclash/backup/$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)"
BACKUP_FILE="/etc/openclash/backup/$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)"
if [ ! -s $CONFIG_FILE ] && [ ! -s $BACKUP_FILE ]; then
if [ ! -s "$CONFIG_FILE" ] && [ ! -s "$BACKUP_FILE" ]; then
exit 0
elif [ ! -s $CONFIG_FILE ] && [ -s $BACKUP_FILE ]; then
mv $BACKUP_FILE $CONFIG_FILE
elif [ ! -s "$CONFIG_FILE" ] && [ -s "$BACKUP_FILE" ]; then
mv "$BACKUP_FILE" "$CONFIG_FILE"
fi
#判断各个区位置

View File

@ -10,9 +10,9 @@ PROXY_PROVIDER_FILE="/tmp/yaml_provider.yaml"
servers_if_update=$(uci get openclash.config.servers_if_update 2>/dev/null)
config_auto_update=$(uci get openclash.config.auto_update 2>/dev/null)
CONFIG_FILE=$(uci get openclash.config.config_path 2>/dev/null)
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_FILE=$(uci get openclash.config.config_update_path 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo $UPDATE_CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
UPDATE_CONFIG_NAME=$(echo "$UPDATE_CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
if [ ! -z "$UPDATE_CONFIG_FILE" ]; then
CONFIG_FILE="$UPDATE_CONFIG_FILE"
@ -21,7 +21,7 @@ fi
if [ -z "$CONFIG_FILE" ]; then
CONFIG_FILE="/etc/openclash/config/$(ls -lt /etc/openclash/config/ | grep -E '.yaml|.yml' | head -n 1 |awk '{print $9}')"
CONFIG_NAME=$(echo $CONFIG_FILE |awk -F '/' '{print $5}' 2>/dev/null)
CONFIG_NAME=$(echo "$CONFIG_FILE" |awk -F '/' '{print $5}' 2>/dev/null)
fi
if [ -z "$CONFIG_NAME" ]; then

View File

@ -0,0 +1,755 @@
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: zh_Hans\n"
msgid "OpenClash"
msgstr "OpenClash"
msgid "A Clash Client For OpenWrt"
msgstr "一个运行在OpenWrt上的Clash客户端兼容Shadowsocks、Vmess、Snell等协议根据灵活的规则配置实现策略代理"
msgid "Global Settings(Will Modify The Config File Or Subscribe According To The Settings On This Page)"
msgstr "全局设置(将按照本页设置自动修改配置文件和获取订阅)"
msgid "Technical Support"
msgstr "技术支持"
msgid "Overviews"
msgstr "运行状态"
msgid "Global Settings"
msgstr "全局设置"
msgid "Game Rules and Groups"
msgstr "游戏规则与策略组管理"
msgid "General Settings"
msgstr "常规设置"
msgid "DNS Setting"
msgstr "DNS设置"
msgid "Config Update"
msgstr "配置文件订阅"
msgid "Rules Update"
msgstr "第三方规则订阅"
msgid "Dashboard Settings"
msgstr "外部控制"
msgid "GEOIP数据库订阅"
msgstr "外部控制"
msgid "Enable"
msgstr "启用"
msgid "Disable"
msgstr "停用"
msgid "RUNNING"
msgstr "运行中"
msgid "NOT RUNNING"
msgstr "未运行"
msgid "(Enable or Disable)"
msgstr "(仅添加选中的设置)"
msgid "Config Normal"
msgstr "检查通过"
msgid "File Not Exist"
msgstr "文件不存在"
msgid "Not Set"
msgstr "未设置"
msgid "Server logs"
msgstr "运行日志"
msgid "Logs"
msgstr "运行日志"
msgid "Enable Clash"
msgstr "启动 OpenClash"
msgid "Disable Clash"
msgstr "关闭 OpenClash"
msgid "Commit Configurations"
msgstr "保存配置"
msgid "Apply Configurations"
msgstr "应用配置"
msgid "Download Configurations"
msgstr "下载配置"
msgid "Select Mode"
msgstr "*运行模式"
msgid "redir-host"
msgstr "Redir-Host兼容模式"
msgid "fake-ip"
msgstr "Fake-IP增强模式"
msgid "redir-host(tun mode)"
msgstr "Redir-HostTUN模式【依赖kmod-tun】"
msgid "fake-ip(tun mode)"
msgstr "Fake-IPTUN模式【依赖kmod-tun】"
msgid "redir-host-vpn(game mode)"
msgstr "Redir-Host游戏模式【依赖kmod-tun】"
msgid "fake-ip-vpn(game mode)"
msgstr "Fake-IP游戏模式【依赖kmod-tun】"
msgid "Select Mode For OpenClash Work, Try Flush DNS Cache If Network Error"
msgstr "选择运行模式如客户端的网络异常请尝试清除DNS缓存"
msgid "Proxy Mode"
msgstr "*代理模式"
msgid "Select Proxy Mode"
msgstr "选择默认代理模式"
msgid "Rule Proxy Mode"
msgstr "Rule【策略代理】"
msgid "Global Proxy Mode"
msgstr "Global【全局代理需前往控制面板手动指定节点】"
msgid "Direct Proxy Mode"
msgstr "Direct【全局直连】"
msgid "Log Level"
msgstr "日志等级"
msgid "Info Mode"
msgstr "Info【信息】"
msgid "Warning Mode"
msgstr "Warning【警告】"
msgid "Error Mode"
msgstr "Error【错误】"
msgid "Debug Mode"
msgstr "Debug【调试】"
msgid "Silent Mode"
msgstr "Silent【静默】"
msgid "Select Core's Log Level"
msgstr "选择内核日志的默认输出模式"
msgid "Only intranet allowed"
msgstr "仅允许内网"
msgid "When enabled, the control panel and the connection broker port will not be accessible from the public network"
msgstr "启用后将禁止从公网访问控制面板和连接代理端口"
msgid "Redirect Local DNS Setting"
msgstr "*本地DNS劫持"
msgid "Set Local DNS Redirect"
msgstr "默认启用将自动设置Dnsmasq的上游服务器如和其他插件冲突可停用但须将OpenClash作为冲突插件的唯一上游服务器"
msgid "Disable Dnsmasq's DNS Cache"
msgstr "禁止Dnsmasq缓存DNS"
msgid "Recommended Enabled For Avoiding Some Connection Errors"
msgstr "推荐启用,防止因缓存造成连接错误"
msgid "(Maybe Incompatible For Your Firmware)"
msgstr "(部分固件可能不兼容)"
msgid "Custom DNS Setting"
msgstr "自定义上游DNS服务器"
msgid "Use Custom Rules"
msgstr "启用后将把自定义规则增加到配置文件并优先匹配,规则请到下方文本框编辑"
msgid "Add Custom DNS Servers"
msgstr "设置自定义上游DNS服务器"
msgid "(Take Effect After Choose Above)"
msgstr "在上方DNS设置中启用本功能后生效"
msgid "Advanced Setting"
msgstr "高级设置"
msgid "DNS Advanced Settings"
msgstr "DNS高级设置"
msgid "(Please Don't Modify it at Will)"
msgstr "(如您不知道选项有何用,请不要随意修改)"
msgid "Specify DNS Server"
msgstr "Fake-IP模式黑名单DNS服务器"
msgid "Specify DNS Server For List, Only One IP Server Address Support"
msgstr "指定下方列表中域名的DNS服务器只支持填写一个IP地址"
msgid "Domain Names In The List Do Not Return Fake-IP, One rule per line"
msgstr "每行请只填写一个域名列表中的域名在Fake-IP模式下查询DNS时将返回真实IP地址更改后点击上方按钮生效"
msgid "Fake-IP Block List Update"
msgstr "更新Fake-IP域名黑名单"
msgid "Set OpenClash Upstream DNS Resolve Server"
msgstr "启用将覆盖配置文件内的设置,请先在下方配置好服务器"
msgid "DNS Server Group"
msgstr "服务器分组"
msgid "(NameServer Group Must Be Set)"
msgstr "(NameServer 组必须设置)"
msgid "DNS Server Address"
msgstr "服务器地址"
msgid "(Do Not Add Type Ahead)"
msgstr "(请勿添加类型前缀)"
msgid "DNS Server Port"
msgstr "服务器端口"
msgid "(Require When Use Non-Standard Port)"
msgstr "(使用非标准端口时必须填写)"
msgid "DNS Server Type"
msgstr "服务器类型"
msgid "(Communication protocol)"
msgstr "(通讯协议)"
msgid "Enable ipv6 Resolve"
msgstr "IPV6类型DNS解析"
msgid "Force Enable to Resolve ipv6 DNS Requests"
msgstr ""
"固件须配置好IPV6的NAT如你不使用IPV6请关闭固件的相关服务避免客户端连接出现异常"
msgid "Rules Setting"
msgstr "规则设置(访问控制)"
msgid "Server Config"
msgstr "配置文件管理"
msgid "Upload File Type"
msgstr "上传文件类型"
msgid "Proxy Provider File"
msgstr "代理集文件"
msgid "Upload"
msgstr "上传"
msgid "File saved to"
msgstr "文件已成功上传到"
msgid "upload file error."
msgstr "文件上传失败"
msgid "No specify upload file."
msgstr "未指定上传文件"
msgid ""
"Only Support yaml what would be save to /etc/openclash/"
msgstr "注意只支持【yaml】后缀的文件文件将被保存到 /etc/openclash/"
msgid "Proxy Provider File List"
msgstr "代理集文件列表"
msgid "Please Make Sure Ports Available"
msgstr "请确保端口可用"
msgid "Update Subcription"
msgstr "更新订阅配置"
msgid "Update time (every day)"
msgstr "更新时间(每天)"
msgid "Auto Update"
msgstr "自动更新"
msgid "Check And Update"
msgstr "检查并更新"
msgid "After clash start running, wait a moment for servers to resolve,enjoy"
msgstr "运行后,请等待服务器上线"
msgid "Redir Port"
msgstr "流量转发端口"
msgid "SOCKS5 Port"
msgstr "SOCKS5 代理端口"
msgid "HTTP(S) Port"
msgstr "HTTP(S) 代理端口"
msgid "Set Authentication of SOCKS5/HTTP(S)"
msgstr "设置SOCKS5/HTTP(S)认证信息"
msgid "Not Null"
msgstr "空值无效"
msgid "Server Subscription Address"
msgstr "配置文件订阅地址"
msgid "Auto Update Server subscription"
msgstr "自动更新配置文件"
msgid "You Can Modify config file Here, Except The Settings That Were Taken Over"
msgstr "您可以在下方直接修改配置文件, 仅支持未被接管的设置"
msgid "Default Config File With Correct General-Settings"
msgstr "参考配置文件,方便您查询各项参数注释和正确的设置、顺序"
msgid "Dashboard Secret"
msgstr "管理页面登录密钥"
msgid "Set Dashboard Secret"
msgstr "设置您的管理页面登录密钥"
msgid "Dashboard Address Example:"
msgstr "管理页面地址示例:"
msgid "Dashboard Port"
msgstr "管理页面端口"
msgid "GEOIP Update"
msgstr "GEOIP数据库订阅"
msgid "Auto Update GEOIP Database"
msgstr "自动更新GEOIP数据库"
msgid "Update GEOIP Database"
msgstr "更新GEOIP数据库"
msgid "Other Rules Update(Only in Use)"
msgstr "正在使用第三方规则时才能更新"
msgid "Enable Other Rules"
msgstr "第三方规则"
msgid "Use Other Rules"
msgstr "选择并启用第三方规则后将覆盖配置文件内的所有规则 (不包括自定义规则)"
msgid "Disable Other Rules"
msgstr "不使用第三方规则"
msgid "lhie1 Rules"
msgstr "lhie1 规则"
msgid "ConnersHua Rules"
msgstr "ConnersHua 规则"
msgid "ConnersHua Return Rules"
msgstr "ConnersHua 回国规则"
msgid "Auto Update Other Rules"
msgstr "正在使用第三方规则时更新设置才会生效"
msgid "Update Time (Every Week)"
msgstr "更新时间(每周)"
msgid "Every Day"
msgstr "每天"
msgid "Every Monday"
msgstr "每周一"
msgid "Every Tuesday"
msgstr "每周二"
msgid "Every Wednesday"
msgstr "每周三"
msgid "Every Thursday"
msgstr "每周四"
msgid "Every Friday"
msgstr "每周五"
msgid "Every Saturday"
msgstr "每周六"
msgid "Every Sunday"
msgstr "每周日"
msgid "Update Other Rules"
msgstr "更新第三方规则"
msgid "GlobalTV"
msgstr "国际流媒体流量"
msgid "AsianTV"
msgstr "亚洲流媒体流量"
msgid "Proxy"
msgstr "必须代理的流量"
msgid "Apple"
msgstr "苹果服务流量"
msgid "Netease Music"
msgstr "网易云音乐流量"
msgid "Speedtest"
msgstr "测速流量"
msgid "Telegram"
msgstr "Telegram流量"
msgid "AdBlock"
msgstr "广告流量"
msgid "Domestic"
msgstr "国内流量"
msgid "Others"
msgstr "未匹配到规则的流量"
msgid "Choose Proxy Group, Base On Your Servers Group in config.yaml"
msgstr "指定流量(策略)的代理方式,只支持选择(服务器组),信息来源于您的配置文件"
msgid "Custom Clash Rules"
msgstr "自定义规则(访问控制)"
msgid "Custom Rules Here, For More Go Github:https://github.com/Dreamacro/clash/blob/master/README.md, IP To CIDR: http://ip2cidr.com"
msgstr "设置自定义规则详细信息请前往Github( https://github.com/Dreamacro/clash/blob/master/README.md )查询在线IP段转CIDR地址http://ip2cidr.com"
msgid "Custom Hosts Here, For More Go Github:https://github.com/Dreamacro/clash/blob/master/README.md"
msgstr "设置自定义Hosts详细信息请前往Github( https://github.com/Dreamacro/clash/blob/master/README.md )查询"
msgid "Set Custom Rules"
msgstr "设置自定义规则(在上方规则设置中启用本功能后生效)"
msgid "Set Custom Hosts, Only Work with Redir-Host Mode"
msgstr "设置自定义Hosts仅在Redir-Host模式下生效不会覆盖配置文件设置"
msgid "Version Update"
msgstr "版本更新"
msgid "CPU Model"
msgstr "处理器架构"
msgid "Model Not Found"
msgstr "处理器架构识别失败"
msgid "Current Core Version"
msgstr "当前内核版本"
msgid "Last Core Version"
msgstr "最新内核版本"
msgid "Unknown"
msgstr "查询失败"
msgid "<New>"
msgstr "<可更新>"
msgid "Chose to Download"
msgstr "*选择内核编译版本"
msgid "Select Based On Your CPU Model For Core Update, Wrong Version Will Not Work"
msgstr "请根据处理器架构选择以便下载、更新对应内核,错误的版本将不能正常运行"
msgid "Update Core File"
msgstr "更新内核"
msgid "Download Form https://github.com/vernesong/OpenClash/releases/tag/Clash If Fail"
msgstr ""
"如下载失败可前往 https://github.com/vernesong/OpenClash/releases/tag/Clash 手动下载并上传"
msgid "Last OpenClash Version"
msgstr "最新客户端版本"
msgid "Current OpenClash Version"
msgstr "当前客户端版本"
msgid "Update OpenClash"
msgstr "更新客户端"
msgid "Only For IPK Install Type Or Not Release Memory"
msgstr ""
"只支持通过IPK安装的版本进行更新因为随系统编译的版本更新后不会释放旧版本的闪存空间"
msgid "Severs and Groups"
msgstr "服务器与策略组管理"
msgid "Load Config"
msgstr "读取配置"
msgid "Delete Unused Servers"
msgstr "删除未启用节点"
msgid "Delete Severs"
msgstr "清空服务器配置"
msgid "Delete Proxy Provider"
msgstr "清空代理集配置"
msgid "Delete Groups"
msgstr "清空策略组配置"
msgid "Back Configurations"
msgstr "返回概览"
msgid "Servers manage and Config create"
msgstr "服务器&策略组管理(支持配置文件一键生成)"
msgid "Keep Settings"
msgstr "保留配置"
msgid "Only Update Servers Below When Subscription"
msgstr "订阅时仅更新节点和代理集,保留下方策略组设置,不修改顺序"
msgid "New Servers Group"
msgstr "新节点默认策略组"
msgid "Set The New Subscribe Server's Default Proxy Groups"
msgstr "选择符合订阅要求的新节点的默认策略组(请勿重复添加)"
msgid "Choose Template For Create Config"
msgstr "选择配置文件模板"
msgid "Use Other Rules To Create Config"
msgstr "使用第三方规则快速创建配置文件(创建后可在全局设置页面调整参数)"
msgid "Disable Create Config"
msgstr "只更新配置文件服务器节点信息"
msgid "Type"
msgstr "节点类型"
msgid "Server Alias"
msgstr "别名(请勿重名)"
msgid "Server Address"
msgstr "服务器地址"
msgid "Server Port"
msgstr "服务器端口"
msgid "Ping Latency"
msgstr "服务器延迟"
msgid "Edit Server"
msgstr "编辑服务器配置"
msgid "Server Node Type"
msgstr "服务器节点类型"
msgid "Using incorrect encryption mothod may causes service fail to start"
msgstr "输入不正确的参数组合可能会导致服务无法启动"
msgid "Password"
msgstr "密码"
msgid "Encrypt Method"
msgstr "加密方式"
msgid "UDP Enable"
msgstr "UDP支持"
msgid "obfs-mode"
msgstr "传输协议"
msgid "obfs-hosts"
msgstr "混淆参数HOST"
msgid "Auth Username"
msgstr "登录用户名"
msgid "Auth Password"
msgstr "登录密码"
msgid "None"
msgstr "未配置"
msgid "Create Config"
msgstr "一键生成配置文件"
msgid "Create Config By One-Click Only Need Proxys"
msgstr "一键生成配置文件功能只需要配置服务器节点信息或代理集信息"
msgid "Proxy Groups(No Need Set when Config Create)"
msgstr "策略组配置(使用一键生成配置文件功能时无需设置)"
msgid "Proxys"
msgstr "服务器节点配置"
msgid "Edit Group"
msgstr "编辑策略组配置"
msgid "Group Type"
msgstr "策略组类型"
msgid "Choose The Operation Mode"
msgstr "设置策略组挑选服务器节点的工作方式"
msgid "Group Name"
msgstr "别名(请勿重名)"
msgid "Test URL"
msgstr "检测地址URL"
msgid "Test Interval(s)"
msgstr "检测频率(秒)"
msgid "Select"
msgstr "Select【手动选择】"
msgid "URL-Test"
msgstr "URL-Test【最低延迟】"
msgid "Fallback"
msgstr "Fallback【故障切换】"
msgid "Load-Balance"
msgstr "Load-Balance【负载均衡】"
msgid "Other Group"
msgstr "包含其他策略组(请勿重复添加)"
msgid "The Added Proxy Groups Must Exist Except 'DIRECT' & 'REJECT'"
msgstr "注意:除'DIRECT'和'REJECT'外,修改配置文件前添加的其他策略组必须已创建"
msgid "The Added Proxy Provider Must Exist"
msgstr "修改配置文件前添加的代理集必须已创建"
msgid "Proxy Group"
msgstr "添加到策略组(请勿重复添加)"
msgid "No Need Set when Config Create, The added Proxy Groups Must Exist"
msgstr "注意:使用一键生成配置文件功能时无需设置此项,修改配置文件前添加的策略组必须已创建"
msgid "Clean Log"
msgstr "清理日志"
msgid "Refresh Log"
msgstr "刷新日志"
msgid "Config File"
msgstr "配置文件"
msgid "State"
msgstr "状态"
msgid "Update Time"
msgstr "更新时间"
msgid "File Name"
msgstr "文件名"
msgid "Switch Config"
msgstr "切换"
msgid "Size"
msgstr "文件大小"
msgid "Remove"
msgstr "移除"
msgid "(Enable or Disable Subscribe)"
msgstr "(启用或禁用更新)"
msgid "Config Alias"
msgstr "配置文件名"
msgid "(Name For Distinguishing)"
msgstr "(用于区分,请勿重名)"
msgid "Subscribe Address"
msgstr "订阅地址"
msgid "Subscribe Type"
msgstr "订阅地址类型"
msgid "(Power By fndroid)"
msgstr "API提供Fndroid"
msgid "(Not Null)"
msgstr "(空值无效)"
msgid "Keyword Match"
msgstr "筛选节点"
msgid "(eg: hk or tw&bgp)"
msgstr "(格式示例:香港、台湾&bgp"
msgid "Config File List"
msgstr "配置文件列表"
msgid "Use For All Config File"
msgstr "添加到所有配置文件"
msgid "Proxy-Provider"
msgstr "代理集配置"
msgid "Edit Proxy-Provider"
msgstr "编辑代理集配置"
msgid "Provider Type"
msgstr "代理集类型
msgid "Choose The Provider Type"
msgstr "选择代理集的类型"
msgid "Provider Name"
msgstr "代理集别名(请勿重名)"
msgid "Provider Path"
msgstr "代理集路径Path"
msgid "Update Your Proxy Provider File From Config Luci Page"
msgstr "请先在配置文件管理页面上传您的代理集文件"
msgid "Provider URL"
msgstr "代理集URL"
msgid "Provider Interval(s)"
msgstr "代理集更新间隔s"
msgid "Provider Health Check"
msgstr "代理集状态检查"
msgid "Health Check URL"
msgstr "状态检查URL"
msgid "Health Check Interval(s)"
msgstr "状态检查间隔s"
msgid "Game Rule's Name"
msgstr "选择游戏规则"
msgid "Select Proxy Group"
msgstr "选择策略组"
msgid "Game Rules List"
msgstr "游戏规则列表"
msgid "Rule Name"
msgstr "规则名称"
msgid "Download Rule"
msgstr "下载规则"
msgid "Exist"
msgstr "已下载"
msgid "Not Exist"
msgstr "未下载"
msgid "Order Number"
msgstr "序号"

File diff suppressed because it is too large Load Diff