aboutsummaryrefslogtreecommitdiffstats
path: root/config/snort/snort.inc
diff options
context:
space:
mode:
authorbmeeks8 <bmeeks8@bellsouth.net>2014-09-17 22:40:44 -0400
committerbmeeks8 <bmeeks8@bellsouth.net>2014-09-17 22:40:44 -0400
commit941115cc178e90650a7d97f2ac929f2441d2f694 (patch)
tree047dc80863d3abf29ce1c2772accb1e3fedc4abb /config/snort/snort.inc
parent3321f53eb16bb7db6522ee571a1df97e2045c82d (diff)
downloadpfsense-packages-941115cc178e90650a7d97f2ac929f2441d2f694.tar.gz
pfsense-packages-941115cc178e90650a7d97f2ac929f2441d2f694.tar.bz2
pfsense-packages-941115cc178e90650a7d97f2ac929f2441d2f694.zip
Adjust rule set downloads for new unique service entries.
Diffstat (limited to 'config/snort/snort.inc')
-rwxr-xr-xconfig/snort/snort.inc34
1 files changed, 34 insertions, 0 deletions
diff --git a/config/snort/snort.inc b/config/snort/snort.inc
index 53ae4a9d..49376aa8 100755
--- a/config/snort/snort.inc
+++ b/config/snort/snort.inc
@@ -634,6 +634,40 @@ function snort_start_all_interfaces($background=FALSE) {
}
}
+function snort_stop_all_interfaces() {
+
+ /*************************************************************/
+ /* This function stops all configured Snort interfaces. */
+ /*************************************************************/
+
+ global $g, $config;
+
+ /* do nothing if no Snort interfaces active */
+ if (!is_array($config['installedpackages']['snortglobal']['rule']))
+ return;
+
+ foreach ($config['installedpackages']['snortglobal']['rule'] as $snortcfg) {
+ snort_stop($snortcfg, get_real_interface($snortcfg['interface']));
+ }
+}
+
+function snort_restart_all_interfaces() {
+
+ /*************************************************************/
+ /* This function stops all configured Snort interfaces and */
+ /* restarts enabled Snort interfaces. */
+ /*************************************************************/
+
+ global $g, $config;
+
+ /* do nothing if no Snort interfaces active */
+ if (!is_array($config['installedpackages']['snortglobal']['rule']))
+ return;
+
+ snort_stop_all_interfaces();
+ snort_start_all_interfaces(TRUE);
+}
+
function snort_reload_config($snortcfg, $signal="SIGHUP") {
/*************************************************************/