From: Felix Fietkau Date: Thu, 9 Nov 2006 05:40:27 +0000 (+0000) Subject: comgt: make firewalling changes when umts goes up or down X-Git-Tag: whiterussian_0.9~90 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=67fe17f8b02953e6f7733a39ef7e7bee1325544c;p=openwrt%2Fsvn-archive%2Fopenwrt.git comgt: make firewalling changes when umts goes up or down SVN-Revision: 5476 --- diff --git a/openwrt/package/comgt/files/wwan.iface b/openwrt/package/comgt/files/wwan.iface index fe3663e0ce..4e9c1c2f79 100644 --- a/openwrt/package/comgt/files/wwan.iface +++ b/openwrt/package/comgt/files/wwan.iface @@ -1,9 +1,17 @@ [ "$INTERFACE" = "wwan" ] && { + WWAN="$(nvram get wwan_ifname)" case "$ACTION" in ifup) + iptables -I LAN_ACCEPT 1 -i "$WWAN" -j RETURN + iptables -A FORWARD -o "$WWAN" -j ACCEPT + iptables -t nat -A POSTROUTING -o "$WWAN" -j MASQUERADE echo 0 > /proc/diag/led/3g_blink ;; ifdown) + iptables -D LAN_ACCEPT -i "$WWAN" -j RETURN + iptables -D FORWARD -o "$WWAN" -j ACCEPT + iptables -t nat -D POSTROUTING -o "$WWAN" -j MASQUERADE + echo 0 > /proc/diag/led/3g_blink echo 0 > /proc/diag/led/3g_blue echo 0 > /proc/diag/led/3g_green echo 0 > /proc/diag/led/3g_blink