diff options
author | bmeeks8 <bmeeks8@bellsouth.net> | 2015-11-09 22:25:06 -0500 |
---|---|---|
committer | bmeeks8 <bmeeks8@bellsouth.net> | 2015-11-09 22:25:06 -0500 |
commit | 0a2d7fa809a9608c5063dd1a352fb53e9e7073a1 (patch) | |
tree | 536703ba5dd04e736cf1a5f79bf39a12b72461d5 /config/suricata/suricata_migrate_config.php | |
parent | 9c77d0bf09e4a483b2080c882e084a4f4e6094b8 (diff) | |
download | pfsense-packages-0a2d7fa809a9608c5063dd1a352fb53e9e7073a1.tar.gz pfsense-packages-0a2d7fa809a9608c5063dd1a352fb53e9e7073a1.tar.bz2 pfsense-packages-0a2d7fa809a9608c5063dd1a352fb53e9e7073a1.zip |
Add support for X-Forwarded-For info to Unified2 log output options.
Diffstat (limited to 'config/suricata/suricata_migrate_config.php')
-rw-r--r-- | config/suricata/suricata_migrate_config.php | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/config/suricata/suricata_migrate_config.php b/config/suricata/suricata_migrate_config.php index 2fd5f96e..8cf69ba6 100644 --- a/config/suricata/suricata_migrate_config.php +++ b/config/suricata/suricata_migrate_config.php @@ -471,6 +471,26 @@ foreach ($rule as &$r) { $updated_cfg = true; } + /**********************************************************/ + /* Create interface Unified2 XFF log settings if not set */ + /**********************************************************/ + if (!isset($pconfig['barnyard_log_xff'])) { + $pconfig['barnyard_log_xff'] = "off"; + $updated_cfg = true; + } + if (!isset($pconfig['barnyard_xff_mode'])) { + $pconfig['barnyard_xff_mode'] = "extra-data"; + $updated_cfg = true; + } + if (!isset($pconfig['barnyard_xff_deployment'])) { + $pconfig['barnyard_xff_deployment'] = "reverse"; + $updated_cfg = true; + } + if (empty($pconfig['barnyard_xff_header'])) { + $pconfig['barnyard_xff_header'] = "X-Forwarded-For"; + $updated_cfg = true; + } + // Save the new configuration data into the $config array pointer $r = $pconfig; } |