From 2ec91c3f58058d1d5b2e21830937a7b0dedb5297 Mon Sep 17 00:00:00 2001 From: suyuan <175338101@qq.com> Date: Mon, 26 Sep 2022 03:59:00 +0800 Subject: [PATCH 1/6] fixx --- openmptcprouter-mini/Makefile | 70 ++++++++++++++++++++------------ openmptcprouter-zuixiao/Makefile | 59 ++++++++++++++++----------- 2 files changed, 79 insertions(+), 50 deletions(-) diff --git a/openmptcprouter-mini/Makefile b/openmptcprouter-mini/Makefile index c1a1b91ab..10353e5bc 100755 --- a/openmptcprouter-mini/Makefile +++ b/openmptcprouter-mini/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2018-2019 Ycarus (Yannick Chabanois) +# Copyright (C) suyunfan # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -7,8 +7,8 @@ include $(TOPDIR)/rules.mk -PKG_NAME:=openmptcprouter-mini -PKG_VERSION:=0.1 +PKG_NAME:=openmptcprouter-zuixiao +PKG_VERSION:=0.14 PKG_RELEASE:=1 include $(INCLUDE_DIR)/package.mk @@ -17,7 +17,6 @@ MY_DEPENDS := \ mptcp \ unbound-daemon unbound-control unbound-anchor \ netifd \ - luci-app-dsvpn \ mc \ f2fs-tools \ openmptcprouter \ @@ -28,30 +27,31 @@ MY_DEPENDS := \ iperf3-ssl luci-app-iperf \ arptables \ bind-dig \ - libnetfilter-conntrack ip-full \ + libnetfilter-conntrack ip-full nstat \ iptables-mod-iface iptables-mod-ipmark iptables-mod-hashlimit iptables-mod-condition iptables-mod-trace iptables-mod-conntrack-extra iptables-mod-account \ - kmod-nf-nat kmod-nf-nathelper kmod-nf-nathelper-extra iptables-mod-extra \ - iptables-mod-ipsec kmod-crypto-authenc kmod-ipsec kmod-ipsec4 kmod-ipsec6 kmod-ipt-ipsec \ + kmod-nf-nat kmod-nf-nathelper kmod-nf-nathelper-extra iptables-mod-extra conntrack kmod-ipt-offload \ + iptables-mod-ipsec kmod-crypto-authenc kmod-ipsec kmod-ipsec4 kmod-ipt-ipsec \ wireless-tools \ libiwinfo-lua \ - ca-bundle ca-certificates libustream-openssl \ - 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-base \ + 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-base \ luci-app-omr-tracker luci-app-omr-dscp \ - luci-app-sqm sqm-scripts-extra \ + luci-app-sqm-autorate sqm-scripts-extra \ luci-app-vnstat2 omr-quota luci-app-omr-quota \ - luci-app-mptcp luci-app-openmptcprouter luci-app-omr-bypass luci-app-mail luci-app-upnp \ - luci-app-opkg \ + luci-app-mptcp luci-app-openmptcprouter luci-app-upnp \ + luci-app-wol luci-app-opkg \ luci-app-uhttpd \ luci-mod-rpc rpcd-mod-rpcsys rpcd-mod-file rpcd-mod-iwinfo \ luci-app-openvpn \ - macvlan \ shadowsocks-libev-ss-server shadowsocks-libev-ss-tunnel \ - omr-6in4 ip6tables-mod-nat luci-proto-ipv6 6to4 6in4 6rd ip6tables \ + speedtestcpp \ iftop \ htop \ + nano \ tcpdump \ ethtool \ iputils-ping \ + tracebox \ !TARGET_mvebu:luci-proto-3g \ !TARGET_mvebu:comgt-ncm !TARGET_mvebu:luci-proto-ncm \ !TARGET_mvebu:luci-proto-modemmanager \ @@ -60,34 +60,52 @@ MY_DEPENDS := \ rng-tools \ openvpn-openssl \ mmc-utils \ - libimobiledevice \ + libimobiledevice libimobiledevice-utils \ comgt \ kmod-random-core \ + kmod-netem \ ca-bundle openssl-util \ dejavu-fonts-ttf-DejaVuSerif dejavu-fonts-ttf-DejaVuSerif-Bold dejavu-fonts-ttf-DejaVuSerif-Italic dejavu-fonts-ttf-DejaVuSerif-BoldItalic \ - iputils-tracepath netcat adb-enablemodem \ - (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 \ - (TARGET_x86||TARGET_x86_64):kmod-e1000 (TARGET_x86||TARGET_x86_64):kmod-e1000e (TARGET_x86||TARGET_x86_64):kmod-igb (TARGET_x86||TARGET_x86_64):kmod-ne2k-pci (TARGET_x86||TARGET_x86_64):kmod-r8169 (TARGET_x86||TARGET_x86_64):kmod-8139too (TARGET_x86||TARGET_x86_64):kmod-bnx2 \ + luci-app-snmpd \ + iputils-tracepath v2ray-plugin netcat simple-obfs \ TARGET_mvebu:kmod-mwlwifi TARGET_mvebu:mwlwifi-firmware-88w8864 TARGET_mvebu:mwlwifi-firmware-88w8897 TARGET_mvebu:mwlwifi-firmware-88w8964 TARGET_mvebu:mwlwifi-firmware-88w8997 \ !TARGET_mvebu:kmod-usb-serial !TARGET_mvebu:kmod-usb-serial-option !TARGET_mvebu:kmod-usb-serial-wwan !TARGET_mvebu:usb-modeswitch !TARGET_mvebu:uqmi \ !TARGET_mvebu:umbim !TARGET_mvebu:kmod-mii !TARGET_mvebu:kmod-usb-net !TARGET_mvebu:kmod-usb-wdm !TARGET_mvebu:kmod-usb-net-qmi-wwan !TARGET_mvebu:kmod-usb-net-cdc-mbim !TARGET_mvebu:umbim \ - !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd \ - kmod-rt2800-usb kmod-rtl8xxxu kmod-rtl8192cu kmod-net-rtl8192su \ - !TARGET_mvebu:luci-proto-qmi wpad-basic kmod-mt7601u kmod-rtl8187 \ - luci-app-mlvpn mlvpn 464xlat kmod-zram kmod-swconfig swconfig kmod-ipt-nat kmod-ipt-nat6 luci-app-https-dns-proxy kmod-tcp-nanqinlang iptables-mod-ipopt ss \ - luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre + !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd !TARGET_mvebu:libusbmuxd \ + !TARGET_mvebu:luci-proto-qmi kmod-rtl8187 TARGET_r4s:kmod-r8168 (TARGET_x86||TARGET_x86_64):kmod-usb-net-rtl8152 \ + kmod-zram kmod-swconfig swconfig kmod-ipt-nat luci-app-https-dns-proxy kmod-tcp-nanqinlang (TARGET_x86_64||aarch64):kmod-tcp-bbr2 iptables-mod-ipopt igmpproxy ss iptraf-ng \ + luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-openssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf (TARGET_x86||TARGET_x86_64):kmod-igbvf \ + hwinfo (TARGET_x86||TARGET_x86_64):dmidecode luci-app-packet-capture kmod-bonding luci-proto-bonding \ + luci-theme-openwrt-2020 luci-proto-wireguard luci-app-wireguard kmod-crypto-lib-blake2s (TARGET_x86||TARGET_x86_64):kmod-r8125 TARGET_x86_64:kmod-atlantic \ + LINUX_5_15:mptcpd (TARGET_x86||TARGET_x86_64):kmod-igc kmod-mmc-spi kmod-macsec usbutils +# !TARGET_mvebu:kmod-usb-net-smsc75xx +# libnetfilter-conntrack ebtables ebtables-utils ip-full nstat \ -OMR_SUPPORTED_LANGS := en +# luci-theme-bootstrap luci-theme-openwrt-2020 luci-theme-openwrt luci-app-status +# luci-proto-bonding luci-app-statistics luci-proto-gre +# softethervpn5-client softethervpn5-server luci-app-nginx-ha + +# luci-app-mlvpn ubond \ +# kmod-ath9k kmod-ath9k-htc + +# (TARGET_x86||TARGET_x86_64):open-vm-tools \ +# (!TARGET_mvebu&&!TARGET_mediatek):kmod-fb-tft-all \ +# lcd4linux-full +# kmod-spi-gpio-custom + +#OMR_SUPPORTED_LANGS := ar bg bn_BD ca en fi fr de el he hi hu it ja mr ms nb_NO pl pt_BR pt ro ru es sv uk vi zh_Hans zh_Hant +#OMR_SUPPORTED_LANGS := ar bg ca cs de en fi fr de el he hi hu it ja ko mr ms no oc pl pt-br pt ro ru es sk sv tr uk vi zh-cn zh-tw +OMR_SUPPORTED_LANGS := en zh-cn zh-tw oc define Package/$(PKG_NAME) SECTION:=OMR CATEGORY:=OpenMPTCProuter DEPENDS:=$(foreach p,$(MY_DEPENDS),+$(p)) $(foreach lang,$(OMR_SUPPORTED_LANGS),+LUCI_LANG_$(lang):luci-i18n-base-$(lang)) -TITLE:=OpenMPTCProuter Mini Package +TITLE:=OpenMPTCProuter zuixiao Package endef define Package/$(PKG_NAME)/description -OpenMPTCProuter Mini package +OpenMPTCProuter zuixiao package endef define Build/Compile diff --git a/openmptcprouter-zuixiao/Makefile b/openmptcprouter-zuixiao/Makefile index c5d329737..10353e5bc 100755 --- a/openmptcprouter-zuixiao/Makefile +++ b/openmptcprouter-zuixiao/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2018-2019 Ycarus (Yannick Chabanois) +# Copyright (C) suyunfan # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=openmptcprouter-zuixiao -PKG_VERSION:=0.1 +PKG_VERSION:=0.14 PKG_RELEASE:=1 include $(INCLUDE_DIR)/package.mk @@ -17,7 +17,6 @@ MY_DEPENDS := \ mptcp \ unbound-daemon unbound-control unbound-anchor \ netifd \ - luci-app-dsvpn \ mc \ f2fs-tools \ openmptcprouter \ @@ -28,26 +27,24 @@ MY_DEPENDS := \ iperf3-ssl luci-app-iperf \ arptables \ bind-dig \ - libnetfilter-conntrack ebtables ebtables-utils ip-full \ + libnetfilter-conntrack ip-full nstat \ iptables-mod-iface iptables-mod-ipmark iptables-mod-hashlimit iptables-mod-condition iptables-mod-trace iptables-mod-conntrack-extra iptables-mod-account \ - kmod-nf-nat kmod-nf-nathelper kmod-nf-nathelper-extra iptables-mod-extra kmod-ledtrig-activity kmod-ledtrig-gpio kmod-ledtrig-oneshot kmod-ledtrig-transient kmod-ledtrig-disk kmod-ledtrig-mtd kmod-ledtrig-heartbeat kmod-ledtrig-backlight kmod-ledtrig-cpu kmod-ledtrig-panic kmod-ledtrig-netdev kmod-ledtrig-pattern kmod-ipt-led \ - iptables-mod-ipsec kmod-crypto-authenc kmod-ipsec kmod-ipsec4 kmod-ipsec6 kmod-ipt-ipsec \ + kmod-nf-nat kmod-nf-nathelper kmod-nf-nathelper-extra iptables-mod-extra conntrack kmod-ipt-offload \ + iptables-mod-ipsec kmod-crypto-authenc kmod-ipsec kmod-ipsec4 kmod-ipt-ipsec \ 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-bootstrap 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-base \ luci-app-omr-tracker luci-app-omr-dscp \ - luci-app-sqm sqm-scripts-extra luci-app-status luci-mod-status frpc rtty-nossl minicom irqbalance mtr \ + luci-app-sqm-autorate sqm-scripts-extra \ luci-app-vnstat2 omr-quota luci-app-omr-quota \ - luci-app-mptcp luci-app-openmptcprouter luci-app-omr-bypass luci-app-mail luci-app-upnp \ + luci-app-mptcp luci-app-openmptcprouter luci-app-upnp \ luci-app-wol luci-app-opkg \ luci-app-uhttpd \ luci-mod-rpc rpcd-mod-rpcsys rpcd-mod-file rpcd-mod-iwinfo \ luci-app-openvpn \ - macvlan \ shadowsocks-libev-ss-server shadowsocks-libev-ss-tunnel \ - omr-6in4 ip6tables-mod-nat luci-proto-ipv6 6to4 6in4 6rd ip6tables \ - speedtestc \ + speedtestcpp \ iftop \ htop \ nano \ @@ -63,28 +60,42 @@ MY_DEPENDS := \ rng-tools \ openvpn-openssl \ mmc-utils \ - libimobiledevice \ + libimobiledevice libimobiledevice-utils \ comgt \ kmod-random-core \ kmod-netem \ ca-bundle openssl-util \ dejavu-fonts-ttf-DejaVuSerif dejavu-fonts-ttf-DejaVuSerif-Bold dejavu-fonts-ttf-DejaVuSerif-Italic dejavu-fonts-ttf-DejaVuSerif-BoldItalic \ luci-app-snmpd \ - iputils-tracepath netcat adb-enablemodem simple-obfs \ - (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 \ - (TARGET_x86||TARGET_x86_64):kmod-e1000 (TARGET_x86||TARGET_x86_64):kmod-e1000e (TARGET_x86||TARGET_x86_64):kmod-igb (TARGET_x86||TARGET_x86_64):kmod-ne2k-pci (TARGET_x86||TARGET_x86_64):kmod-r8169 (TARGET_x86||TARGET_x86_64):kmod-8139too (TARGET_x86||TARGET_x86_64):kmod-bnx2 \ + iputils-tracepath v2ray-plugin netcat simple-obfs \ TARGET_mvebu:kmod-mwlwifi TARGET_mvebu:mwlwifi-firmware-88w8864 TARGET_mvebu:mwlwifi-firmware-88w8897 TARGET_mvebu:mwlwifi-firmware-88w8964 TARGET_mvebu:mwlwifi-firmware-88w8997 \ !TARGET_mvebu:kmod-usb-serial !TARGET_mvebu:kmod-usb-serial-option !TARGET_mvebu:kmod-usb-serial-wwan !TARGET_mvebu:usb-modeswitch !TARGET_mvebu:uqmi \ !TARGET_mvebu:umbim !TARGET_mvebu:kmod-mii !TARGET_mvebu:kmod-usb-net !TARGET_mvebu:kmod-usb-wdm !TARGET_mvebu:kmod-usb-net-qmi-wwan !TARGET_mvebu:kmod-usb-net-cdc-mbim !TARGET_mvebu:umbim \ - !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd \ - kmod-rt2800-usb kmod-rtl8xxxu kmod-rtl8192cu kmod-net-rtl8192su \ - !TARGET_mvebu:luci-proto-qmi wpad-basic kmod-mt7601u kmod-rtl8187 \ - luci-app-mlvpn mlvpn 464xlat !TARGET_mvebu:kmod-usb-net-smsc75xx kmod-zram kmod-swconfig swconfig kmod-ipt-nat kmod-ipt-nat6 luci-app-https-dns-proxy kmod-tcp-nanqinlang (TARGET_x86_64||aarch64):kmod-tcp-bbr2 iptables-mod-ipopt igmpproxy ss iptraf-ng \ - luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim kmod-rtl8xxxu kmod-ath9k-htc luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-wolfssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf \ + !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd !TARGET_mvebu:libusbmuxd \ + !TARGET_mvebu:luci-proto-qmi kmod-rtl8187 TARGET_r4s:kmod-r8168 (TARGET_x86||TARGET_x86_64):kmod-usb-net-rtl8152 \ + kmod-zram kmod-swconfig swconfig kmod-ipt-nat luci-app-https-dns-proxy kmod-tcp-nanqinlang (TARGET_x86_64||aarch64):kmod-tcp-bbr2 iptables-mod-ipopt igmpproxy ss iptraf-ng \ + luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-openssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf (TARGET_x86||TARGET_x86_64):kmod-igbvf \ hwinfo (TARGET_x86||TARGET_x86_64):dmidecode luci-app-packet-capture kmod-bonding luci-proto-bonding \ - luci-theme-openwrt-2020 luci-proto-wireguard luci-app-wireguard (TARGET_x86||TARGET_x86_64):kmod-r8125 + luci-theme-openwrt-2020 luci-proto-wireguard luci-app-wireguard kmod-crypto-lib-blake2s (TARGET_x86||TARGET_x86_64):kmod-r8125 TARGET_x86_64:kmod-atlantic \ + LINUX_5_15:mptcpd (TARGET_x86||TARGET_x86_64):kmod-igc kmod-mmc-spi kmod-macsec usbutils +# !TARGET_mvebu:kmod-usb-net-smsc75xx +# libnetfilter-conntrack ebtables ebtables-utils ip-full nstat \ -OMR_SUPPORTED_LANGS := zh-cn zh-tw oc +# luci-theme-bootstrap luci-theme-openwrt-2020 luci-theme-openwrt luci-app-status +# luci-proto-bonding luci-app-statistics luci-proto-gre +# softethervpn5-client softethervpn5-server luci-app-nginx-ha + +# luci-app-mlvpn ubond \ +# kmod-ath9k kmod-ath9k-htc + +# (TARGET_x86||TARGET_x86_64):open-vm-tools \ +# (!TARGET_mvebu&&!TARGET_mediatek):kmod-fb-tft-all \ +# lcd4linux-full +# kmod-spi-gpio-custom + +#OMR_SUPPORTED_LANGS := ar bg bn_BD ca en fi fr de el he hi hu it ja mr ms nb_NO pl pt_BR pt ro ru es sv uk vi zh_Hans zh_Hant +#OMR_SUPPORTED_LANGS := ar bg ca cs de en fi fr de el he hi hu it ja ko mr ms no oc pl pt-br pt ro ru es sk sv tr uk vi zh-cn zh-tw +OMR_SUPPORTED_LANGS := en zh-cn zh-tw oc define Package/$(PKG_NAME) SECTION:=OMR @@ -104,4 +115,4 @@ define Package/$(PKG_NAME)/install endef -$(eval $(call BuildPackage,$(PKG_NAME))) \ No newline at end of file +$(eval $(call BuildPackage,$(PKG_NAME))) From 39845bdf58de07cf6b9c386a212118089e374d59 Mon Sep 17 00:00:00 2001 From: suyuan <175338101@qq.com> Date: Mon, 26 Sep 2022 03:59:41 +0800 Subject: [PATCH 2/6] Update Makefile --- openmptcprouter-mini/Makefile | 70 +++++++++++++---------------------- 1 file changed, 26 insertions(+), 44 deletions(-) diff --git a/openmptcprouter-mini/Makefile b/openmptcprouter-mini/Makefile index 10353e5bc..c1a1b91ab 100755 --- a/openmptcprouter-mini/Makefile +++ b/openmptcprouter-mini/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) suyunfan +# Copyright (C) 2018-2019 Ycarus (Yannick Chabanois) # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -7,8 +7,8 @@ include $(TOPDIR)/rules.mk -PKG_NAME:=openmptcprouter-zuixiao -PKG_VERSION:=0.14 +PKG_NAME:=openmptcprouter-mini +PKG_VERSION:=0.1 PKG_RELEASE:=1 include $(INCLUDE_DIR)/package.mk @@ -17,6 +17,7 @@ MY_DEPENDS := \ mptcp \ unbound-daemon unbound-control unbound-anchor \ netifd \ + luci-app-dsvpn \ mc \ f2fs-tools \ openmptcprouter \ @@ -27,31 +28,30 @@ MY_DEPENDS := \ iperf3-ssl luci-app-iperf \ arptables \ bind-dig \ - libnetfilter-conntrack ip-full nstat \ + libnetfilter-conntrack ip-full \ iptables-mod-iface iptables-mod-ipmark iptables-mod-hashlimit iptables-mod-condition iptables-mod-trace iptables-mod-conntrack-extra iptables-mod-account \ - kmod-nf-nat kmod-nf-nathelper kmod-nf-nathelper-extra iptables-mod-extra conntrack kmod-ipt-offload \ - iptables-mod-ipsec kmod-crypto-authenc kmod-ipsec kmod-ipsec4 kmod-ipt-ipsec \ + kmod-nf-nat kmod-nf-nathelper kmod-nf-nathelper-extra iptables-mod-extra \ + iptables-mod-ipsec kmod-crypto-authenc kmod-ipsec kmod-ipsec4 kmod-ipsec6 kmod-ipt-ipsec \ 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-base \ + ca-bundle ca-certificates libustream-openssl \ + 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-base \ luci-app-omr-tracker luci-app-omr-dscp \ - luci-app-sqm-autorate sqm-scripts-extra \ + luci-app-sqm sqm-scripts-extra \ luci-app-vnstat2 omr-quota luci-app-omr-quota \ - luci-app-mptcp luci-app-openmptcprouter luci-app-upnp \ - luci-app-wol luci-app-opkg \ + luci-app-mptcp luci-app-openmptcprouter luci-app-omr-bypass luci-app-mail luci-app-upnp \ + luci-app-opkg \ luci-app-uhttpd \ luci-mod-rpc rpcd-mod-rpcsys rpcd-mod-file rpcd-mod-iwinfo \ luci-app-openvpn \ + macvlan \ shadowsocks-libev-ss-server shadowsocks-libev-ss-tunnel \ - speedtestcpp \ + omr-6in4 ip6tables-mod-nat luci-proto-ipv6 6to4 6in4 6rd ip6tables \ iftop \ htop \ - nano \ tcpdump \ ethtool \ iputils-ping \ - tracebox \ !TARGET_mvebu:luci-proto-3g \ !TARGET_mvebu:comgt-ncm !TARGET_mvebu:luci-proto-ncm \ !TARGET_mvebu:luci-proto-modemmanager \ @@ -60,52 +60,34 @@ MY_DEPENDS := \ rng-tools \ openvpn-openssl \ mmc-utils \ - libimobiledevice libimobiledevice-utils \ + libimobiledevice \ comgt \ kmod-random-core \ - kmod-netem \ ca-bundle openssl-util \ dejavu-fonts-ttf-DejaVuSerif dejavu-fonts-ttf-DejaVuSerif-Bold dejavu-fonts-ttf-DejaVuSerif-Italic dejavu-fonts-ttf-DejaVuSerif-BoldItalic \ - luci-app-snmpd \ - iputils-tracepath v2ray-plugin netcat simple-obfs \ + iputils-tracepath netcat adb-enablemodem \ + (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 \ + (TARGET_x86||TARGET_x86_64):kmod-e1000 (TARGET_x86||TARGET_x86_64):kmod-e1000e (TARGET_x86||TARGET_x86_64):kmod-igb (TARGET_x86||TARGET_x86_64):kmod-ne2k-pci (TARGET_x86||TARGET_x86_64):kmod-r8169 (TARGET_x86||TARGET_x86_64):kmod-8139too (TARGET_x86||TARGET_x86_64):kmod-bnx2 \ TARGET_mvebu:kmod-mwlwifi TARGET_mvebu:mwlwifi-firmware-88w8864 TARGET_mvebu:mwlwifi-firmware-88w8897 TARGET_mvebu:mwlwifi-firmware-88w8964 TARGET_mvebu:mwlwifi-firmware-88w8997 \ !TARGET_mvebu:kmod-usb-serial !TARGET_mvebu:kmod-usb-serial-option !TARGET_mvebu:kmod-usb-serial-wwan !TARGET_mvebu:usb-modeswitch !TARGET_mvebu:uqmi \ !TARGET_mvebu:umbim !TARGET_mvebu:kmod-mii !TARGET_mvebu:kmod-usb-net !TARGET_mvebu:kmod-usb-wdm !TARGET_mvebu:kmod-usb-net-qmi-wwan !TARGET_mvebu:kmod-usb-net-cdc-mbim !TARGET_mvebu:umbim \ - !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd !TARGET_mvebu:libusbmuxd \ - !TARGET_mvebu:luci-proto-qmi kmod-rtl8187 TARGET_r4s:kmod-r8168 (TARGET_x86||TARGET_x86_64):kmod-usb-net-rtl8152 \ - kmod-zram kmod-swconfig swconfig kmod-ipt-nat luci-app-https-dns-proxy kmod-tcp-nanqinlang (TARGET_x86_64||aarch64):kmod-tcp-bbr2 iptables-mod-ipopt igmpproxy ss iptraf-ng \ - luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-openssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf (TARGET_x86||TARGET_x86_64):kmod-igbvf \ - hwinfo (TARGET_x86||TARGET_x86_64):dmidecode luci-app-packet-capture kmod-bonding luci-proto-bonding \ - luci-theme-openwrt-2020 luci-proto-wireguard luci-app-wireguard kmod-crypto-lib-blake2s (TARGET_x86||TARGET_x86_64):kmod-r8125 TARGET_x86_64:kmod-atlantic \ - LINUX_5_15:mptcpd (TARGET_x86||TARGET_x86_64):kmod-igc kmod-mmc-spi kmod-macsec usbutils -# !TARGET_mvebu:kmod-usb-net-smsc75xx -# libnetfilter-conntrack ebtables ebtables-utils ip-full nstat \ + !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd \ + kmod-rt2800-usb kmod-rtl8xxxu kmod-rtl8192cu kmod-net-rtl8192su \ + !TARGET_mvebu:luci-proto-qmi wpad-basic kmod-mt7601u kmod-rtl8187 \ + luci-app-mlvpn mlvpn 464xlat kmod-zram kmod-swconfig swconfig kmod-ipt-nat kmod-ipt-nat6 luci-app-https-dns-proxy kmod-tcp-nanqinlang iptables-mod-ipopt ss \ + luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre -# luci-theme-bootstrap luci-theme-openwrt-2020 luci-theme-openwrt luci-app-status -# luci-proto-bonding luci-app-statistics luci-proto-gre -# softethervpn5-client softethervpn5-server luci-app-nginx-ha - -# luci-app-mlvpn ubond \ -# kmod-ath9k kmod-ath9k-htc - -# (TARGET_x86||TARGET_x86_64):open-vm-tools \ -# (!TARGET_mvebu&&!TARGET_mediatek):kmod-fb-tft-all \ -# lcd4linux-full -# kmod-spi-gpio-custom - -#OMR_SUPPORTED_LANGS := ar bg bn_BD ca en fi fr de el he hi hu it ja mr ms nb_NO pl pt_BR pt ro ru es sv uk vi zh_Hans zh_Hant -#OMR_SUPPORTED_LANGS := ar bg ca cs de en fi fr de el he hi hu it ja ko mr ms no oc pl pt-br pt ro ru es sk sv tr uk vi zh-cn zh-tw -OMR_SUPPORTED_LANGS := en zh-cn zh-tw oc +OMR_SUPPORTED_LANGS := en define Package/$(PKG_NAME) SECTION:=OMR CATEGORY:=OpenMPTCProuter DEPENDS:=$(foreach p,$(MY_DEPENDS),+$(p)) $(foreach lang,$(OMR_SUPPORTED_LANGS),+LUCI_LANG_$(lang):luci-i18n-base-$(lang)) -TITLE:=OpenMPTCProuter zuixiao Package +TITLE:=OpenMPTCProuter Mini Package endef define Package/$(PKG_NAME)/description -OpenMPTCProuter zuixiao package +OpenMPTCProuter Mini package endef define Build/Compile From c999d4776bf97413cb74f927999ceddddbcbaa62 Mon Sep 17 00:00:00 2001 From: suyuan <175338101@qq.com> Date: Mon, 26 Sep 2022 04:10:20 +0800 Subject: [PATCH 3/6] Update Makefile --- openmptcprouter-zuixiao/Makefile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/openmptcprouter-zuixiao/Makefile b/openmptcprouter-zuixiao/Makefile index 10353e5bc..44e5c502e 100755 --- a/openmptcprouter-zuixiao/Makefile +++ b/openmptcprouter-zuixiao/Makefile @@ -74,8 +74,7 @@ MY_DEPENDS := \ !TARGET_mvebu:kmod-usb-net-huawei-cdc-ncm !TARGET_mvebu:kmod-usb-net-rndis !TARGET_mvebu:kmod-usb-net-cdc-ether !TARGET_mvebu:kmod-usb-net-ipheth !TARGET_mvebu:usbmuxd !TARGET_mvebu:libusbmuxd \ !TARGET_mvebu:luci-proto-qmi kmod-rtl8187 TARGET_r4s:kmod-r8168 (TARGET_x86||TARGET_x86_64):kmod-usb-net-rtl8152 \ kmod-zram kmod-swconfig swconfig kmod-ipt-nat luci-app-https-dns-proxy kmod-tcp-nanqinlang (TARGET_x86_64||aarch64):kmod-tcp-bbr2 iptables-mod-ipopt igmpproxy ss iptraf-ng \ - luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-openssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf (TARGET_x86||TARGET_x86_64):kmod-igbvf \ - hwinfo (TARGET_x86||TARGET_x86_64):dmidecode luci-app-packet-capture kmod-bonding luci-proto-bonding \ + luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-openssl (TARGET_x86||TARGET_x86_64):dmidecode kmod-bonding luci-proto-bonding \ luci-theme-openwrt-2020 luci-proto-wireguard luci-app-wireguard kmod-crypto-lib-blake2s (TARGET_x86||TARGET_x86_64):kmod-r8125 TARGET_x86_64:kmod-atlantic \ LINUX_5_15:mptcpd (TARGET_x86||TARGET_x86_64):kmod-igc kmod-mmc-spi kmod-macsec usbutils # !TARGET_mvebu:kmod-usb-net-smsc75xx From 09977d0f5a6b9064b5cb62779bb87db63b25d862 Mon Sep 17 00:00:00 2001 From: suyuan <175338101@qq.com> Date: Fri, 30 Sep 2022 16:58:33 +0800 Subject: [PATCH 4/6] Update Makefile --- netmaker-openwrt/netmaker/Makefile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/netmaker-openwrt/netmaker/Makefile b/netmaker-openwrt/netmaker/Makefile index 903dd2beb..55544abba 100644 --- a/netmaker-openwrt/netmaker/Makefile +++ b/netmaker-openwrt/netmaker/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2019 sbilly +# Copyright (C) 2019 suyuan <175338101@qqcom> # # This is free software, licensed under the MIT License. # See /LICENSE for more information. @@ -8,18 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=netmaker -PKG_VERSION:=0.9.4 +PKG_VERSION:=0.16.0 PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/gravitl/netmaker.git -PKG_SOURCE_VERSION:=e9bce264719f88c30e252ecc754d08f422f4c080 -PKG_SOURCE_DATE:=20220117 +PKG_SOURCE_VERSION:=db3288782965a7d4713cf271c1277957749802d1 +PKG_SOURCE_DATE:=20220930 PKG_MIRROR_HASH:=skip PKG_LICENSE:=MIT PKG_LICENSE_FILES:=LICENSE -PKG_MAINTAINER:=sbilly +PKG_MAINTAINER:=suyuan <175338101@qqcom> PKG_BUILD_DEPENDS:=golang/host PKG_BUILD_PARALLEL:=1 @@ -31,7 +31,7 @@ GO_PKG_EXCLUDES:=excluded GO_PKG_LDFLAGS:=-s -w include $(INCLUDE_DIR)/package.mk -include $(TOPDIR)/feeds/packages/lang/golang/golang-package.mk +include $(TOPDIR)/feeds/openmptcprouter/golang/golang-package.mk define Package/netmaker $(call Package/netmaker/Default) @@ -45,7 +45,7 @@ define Package/netmaker/Default TITLE:=Netmaker for OpenWRT URL:=https://github.com/gravitl/netmaker DEPENDS:=$(GO_ARCH_DEPENDS) - MAINTAINER:=sbilly + MAINTAINER:=suyuan <175338101@qqcom> endef define Package/netmaker/Default/description From 2112c8c9beaf2acdc759720648434b5941f6c01b Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Wed, 28 Sep 2022 19:50:50 +0200 Subject: [PATCH 5/6] luci-app-status first modifications --- luci-app-status/luasrc/controller/status.lua | 4 +- luci-app-status/luasrc/controller/wan.lua | 551 ++++++++++++++++ luci-app-status/luasrc/view/status/wan.htm | 640 +++++++++++++++++++ 3 files changed, 1193 insertions(+), 2 deletions(-) create mode 100755 luci-app-status/luasrc/controller/wan.lua create mode 100755 luci-app-status/luasrc/view/status/wan.htm diff --git a/luci-app-status/luasrc/controller/status.lua b/luci-app-status/luasrc/controller/status.lua index 8cf891974..1bbb31e17 100755 --- a/luci-app-status/luasrc/controller/status.lua +++ b/luci-app-status/luasrc/controller/status.lua @@ -9,9 +9,9 @@ module("luci.controller.status", package.seeall) function index() entry({"admin", "system", "status"}, alias("admin", "system", "status", "server"), _("Settings"), 1) - entry({"admin", "system", "status","server"}, template("status/server"),_('Settings'),1).leaf = true + -- entry({"admin", "system", "status","server"}, template("status/server"),_('Settings'),1).leaf = true entry({"admin", "system", "status","status"}, template("status/wanstatus"),_('Status'),2).leaf = true - entry({"admin", "system", "status","server_add"}, post("server_add")) + -- entry({"admin", "system", "status","server_add"}, post("server_add")) entry({"admin", "system", "status", "interfaces_status"}, call("interfaces_status")).leaf = true entry({"admin", "system", "status", "multipath_bandwidth"}, call("multipath_bandwidth")).leaf = true entry({"admin", "system", "status", "interface_bandwidth"}, call("interface_bandwidth")).leaf = true diff --git a/luci-app-status/luasrc/controller/wan.lua b/luci-app-status/luasrc/controller/wan.lua new file mode 100755 index 000000000..7e5c2743c --- /dev/null +++ b/luci-app-status/luasrc/controller/wan.lua @@ -0,0 +1,551 @@ +local math = require "math" +local sys = require "luci.sys" +local json = require("luci.json") +local fs = require("nixio.fs") +local net = require "luci.model.network".init() +local ucic = luci.model.uci.cursor() +local ipc = require "luci.ip" +module("luci.controller.wan", package.seeall) + +function index() + local ucic = luci.model.uci.cursor() + menuentry = "status" + entry({"admin", "system", menuentry:lower()}, alias("admin", "system", menuentry:lower(), "wizard"), _(menuentry), 1) + entry({"admin", "system", menuentry:lower(), "wizard"}, template("status/wan"), _("Settings Wizard"), 1) + entry({"admin", "system", menuentry:lower(), "wizard_add"}, post("wizard_add")) +-- entry({"admin", "system", menuentry:lower(), "status"}, template("status/wanstatus"), _("Status"), 2).leaf = true +-- entry({"admin", "system", menuentry:lower(), "interfaces_status"}, call("interfaces_status")).leaf = true +-- entry({"admin", "system", menuentry:lower(), "settings"}, template("openmptcprouter/settings"), _("Advanced Settings"), 3).leaf = true +-- entry({"admin", "system", menuentry:lower(), "settings_add"}, post("settings_add")) +-- entry({"admin", "system", menuentry:lower(), "update_vps"}, post("update_vps")) +-- entry({"admin", "system", menuentry:lower(), "backup"}, template("openmptcprouter/backup"), _("Backup on server"), 3).leaf = true +-- entry({"admin", "system", menuentry:lower(), "backupgr"}, post("backupgr")) +-- entry({"admin", "system", menuentry:lower(), "debug"}, template("openmptcprouter/debug"), _("Show all settings"), 5).leaf = true +end + +function interface_from_device(dev) + for _, iface in ipairs(net:get_networks()) do + local ifacen = iface:name() + local ifacename = "" + ifacename = ucic:get("network",ifacen,"device") + if ifacename == "" then + ifacename = ucic:get("network",ifacen,"ifname") + end + if ifacename == dev then + return ifacen + end + end + return "" +end + +function uci_device_from_interface(intf) + intfname = ucic:get("network",intf,"device") + deviceuci = "" + ucic:foreach("network", "device", function(s) + if intfname == ucic:get("network",s[".name"],"name") then + deviceuci = s[".name"] + end + end) + return deviceuci +end + +function wizard_add() + local gostatus = true + + -- Force WAN zone firewall members to be a list + local fwwan = sys.exec("uci -q get firewall.zone_wan.network") + luci.sys.call("uci -q delete firewall.zone_wan.network") + for interface in fwwan:gmatch("%S+") do + luci.sys.call("uci -q add_list firewall.zone_wan.network=" .. interface) + end + ucic:save("firewall") + + -- Add new interface + local add_interface = luci.http.formvalue("add_interface") or "" + local add_interface_ifname = luci.http.formvalue("add_interface_ifname") or "" + if add_interface ~= "" then + local i = 1 + local multipath_master = false + ucic:foreach("network", "interface", function(s) + local sectionname = s[".name"] + if sectionname:match("^wan(%d+)$") then + if i <= tonumber(string.match(sectionname, '%d+')) then + i = tonumber(string.match(sectionname, '%d+')) + 1 + end + end + if ucic:get("network",sectionname,"multipath") == "master" then + multipath_master = true + end + end) + local defif = "eth0" + if add_interface_ifname == "" then + local defif1 = ucic:get("network","wan1_dev","device") or "" + if defif1 == "" then + defif1 = ucic:get("network","wan1_dev","ifname") or "" + end + if defif1 ~= "" then + defif = defif1 + end + else + defif = add_interface_ifname + end + + local ointf = interface_from_device(defif) or "" + local wanif = defif + if ointf ~= "" then + if ucic:get("network",ointf,"type") == "" then + ucic:set("network",ointf,"type","macvlan") + ucic:set("network",ointf,"device",ointf) + ucic:set("network",ointf .. "_dev","device") + ucic:set("network",ointf .. "_dev","type","macvlan") + ucic:set("network",ointf .. "_dev","mode","vepa") + ucic:set("network",ointf .. "_dev","ifname",defif) + ucic:set("network",ointf .. "_dev","name",ointf) + end + wanif = "wan" .. i + end + + ucic:set("network","wan" .. i,"interface") + ucic:set("network","wan" .. i,"device",defif) + ucic:set("network","wan" .. i,"proto","static") + ucic:set("openmptcprouter","wan" .. i,"interface") + if ointf ~= "" then + ucic:set("network","wan" .. i,"type","macvlan") + ucic:set("network","wan" .. i,"device","wan" .. i) + ucic:set("network","wan" .. i,"masterintf",defif) + ucic:set("network","wan" .. i .. "_dev","device") + ucic:set("network","wan" .. i .. "_dev","type","macvlan") + ucic:set("network","wan" .. i .. "_dev","mode","vepa") + ucic:set("network","wan" .. i .. "_dev","ifname",defif) + ucic:set("network","wan" .. i .. "_dev","name","wan" .. i) + ucic:set("network","wan" .. i .. "_dev","txqueuelen","20") + end + ucic:set("network","wan" .. i,"ip4table","wan") + if multipath_master then + ucic:set("network","wan" .. i,"multipath","on") + ucic:set("openmptcprouter","wan" .. i,"multipath","on") + else + ucic:set("network","wan" .. i,"multipath","master") + ucic:set("openmptcprouter","wan" .. i,"multipath","master") + end + ucic:set("network","wan" .. i,"defaultroute","0") + ucic:reorder("network","wan" .. i, i + 2) + ucic:save("network") + ucic:commit("network") + ucic:save("openmptcprouter") + ucic:commit("openmptcprouter") + + ucic:set("qos","wan" .. i,"interface") + ucic:set("qos","wan" .. i,"classgroup","Default") + ucic:set("qos","wan" .. i,"enabled","0") + ucic:set("qos","wan" .. i,"upload","4000") + ucic:set("qos","wan" .. i,"download","100000") + ucic:save("qos") + ucic:commit("qos") + + ucic:set("sqm","wan" .. i,"queue") + if ointf ~= "" then + ucic:set("sqm","wan" .. i,"interface","wan" .. i) + else + ucic:set("sqm","wan" .. i,"interface",defif) + end + ucic:set("sqm","wan" .. i,"qdisc","fq_codel") + ucic:set("sqm","wan" .. i,"script","simple.qos") + ucic:set("sqm","wan" .. i,"qdisc_advanced","0") + ucic:set("sqm","wan" .. i,"linklayer","none") + ucic:set("sqm","wan" .. i,"enabled","1") + ucic:set("sqm","wan" .. i,"debug_logging","0") + ucic:set("sqm","wan" .. i,"verbosity","5") + ucic:set("sqm","wan" .. i,"download","0") + ucic:set("sqm","wan" .. i,"upload","0") + ucic:set("sqm","wan" .. i,"iqdisc_opts","autorate-ingress dual-dsthost") + ucic:set("sqm","wan" .. i,"eqdisc_opts","dual-srchost") + ucic:save("sqm") + ucic:commit("sqm") + + luci.sys.call("uci -q add_list vnstat.@vnstat[-1].interface=" .. wanif) + luci.sys.call("uci -q commit vnstat") + + -- Dirty way to add new interface to firewall... + luci.sys.call("uci -q add_list firewall.zone_wan.network=wan" .. i) + luci.sys.call("uci -q commit firewall") + + luci.sys.call("/etc/init.d/macvlan restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/vnstat restart >/dev/null 2>/dev/null") + gostatus = false + end + + -- Remove existing interface + local delete_intf = luci.http.formvaluetable("delete") or "" + if delete_intf ~= "" then + for intf, _ in pairs(delete_intf) do + local defif = ucic:get("network",intf,"ifname") or "" + if defif == "" then + defif = ucic:get("network",intf,"ifname") + end + ucic:delete("network",intf) + if ucic:get("network",intf .. "_dev") ~= "" then + ucic:delete("network",intf .. "_dev") + end + ucic:save("network") + ucic:commit("network") + ucic:delete("sqm",intf) + ucic:save("sqm") + ucic:commit("sqm") + ucic:delete("qos",intf) + ucic:save("qos") + ucic:commit("qos") + ucic:delete("openmptcprouter",intf) + ucic:save("openmptcprouter") + ucic:commit("openmptcprouter") + if defif ~= nil and defif ~= "" then + luci.sys.call("uci -q del_list vnstat.@vnstat[-1].interface=" .. defif) + end + luci.sys.call("uci -q commit vnstat") + luci.sys.call("uci -q del_list firewall.zone_wan.network=" .. intf) + luci.sys.call("uci -q commit firewall") + gostatus = false + end + end + + -- Set interfaces settings + local interfaces = luci.http.formvaluetable("intf") + for intf, _ in pairs(interfaces) do + local label = luci.http.formvalue("cbid.network.%s.label" % intf) or "" + local proto = luci.http.formvalue("cbid.network.%s.proto" % intf) or "static" + local typeintf = luci.http.formvalue("cbid.network.%s.type" % intf) or "" + local masterintf = luci.http.formvalue("cbid.network.%s.masterintf" % intf) or "" + local ifname = luci.http.formvalue("cbid.network.%s.intf" % intf) or "" + local vlan = luci.http.formvalue("cbid.network.%s.vlan" % intf) or "" + local device_ncm = luci.http.formvalue("cbid.network.%s.device.ncm" % intf) or "" + local device_qmi = luci.http.formvalue("cbid.network.%s.device.qmi" % intf) or "" + local device_modemmanager = luci.http.formvalue("cbid.network.%s.device.modemmanager" % intf) or "" + local ipaddr = luci.http.formvalue("cbid.network.%s.ipaddr" % intf) or "" + local ip6addr = luci.http.formvalue("cbid.network.%s.ip6addr" % intf) or "" + local netmask = luci.http.formvalue("cbid.network.%s.netmask" % intf) or "" + local gateway = luci.http.formvalue("cbid.network.%s.gateway" % intf) or "" + local ip6gw = luci.http.formvalue("cbid.network.%s.ip6gw" % intf) or "" + local ipv6 = luci.http.formvalue("cbid.network.%s.ipv6" % intf) or "0" + local apn = luci.http.formvalue("cbid.network.%s.apn" % intf) or "" + local pincode = luci.http.formvalue("cbid.network.%s.pincode" % intf) or "" + local delay = luci.http.formvalue("cbid.network.%s.delay" % intf) or "" + local username = luci.http.formvalue("cbid.network.%s.username" % intf) or "" + local password = luci.http.formvalue("cbid.network.%s.password" % intf) or "" + local auth = luci.http.formvalue("cbid.network.%s.auth" % intf) or "" + local mode = luci.http.formvalue("cbid.network.%s.mode" % intf) or "" + local sqmenabled = luci.http.formvalue("cbid.sqm.%s.enabled" % intf) or "0" + local sqmautorate = luci.http.formvalue("cbid.sqm.%s.autorate" % intf) or "0" + local qosenabled = luci.http.formvalue("cbid.qos.%s.enabled" % intf) or "0" + local multipath = luci.http.formvalue("cbid.network.%s.multipath" % intf) or "on" + local lan = luci.http.formvalue("cbid.network.%s.lan" % intf) or "0" + local ttl = luci.http.formvalue("cbid.network.%s.ttl" % intf) or "" + if typeintf ~= "" then + if typeintf == "normal" then + typeintf = "" + end + ucic:set("network",intf,"type",typeintf) + end + if vlan ~= "" then + ifname = ifname .. '.' .. vlan + end + if typeintf == "macvlan" and masterintf ~= "" then + ucic:set("network",intf,"type","macvlan") + ucic:set("network",intf .. "_dev","device") + ucic:set("network",intf .. "_dev","type","macvlan") + ucic:set("network",intf .. "_dev","ifname",masterintf) + ucic:set("network",intf .. "_dev","mode","vepa") + ucic:set("network",intf .. "_dev","name",intf) + ucic:set("network",intf,"device",intf) + ucic:set("network",intf,"masterintf",masterintf) + elseif typeintf == "" and ifname ~= "" and (proto == "static" or proto == "dhcp" or proto == "dhcpv6") then + ucic:set("network",intf,"device",ifname) + if uci_device_from_interface(intf) == "" then + ucic:set("network",intf .. "_dev","device") + ucic:set("network",intf .. "_dev","name",ifname) + end + elseif typeintf == "" and device ~= "" and proto == "ncm" then + ucic:set("network",intf,"device",device_ncm) + if uci_device_from_interface(intf) == "" then + ucic:set("network",intf .. "_dev","device") + ucic:set("network",intf .. "_dev","name",device_ncm) + end + elseif typeintf == "" and device ~= "" and proto == "qmi" then + ucic:set("network",intf,"device",device_qmi) + if uci_device_from_interface(intf) == "" then + ucic:set("network",intf .. "_dev","device") + ucic:set("network",intf .. "_dev","name",device_qmi) + end + elseif typeintf == "" and device ~= "" and proto == "modemmanager" then + ucic:set("network",intf,"device",device_manager) + if uci_device_from_interface(intf) == "" then + ucic:set("network",intf .. "_dev","device") + ucic:set("network",intf .. "_dev","name",device_manager) + end + elseif typeintf == "" and ifname ~= "" and proto == "static" then + ucic:set("network",intf,"device",ifname) + if uci_device_from_interface(intf) == "" then + ucic:set("network",intf .. "_dev","device") + ucic:set("network",intf .. "_dev","name",ifname) + end + end + if typeintf ~= "macvlan" then + if ucic:get("network",intf .. "_dev","type") == "macvlan" then + ucic:delete("network",intf .. "_dev","type") + ucic:delete("network",intf .. "_dev","mode") + ucic:delete("network",intf .. "_dev","ifname") + ucic:delete("network",intf .. "_dev","macaddr") + end + ucic:delete("network",intf,"masterintf") + end + if proto == "pppoe" then + ucic:set("network",intf,"pppd_options","persist maxfail 0") + end + if proto ~= "other" then + ucic:set("network",intf,"proto",proto) + end + + uci_device = uci_device_from_interface(intf) + if uci_device == "" then + uci_device = intf .. "_dev" + end + ucic:set("network",uci_device,"ttl",ttl) + + --ucic:set("network",intf,"apn",apn) + --ucic:set("network",intf,"pincode",pincode) + --ucic:set("network",intf,"delay",delay) + --ucic:set("network",intf,"username",username) + --ucic:set("network",intf,"password",password) + --ucic:set("network",intf,"auth",auth) + --ucic:set("network",intf,"mode",mode) + --ucic:set("network",intf,"label",label) + --ucic:set("network",intf,"ipv6",ipv6) + if lan == "1" then + ucic:set("network",intf,"multipath","off") + else + ucic:set("network",intf,"multipath",multipath) + ucic:set("openmptcprouter",intf,"multipath",multipath) + end + ucic:set("network",intf,"defaultroute",0) + ucic:set("network",intf,"peerdns",0) + if ipaddr ~= "" then + ucic:set("network",intf,"ipaddr",ipaddr:gsub("%s+", "")) + ucic:set("network",intf,"netmask",netmask:gsub("%s+", "")) + ucic:set("network",intf,"gateway",gateway:gsub("%s+", "")) + else + ucic:set("network",intf,"ipaddr","") + ucic:set("network",intf,"netmask","") + ucic:set("network",intf,"gateway","") + end + if ip6addr ~= "" then + ucic:set("network",intf,"ip6addr",ip6addr:gsub("%s+", "")) + ucic:set("network",intf,"ip6gw",ip6gw:gsub("%s+", "")) + else + ucic:set("network",intf,"ip6addr","") + ucic:set("network",intf,"ip6gw","") + end + + if proto == "dhcpv6" then + ucic:set("network",intf,"reqaddress","try") + ucic:set("network",intf,"reqprefix","no") + ucic:set("network",intf,"iface_map","0") + ucic:set("network",intf,"iface_dslite","0") + ucic:set("network",intf,"iface_464xlate","0") + ucic:set("network",intf,"ipv6","1") + end + + ucic:delete("openmptcprouter",intf,"lc") + ucic:save("openmptcprouter") + + --local multipathvpn = luci.http.formvalue("multipathvpn.%s.enabled" % intf) or "0" + --ucic:set("openmptcprouter",intf,"multipathvpn",multipathvpn) + --ucic:save("openmptcprouter") + + end + -- Disable multipath on LAN, VPN and loopback + ucic:set("network","loopback","multipath","off") + ucic:set("network","lan","multipath","off") + ucic:set("network","omr6in4","multipath","off") + ucic:set("network","omrvpn","multipath","off") + + ucic:save("network") + ucic:commit("network") + + ucic:save("network") + ucic:commit("network") + + ucic:save("openmptcprouter") + ucic:commit("openmptcprouter") + + -- Restart all + menuentry = "status" + if gostatus == true then + --luci.sys.call("/etc/init.d/macvlan restart >/dev/null 2>/dev/null") + luci.sys.call("(env -i /bin/ubus call network reload) >/dev/null 2>/dev/null") + luci.sys.call("ip addr flush dev tun0 >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/omr-tracker stop >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/mptcp restart >/dev/null 2>/dev/null") + --if openmptcprouter_vps_key ~= "" then + -- luci.sys.call("/etc/init.d/openmptcprouter-vps restart >/dev/null 2>/dev/null") + -- luci.sys.call("sleep 2") + --end + luci.sys.call("/etc/init.d/shadowsocks-libev restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/glorytun restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/glorytun-udp restart >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/mlvpn restart >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/ubond restart >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/mptcpovervpn restart >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/openvpn restart >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/openvpnbonding restart >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/dsvpn restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/omr-tracker start >/dev/null 2>/dev/null") + --luci.sys.call("/etc/init.d/omr-6in4 restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/vnstat restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/v2ray restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/sqm-autorate restart >/dev/null 2>/dev/null") + luci.sys.call("/etc/init.d/sysntpd restart >/dev/null 2>/dev/null") + luci.http.redirect(luci.dispatcher.build_url("admin/system/" .. menuentry:lower() .. "/status")) + else + luci.http.redirect(luci.dispatcher.build_url("admin/system/" .. menuentry:lower() .. "/wizard")) + end + return +end + +function get_device(interface) + local dump = require("luci.util").ubus("network.interface.%s" % interface, "status", {}) + if dump ~= nil then + if dump['l3_device'] ~= nil then + return dump['l3_device'] + elseif dump['device'] ~= nil then + return dump['device'] + else + return "" + end + else + return "" + end +end + +-- This function come from modules/luci-bbase/luasrc/tools/status.lua from old OpenWrt +-- Copyright 2011 Jo-Philipp Wich +-- Licensed to the public under the Apache License 2.0. +local function dhcp_leases_common(family) + local rv = { } + local nfs = require "nixio.fs" + local sys = require "luci.sys" + local leasefile = "/tmp/dhcp.leases" + + ucic:foreach("dhcp", "dnsmasq", + function(s) + if s.leasefile and nfs.access(s.leasefile) then + leasefile = s.leasefile + return false + end + end) + + local fd = io.open(leasefile, "r") + if fd then + while true do + local ln = fd:read("*l") + if not ln then + break + else + local ts, mac, ip, name, duid = ln:match("^(%d+) (%S+) (%S+) (%S+) (%S+)") + local expire = tonumber(ts) or 0 + if ts and mac and ip and name and duid then + if family == 4 and not ip:match(":") then + rv[#rv+1] = { + expires = (expire ~= 0) and os.difftime(expire, os.time()), + macaddr = ipc.checkmac(mac) or "00:00:00:00:00:00", + ipaddr = ip, + hostname = (name ~= "*") and name + } + elseif family == 6 and ip:match(":") then + rv[#rv+1] = { + expires = (expire ~= 0) and os.difftime(expire, os.time()), + ip6addr = ip, + duid = (duid ~= "*") and duid, + hostname = (name ~= "*") and name + } + end + end + end + end + fd:close() + end + + local lease6file = "/tmp/hosts/odhcpd" + ucic:foreach("dhcp", "odhcpd", + function(t) + if t.leasefile and nfs.access(t.leasefile) then + lease6file = t.leasefile + return false + end + end) + local fd = io.open(lease6file, "r") + if fd then + while true do + local ln = fd:read("*l") + if not ln then + break + else + local iface, duid, iaid, name, ts, id, length, ip = ln:match("^# (%S+) (%S+) (%S+) (%S+) (-?%d+) (%S+) (%S+) (.*)") + local expire = tonumber(ts) or 0 + if ip and iaid ~= "ipv4" and family == 6 then + rv[#rv+1] = { + expires = (expire >= 0) and os.difftime(expire, os.time()), + duid = duid, + ip6addr = ip, + hostname = (name ~= "-") and name + } + elseif ip and iaid == "ipv4" and family == 4 then + rv[#rv+1] = { + expires = (expire >= 0) and os.difftime(expire, os.time()), + macaddr = sys.net.duid_to_mac(duid) or "00:00:00:00:00:00", + ipaddr = ip, + hostname = (name ~= "-") and name + } + end + end + end + fd:close() + end + + if family == 6 then + local _, lease + local hosts = sys.net.host_hints() + for _, lease in ipairs(rv) do + local mac = sys.net.duid_to_mac(lease.duid) + local host = mac and hosts[mac] + if host then + if not lease.name then + lease.host_hint = host.name or host.ipv4 or host.ipv6 + elseif host.name and lease.hostname ~= host.name then + lease.host_hint = host.name + end + end + end + end + + return rv +end + +function interfaces_status() + local ut = require "luci.util" + --local mArray = ut.ubus("openmptcprouter", "status", {}) or {_=0} + local mArray = luci.json.decode(ut.trim(sys.exec("/bin/ubus -t 600 -S call openmptcprouter status 2>/dev/null"))) + + if mArray ~= nil and mArray.openmptcprouter ~= nil then + mArray.openmptcprouter["remote_addr"] = luci.http.getenv("REMOTE_ADDR") or "" + mArray.openmptcprouter["remote_from_lease"] = false + local leases=dhcp_leases_common(4) + for _, value in pairs(leases) do + if value["ipaddr"] == mArray.openmptcprouter["remote_addr"] then + mArray.openmptcprouter["remote_from_lease"] = true + mArray.openmptcprouter["remote_hostname"] = value["hostname"] + end + end + end + + luci.http.prepare_content("application/json") + luci.http.write_json(mArray) +end diff --git a/luci-app-status/luasrc/view/status/wan.htm b/luci-app-status/luasrc/view/status/wan.htm new file mode 100755 index 000000000..10cbb1861 --- /dev/null +++ b/luci-app-status/luasrc/view/status/wan.htm @@ -0,0 +1,640 @@ +<%+header%> + +<% + local uci = require("luci.model.uci").cursor() + local net = require "luci.model.network".init() + local fs = require "nixio.fs" + local sys = require "luci.sys" + local ut = require "luci.util" + local ifaces = sys.net:devices() + local ifttyu = nixio.fs.glob("/dev/ttyUSB*") + local ifttyc = nixio.fs.glob("/dev/cdc-wdm*") + local sqm = luci.sys.exec("opkg list-installed | grep -q luci-app-sqm && echo -n '1' || echo -n '0'") + local qos = luci.sys.exec("opkg list-installed | grep -q luci-app-qos && echo -n '1' || echo -n '0'") + menuentry = "status" + function device_notvirtual(dev) + if dev:match("^eth.*") or dev:match("^wwan.*") or dev:match("^tun.*") or dev:match("/") then + return true + end + networks = net:get_networks() + for _, iface in ipairs(networks) do + local ifacen = iface:name() + local ifacename = uci:get("network",ifacen,"device") + local ifacetype = uci:get("network",ifacen,"type") or "" + local ifaceproto = uci:get("network",ifacen,"proto") or "" + --if ifacename == dev and (ifacetype == "macvlan" or ifacetype == "bridge" or ifaceproto == "6in4") then + if ifacename == dev and (ifacetype == "macvlan" or ifaceproto == "6in4") then + return false + end + end + return true + end + function splitstring(inputstr, sep) + if inputstr == nil then + return "" + end + if sep == nil then + sep = "%s" + end + local t={} + for str in string.gmatch(inputstr, "([^"..sep.."]+)") do + table.insert(t, str) + end + return t + end + + alltty = {} + iftty = luci.sys.exec("timeout 1 /usr/bin/mmcli -L") + for listtty in iftty:gmatch("([^\r\n]*)[\r\n]") do + modemid = luci.util.trim(luci.sys.exec("echo '" .. listtty .. "' | awk -F' ' '{print $1}' | awk -F/ '{print $6}'")) + if modemid ~= '' then + modeminfo = luci.sys.exec("timeout 1 /usr/bin/mmcli -m " .. modemid .. " --output-keyvalue") + tty = luci.util.trim(luci.sys.exec("echo '" .. modeminfo .. "' | grep 'modem.generic.device ' | awk -F': ' '{print $2}'")) + table.insert(alltty, tty) + end + end + + +%> + + + +<% if stderr and #stderr > 0 then %>
<%=pcdata(stderr)%>
<% end %> +
+
+

