forked from Ysurac/openmptcprouter-feeds
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
45 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,7 +41,7 @@ define Package/iptables-mod-ndpi | |
# DEPENDS:=+iptables +iptables-mod-conntrack-extra +kmod-ipt-ndpi +libpcap | ||
# DEPENDS:=+iptables +kmod-ipt-ndpi +libpcap @(LINUX_5_4||LINUX_5_15||TARGET_x86_64) | ||
# DEPENDS:=+iptables +kmod-ipt-ndpi +libpcap @(LINUX_5_4||LINUX_5_15) @!TARGET_ramips | ||
DEPENDS:=+iptables +kmod-ipt-ndpi +libpcap @!TARGET_ramips @!LINUX_6_6 @!LINUX_6_10 | ||
DEPENDS:=+iptables +kmod-ipt-ndpi +libpcap @!TARGET_ramips @!LINUX_6_6 @!LINUX_6_10 @!LINUX_6_11 | ||
MAINTAINER:=Ycarus (Yannick Chabanois) <[email protected]> | ||
endef | ||
|
||
|
@@ -83,7 +83,7 @@ define KernelPackage/ipt-ndpi | |
TITLE:= nDPI net netfilter module | ||
# DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap @(LINUX_5_4||LINUX_5_15||TARGET_x86_64) | ||
# DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap @(LINUX_5_4||LINUX_5_15) @!TARGET_ramips | ||
DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +(LINUX_5_4||LINUX_6_1):kmod-ipt-compat-xtables +libpcap @!TARGET_ramips @!LINUX_6_6 @!LINUX_6_10 | ||
DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +(LINUX_5_4||LINUX_6_1):kmod-ipt-compat-xtables +libpcap @!TARGET_ramips @!LINUX_6_6 @!LINUX_6_10 @!LINUX_6_11 | ||
# DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap | ||
KCONFIG:=CONFIG_NF_CONNTRACK_LABELS=y \ | ||
CONFIG_NETFILTER_XT_MATCH_CONNLABEL=y | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
#!/bin/sh /etc/rc.common | ||
# Copyright (C) 2018-2023 Ycarus (Yannick Chabanois) <[email protected]> for OpenMPTCProuter | ||
# Copyright (C) 2018-2024 Ycarus (Yannick Chabanois) <[email protected]> for OpenMPTCProuter | ||
|
||
START=98 | ||
STOP=10 | ||
|
@@ -124,6 +124,7 @@ _bypass_domain() { | |
local family=$3 | ||
local noipv6=$4 | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
[ -z "$intf" ] && intf="all" | ||
if [ -n "$domain" ]; then | ||
domain=$(echo $domain | sed 's:^\.::') | ||
|
@@ -160,6 +161,7 @@ _bypass_mac() { | |
config_get enabled $1 enabled | ||
[ "$enabled" = "0" ] && return | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
local intfid="$(uci -q get omr-bypass.$intf.id)" | ||
|
||
[ -z "$intf" ] && intf="all" | ||
|
@@ -186,6 +188,7 @@ _bypass_lan_ip() { | |
config_get enabled $1 enabled | ||
[ "$enabled" = "0" ] && return | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
#[ -n "$intf" ] && [ -z "$(ipset --list | grep omr_dst_bypass_$intf)" ] && return | ||
local intfid="$(uci -q get omr-bypass.$intf.id)" | ||
|
||
|
@@ -217,6 +220,7 @@ _bypass_dest_port() { | |
config_get enabled $1 enabled | ||
[ "$enabled" = "0" ] && return | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
#[ -n "$intf" ] && [ -z "$(ipset --list | grep omr_dst_bypass_$intf)" ] && return | ||
local intfid="$(uci -q get omr-bypass.$intf.id)" | ||
|
||
|
@@ -259,6 +263,7 @@ _bypass_src_port() { | |
config_get enabled $1 enabled | ||
[ "$enabled" = "0" ] && return | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
#[ -n "$intf" ] && [ -z "$(ipset --list | grep omr_dst_bypass_$intf)" ] && return | ||
local intfid="$(uci -q get omr-bypass.$intf.id)" | ||
|
||
|
@@ -307,6 +312,7 @@ _bypass_proto() { | |
[ -z "$noipv6" ] && noipv6="0" | ||
[ -z "$family" ] && family="ipv4ipv6" | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
#[ -n "$intf" ] && [ -z "$(ipset --list | grep omr_dst_bypass_$intf)" ] && return | ||
local intfid="$(uci -q get omr-bypass.$intf.id)" | ||
|
||
|
@@ -406,6 +412,7 @@ _bypass_proto_without_ndpi() { | |
[ -z "$noipv6" ] && noipv6="0" | ||
[ -z "$family" ] && family="ipv4ipv6" | ||
intf=$(echo $intf | sed -e 's/\./_/') | ||
intf=$(echo $intf | sed -e 's/-/_/') | ||
#[ -n "$intf" ] && [ -z "$(ipset --list | grep omr_dst_bypass_$intf)" ] && return | ||
local intfid="$(uci -q get omr-bypass.$intf.id)" | ||
|
||
|
@@ -732,9 +739,9 @@ _intf_rule() { | |
#config_load shadowsocks-rust | ||
#config_foreach _intf_rule_ss_rules ss_rules | ||
_intf_rule_ss_rules | ||
elif [ "$(uci -q get openmptcprouter.settings.proxy)" = "v2ray" ] && [ "$(uci -q get v2ray.main.enabled)" = "1" ]; then | ||
elif [ -n "$(uci -q get openmptcprouter.settings.proxy | grep v2ray)" ] && [ "$(uci -q get v2ray.main.enabled)" = "1" ]; then | ||
_intf_rule_v2ray_rules | ||
elif [ "$(uci -q get openmptcprouter.settings.proxy)" = "xray" ] && [ "$(uci -q get xray.main.enabled)" = "1" ]; then | ||
elif [ -n "$(uci -q get openmptcprouter.settings.proxy | grep xray)" ] && [ "$(uci -q get xray.main.enabled)" = "1" ]; then | ||
_intf_rule_xray_rules | ||
fi | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters