From 55b951afc1ac2281d3fec007196c1691448d1db4 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Mon, 2 Sep 2024 17:52:26 +0200 Subject: [PATCH 1/7] Fix unbound status check in OMR-Schedule --- omr-schedule/files/usr/share/omr/schedule.d/010-services | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/omr-schedule/files/usr/share/omr/schedule.d/010-services b/omr-schedule/files/usr/share/omr/schedule.d/010-services index bc78571e1a..0970d355b4 100755 --- a/omr-schedule/files/usr/share/omr/schedule.d/010-services +++ b/omr-schedule/files/usr/share/omr/schedule.d/010-services @@ -28,7 +28,7 @@ if [ -f /etc/init.d/glorytun-udp ] && [ "$(pgrep glorytun-udp)" = "" ] && [ "$(u sleep 5 fi -if [ -f /etc/init.d/unbound ] && [ "$(uci -q get unbound.@unbound[0].enabled)" = "1" ] && [ -n "$(uci -q get dnsmasq1.server | grep 127.0.0.1#5353)" ]; then +if [ -f /etc/init.d/unbound ] && [ "$(uci -q get unbound.@unbound[0].enabled)" = "1" ] && [ -n "$(uci -q get dhcp.dnsmasq1.server | grep 127.0.0.1#5353)" ]; then if [ "$(pgrep -f unbound)" = "" ]; then _log "Can't find unbound, restart it..." /etc/init.d/unbound restart >/dev/null 2>&1 From 96f593be3edd0fdfe328b844ef4152a081b8fe85 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Mon, 2 Sep 2024 17:52:44 +0200 Subject: [PATCH 2/7] Add luci-theme-material --- openmptcprouter-full/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openmptcprouter-full/Makefile b/openmptcprouter-full/Makefile index 39f7e2cdf5..64ef33bb80 100644 --- a/openmptcprouter-full/Makefile +++ b/openmptcprouter-full/Makefile @@ -36,7 +36,7 @@ MY_DEPENDS := \ wireless-tools \ libiwinfo-lua \ ca-bundle ca-certificates \ - luci-mod-admin-full luci-app-firewall luci-app-glorytun-tcp luci-app-glorytun-udp luci-app-shadowsocks-libev luci-app-unbound luci-theme-openmptcprouter luci-theme-argon luci-theme-alpha luci-theme-design luci-base \ + luci-mod-admin-full luci-app-firewall luci-app-glorytun-tcp luci-app-glorytun-udp luci-app-shadowsocks-libev luci-app-unbound luci-theme-openmptcprouter luci-theme-argon luci-theme-alpha luci-theme-design luci-base luci-theme-material \ luci-app-omr-tracker luci-app-omr-dscp \ luci-app-sqm-autorate sqm-scripts-extra \ luci-app-vnstat2 omr-quota luci-app-omr-quota \ From 54d408d97cbf0ed0249be791716a0410181da3e4 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Wed, 4 Sep 2024 09:28:28 +0200 Subject: [PATCH 3/7] Fix on Openmptcprouter-vps script when v2ray/xray are not installed --- openmptcprouter/files/etc/init.d/openmptcprouter-vps | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openmptcprouter/files/etc/init.d/openmptcprouter-vps b/openmptcprouter/files/etc/init.d/openmptcprouter-vps index 68d0b96315..08261f44a9 100755 --- a/openmptcprouter/files/etc/init.d/openmptcprouter-vps +++ b/openmptcprouter/files/etc/init.d/openmptcprouter-vps @@ -1075,8 +1075,8 @@ _vps_firewall_redirect_port() { #return fi xray="$v2ray" - ([ "$(uci -q get v2ray.main.enabled)" = "0" ] || [ "$(uci -q get openmptcprouter.omr.v2ray)" = "down" ]) && v2ray="0" - ([ "$(uci -q get xray.main.enabled)" = "0" ] || [ "$(uci -q get openmptcprouter.omr.xray)" = "down" ]) && xray="0" + ([ "$(uci -q get v2ray.main.enabled)" != "1" ] || [ "$(uci -q get openmptcprouter.omr.v2ray)" = "down" ]) && v2ray="0" + ([ "$(uci -q get xray.main.enabled)" != "1" ] || [ "$(uci -q get openmptcprouter.omr.xray)" = "down" ]) && xray="0" [ "$proto" = "all" ] && proto="tcp udp" [ "$proto" = "" ] && proto="tcp udp" [ "$src" = "vpn" ] && [ -n "$proto" ] && [ -n "$src_dport" ] && [ "$enabled" != "0" ] && [ "$name" != "Allow-DHCP-Request-VPN" ] && { From 962b9ad7eb317003a9b2544fd4dc159cb13a6273 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Wed, 4 Sep 2024 09:28:47 +0200 Subject: [PATCH 4/7] Add luci-theme-bootstrap --- openmptcprouter-full/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openmptcprouter-full/Makefile b/openmptcprouter-full/Makefile index 64ef33bb80..9d0754be7e 100644 --- a/openmptcprouter-full/Makefile +++ b/openmptcprouter-full/Makefile @@ -36,7 +36,7 @@ MY_DEPENDS := \ wireless-tools \ libiwinfo-lua \ ca-bundle ca-certificates \ - luci-mod-admin-full luci-app-firewall luci-app-glorytun-tcp luci-app-glorytun-udp luci-app-shadowsocks-libev luci-app-unbound luci-theme-openmptcprouter luci-theme-argon luci-theme-alpha luci-theme-design luci-base luci-theme-material \ + luci-mod-admin-full luci-app-firewall luci-app-glorytun-tcp luci-app-glorytun-udp luci-app-shadowsocks-libev luci-app-unbound luci-theme-openmptcprouter luci-theme-argon luci-theme-alpha luci-theme-design luci-base luci-theme-material luci-theme-bootstrap \ luci-app-omr-tracker luci-app-omr-dscp \ luci-app-sqm-autorate sqm-scripts-extra \ luci-app-vnstat2 omr-quota luci-app-omr-quota \ From 6272837d37505cd0d217aa9ca27862d18f152f38 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 5 Sep 2024 15:00:26 +0200 Subject: [PATCH 5/7] Check if Shadowsocks status is correc tin OMR-Tracker-ss --- omr-tracker/files/bin/omr-tracker-ss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/omr-tracker/files/bin/omr-tracker-ss b/omr-tracker/files/bin/omr-tracker-ss index de772e5fdf..e56748f7fc 100755 --- a/omr-tracker/files/bin/omr-tracker-ss +++ b/omr-tracker/files/bin/omr-tracker-ss @@ -99,7 +99,7 @@ while true; do } if [ "$(curl -s -I -w %{http_code} --socks5 "${proxy}" --max-time "${timeout}" "$host" -o /dev/null)" != "000" ]; then nocontact="" - [ "${last}" -ge "${retry}" ] || [ "$(uci -q get openmptcprouter.omr.ss_${server})" = "" ] && { + [ "${last}" -ge "${retry}" ] || [ "$(uci -q get openmptcprouter.omr.ss_${server})" != "up" ] && { _log "Shadowsocks $type ${server} is up (can contact via http ${host})" OMR_TRACKER_STATUS_MSG="Shadowsocks $type ${server} is up (can contact via http ${host})" uci -q set openmptcprouter.omr.ss_${server}="up" From 43f4d52f09d948af3fe81c69aade6f5680480d2c Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 5 Sep 2024 15:01:13 +0200 Subject: [PATCH 6/7] Add MPTCP BPF scheduler on anything that is not kernel 5.4/6.1 or ramips --- openmptcprouter-full/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openmptcprouter-full/Makefile b/openmptcprouter-full/Makefile index 9d0754be7e..9bdbc28cc4 100644 --- a/openmptcprouter-full/Makefile +++ b/openmptcprouter-full/Makefile @@ -92,7 +92,7 @@ MY_DEPENDS := \ TARGET_mvebu:kmod-mwlwifi TARGET_mvebu:mwlwifi-firmware-88w8864 TARGET_mvebu:mwlwifi-firmware-88w8897 TARGET_mvebu:mwlwifi-firmware-88w8964 TARGET_mvebu:mwlwifi-firmware-88w8997 \ (LINUX_5_4&&(TARGET_x86_64||TARGET_aarch64)):kmod-tcp-bbr2 \ TARGET_x86_64:kmod-atlantic \ - (LINUX_6_6||LINUX_6_10):mptcp-bpf-burst (LINUX_6_6||LINUX_6_10):mptcp-bpf-first (LINUX_6_6||LINUX_6_10):mptcp-bpf-red (LINUX_6_6||LINUX_6_10):mptcp-bpf-rr (LINUX_6_6||LINUX_6_10):bpftool-full \ + !(LINUX_5_4||LINUX_6_1||TARGET_ramips):mptcp-bpf-burst !(LINUX_5_4||LINUX_6_1||TARGET_ramips):mptcp-bpf-first !(LINUX_5_4||LINUX_6_1||TARGET_ramips):mptcp-bpf-red !(LINUX_5_4||LINUX_6_1||TARGET_ramips):mptcp-bpf-rr !(LINUX_5_4||LINUX_6_1||TARGET_ramips):bpftool-full \ !LINUX_6_10:kmod-ovpn-dco-v2 # !TARGET_ipq40xx:kmod-rt2800-usb (TARGET_x86||TARGET_x86_64):kmod-iwlwifi (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl1000 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl100 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl105 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl135 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl2000 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl2030 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl3160 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl3168 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl5000 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl5150 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl6000g2 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl6000g2a (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl6000g2b (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl6050 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl7260 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl7265 (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl7265d (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl8260c (TARGET_x86||TARGET_x86_64):iwlwifi-firmware-iwl8265 \ From 4e228fd6f517b9067c3e344e6c58931c4db71e99 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 5 Sep 2024 15:01:45 +0200 Subject: [PATCH 7/7] Remove DHCP on interface OMRVPN by default --- openmptcprouter/files/etc/uci-defaults/2020-omr-vpn | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openmptcprouter/files/etc/uci-defaults/2020-omr-vpn b/openmptcprouter/files/etc/uci-defaults/2020-omr-vpn index 95d6c3c066..ef15c5a1e8 100755 --- a/openmptcprouter/files/etc/uci-defaults/2020-omr-vpn +++ b/openmptcprouter/files/etc/uci-defaults/2020-omr-vpn @@ -6,7 +6,7 @@ if [ "$(uci -q get network.omrvpn)" = "" ]; then delete network.omrvpn set network.omrvpn=interface set network.omrvpn.device=tun0 - set network.omrvpn.proto=dhcp + set network.omrvpn.proto=none set network.omrvpn.ip4table=vpn set network.omrvpn.multipath=off set network.omrvpn.leasetime=12h