diff options
Diffstat (limited to 'config')
-rw-r--r-- | config/snort/snort_rulesets.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/config/snort/snort_rulesets.php b/config/snort/snort_rulesets.php index a3d41762..3d6de228 100644 --- a/config/snort/snort_rulesets.php +++ b/config/snort/snort_rulesets.php @@ -177,7 +177,8 @@ if ($savemsg) { <table id="maintable" class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0"> <?php $isrulesfolderempty = glob("{$snortdir}/rules/*.rules"); - if (empty($isrulesfolderempty)): + $iscfgdirempty = glob("{$snortdir}/snort_{$snort_uuid}_{$if_real}/rules/*.rules"); + if (empty($isrulesfolderempty) && empty($iscfgdirempty)): ?> <tr> <td> @@ -226,7 +227,10 @@ if ($savemsg) { $emergingrules = array(); $snortsorules = array(); $snortrules = array(); - $dh = opendir("{$snortdir}/rules/"); + if (empty($isrulesfolderempty)) + $dh = opendir("{$snortdir}/snort_{$snort_uuid}_{$if_real}/rules/"); + else + $dh = opendir("{$snortdir}/rules/"); while (false !== ($filename = readdir($dh))) { $filename = basename($filename); if (substr($filename, -5) != "rules") |