From patchwork Mon Oct 7 15:54:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Valerio X-Patchwork-Id: 1993722 X-Patchwork-Delegate: aconole@redhat.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=GkeLqHP/; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4XMkHh6fSnz1xvJ for ; Tue, 8 Oct 2024 02:54:56 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id E4F506076F; Mon, 7 Oct 2024 15:54:53 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id HTg-3J_vxKsS; Mon, 7 Oct 2024 15:54:53 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=2605:bc80:3010:104::8cd3:938; helo=lists.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org F20BF6075A Authentication-Results: smtp3.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=GkeLqHP/ Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp3.osuosl.org (Postfix) with ESMTPS id F20BF6075A; Mon, 7 Oct 2024 15:54:52 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 6D14FC08AA; Mon, 7 Oct 2024 15:54:52 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 902F5C08A3 for ; Mon, 7 Oct 2024 15:54:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 7F3EE403AA for ; Mon, 7 Oct 2024 15:54:50 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id U6Rc7MObUfum for ; Mon, 7 Oct 2024 15:54:49 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=170.10.133.124; helo=us-smtp-delivery-124.mimecast.com; envelope-from=pvalerio@redhat.com; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp2.osuosl.org 71D5C408FB Authentication-Results: smtp2.osuosl.org; dmarc=pass (p=none dis=none) header.from=redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 71D5C408FB Authentication-Results: smtp2.osuosl.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=GkeLqHP/ Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp2.osuosl.org (Postfix) with ESMTPS id 71D5C408FB for ; Mon, 7 Oct 2024 15:54:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1728316488; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=xgyyVCyDiR/2QQMfusZ/jIR9TwQF1YMrvWbNryM15W4=; b=GkeLqHP/+X9XgE2ILXhpnwMsY/f8M4Dq9v+rGWkG/5Z5z+B6tStdYEZu1Xmzqb9lwpA4Qo cgWUYQaRf3557h82nLbXme4cHvuT2HY2Bp81JKgk+v47HBL7OJ44FtbL7mdDdiw+cjVH4e EXK3QH+SbOc2ikennjqjPe/O1q3cD2A= Received: from mail-qv1-f71.google.com (mail-qv1-f71.google.com [209.85.219.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-204-DH7sI6jnMzCMlC2uflZ3QA-1; Mon, 07 Oct 2024 11:54:47 -0400 X-MC-Unique: DH7sI6jnMzCMlC2uflZ3QA-1 Received: by mail-qv1-f71.google.com with SMTP id 6a1803df08f44-6cb37b45f24so84116066d6.1 for ; Mon, 07 Oct 2024 08:54:47 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728316486; x=1728921286; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xgyyVCyDiR/2QQMfusZ/jIR9TwQF1YMrvWbNryM15W4=; b=i8oUexj9OLs1lMizEk9Jl9EmaJB13xe2iIDtIqyZFJWydx82T7FmQsHl6KB+DJ/2Uq FmCyYcOHyFn5wtAe4YFgvaUK1l3oPxVQ3Xexs8jWLOJm6L1DPS+GLJOXfBSk7UEdD2r5 unLbO+GjSdRghquacpztNQAcNG39cdZQltkf3krMzcHFDYMNuS8/jBWlexpDqoQOdPWN KND4C0sU68HKT11meiVrCtMxm4L3ejhB7Ylzp3ZaVih6+9QqaEinuX6KT+N12+gzC2hU 4JWaYII2x1wepjow/LDRAUMqcrQrDOleoRgMxfrRHDC7aMZtZYxU6uMOM25oe8g9utst 8Elw== X-Gm-Message-State: AOJu0Yz3ZF4Xhbg9afRLcVNajwzFrOSxMpdBhnQOv8U1KBnjmZXOxZkk n0vZtA+/udvFHRKt2gZ+REmHSvIRyVAZc+5GIvFsmc3c1siMzPrphV4RSSrVZVl9zU0xoudNcCw sfjx05YPUKQFcACf63EI6YK8lVOQRBav26zNFoCgTZFP03kjS3d314KuFxQeFt1811Idgg2FVkt hUKE2wRs1JF0dt3CLkC+HKeDjp/jZL1imwQzevR/g= X-Received: by 2002:ad4:5aae:0:b0:6cb:29fe:f5bc with SMTP id 6a1803df08f44-6cbba97bfcemr1200776d6.17.1728316486215; Mon, 07 Oct 2024 08:54:46 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEj4qxww59Dixzj2V6KEFcUdWaXB97FA3iPliTi5SRmPKhms0uNCgJHe4qvMN5BSUT+Vw/9wA== X-Received: by 2002:ad4:5aae:0:b0:6cb:29fe:f5bc with SMTP id 6a1803df08f44-6cbba97bfcemr1200416d6.17.1728316485893; Mon, 07 Oct 2024 08:54:45 -0700 (PDT) Received: from localhost (net-188-216-80-179.cust.vodafonedsl.it. [188.216.80.179]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6cba47513e8sm26794496d6.75.2024.10.07.08.54.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Oct 2024 08:54:45 -0700 (PDT) From: Paolo Valerio To: ovs-dev@openvswitch.org Date: Mon, 7 Oct 2024 17:54:25 +0200 Message-ID: <20241007155425.28710-2-pvalerio@redhat.com> X-Mailer: git-send-email 2.46.1 In-Reply-To: <20241007155425.28710-1-pvalerio@redhat.com> References: <20241007155425.28710-1-pvalerio@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH v4 2/2] ovs-macros.at: Correctly delete iptables rule on_exit. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" Currently, at every call of IPTABLES_ACCEPT() an iptables rule gets added. Such rule is supposed to be removed on exit, but the current syntax for deleting the rule is incorrect, resulting in a leftover rule after execution. Fix it by correcting the deletion command. Fixes: 5e06e7ac99dc ("tests: Refactor the iptables accept rule.") Signed-off-by: Paolo Valerio Reviewed-by: Aaron Conole Acked-by: Simon Horman Acked-by: Eelco Chaudron --- tests/ovs-macros.at | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/ovs-macros.at b/tests/ovs-macros.at index 06c978555..f1b8041fb 100644 --- a/tests/ovs-macros.at +++ b/tests/ovs-macros.at @@ -365,4 +365,4 @@ dnl to reject input traffic from bridges such as br-underlay. dnl Add a rule to always accept the traffic. m4_define([IPTABLES_ACCEPT], [AT_CHECK([iptables -I INPUT 1 -i $1 -j ACCEPT]) - on_exit 'iptables -D INPUT 1 -i $1']) + on_exit 'iptables -D INPUT 1'])