]> git.ipfire.org Git - people/fbuehrle/ipfire-2.x.git/commitdiff
suricata: Redirect oinkmaster output to perl function
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 17 Apr 2019 19:59:55 +0000 (20:59 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 17 Apr 2019 19:59:55 +0000 (20:59 +0100)
The output was written to stderr before and landed in apache's
error log where we do not want it.

Fixes: #12004
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
config/cfgroot/ids-functions.pl

index 016c0e49d609a80cdad6253f4560ccfdfcd1b002..425b5e5a09cf78f5896eee05c1c40a55a0e4cb17 100644 (file)
@@ -324,7 +324,7 @@ sub oinkmaster () {
        openlog('oinkmaster', 'cons,pid', 'user');
 
        # Call oinkmaster to generate ruleset.
-       open(OINKMASTER, "/usr/local/bin/oinkmaster.pl -v -s -u file://$rulestarball -C $settingsdir/oinkmaster.conf -o $rulespath|") or die "Could not execute oinkmaster $!\n";
+       open(OINKMASTER, "/usr/local/bin/oinkmaster.pl -v -s -u file://$rulestarball -C $settingsdir/oinkmaster.conf -o $rulespath 2>&1 |") or die "Could not execute oinkmaster $!\n";
 
        # Log output of oinkmaster to syslog.
        while(<OINKMASTER>) {