diff --git a/UnblockNeteaseMusic/Makefile b/UnblockNeteaseMusic/Makefile index 5a0df9845fc..6dea7edd084 100644 --- a/UnblockNeteaseMusic/Makefile +++ b/UnblockNeteaseMusic/Makefile @@ -6,12 +6,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=UnblockNeteaseMusic PKG_BASE_VERSION:=0.27.0-rc.4 -PKG_RELEASE:=102 +PKG_RELEASE:=103 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/UnblockNeteaseMusic/server.git PKG_SOURCE_DATE:=2021-12-21 -PKG_SOURCE_VERSION:=027e0df75eda788b7de9ddf1467040b635a3e3c8 +PKG_SOURCE_VERSION:=55c53cf9e5ac176e8cd171b0ca0b3a0b50d614f6 PKG_MIRROR_HASH:=skip PKG_VERSION:=$(PKG_BASE_VERSION)-$(PKG_SOURCE_DATE)-$(call version_abbrev,$(PKG_SOURCE_VERSION)) diff --git a/luci-app-gpsysupgrade/root/etc/hotplug.d/online/51-opkg-upgrade b/luci-app-gpsysupgrade/root/etc/hotplug.d/online/51-opkg-upgrade index 36281ba55cf..7913f876b92 100644 --- a/luci-app-gpsysupgrade/root/etc/hotplug.d/online/51-opkg-upgrade +++ b/luci-app-gpsysupgrade/root/etc/hotplug.d/online/51-opkg-upgrade @@ -1,4 +1,4 @@ -if lock -n /var/lock/opkg-upgrade && opkg update; then +if [ "$(uci -q get wizard.default.autoupgrade_pkg)" != '0' ] && lock -n /var/lock/opkg-upgrade && opkg update; then . /etc/profile.d/opkg.sh opkg upgr 2>&1 | logger -t opkg fi diff --git a/luci-app-serverchan/luasrc/model/cbi/serverchan/advanced.lua b/luci-app-serverchan/luasrc/model/cbi/serverchan/advanced.lua index 2e3edf339b2..97f4aa5a719 100644 --- a/luci-app-serverchan/luasrc/model/cbi/serverchan/advanced.lua +++ b/luci-app-serverchan/luasrc/model/cbi/serverchan/advanced.lua @@ -70,7 +70,7 @@ a.description = translate("请确认脚本可以正常运行,否则可能造 a=s:option(Flag,"err_sheep_enable",translate("仅在免打扰时段重拨")) a.default=0 a.rmempty=true -a.description = translate("避免白天重拨 ddns 域名等待解析,此功能不影响断网检测
因夜间跑流量问题,该功能可能不稳定") +a.description = translate("避免白天重拨 DDNS 域名等待解析,此功能不影响断网检测
因夜间跑流量问题,该功能可能不稳定") a:depends({err_enable="1"}) a= s:option(DynamicList, "err_device_aliases", translate("关注列表")) @@ -109,11 +109,11 @@ a.datatype="uinteger" a:depends({system_time_event="2"}) a.description = translate("单位为小时") -a=s:option(Flag,"public_ip_event",translate("重拨尝试获取公网 ip")) +a=s:option(Flag,"public_ip_event",translate("重拨尝试获取公网 IP")) a.default=0 a.rmempty=true a:depends({err_enable="1"}) -a.description = translate("重拨时不会推送 ip 变动通知,并会导致你的域名无法及时更新 ip 地址
请确认你可以通过重拨获取公网 ip,否则这不仅徒劳无功还会引起频繁断网
移动等大内网你就别挣扎了!!") +a.description = translate("重拨时不会推送 IP 变动通知,并会导致你的域名无法及时更新 IP 地址
请确认你可以通过重拨获取公网 IP,否则这不仅徒劳无功还会引起频繁断网
移动等大内网你就别挣扎了!!") a= s:option(Value, "public_ip_retry_count", "当天最大重试次数") a.rmempty = true diff --git a/luci-app-serverchan/luasrc/model/cbi/serverchan/setting.lua b/luci-app-serverchan/luasrc/model/cbi/serverchan/setting.lua index 74ffc7a42cb..9deb71bd26a 100644 --- a/luci-app-serverchan/luasrc/model/cbi/serverchan/setting.lua +++ b/luci-app-serverchan/luasrc/model/cbi/serverchan/setting.lua @@ -9,7 +9,7 @@ local ifaces = sys.net:devices() m=Map("serverchan",translate("ServerChan"), translate("「Server酱」,英文名「ServerChan」,是一款从服务器推送报警信息和日志到微信的工具。

如果你在使用中遇到问题,请到这里提交:") .. [[]] -.. translate("github 项目地址") +.. translate("GitHub 项目地址") .. [[]] ) @@ -132,7 +132,7 @@ a:value("",translate("关闭")) a:value("1",translate("简化版")) a:value("2",translate("完整版")) a:value("3",translate("网络查询")) -a.description = translate("需下载 4.36m 原始数据,处理后完整版约 1.2M,简化版约 250kb
若无梯子,请勿使用网络查询") +a.description = translate("需下载 4.36 MB 原始数据,处理后完整版约 1.2 MB,简化版约 250 kB
若无梯子,请勿使用网络查询") a=s:taboption("basic", Flag,"oui_dir",translate("下载到内存")) a.rmempty = true @@ -151,7 +151,7 @@ a.rmempty = true a.description = translate("
请输入设备 MAC 和设备别名,用“-”隔开,如:
XX:XX:XX:XX:XX:XX-我的手机") --设备状态 -a=s:taboption("content", ListValue,"serverchan_ipv4",translate("ipv4 变动通知")) +a=s:taboption("content", ListValue,"serverchan_ipv4",translate("IPv4 变动通知")) a.rmempty = true a.default="" a:value("",translate("关闭")) @@ -174,7 +174,7 @@ for _, iface in ipairs(ifaces) do end a.description = translate("
一般选择 wan 接口,多拨环境请自行选择") -a=s:taboption("content", TextValue, "ipv4_list", translate("ipv4 api列表")) +a=s:taboption("content", TextValue, "ipv4_list", translate("IPv4 API列表")) a.optional = false a.rows = 8 a.wrap = "soft" @@ -187,7 +187,7 @@ end a.description = translate("
会因服务器稳定性、连接频繁等原因导致获取失败
如接口可以正常获取 IP,不推荐使用
从以上列表中随机地址访问") a:depends({serverchan_ipv4="2"}) -a=s:taboption("content", ListValue,"serverchan_ipv6",translate("ipv6 变动通知")) +a=s:taboption("content", ListValue,"serverchan_ipv6",translate("IPv6 变动通知")) a.rmempty = true a.default="disable" a:value("0",translate("关闭")) @@ -210,7 +210,7 @@ for _, iface in ipairs(ifaces) do end a.description = translate("
一般选择 wan 接口,多拨环境请自行选择") -a=s:taboption("content", TextValue, "ipv6_list", translate("ipv6 api列表")) +a=s:taboption("content", TextValue, "ipv6_list", translate("IPv6 API列表")) a.optional = false a.rows = 8 a.wrap = "soft" diff --git a/luci-app-serverchan/root/usr/bin/serverchan/api/ipv4.list b/luci-app-serverchan/root/usr/bin/serverchan/api/ipv4.list index 158e572504e..7798e45188e 100644 --- a/luci-app-serverchan/root/usr/bin/serverchan/api/ipv4.list +++ b/luci-app-serverchan/root/usr/bin/serverchan/api/ipv4.list @@ -1,5 +1,5 @@ www.cip.cc ifcfg.cn -speed.neu.edu.cn/getIP.php ddns.oray.com/checkip www.net.cn/static/customercare/yourip.asp +myip.ipip.net/s diff --git a/luci-app-serverchan/root/usr/bin/serverchan/serverchan b/luci-app-serverchan/root/usr/bin/serverchan/serverchan index 06ddfcd20b3..62e5601de32 100755 --- a/luci-app-serverchan/root/usr/bin/serverchan/serverchan +++ b/luci-app-serverchan/root/usr/bin/serverchan/serverchan @@ -68,7 +68,7 @@ function serverchan_init(){ [ ! -f "/usr/sbin/wrtbwmon" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】未安装 wrtbwmon ,流量统计不可用" >> ${logfile} [ -z "$ip_version" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】无法获取依赖项 iputils-arping 版本号,请确认插件是否正常运行" >> ${logfile} [ -z "$cu_version" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】无法获取依赖项 curl 版本号,请确认插件是否正常运行" >> ${logfile} - [ -z "${sckey}${tg_token}${pushplus_token}${corpid}${wxpusher_apptoken}${wxpusher_uids}${wxpusher_topicIds}" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】请填写正确的 key " >> ${logfile} && return 1 + [ -z "${sckey}${tg_token}${pushplus_token}${corpid}${wxpusher_apptoken}${wxpusher_uids}${wxpusher_topicIds}" -a "${jsonpath}" != "/usr/bin/serverchan/api/diy.json" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】请填写正确的 key " >> ${logfile} && return 1 local interfacelist=`getinterfacelist` && [ -z "$interfacelist" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】无法正确获取接口信息,请确认插件是否正常运行" >> ${logfile} return 0 } @@ -81,12 +81,12 @@ function diy_send(){ local data=`/usr/bin/jq -r '.data' ${3}` && local data=`eval echo ${data}` local content_type=`/usr/bin/jq -r '.content_type' ${3}` /usr/bin/jq ".type + $type" ${jsonpath} > ${tempjsonpath} - + /usr/bin/jq -r '.[]' ${tempjsonpath}|grep -w "null" && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】参数值错误,请检查设置项 `/usr/bin/jq -r '.' ${tempjsonpath}|grep "null"`" >> ${logfile} && return 1 [ -f ${tempjsonpath} ] && local logrow=$(grep -c "" ${tempjsonpath}) || local logrow="0" [ $logrow -eq "0" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】json 文件生成失败,请检查文件格式" >> ${logfile} && return 1 /usr/bin/jq -r '.[]' ${tempjsonpath}|grep "null" && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】参数变量生成失败,请检查设置项 `/usr/bin/jq -r '.' ${tempjsonpath}|grep "null"`" >> ${logfile} - + curl -X POST -H "$content_type" -d "${data}" "${diyurl}" } @@ -101,7 +101,7 @@ function down_oui(){ cat ${dir}oui.txt|grep "base 16"|grep -i "apple\|aruba\|asus\|autelan\|belkin\|bhu\|buffalo\|cctf\|cisco\|comba\|datang\|dell\|dlink\|dowell\|ericsson\|fast\|feixun\|\ fiberhome\|fujitsu\|grentech\|h3c\|hisense\|hiwifi\|honghai\|honghao\|hp\|htc\|huawei\|intel\|jinli\|jse\|lenovo\|lg\|liteon\|malata\|meizu\|mercury\|meru\|moto\|netcore\|\ netgear\|nokia\|omron\|oneplus\|oppo\|philips\|router_unkown\|samsung\|shanzhai\|sony\|start_net\|sunyuanda\|tcl\|tenda\|texas\|tianyu\|tp-link\|ubq\|undefine\|VMware\|\ -utstarcom\|volans\|xerox\|xiaomi\|zdc\|zhongxing\|smartisan" > ${oui_base} && echo "`date "+%Y-%m-%d %H:%M:%S"` 【初始化】设备MAC厂商信息下载成功" >> ${logfile} || echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】设备MAC厂商信息下载失败" >> ${logfile} +utstarcom\|volans\|xerox\|xiaomi\|zdc\|zhongxing\|smartisan" > ${oui_base} && echo "`date "+%Y-%m-%d %H:%M:%S"` 【初始化】设备MAC厂商信息下载成功" >> ${logfile} || echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】设备MAC厂商信息下载失败" >> ${logfile} fi if [ -f ${dir}oui.txt ] && [ "$oui_data" -eq "2" ]; then cat ${dir}oui.txt|grep "base 16" > ${oui_base} && echo "`date "+%Y-%m-%d %H:%M:%S"` 【初始化】设备MAC厂商信息下载成功" >> ${logfile} || echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】设备MAC厂商信息下载失败" >> ${logfile} @@ -143,8 +143,8 @@ function getip(){ echo $hostIP|grep -oE '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'|head -n1 } local hostIP=`get_hostipv4` - [ -z "$hostIP" ] && local hostIP=`get_hostipv4` - [ -z "$hostIP" ] && local hostIP=`get_hostipv4` + [ -z "$hostIP" ] && sleep 1 && local hostIP=`get_hostipv4` + [ -z "$hostIP" ] && sleep 1 && local hostIP=`get_hostipv4` echo $hostIP # 重试,偷懒,有空再优化 elif [ $1 == "wanipv6" ] ;then [ ! -z "$ipv6_interface" ] && local wanIPv6=$(ip addr show ${ipv6_interface}|grep -v deprecated|grep -A1 'inet6 [^f:]'|sed -nr ':a;N;s#^ +inet6 ([a-f0-9:]+)/.+? scope global .*? valid_lft ([0-9]+sec) .*#\2 \1#p;ta'|sort -nr|head -n1|awk '{print $2}') @@ -159,8 +159,8 @@ function getip(){ echo $hostIPv6|grep -oE '([\da-fA-F0-9]{1,4}(:{1,2})){1,15}[\da-fA-F0-9]{1,4}'|head -n1 } local hostIPv6=`get_hostipv6` - [ -z "$hostIPv6" ] && local hostIPv6=`get_hostipv6` - [ -z "$hostIPv6" ] && local hostIPv6=`get_hostipv6` + [ -z "$hostIPv6" ] && sleep 1 && local hostIPv6=`get_hostipv6` + [ -z "$hostIPv6" ] && sleep 1 && local hostIPv6=`get_hostipv6` echo $hostIPv6 # 重试,偷懒,有空再优化 fi } @@ -176,12 +176,12 @@ function getinterfaceuptime(){ getinterfacelist|grep \"uptime\"|sed $'s/\"uptime": //g'|sed $'s/\,//g' } -# 查询 mac 地址 +# 查询 MAC 地址 function getmac(){ ( echo "$tmp_mac"|grep -q "unknown" ) && unset tmp_mac # 为unknown时重新读取 [ -f "${dir}ipAddress" ] && [ -z "$tmp_mac" ] && local tmp_mac=`cat ${dir}ipAddress|grep -w ${1}|awk '{print $2}'|grep -v "^$"|sort -u|head -n1` [ -f "${dir}tmp_downlist" ] && [ -z "$tmp_mac" ] && local tmp_mac=`cat ${dir}tmp_downlist|grep -w ${1}|awk '{print $2}'|grep -v "^$"|sort -u|head -n1` - [ -f "/var/dhcp.leases" ] && [ -z "$tmp_mac" ] && local tmp_mac=`cat /var/dhcp.leases|grep -w ${1}|awk '{print $2}'|grep -v "^$"|sort -u|head -n1` + [ -f "/tmp/dhcp.leases" ] && [ -z "$tmp_mac" ] && local tmp_mac=`cat /tmp/dhcp.leases|grep -w ${1}|awk '{print $2}'|grep -v "^$"|sort -u|head -n1` [ -z "$tmp_mac" ] && local tmp_mac=`cat /proc/net/arp|grep "0x2\|0x6"|grep -w ${1}|awk '{print $4}'|grep -v "^$"|sort -u|head -n1` [ -z "$tmp_mac" ] && local tmp_mac="unknown" echo "$tmp_mac" @@ -193,7 +193,7 @@ function getname(){ [ -f "${dir}ipAddress" ] && [ -z "$tmp_name" ] && local tmp_name=`cat ${dir}ipAddress|grep -w ${1}|awk '{print $3}'|grep -v "^$"|sort -u|head -n1` [ -f "${dir}tmp_downlist" ] && [ -z "$tmp_name" ] && local tmp_name=`cat ${dir}tmp_downlist|grep -w ${1}|awk '{print $3}'|grep -v "^$"|sort -u|head -n1` ( ! echo "$tmp_name"|grep -q -w "unknown\|*" ) && [ ! -z "$tmp_name" ] && echo "$tmp_name" && return || unset tmp_name # 为unknown时重新读取 - [ -f "/var/dhcp.leases" ] && [ -z "$tmp_name" ] && local tmp_name=`cat /var/dhcp.leases|grep -w ${1}|awk '{print $4}'|grep -v "^$"|sort -u|head -n1` + [ -f "/tmp/dhcp.leases" ] && [ -z "$tmp_name" ] && local tmp_name=`cat /tmp/dhcp.leases|grep -w ${1}|awk '{print $4}'|grep -v "^$"|sort -u|head -n1` ( ! echo "$tmp_name"|grep -q -w "unknown\|*" ) && [ ! -z "$tmp_name" ] && echo "$tmp_name" && return || unset tmp_name # 为unknown时重新读取 [ -z "$dhcp_config" ] && dhcp_config=`uci show dhcp|grep "ip\|mac\|name"` for dhcp_config_str in "host" "domain"; do @@ -506,7 +506,7 @@ function get_client(){ done < ${dir}ipAddress fi cat>/usr/lib/lua/luci/view/serverchan/serverchan_client.htm<<%:在线设备列表%>
<%:客户端名%>
<%:MAC%>
<%:IP%>
<%:总计流量%>
<%: 在线时间%>
+

<%:在线设备列表%>

<%:主机名%>
<%:MAC%>
<%:IP%>
<%:总计流量%>
<%: 在线时间%>
$js_str
EOF @@ -709,7 +709,7 @@ function ip_changes(){ echo IPv4 $IPv4 > ${dir}ip && echo -e IPv6 $IPv6 >> ${dir}ip [ -z "$title" ] && title="IPv6 地址变化" [ ! -z "$title" ] && title="IP 地址变化" - content="${content}${str_splitline}${str_title_start} IPv6 地址变化${str_title_end}${str_linefeed}${str_tab}当前 IPv6:${IPv6}" + content="${content}${str_splitline}${str_title_start} IPv6 地址变化${str_title_end}${str_linefeed}${str_tab}当前 IPv6:${IPv6}" elif [ ! -z "$serverchan_ipv6" ] && [ "$serverchan_ipv6" -ne "0" ] && [ -z "$IPv6" ]; then echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】获取 IPv6 地址失败" >> ${logfile} fi @@ -718,7 +718,7 @@ function ip_changes(){ echo "`date "+%Y-%m-%d %H:%M:%S"` ${disturb_text}路由器已经重启!" >> ${logfile} [ ! -z "$serverchan_ipv4" ] && [ "$serverchan_ipv4" -ne "0" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 当前IP: ${IPv4}" >> ${logfile} [ ! -z "$serverchan_ipv6" ] && [ "$serverchan_ipv6" -ne "0" ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 当前IPv6: ${IPv6}" >> ${logfile} - echo IPv4 $IPv4 > ${dir}ip && echo -e IPv6 $IPv6 >> ${dir}ip + echo IPv4 $IPv4 > ${dir}ip && echo -e IPv6 $IPv6 >> ${dir}ip title="路由器重新启动" content="${content}${str_splitline}${str_title_start} 路由器重新启动${str_title_end}" [ ! -z "$serverchan_ipv4" ] && [ "$serverchan_ipv4" -ne "0" ] && content="${content}${str_linefeed}${str_tab}当前IP:${IPv4}" @@ -967,7 +967,7 @@ function login_send(){ cat ${dir}login_monitor|grep -i "Bad password attempt\|Login attempt for nonexistent user from"|grep -Eo "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}" >> ${dir}ssh_failed echo "" > ${dir}login_monitor add_ip_black - + local login_ip_list=`cat ${dir}web_login|awk '{print $2}'|grep -v "^$"|sort -u|head -n1` for login_ip in $login_ip_list; do [ -z "$login_ip" ] && continue @@ -1073,13 +1073,13 @@ function add_ip_black(){ [ ! -f "${ip_blacklist_path}" ] && local logrow="0" [ ! -z "$web_login_black" ] && [ "$web_login_black" -eq "0" ] || [ -z "$web_login_black" ] && local logrow="0" ipset flush ip_blacklist >/dev/null 2>&1 - + if [ $logrow -le "0" ]; then iptables -D INPUT -m set --match-set ip_blacklist src -j DROP >/dev/null 2>&1 ipset destroy ip_blacklist >/dev/null 2>&1 return fi - + ipset list ip_blacklist >/dev/null 2>&1 || ipset create ip_blacklist hash:ip timeout ${ip_black_timeout} >/dev/null 2>&1 iptables -C INPUT -m set --match-set ip_blacklist src -j DROP >/dev/null 2>&1 || iptables -I INPUT -m set --match-set ip_blacklist src -j DROP >/dev/null 2>&1 echo "$1" >> ${ip_blacklist_path} @@ -1128,14 +1128,14 @@ function send(){ if [ -z "$1" ] && [ ! -z "$router_wan" ] && [ "$router_wan" -eq "1" ]; then local send_wanIP=`getip wanipv4`;local send_hostIP=`getip hostipv4` - local send_content="${send_content}${str_splitline}${str_title_start} WAN 口信息${str_title_end}${str_linefeed}${str_tab}接口ip:${send_wanIP}" - local send_content="${send_content}${str_linefeed}${str_tab}外网ip:${send_hostIP}" + local send_content="${send_content}${str_splitline}${str_title_start} WAN 口信息${str_title_end}${str_linefeed}${str_tab}接口 IPv4:${send_wanIP}" + local send_content="${send_content}${str_linefeed}${str_tab}外网 IPv4:${send_hostIP}" if [ ! -z "$serverchan_ipv6" ] && [ "$serverchan_ipv6" -ne "0" ]; then local send_wanIPv6=`getip wanipv6`;local send_hostIPv6=`getip hostipv6` - local send_content="${send_content}${str_linefeed}${str_tab}ipv6 :${send_wanIPv6}" - local send_content="${send_content}${str_linefeed}${str_tab}外网v6:${send_hostIPv6}" + local send_content="${send_content}${str_linefeed}${str_tab}接口 IPv6:${send_wanIPv6}" + local send_content="${send_content}${str_linefeed}${str_tab}外网 IPv6:${send_hostIPv6}" fi - ( ! echo "$send_wanIP"|grep -q -w ${send_hostIP} ) && local send_content="${send_content}${str_linefeed}${str_tab}外网 ip 与接口 ip 不一致,你的 ip 不是公网 ip" + ( ! echo "$send_wanIP"|grep -q -w ${send_hostIP} ) && local send_content="${send_content}${str_linefeed}${str_tab}外网 IP 与接口 IP 不一致,你的 IP 可能不是公网 IP" local interfaceuptime=`getinterfaceuptime` [ ! -z "$interfaceuptime" ] && local wanstatustime=`getinterfaceuptime|awk -F. '{run_days=$1 / 86400;run_hour=($1 % 86400)/3600;run_minute=($1 % 3600)/60;run_second=$1 % 60;printf("在线时间:%d天%d时%d分%d秒",run_days,run_hour,run_minute,run_second)}'` && unset run_days run_hour run_minute run_second local send_content="${send_content}${str_linefeed}${str_tab}${wanstatustime}" @@ -1200,7 +1200,7 @@ while [ "$serverchan_enable" -eq "1" ]; do deltemp usage update serverchan_disturb;disturb=$? - + [ -f ${dir}ipAddress ] && ipAddress_logrow=$(grep -c "" ${dir}ipAddress) || ipAddress_logrow="0"; if [ $ipAddress_logrow -ne "0" ]; then online_list=`cat ${dir}ipAddress|awk '{print $2}'|grep -v "^$"|sort -u` @@ -1237,9 +1237,9 @@ while [ "$serverchan_enable" -eq "1" ]; do # 异常流量检测 [ ! -f "${dir}send_enable.lock" ] && get_client_usage - + # 登陆提醒通知 - [ ! -f "${dir}send_enable.lock" ] && login_send + [ ! -f "${dir}send_enable.lock" ] && login_send if [ ! -f "${dir}send_enable.lock" ] && [ ! -z "$title" ] && [ ! -z "$content" ]; then [ ! -z "$device_name" ] && title="【$device_name】$title" @@ -1247,7 +1247,7 @@ while [ "$serverchan_enable" -eq "1" ]; do [ "$disturb" -eq "0" ] && diy_send "${title}" "${content}" "${jsonpath}" >/dev/null 2>&1 [ $? -eq 1 ] && echo "`date "+%Y-%m-%d %H:%M:%S"` 【!!!】推送失败,请检查网络或设置信息 " >> ${logfile} fi - + while [ -f "${dir}send_enable.lock" ]; do sleep $sleeptime done diff --git a/luci-app-socatg/Makefile b/luci-app-socatg/Makefile index 8b81270475a..ff5a2206ecf 100644 --- a/luci-app-socatg/Makefile +++ b/luci-app-socatg/Makefile @@ -1,13 +1,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=luci-app-socatg -PKG_VERSION=1.2 + PKG_LICENSE:=MIT PKG_MAINTAINER:=drophair + LUCI_TITLE:=LuCI Support for socatg LUCI_PKGARCH:=all LUCI_DEPENDS:=+socat -# PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) -include $(INCLUDE_DIR)/package.mk include $(TOPDIR)/feeds/luci/luci.mk + +# call BuildPackage - OpenWrt buildroot signature diff --git a/luci-app-socatg/README-Chinese.md b/luci-app-socatg/README-Chinese.md deleted file mode 100644 index d289a7b613a..00000000000 --- a/luci-app-socatg/README-Chinese.md +++ /dev/null @@ -1,18 +0,0 @@ -# luci-app-socatg - -**SocatG** -Socat GUI,Socat可视化插件,支持所有架构,需要提前安装`socat`: -```Bash opkg install socat``` -- 插件位置:网络->SocatG -- 使用教程(正在审核):[什么值得买](https://post.smzdm.com/detail_preview/anxr0w00/) -- 安装: -已向lean提交合并申请(待合并),[GitHub Releases](https://github.com/big-tooth/luci-app-socatg/releases) 中有预编译的 ipk 文件,安装命令: - ```bash - wget -P /tmp https://github.com/big-tooth/luci-app-socatg/releases/download/v1.1/luci-app-socatg_1.1-1_all.ipk - opkg install /tmp/luci-app-socatg_1.1-1_all.ipk - ``` -![OpenWrt 配置界面](./doc/openwrt) - -*** -感谢 -[Beginner-Go](https://github.com/Beginner-Go) \ No newline at end of file diff --git a/luci-app-socatg/README.md b/luci-app-socatg/README.md deleted file mode 100644 index 936f2ab1b32..00000000000 --- a/luci-app-socatg/README.md +++ /dev/null @@ -1,18 +0,0 @@ -# luci-app-socatg/ [中文文档](./README-Chinese.md) - -**SocatG** (Socat GUI),about IPv6 port forwarding IPv4,SocatG supports all architectures(x86,Arm,MIPS),SocatG needs the support of `socat`👇 -```opkg install socat``` -- Localtion:Network->SocatG -- How to use(reviewing):[smzdm/什么值得买](https://post.smzdm.com/detail_preview/anxr0w00/) -- Install: -1.We already commit a Pull Request to lean(Wait Merge) -2.[GitHub Releases](https://github.com/big-tooth/luci-app-socatg/releases) has uploaded precompiled file with ipk suffix,Command: - ```bash - wget -P /tmp https://github.com/big-tooth/luci-app-socatg/releases/download/v1.1/luci-app-socatg_1.1-1_all.ipk - opkg install /tmp/luci-app-socatg_1.1-1_all.ipk - ``` -![OpenWrt Configuration interface](./doc/openwrt) - -*** -Thanks -[Beginner-Go](https://github.com/Beginner-Go) \ No newline at end of file diff --git a/luci-app-socatg/doc/openwrt b/luci-app-socatg/doc/openwrt deleted file mode 100644 index d5c0e8bf4cb..00000000000 Binary files a/luci-app-socatg/doc/openwrt and /dev/null differ diff --git a/luci-app-socatg/luasrc/model/cbi/socatg.lua b/luci-app-socatg/luasrc/model/cbi/socatg.lua index 21e0ca3b062..da5fb84029c 100644 --- a/luci-app-socatg/luasrc/model/cbi/socatg.lua +++ b/luci-app-socatg/luasrc/model/cbi/socatg.lua @@ -6,9 +6,9 @@ s = m:section(TypedSection, "socatg") s.addremove = false s.anonymous = true -v6port = s:option(Value, "v6port", translate("v6port")) -v4host = s:option(Value, "v4host", translate("v4host")) -v4port = s:option(Value, "v4port", translate("v4port")) +v6port = s:option(Value, "v6port", translate("IPv6 Port")) +v4host = s:option(Value, "v4host", translate("IPv4 Host")) +v4port = s:option(Value, "v4port", translate("IPv4 Port")) local apply = luci.http.formvalue("cbi.apply") if apply then diff --git a/luci-app-socatg/root/etc/init.d/socatg b/luci-app-socatg/root/etc/init.d/socatg old mode 100644 new mode 100755 diff --git a/luci-app-socatg/root/etc/uci-defaults/luci-socatg b/luci-app-socatg/root/etc/uci-defaults/luci-socatg old mode 100644 new mode 100755 diff --git a/luci-app-verysync/root/etc/init.d/verysync b/luci-app-verysync/root/etc/init.d/verysync index 146ddc35068..1ebffe97253 100755 --- a/luci-app-verysync/root/etc/init.d/verysync +++ b/luci-app-verysync/root/etc/init.d/verysync @@ -3,6 +3,8 @@ START=50 STOP=10 +VERYSYNC="/usr/bin/verysync" + start() { local enabled="$(uci get verysync.config.enabled)" local port="$(uci get verysync.config.port)" @@ -10,9 +12,9 @@ start() { stop [ "${enabled}" == "1" ] || exit 0 export HOME="/root/" - verysync -gui-address="0.0.0.0:${port}" -logfile="/var/log/verysync.log" -home="${profile}" -no-browser >/dev/null 2>&1 & + "${VERYSYNC}" -gui-address="0.0.0.0:${port}" -logfile="/var/log/verysync.log" -home="${profile}" -no-browser >/dev/null 2>&1 & } stop() { - kill -9 `pgrep verysync` >/dev/null 2>&1 + kill -9 `pgrep "${VERYSYNC}"` >/dev/null 2>&1 }