diff options
author | jim-p <jimp@pfsense.org> | 2011-10-26 17:13:01 -0400 |
---|---|---|
committer | jim-p <jimp@pfsense.org> | 2011-10-26 17:14:37 -0400 |
commit | 4659f856f96b4f289d3f5de55d6b7d15f7c5351c (patch) | |
tree | 711ef9366e57c99afacdf14bbd128b33546e76ae /usr/local/www/diag_logs_settings.php | |
parent | 16cc1c10bf5b5ccad91e30a5e78c9ed77742d176 (diff) | |
download | pfsense-4659f856f96b4f289d3f5de55d6b7d15f7c5351c.zip pfsense-4659f856f96b4f289d3f5de55d6b7d15f7c5351c.tar.gz |
Fix up syslog settings a bit, add some missing options, fix formatting of syslog.conf, correct behavior of 'everything', code cleanup.
Diffstat (limited to 'usr/local/www/diag_logs_settings.php')
-rwxr-xr-x | usr/local/www/diag_logs_settings.php | 64 |
1 files changed, 58 insertions, 6 deletions
diff --git a/usr/local/www/diag_logs_settings.php b/usr/local/www/diag_logs_settings.php index 77e1b91..44a682c 100755 --- a/usr/local/www/diag_logs_settings.php +++ b/usr/local/www/diag_logs_settings.php @@ -56,6 +56,9 @@ $pconfig['filter'] = isset($config['syslog']['filter']); $pconfig['dhcp'] = isset($config['syslog']['dhcp']); $pconfig['portalauth'] = isset($config['syslog']['portalauth']); $pconfig['vpn'] = isset($config['syslog']['vpn']); +$pconfig['apinger'] = isset($config['syslog']['apinger']); +$pconfig['relayd'] = isset($config['syslog']['relayd']); +$pconfig['hostapd'] = isset($config['syslog']['hostapd']); $pconfig['logall'] = isset($config['syslog']['logall']); $pconfig['system'] = isset($config['syslog']['system']); $pconfig['enable'] = isset($config['syslog']['enable']); @@ -99,6 +102,9 @@ if ($_POST) { $config['syslog']['dhcp'] = $_POST['dhcp'] ? true : false; $config['syslog']['portalauth'] = $_POST['portalauth'] ? true : false; $config['syslog']['vpn'] = $_POST['vpn'] ? true : false; + $config['syslog']['apinger'] = $_POST['apinger'] ? true : false; + $config['syslog']['relayd'] = $_POST['relayd'] ? true : false; + $config['syslog']['hostapd'] = $_POST['hostapd'] ? true : false; $config['syslog']['logall'] = $_POST['logall'] ? true : false; $config['syslog']['system'] = $_POST['system'] ? true : false; $config['syslog']['disablelocallogging'] = $_POST['disablelocallogging'] ? true : false; @@ -140,6 +146,9 @@ function enable_change(enable_over) { document.iform.dhcp.disabled = 0; document.iform.portalauth.disabled = 0; document.iform.vpn.disabled = 0; + document.iform.apinger.disabled = 0; + document.iform.relayd.disabled = 0; + document.iform.hostapd.disabled = 0; document.iform.system.disabled = 0; document.iform.logall.disabled = 0; } else { @@ -150,10 +159,42 @@ function enable_change(enable_over) { document.iform.dhcp.disabled = 1; document.iform.portalauth.disabled = 1; document.iform.vpn.disabled = 1; + document.iform.apinger.disabled = 1; + document.iform.relayd.disabled = 1; + document.iform.hostapd.disabled = 1; document.iform.system.disabled = 1; document.iform.logall.disabled = 1; } } +function check_everything() { + if (document.iform.logall.checked) { + document.iform.filter.disabled = 1; + document.iform.filter.checked = false + document.iform.dhcp.disabled = 1; + document.iform.dhcp.checked = false + document.iform.portalauth.disabled = 1; + document.iform.portalauth.checked = false + document.iform.vpn.disabled = 1; + document.iform.vpn.checked = false + document.iform.apinger.disabled = 1; + document.iform.apinger.checked = false + document.iform.relayd.disabled = 1; + document.iform.relayd.checked = false + document.iform.hostapd.disabled = 1; + document.iform.hostapd.checked = false + document.iform.system.disabled = 1; + document.iform.system.checked = false + } else { + document.iform.filter.disabled = 0; + document.iform.dhcp.disabled = 0; + document.iform.portalauth.disabled = 0; + document.iform.vpn.disabled = 0; + document.iform.apinger.disabled = 0; + document.iform.relayd.disabled = 0; + document.iform.hostapd.disabled = 0; + document.iform.system.disabled = 0; + } +} // --> </script> @@ -256,12 +297,22 @@ function enable_change(enable_over) { </td> </table> <input name="system" id="system" type="checkbox" value="yes" onclick="enable_change(false)" <?php if ($pconfig['system']) echo "checked"; ?>> - <?=gettext("system events");?><br> <input name="filter" id="filter" type="checkbox" value="yes" <?php if ($pconfig['filter']) echo "checked"; ?>> - <?=gettext("firewall events");?><br> <input name="dhcp" id="dhcp" type="checkbox" value="yes" <?php if ($pconfig['dhcp']) echo "checked"; ?>> - <?=gettext("DHCP service events");?><br> <input name="portalauth" id="portalauth" type="checkbox" value="yes" <?php if ($pconfig['portalauth']) echo "checked"; ?>> - <?=gettext("Portal Auth");?><br> <input name="vpn" id="vpn" type="checkbox" value="yes" <?php if ($pconfig['vpn']) echo "checked"; ?>> - <?=gettext("PPTP VPN events");?> - <br> <input name="logall" id="logall" type="checkbox" value="yes" <?php if ($pconfig['logall']) echo "checked"; ?>> + <?=gettext("System events");?><br> + <input name="filter" id="filter" type="checkbox" value="yes" <?php if ($pconfig['filter']) echo "checked"; ?>> + <?=gettext("Firewall events");?><br> + <input name="dhcp" id="dhcp" type="checkbox" value="yes" <?php if ($pconfig['dhcp']) echo "checked"; ?>> + <?=gettext("DHCP service events");?><br> + <input name="portalauth" id="portalauth" type="checkbox" value="yes" <?php if ($pconfig['portalauth']) echo "checked"; ?>> + <?=gettext("Portal Auth events");?><br> + <input name="vpn" id="vpn" type="checkbox" value="yes" <?php if ($pconfig['vpn']) echo "checked"; ?>> + <?=gettext("VPN (PPTP, IPsec, OpenVPN) events");?><br> + <input name="apinger" id="apinger" type="checkbox" value="yes" <?php if ($pconfig['apinger']) echo "checked"; ?>> + <?=gettext("Gateway Monitor events");?><br> + <input name="relayd" id="relayd" type="checkbox" value="yes" <?php if ($pconfig['relayd']) echo "checked"; ?>> + <?=gettext("Server Load Balancer events");?><br> + <input name="hostapd" id="hostapd" type="checkbox" value="yes" <?php if ($pconfig['hostapd']) echo "checked"; ?>> + <?=gettext("Wireless events");?><br> + <br> <input name="logall" id="logall" type="checkbox" value="yes" <?php if ($pconfig['logall']) echo "checked"; ?> onclick="check_everything();"> <?=gettext("Everything");?> </td> </tr> @@ -287,6 +338,7 @@ function enable_change(enable_over) { <script language="JavaScript"> <!-- enable_change(false); +check_everything(); //--> </script> <?php include("fend.inc"); ?> |