From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Schantl To: development@lists.ipfire.org Subject: [PATCH 3/4] rules.pl: Do not create HOSTILE rules if no red dev is available. Date: Wed, 09 Mar 2022 15:12:31 +0100 Message-ID: <20220309141232.2401848-3-stefan.schantl@ipfire.org> In-Reply-To: <20220309141232.2401848-1-stefan.schantl@ipfire.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3170828523619912286==" List-Id: --===============3170828523619912286== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Signed-off-by: Stefan Schantl --- config/firewall/rules.pl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/config/firewall/rules.pl b/config/firewall/rules.pl index 83216e78a..57f4809b4 100644 --- a/config/firewall/rules.pl +++ b/config/firewall/rules.pl @@ -695,6 +695,9 @@ sub drop_hostile_networks () { return; } + # Exit if there is no red interface. + return unless($RED_DEV); + # Call function to load the network list of hostile networks. &ipset_restore($HOSTILE_CCODE); -- 2.30.2 --===============3170828523619912286==--