summaryrefslogtreecommitdiffhomepage
path: root/module
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2008-04-28 08:16:07 +0000
committerSteven Barth <steven@midlink.org>2008-04-28 08:16:07 +0000
commitde13f9f262da3da7bee2c48dad8be23d09528a9f (patch)
tree8a437a2f43c75db92f2ecee8af33fbb82c2f4bf5 /module
parentdef5d719241cad812c9dda4a5519ef4a0755d90b (diff)
* Added NAT rule for Freifunk DHCP
Diffstat (limited to 'module')
-rw-r--r--module/admin-core/contrib/init.d/luci_freifunk11
-rw-r--r--module/admin-core/src/view/admin_system/reboot.htm2
2 files changed, 12 insertions, 1 deletions
diff --git a/module/admin-core/contrib/init.d/luci_freifunk b/module/admin-core/contrib/init.d/luci_freifunk
index 663112389f..d3c23e54d6 100644
--- a/module/admin-core/contrib/init.d/luci_freifunk
+++ b/module/admin-core/contrib/init.d/luci_freifunk
@@ -10,6 +10,7 @@ start() {
config_get wanif wan ifname
config_get lanif lan ifname
config_get ffif ff ifname
+ config_get ffdif ffdhcp ifname
config_get lanip lan ipaddr
config_get lanmask lan netmask
@@ -17,6 +18,9 @@ start() {
config_get ffip ff ipaddr
config_get ffmask ff netmask
+ config_get ffdip ffdhcp ipaddr
+ config_get ffdmask ffdhcp netmask
+
[ -n "$ffif" ] || return 0
@@ -53,6 +57,13 @@ start() {
iptables -t nat -A luci_freifunk_postrouting -s "$NETWORK/$PREFIX" -o "$wanif" -j MASQUERADE
}
+ ### Freifunk DHCP to Wan
+ [ "$internet" -gt 0 -a -n "$ffdif" ] && {
+ eval "$(ipcalc.sh $ffdip $ffdmask)"
+
+ iptables -t nat -A luci_freifunk_postrouting -s "$NETWORK/$PREFIX" -o "$wanif" -j MASQUERADE
+ }
+
### Hook in the chains
iptables -A forwarding_rule -j luci_freifunk_forwarding
iptables -t nat -A postrouting_rule -j luci_freifunk_postrouting
diff --git a/module/admin-core/src/view/admin_system/reboot.htm b/module/admin-core/src/view/admin_system/reboot.htm
index b6c38b75c4..e81be408c9 100644
--- a/module/admin-core/src/view/admin_system/reboot.htm
+++ b/module/admin-core/src/view/admin_system/reboot.htm
@@ -6,6 +6,6 @@
<p><a href="<%=controller%>/admin/system/reboot?reboot=1"><%:reboot_do Neustart durchführen%></a></p>
<% else %>
<p><%:reboot_running Bitte warten: Neustart wird durchgeführt...%></p>
-<script type="text/javascript">setTimeout("location='<%=controller%>/admin'", 45000)</script>
+<script type="text/javascript">setTimeout("location='<%=controller%>/admin'", 60000)</script>
<% end %>
<%+footer%> \ No newline at end of file