From patchwork Wed Mar 2 19:43:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Schantl X-Patchwork-Id: 5298 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4K84Kj0CZGz3xkG for ; Wed, 2 Mar 2022 19:43:21 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4K84Kg5ppXz5Xf; Wed, 2 Mar 2022 19:43:19 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4K84Kg5V5mz2ynw; Wed, 2 Mar 2022 19:43:19 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4K84Kc477jz2xkT for ; Wed, 2 Mar 2022 19:43:16 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4K84Kb4603z2RB; Wed, 2 Mar 2022 19:43:15 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1646250196; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YegYLllhliawZcQDS1tsSwKhI2tt2hJMg521PS7bR3Q=; b=9exXzeVoBK9HUbTP+CmUjPK+wj44v9qBQ2Dw9IzLoKqnqMoDGyN6f6V2+lXULZSjYCRU+Z sn6K743+fUja07Cw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1646250196; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YegYLllhliawZcQDS1tsSwKhI2tt2hJMg521PS7bR3Q=; b=F2gAStpkMhTjt3DvETrv/RKTdUWhjQsfY4NjrEVfQ/hZf5d2hjY8QxgX8sDGNH8FulAfhe epI7G12QE1Bc41W5OCdwbCbMM7jipR1ciDB8ZmAzx/T7XsCP/jwrXEpBCVNfKLw260DVoT dh6ZbOvKetAhbEy7jUiy/orCZOtpU7QmbBT0jhRDd43554i0kxFqTQJ0GZXuhGVMrOWN/W waLHoLUvSqs7oN/T02Q5OKZlZcHzM1lmEfN2OWe37/JLSFJdhawYyDMmL85F8laZbTU1m4 JhVGzqzkR7d4T9LLmmA46lgNzpXmLD4TO9Y3XuE9Z5CAJe5lxSRTl8yRGOGefg== From: Stefan Schantl To: development@lists.ipfire.org Subject: [PATCH 2/2] firewall-lib.pl: Remove prefix when dealing with ipset sets. Date: Wed, 2 Mar 2022 20:43:06 +0100 Message-Id: <20220302194306.4110-2-stefan.schantl@ipfire.org> In-Reply-To: <20220302194306.4110-1-stefan.schantl@ipfire.org> References: <20220302194306.4110-1-stefan.schantl@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" Signed-off-by: Stefan Schantl --- config/firewall/firewall-lib.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/firewall/firewall-lib.pl b/config/firewall/firewall-lib.pl index f4089a3a0..7d35d5686 100644 --- a/config/firewall/firewall-lib.pl +++ b/config/firewall/firewall-lib.pl @@ -466,7 +466,7 @@ sub get_address # Get external interface. my $external_interface = &get_external_interface(); - push(@ret, ["-m set --match-set CC_$value src", "$external_interface"]); + push(@ret, ["-m set --match-set $value src", "$external_interface"]); } # Handle rule options with a location as target. @@ -476,7 +476,7 @@ sub get_address # Get external interface. my $external_interface = &get_external_interface(); - push(@ret, ["-m set --match-set CC_$value dst", "$external_interface"]); + push(@ret, ["-m set --match-set $value dst", "$external_interface"]); } # If nothing was selected, we assume "any".