summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2011-02-01 19:32:10 +0000
committerErmal <eri@pfsense.org>2011-02-01 19:32:10 +0000
commitb0899ee4581548dde8060370a3063ffd18462883 (patch)
tree4b153446d71972f2d2e0c9356fb2a97d0cf7bd2f /usr/local
parent4e8c89fdbedce2188da48f8db1c0dfe83df36435 (diff)
downloadpfsense-b0899ee4581548dde8060370a3063ffd18462883.zip
pfsense-b0899ee4581548dde8060370a3063ffd18462883.tar.gz
Test for arrach before foreach'ing. Reported-by: http://forum.pfsense.org/index.php/topic,32865.0.html
Diffstat (limited to 'usr/local')
-rwxr-xr-xusr/local/www/firewall_rules.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr/local/www/firewall_rules.php b/usr/local/www/firewall_rules.php
index b5a1ce0..cf50140 100755
--- a/usr/local/www/firewall_rules.php
+++ b/usr/local/www/firewall_rules.php
@@ -162,9 +162,11 @@ if ($config['pptpd']['mode'] == "server")
if(have_ruleint_access("pptp"))
$iflist['pptp'] = "PPTP VPN";
-foreach ($config['pppoes']['pppoe'] as $pppoes)
- if (($pppoes['mode'] == 'server') && have_ruleint_access("pppoe"))
- $iflist['pppoe'] = "PPPoE Server";
+if (is_array($config['pppoes']['pppoe'])) {
+ foreach ($config['pppoes']['pppoe'] as $pppoes)
+ if (($pppoes['mode'] == 'server') && have_ruleint_access("pppoe"))
+ $iflist['pppoe'] = "PPPoE Server";
+}
/* add ipsec interfaces */
if (isset($config['ipsec']['enable']) || isset($config['ipsec']['mobileclients']['enable']))
OpenPOWER on IntegriCloud