]> git.ipfire.org Git - people/stevee/ipfire-2.x.git/commitdiff
convert-ids-multiple-providers: Fix setting ownership for the main
authorStefan Schantl <stefan.schantl@ipfire.org>
Sun, 11 Apr 2021 07:02:33 +0000 (09:02 +0200)
committerStefan Schantl <stefan.schantl@ipfire.org>
Sun, 19 Dec 2021 12:23:44 +0000 (13:23 +0100)
oinkmaster provider includes file.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
config/suricata/convert-ids-multiple-providers

index 971695dd73ac09683870817a19fedd845a402bae..82beb58036abdcac22ef4b6ddb68b6e96d25da89 100644 (file)
@@ -167,14 +167,16 @@ if (%enabled_disabled_sids) {
        # Add the provider modifications file to the oinkmaster provider includes file.
        &IDS::alter_oinkmaster_provider_includes_file("add", "$ruleset_provider");
 
-       # Set correct ownerships.
-       &IDS::set_ownership("$IDS::oinkmaster_provider_includes_file");
+       # Set correct ownership for the new generated file.
        &IDS::set_ownership("$oinkmaster_provider_modified_sids_file");
 }
 
-       # Remove old files.
-       unlink($old_enabled_sids_file);
-       unlink($old_disabled_sids_file);
+# Set correct ownership for the main file.
+&IDS::set_ownership("$IDS::oinkmaster_provider_includes_file");
+
+# Remove old files.
+unlink($old_enabled_sids_file);
+unlink($old_disabled_sids_file);
 
 #
 ## Step 6: Call oinkmaster and regenerate the ruleset structures.