From: Michael Tremer Date: Mon, 9 Sep 2024 09:54:04 +0000 (+0200) Subject: initscripts: Fix bash function definitions in suricata X-Git-Tag: v2.29-core189~52 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7e5ec5699886664686d05ef3d7dc3006d162b5a7;p=ipfire-2.x.git initscripts: Fix bash function definitions in suricata Signed-off-by: Michael Tremer --- diff --git a/src/initscripts/system/suricata b/src/initscripts/system/suricata index 253ece1175..0c60c51198 100644 --- a/src/initscripts/system/suricata +++ b/src/initscripts/system/suricata @@ -52,7 +52,7 @@ enabled_ips_zones=() PID_FILE="/var/run/suricata.pid" # Function to get the amount of CPU cores of the system. -function get_cpu_count { +get_cpu_count() { CPUCOUNT=0 # Loop through "/proc/cpuinfo" and count the amount of CPU cores. @@ -70,12 +70,12 @@ function get_cpu_count { } # Function to flush the firewall chains. -function flush_fw_chain { +flush_fw_chain() { iptables -w -t mangle -F IPS } # Function to create the firewall rules to pass the traffic to suricata. -function generate_fw_rules { +generate_fw_rules() { # Assign NFQ_OPTS local NFQ_OPTIONS=( "${NFQ_OPTS[@]}" )