Set action = pass for configured mac addresses on CP passtrumac

This commit is contained in:
Renato Botelho 2013-09-14 11:17:43 -03:00
parent 81ce28d870
commit 67e5e3c6db
3 changed files with 17 additions and 2 deletions

View File

@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!-- pfSense default system configuration -->
<pfsense>
<version>9.8</version>
<version>9.9</version>
<lastchange></lastchange>
<theme>pfsense_ng</theme>
<sysctl>

View File

@ -72,7 +72,7 @@ $g = array(
"disablecrashreporter" => false,
"crashreporterurl" => "http://crashreporter.pfsense.org/crash_reporter.php",
"debug" => false,
"latest_config" => "9.8",
"latest_config" => "9.9",
"nopkg_platforms" => array("cdrom"),
"minimum_ram_warning" => "101",
"minimum_ram_warning_text" => "128 MB",

View File

@ -3142,4 +3142,19 @@ function upgrade_097_to_098() {
/* Disable kill_states by default */
$config['system']['kill_states'] = true;
}
function upgrade_098_to_099() {
global $config, $g;
if (!is_array($config['captiveportal']))
return;
foreach ($config['captiveportal'] as $cpzone => $cp) {
if (!is_array($cp['passthrumac']))
continue;
foreach ($cp['passthrumac'] as $idx => $passthrumac)
$config['captiveportal'][$cpzone]['passthrumac'][$idx]['action'] = 'pass';
}
}
?>