From 96616c4b3caaaeefe31c58973e71fc9ab287a475 Mon Sep 17 00:00:00 2001 From: robiscool Date: Mon, 7 Dec 2009 19:27:05 -0800 Subject: snort-dev, download rules code --- config/snort-dev/snort_download_rules.php | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) (limited to 'config/snort-dev/snort_download_rules.php') diff --git a/config/snort-dev/snort_download_rules.php b/config/snort-dev/snort_download_rules.php index d7b58c39..952a4d4d 100644 --- a/config/snort-dev/snort_download_rules.php +++ b/config/snort-dev/snort_download_rules.php @@ -53,8 +53,22 @@ if (isset($_POST['id_d'])) $last_md5_download = $config['installedpackages']['snortglobal']['last_md5_download']; $last_rules_install = $config['installedpackages']['snortglobal']['last_rules_install']; +$snort_rule_d_chk = $config['installedpackages']['snortglobal']['snortdownload']; +$emrging_rule_d_chk = $config['installedpackages']['snortglobal']['emergingthreats']; + +if ($snort_rule_d_chk != premium || $snort_rule_d_chk == "" ) + $snort_rule_d_info = "no"; + +if ($emrging_rule_d_chk != on || $emrging_rule_d_chk == "" ) + $emrging_rule_d_info = "no"; + +if ($snort_rule_d_info == "no" && $emrging_rule_d_info = "no") + $snort_$emrging_info = "stop"; + + + /* If no id show the user a button */ -if ($id_d == "") { +if ($id_d == "" || $snort_$emrging_info = "stop") { $pgtitle = "Services: Snort: Update Rules"; @@ -117,8 +131,12 @@ echo "\n \n

\n\n"; +if ($id_d == "") echo "Click on the \"Update Rules\" button to start the updates.

\n"; +if ($snort_$emrging_info = "stop") +echo "Click on the \"Global Settings\" TAB and select ether snort.org or enmergingthreats.net rules to download.

\n"; + if ($config['installedpackages']['snortglobal']['last_md5_download'] != "") echo "The last time the updates were started $last_md5_download.

\n"; -- cgit v1.2.3