aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorrobiscool <robrob2626@yahoo.com>2009-12-28 17:12:32 -0800
committerrobiscool <robrob2626@yahoo.com>2009-12-28 17:13:18 -0800
commit4c10a1c2f3e961c0b6bc55cd062d46e4fe7ae2b2 (patch)
treef347033f486688fb028f4fd0e828a1a73aedad2f /config
parent9620f6d964c9a9219ab2e928630b9c46d481e47d (diff)
downloadpfsense-packages-4c10a1c2f3e961c0b6bc55cd062d46e4fe7ae2b2.tar.gz
pfsense-packages-4c10a1c2f3e961c0b6bc55cd062d46e4fe7ae2b2.tar.bz2
pfsense-packages-4c10a1c2f3e961c0b6bc55cd062d46e4fe7ae2b2.zip
snort-dev, add code to rules.php, code speed up start
Diffstat (limited to 'config')
-rw-r--r--config/snort-dev/snort_gui.inc5
-rw-r--r--config/snort-dev/snort_rules.php16
2 files changed, 8 insertions, 13 deletions
diff --git a/config/snort-dev/snort_gui.inc b/config/snort-dev/snort_gui.inc
index d8743b43..1746ab54 100644
--- a/config/snort-dev/snort_gui.inc
+++ b/config/snort-dev/snort_gui.inc
@@ -40,11 +40,6 @@ function print_info_box_np2($msg) {
echo " </td>\n";
echo " <td width='70%'><font color='white'><b>{$msg}</b></font>\n";
echo " </td>";
- if(stristr($msg, "apply") == true) {
- echo " <td>";
- echo " <input name=\"apply\" type=\"submit\" class=\"formbtn\" id=\"apply\" value=\"Apply changes\">\n";
- echo " </td>";
- }
echo " </tr></table>\n";
echo " </div>\n";
echo " </td>\n";
diff --git a/config/snort-dev/snort_rules.php b/config/snort-dev/snort_rules.php
index 2a9d4f2f..bc2f481d 100644
--- a/config/snort-dev/snort_rules.php
+++ b/config/snort-dev/snort_rules.php
@@ -29,6 +29,7 @@
*/
require("guiconfig.inc");
require("config.inc");
+require("/usr/local/pkg/snort/snort_gui.inc");
if (!is_array($config['installedpackages']['snortglobal']['rule'])) {
$config['installedpackages']['snortglobal']['rule'] = array();
@@ -384,17 +385,16 @@ else if ($_GET['act'] == "toggle")
}
-//if ($GET['saved'] == 'yes')
-//{
- $message = "The Snort rule configuration has been changed.<br>You must apply the changes in order for them to take effect.";
- echo "please work";
+if ($_GET['saved'] == 'yes')
+{
+ $message = "The Snort rule configuration has been changed.<br>You must restart this snort interface in order for the changes to take effect.";
+
// stop_service("snort");
// sleep(2);
// start_service("snort");
// $savemsg = "";
// $stopMsg = false;
-
-//}
+}
$currentruleset = basename($file);
@@ -409,7 +409,7 @@ include("head.inc");
<?php
echo "<form action=\"snort_rules.php?id={$id}\" method=\"post\" name=\"iform\" id=\"iform\">";
?>
-<?php // print_info_box($message);?>
+<?php if ($_GET['saved'] == 'yes') {print_info_box_np2($message);}?>
</form>
<script type="text/javascript" language="javascript" src="row_toggle.js">
<script src="/javascript/sorttable.js" type="text/javascript">
@@ -582,7 +582,7 @@ function popup(url)
echo $textss;
?>
<a href="?id=<?=$id;?>&openruleset=<?=$file;?>&act=toggle&ids=<?=$counter;?>"><img src="../themes/<?= $g['theme']; ?>/images/icons/<?=$iconb;?>" width="11" height="11" border="0" title="click to toggle enabled/disabled status"></a>
- <input name="enable" type="checkbox" value="yes" <?= $ischecked; ?> onClick="enable_change(false)">
+ <input name="enable" type="checkbox" value="yes" <?= $ischecked; ?> onClick="enable_change(false) ">
<?php
echo $textse;
echo "</td>";