]> git.ipfire.org Git - people/stevee/ipfire-2.x.git/commitdiff
ids-functions.pl: Use "enabled/disabled" to mark if a rule should be
authorStefan Schantl <stefan.schantl@ipfire.org>
Sun, 20 Mar 2022 15:10:01 +0000 (16:10 +0100)
committerStefan Schantl <stefan.schantl@ipfire.org>
Sun, 20 Mar 2022 15:10:01 +0000 (16:10 +0100)
altered.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
config/cfgroot/ids-functions.pl

index 7993453af7c95cc4422f6df58f721490e192b4f2..9c837d724daa0e00ee8f3a7b92511e6437215ce4 100644 (file)
@@ -784,10 +784,10 @@ sub process_ruleset(@) {
                                next if ($rev lt $rules{$sid});
 
                                # Check if the rule should be enabled or disabled.
-                               if ($modifications{$sid} eq "on") {
+                               if ($modifications{$sid} eq "enabled") {
                                        # Drop the # at the start of the line.
                                        $line =~ s/^\#//;
-                               } elsif ($modifications{$sid} eq "off") {
+                               } elsif ($modifications{$sid} eq "disabled") {
                                        # Add a # at the start of the line to disable the rule.
                                        $line = "#$line" unless ($line =~ /^#/);
                                }