Disabled IF_LAN

This commit is contained in:
gSpot
2022-03-17 18:48:18 +03:00
parent 94a52da8dc
commit 5446b4ccee
11 changed files with 15 additions and 21 deletions
+3 -9
View File
@@ -9,9 +9,9 @@ LUA_MODULE=1
LUCI_APP=1
OWRT_VERSION="current"
RUAB_VERSION="0.9.1-1"
RUAB_MOD_LUA_VERSION="0.9.1-1"
RUAB_LUCI_APP_VERSION="0.9.1-1"
RUAB_VERSION="0.9.1-2"
RUAB_MOD_LUA_VERSION="0.9.1-2"
RUAB_LUCI_APP_VERSION="0.9.1-2"
BASE_URL="https://github.com/gSpotx2f/packages-openwrt/raw/master"
PKG_DIR="/tmp"
@@ -211,17 +211,11 @@ TorrcSettings() {
}
InstallTorConfig() {
local _if_lan
InstallPackages "tor" "tor-geoip"
BackupFile "$FILE_TORRC"
DlFile "$URL_TORRC" "$FILE_TORRC"
TorrcSettings
$UCI_CMD set ruantiblock.config.proxy_mode="1"
_if_lan=`$UCI_CMD get network.lan.ifname`
if [ -z "$_if_lan" ]; then
_if_lan="eth0"
fi
$UCI_CMD set ruantiblock.config.if_lan="$_if_lan"
# dnsmasq rebind protection
$UCI_CMD set dhcp.@dnsmasq[0].rebind_localhost='1'
$UCI_CMD set dhcp.@dnsmasq[0].rebind_domain='.onion'
+1 -1
View File
@@ -4,7 +4,7 @@
include $(TOPDIR)/rules.mk
PKG_VERSION:=0.9.1-1
PKG_VERSION:=0.9.1-2
LUCI_TITLE:=LuCI support for ruantiblock
LUCI_DEPENDS:=+ruantiblock
LUCI_PKGARCH:=all
@@ -62,7 +62,6 @@ return view.extend({
};
this.appStatusCode = data[0].code;
let p_dir_arr = data[1];
let lan_iface = uci.get('network', 'lan', 'ifname') || 'eth0';
let vpn_iface = uci.get('network', 'VPN', 'ifname') || 'tun0';
if(p_dir_arr) {
@@ -162,8 +161,7 @@ return view.extend({
_('LAN interface'));
o.multiple = false;
o.noaliases = true;
o.rmempty = false;
o.default = lan_iface;
o.optional = true;
// TOR_TRANS_PORT
o = s.taboption('tor_settings', form.Value, 'tor_trans_port',
+1 -1
View File
@@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=ruantiblock-mod-lua
PKG_VERSION:=0.9.1
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_MAINTAINER:=gSpot <https://github.com/gSpotx2f/ruantiblock_openwrt>
include $(INCLUDE_DIR)/package.mk
+1 -1
View File
@@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=ruantiblock-mod-py
PKG_VERSION:=0.9.1
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_MAINTAINER:=gSpot <https://github.com/gSpotx2f/ruantiblock_openwrt>
include $(INCLUDE_DIR)/package.mk
+1 -1
View File
@@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=ruantiblock
PKG_VERSION:=0.9.1
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_MAINTAINER:=gSpot <https://github.com/gSpotx2f/ruantiblock_openwrt>
include $(INCLUDE_DIR)/package.mk
-1
View File
@@ -3,7 +3,6 @@ config main 'config'
option proxy_mode '1'
option proxy_local_clients '1'
option ipset_clear_sets '0'
option if_lan 'eth0'
option if_vpn 'tun0'
option tor_trans_port '9040'
option onion_dns_addr '127.0.0.1#9053'
@@ -1,4 +1,3 @@
^youtube[.]com
parimatch
paripartners
marathon
@@ -17,7 +17,7 @@ PROXY_LOCAL_CLIENTS=1
### Удаление записей из основных сетов перед началом заполнения временных сетов при обновлении (для освобождения оперативной памяти перед заполнением сетов) (0 - off, 1 - on)
IPSET_CLEAR_SETS=0
### Входящий сетевой интерфейс для правил iptables
IF_LAN="eth0"
IF_LAN=""
### VPN интерфейс для правил маршрутизации
IF_VPN="tun0"
### Порт транспарентного proxy Tor (параметр TransPort в torrc)
@@ -7,7 +7,11 @@ VPN_ROUTE_TABLE=99
### Tor
IPT_TABLE="nat"
if [ -n "$IF_LAN" ]; then
IPT_FIRST_CHAIN_RULE="-i ${IF_LAN} -j ${IPT_CHAIN}"
else
IPT_FIRST_CHAIN_RULE="-j ${IPT_CHAIN}"
fi
IPT_IPSET_TARGET="dst -p tcp -j REDIRECT --to-ports ${TOR_TRANS_PORT}"
IPT_IPSETS="${IPSET_ONION} ${IPSET_CIDR} ${IPSET_IP} ${IPSET_DNSMASQ}"
+1 -1
View File
@@ -32,7 +32,7 @@ export PROXY_LOCAL_CLIENTS=1
### Удаление записей из основных сетов перед началом заполнения временных сетов при обновлении (для освобождения оперативной памяти перед заполнением сетов) (0 - off, 1 - on)
export IPSET_CLEAR_SETS=0
### Входящий сетевой интерфейс для правил iptables
export IF_LAN="eth0"
export IF_LAN=""
### VPN интерфейс для правил iptables
export IF_VPN="tun0"
### Порт транспарентного proxy Tor (параметр TransPort в torrc)