<%:Wizard%>

+
+ <%:Interfaces settings%> + +<% + for _, iface in ipairs(net:get_networks()) do + local ifname = iface:name() + local firewall_wan = luci.util.trim(luci.sys.exec("uci -q get firewall.zone_wan.network | tr ' ' '\n' | grep \'^" .. ifname .. "$\'")) + if firewall_wan ~= "" and ifname:match("^wan.*") then + +-- local multipath = uci:get("network",ifname,"multipath") +-- local multipathvpn = uci:get("openmptcprouter",ifname,"multipathvpn") +-- local vpn = uci:get("openmptcprouter",ifname,"vpn") +-- if (multipath ~= nil and multipath ~= "off" and vpn ~= "1") or multipathvpn == "1" then +%> +
+ +
+

<%=ifname%>

+
+ +
+ +
+ "> +
+
+ <%:Label for the interface%> +
+
+
+ + + +
+ +
+ <% findproto = 0 %> + +
+
+ <%:You can use DHCP if you have multiple real ethernet ports. Select other if you want to use another protocol available in Network Interfaces page.%> +
+
+
+ + +
+ +
+ " data-type="ip4addr"> +
+
+ <%:Set an IP in the same network as the modem%> +
+
+
+
+ +
+ " data-type="ip4addr"> +
+
+
+ +
+ " data-type="ip4addr"> +
+
+ <%:Set here IP of the modem%> +
+
+
+ <% + ipv6list = uci:get_list("network",ifname,"ip6addr") + for key, value in pairs(ipv6list) do + %> +
+ +
+ +
+
+ <%:Set an IP in the same network as the modem%> +
+
+
+ <% + end + if table.getn(ipv6list) ~= 0 then + %> +
+ +
+ " data-type="ip6addr" data-optional="true"> +
+
+ <%:Set here IP of the modem%> +
+
+
+ <% + else + %> +
+ +
+ +
+
+ <%:Set an IP in the same network as the modem%> +
+
+
+
+ +
+ " data-type="ip6addr"> +
+
+ <%:Set here IP of the modem%> +
+
+
+ <% + end + %> + + +
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ "> +
+
+
+ +
+ "> +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ "> +
+
+
+ +
+ "> +
+
+
+ +
+ "> +
+
+ <% + if uci:get("openmptcprouter",ifname,"multipathvpn") == "1" then + %> +
+ +
+ +
+
+ <%:Only one interface must be set as "Master", this should be the most stable interface.%> +
+
+
+ <% else %> +
+ +
+ +
+
+ <% + end + %> + + + <% + local download = "0" + local upload = "0" + download = uci:get("network",ifname,"downloadspeed") or "0" + upload = uci:get("network",ifname,"uploadspeed") or "0" + cake = uci:get("sqm",ifname,"qdisc") or "cake" + --if download == "0" or upload == "0" then + -- if nixio.fs.access("/etc/init.d/sqm") then + -- download = uci:get("sqm",ifname,"download") + -- upload = uci:get("sqm",ifname,"upload") + -- else + -- download = uci:get("qos",ifname,"download") + -- upload = uci:get("qos",ifname,"upload") + -- end + --end + %> + + <% + if sqm == "1" then + %> + + + <% + end + %> + <% + if qos == "1" then + %> + + <% + end + %> + + +
+<% + end + end +%> + + + +
+
+<% + if uci:get('wireless','default_radio0') == 'wifi-iface' and uci:get('wireless','default_radio0','disabled') ~= '1' then +%> +
+

<%:Wifi%>

+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+ +
+
+<% + end +%> +
+ + + +
+
+ + +<%+footer%> From d3cb02bd05955bf67d6fea1da6e76b15814f5565 Mon Sep 17 00:00:00 2001 From: suyuan <175338101@qq.com> Date: Sat, 1 Oct 2022 11:14:50 +0800 Subject: [PATCH 6/6] Revert "Update Makefile" This reverts commit 09977d0f5a6b9064b5cb62779bb87db63b25d862. --- netmaker-openwrt/netmaker/Makefile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/netmaker-openwrt/netmaker/Makefile b/netmaker-openwrt/netmaker/Makefile index 55544abba..903dd2beb 100644 --- a/netmaker-openwrt/netmaker/Makefile +++ b/netmaker-openwrt/netmaker/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2019 suyuan <175338101@qqcom> +# Copyright (C) 2019 sbilly # # This is free software, licensed under the MIT License. # See /LICENSE for more information. @@ -8,18 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=netmaker -PKG_VERSION:=0.16.0 +PKG_VERSION:=0.9.4 PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/gravitl/netmaker.git -PKG_SOURCE_VERSION:=db3288782965a7d4713cf271c1277957749802d1 -PKG_SOURCE_DATE:=20220930 +PKG_SOURCE_VERSION:=e9bce264719f88c30e252ecc754d08f422f4c080 +PKG_SOURCE_DATE:=20220117 PKG_MIRROR_HASH:=skip PKG_LICENSE:=MIT PKG_LICENSE_FILES:=LICENSE -PKG_MAINTAINER:=suyuan <175338101@qqcom> +PKG_MAINTAINER:=sbilly PKG_BUILD_DEPENDS:=golang/host PKG_BUILD_PARALLEL:=1 @@ -31,7 +31,7 @@ GO_PKG_EXCLUDES:=excluded GO_PKG_LDFLAGS:=-s -w include $(INCLUDE_DIR)/package.mk -include $(TOPDIR)/feeds/openmptcprouter/golang/golang-package.mk +include $(TOPDIR)/feeds/packages/lang/golang/golang-package.mk define Package/netmaker $(call Package/netmaker/Default) @@ -45,7 +45,7 @@ define Package/netmaker/Default TITLE:=Netmaker for OpenWRT URL:=https://github.com/gravitl/netmaker DEPENDS:=$(GO_ARCH_DEPENDS) - MAINTAINER:=suyuan <175338101@qqcom> + MAINTAINER:=sbilly endef define Package/netmaker/Default/description