mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
icwmp: 8.2.19
This commit is contained in:
parent
431325e6e6
commit
9b823e5937
2 changed files with 18 additions and 11 deletions
|
|
@ -8,11 +8,11 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=icwmp
|
||||
PKG_VERSION:=8.2.18
|
||||
PKG_VERSION:=8.2.19
|
||||
PKG_FIXUP:=autoreconf
|
||||
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/icwmp.git
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_VERSION:=00e48a59436160b1692f2da3590904bf296f1ab4
|
||||
PKG_SOURCE_VERSION:=d18400eca5e22abfefacd386e669466d16d1b18e
|
||||
PKG_RELEASE=$(PKG_SOURCE_VERSION)
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
|
||||
PKG_MIRROR_HASH:=skip
|
||||
|
|
|
|||
|
|
@ -1,6 +1,12 @@
|
|||
#!/bin/sh
|
||||
|
||||
#created by the icwmp package
|
||||
log() {
|
||||
echo "${@}"|logger -t firewall.cwmp -p info
|
||||
}
|
||||
|
||||
if [ ! -f "/var/state/cwmp" ]; then
|
||||
touch "/var/state/cwmp"
|
||||
exit 0;
|
||||
fi
|
||||
|
||||
|
|
@ -10,22 +16,23 @@ ipaddr=$(uci -c /var/state -q get cwmp.acs.ip)
|
|||
ip6addr=$(uci -c /var/state -q get cwmp.acs.ip6)
|
||||
incoming_rule=$(uci -q get cwmp.cpe.incoming_rule|tr 'A-Z' 'a-z')
|
||||
|
||||
if [ "$zone_name" = "" ]; then
|
||||
if [ -z "${zone_name}" ]; then
|
||||
log "empty firewall zone name"
|
||||
exit 0
|
||||
elif [ "$zone_name" = "icwmp" ]; then
|
||||
iptables -nL zone_icwmp_input 2> /dev/null
|
||||
if [ $? != 0 ]; then
|
||||
iptables -N zone_icwmp_input
|
||||
iptables -t filter -A INPUT -j zone_icwmp_input
|
||||
iptables -I zone_icwmp_input -p tcp --dport $port -j REJECT
|
||||
iptables -w 1 -N zone_icwmp_input
|
||||
iptables -w 1 -t filter -A INPUT -j zone_icwmp_input
|
||||
iptables -w 1 -I zone_icwmp_input -p tcp --dport $port -j REJECT
|
||||
else
|
||||
iptables -F zone_icwmp_input
|
||||
iptables -I zone_icwmp_input -p tcp --dport $port -j REJECT
|
||||
iptables -w 1 -F zone_icwmp_input
|
||||
iptables -w 1 -I zone_icwmp_input -p tcp --dport $port -j REJECT
|
||||
fi
|
||||
else
|
||||
iptables -F zone_icwmp_input 2> /dev/null
|
||||
iptables -t filter -D INPUT -j zone_icwmp_input 2> /dev/null
|
||||
iptables -X zone_icwmp_input 2> /dev/null
|
||||
iptables -w 1 -F zone_icwmp_input 2> /dev/null
|
||||
iptables -w 1 -t filter -D INPUT -j zone_icwmp_input 2> /dev/null
|
||||
iptables -w 1 -X zone_icwmp_input 2> /dev/null
|
||||
fi
|
||||
|
||||
cmd="iptables -w 1 -I zone_${zone_name}_input -p tcp"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue