diff options
author | Ermal Luçi <eri@pfsense.org> | 2008-12-07 14:34:38 +0000 |
---|---|---|
committer | Ermal Luçi <eri@pfsense.org> | 2008-12-07 14:34:38 +0000 |
commit | 5209079f7c20b6b12a7566c60a2e6fe63812987f (patch) | |
tree | 0dd6f08d5a83d5957aaaf3a83d221ee05451bb25 /etc | |
parent | 105a0f744b04f885e782ec7369bc2e1c309fd002 (diff) | |
download | pfsense-5209079f7c20b6b12a7566c60a2e6fe63812987f.zip pfsense-5209079f7c20b6b12a7566c60a2e6fe63812987f.tar.gz |
Shaper has no more enable disable functionality.
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/captiveportal.inc | 27 |
1 files changed, 11 insertions, 16 deletions
diff --git a/etc/inc/captiveportal.inc b/etc/inc/captiveportal.inc index 379835d..4228db6 100644 --- a/etc/inc/captiveportal.inc +++ b/etc/inc/captiveportal.inc @@ -267,17 +267,17 @@ EOD; mwexec("/sbin/sysctl net.link.ether.ipfw=0"); - if (!isset($config['shaper']['enable'])) { - /* unload ipfw */ - $installed_time_based_rules = false; - if($config['schedules']) { - foreach($config['schedules']['schedule'] as $sched) { - $installed_time_based_rules = true; - } + /* unload ipfw */ + $installed_time_based_rules = false; + if($config['schedules']) { + foreach($config['schedules']['schedule'] as $sched) { + $installed_time_based_rules = true; + break; } - if($installed_time_based_rules == false) - mwexec("/sbin/kldunload ipfw"); - } else { + } + if($installed_time_based_rules == false) + mwexec("/sbin/kldunload ipfw"); + else { /* shaper is on - just remove our rules */ mwexec("/sbin/ipfw -f delete set 1"); mwexec("/sbin/ipfw -f delete set 2"); @@ -399,11 +399,6 @@ EOD; # Allow WPA add 1100 set 1 pass layer2 mac-type 0x888e -EOD; - - - $cprules .= <<<EOD - # ... 10000-19899: rules per authenticated client go here... # redirect non-authenticated clients to captive portal @@ -985,7 +980,7 @@ function captiveportal_write_elements() { } closedir($dh); } else { - mkdir($g['captiveportal_element_path']); + @mkdir($g['captiveportal_element_path']); } if (is_array($config['captiveportal']['element'])) { |