aboutsummaryrefslogtreecommitdiffstats
path: root/config/snort
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2013-01-26 18:52:09 +0100
committerErmal <eri@pfsense.org>2013-01-26 18:52:09 +0100
commit995657bce91f35bf11beda71c224aa9afb2db9fe (patch)
tree7ae47e5a3781ca6c7cc92c8c7ce201d3613e8241 /config/snort
parent29dd57f966af743dbf2c77e94d050a167266bf10 (diff)
downloadpfsense-packages-995657bce91f35bf11beda71c224aa9afb2db9fe.tar.gz
pfsense-packages-995657bce91f35bf11beda71c224aa9afb2db9fe.tar.bz2
pfsense-packages-995657bce91f35bf11beda71c224aa9afb2db9fe.zip
Do not do dangerous staff during uninstall. This should fix reinstalling snort. Also remove the signatures files and previous configurations
Diffstat (limited to 'config/snort')
-rwxr-xr-xconfig/snort/snort.inc14
1 files changed, 1 insertions, 13 deletions
diff --git a/config/snort/snort.inc b/config/snort/snort.inc
index e2695ed4..80088779 100755
--- a/config/snort/snort.inc
+++ b/config/snort/snort.inc
@@ -1680,19 +1680,6 @@ function snort_deinstall() {
sleep(2);
mwexec('/usr/sbin/pw userdel snort; /usr/sbin/pw groupdel snort', true);
- if (!function_exists("get_interface_ipv6")) {
- /* create a few directories and ensure the sample files are in place */
- $snort_dirs = array( $snortdir, $snortlogdir,
- "dynamicrules" => "/usr/local/lib/snort/dynamicrules",
- "dynamicengine" => "/usr/local/lib/snort/dynamicengine",
- "dynamicpreprocessor" => "/usr/local/lib/snort/dynamicpreprocessor"
- );
- foreach ($snort_dirs as $dir) {
- if (is_dir($dir))
- mwexec("/bin/rm -rf {$dir}", true);
- }
- }
-
/* Remove snort cron entries Ugly code needs smoothness*/
if (!function_exists('snort_deinstall_cron')) {
function snort_deinstall_cron($crontask) {
@@ -1715,6 +1702,7 @@ function snort_deinstall() {
}
}
+ mwexec("/bin/rm {$snortdir}/*.md5; /bin/rm -r {$snortdir}/snort_*");
snort_deinstall_cron("snort2c");
snort_deinstall_cron("snort_check_for_rule_updates.php");
snort_deinstall_cron("snort_check_cron_misc.inc");