From 615385a377ab13f038f4e438b53924e3ee70a584 Mon Sep 17 00:00:00 2001 From: bmeeks8 Date: Fri, 3 Jul 2015 23:09:38 -0400 Subject: Fix PHP warnings from array/string mismatch error. --- config/snort/snort_preprocessors.php | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'config/snort/snort_preprocessors.php') diff --git a/config/snort/snort_preprocessors.php b/config/snort/snort_preprocessors.php index d5eadfd9..dd8ec660 100755 --- a/config/snort/snort_preprocessors.php +++ b/config/snort/snort_preprocessors.php @@ -80,6 +80,18 @@ $pconfig = array(); if (isset($id) && isset($a_nat[$id])) { $pconfig = $a_nat[$id]; + // Initialize multiple config engine arrays for supported preprocessors if necessary + if (!is_array($pconfig['frag3_engine']['item'])) + $pconfig['frag3_engine']['item'] = array(); + if (!is_array($pconfig['stream5_tcp_engine']['item'])) + $pconfig['stream5_tcp_engine']['item'] = array(); + if (!is_array($pconfig['http_inspect_engine']['item'])) + $pconfig['http_inspect_engine']['item'] = array(); + if (!is_array($pconfig['ftp_server_engine']['item'])) + $pconfig['ftp_server_engine']['item'] = array(); + if (!is_array($pconfig['ftp_client_engine']['item'])) + $pconfig['ftp_client_engine']['item'] = array(); + /************************************************************/ /* To keep new users from shooting themselves in the foot */ /* enable the most common required preprocessors by default */ @@ -1509,10 +1521,10 @@ if ($savemsg) { - - +

-- cgit v1.2.3