From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 3E90E42B7F for ; Tue, 23 May 2023 12:16:37 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3A01642BB1; Tue, 23 May 2023 12:16:37 +0200 (CEST) Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by mails.dpdk.org (Postfix) with ESMTP id B620E40689; Tue, 23 May 2023 12:16:34 +0200 (CEST) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 011C35C01F9; Tue, 23 May 2023 06:16:34 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Tue, 23 May 2023 06:16:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm1; t= 1684836993; x=1684923393; bh=0L2zTlYWR8p2HisijITSb8ZbpfZLcv/YHsO 5kQxDJNM=; b=gyBkcojktRdtr4qyB7SJJyELBW7RHoNd4n2j/g65DokNvWCIZ8I TyUKvKhpBpu6wjcAdHjDHsx8t5htVlM4VVgH+5qFJqUMCEMzneEeVXWHGifsWX2B hmNUdV2jmVqVH+AC227qs+1cfTMzOtpK/8qD6sYwW4impmiW/Eooq13dosehS5JN 0ZHdhFmJX3tZmlq0+ER+yKC7Z0DhRMyXVTPwU5YmiupUyHJQ1O9Dkyk5Lqhs2Q7B wQY1HbYDQoqdGisaFf6M+F8ADojRzsuHzh7ZFBbIzaxtepfKYNxfRPFagG5BF7Yq l5qt0I8/qV403qsnJO/KQF3rUbsViQleKkg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1684836993; x=1684923393; bh=0L2zTlYWR8p2HisijITSb8ZbpfZLcv/YHsO 5kQxDJNM=; b=N1bDNYkYOXd+vubgFKdrfzXU30VrVf8sylj2/6eqn3Gn2e/NvEB wbmpDfMw4qEKi6Il7hzx5vAFDIFqGmink17jovg7rw6DDXzKXpg4l7wBjWsAwK8p l8c7rh92AIV9894yhkat5tnpO9TwhHtsiMel8KmBh5CX1EBY6CvG24cNIe8VVuqM G/tCcm6uKh4K4mwLsW8O7FYzYLQj8jpBntLTOWDL0DqRSYyIStMLrmmk+MgMeR7c 6EVAhil7LbsIW9W1dpbiv0sb1+BBEvrWipf8SEuMJYiEqdUAHEdfCTz1xJzZY6OJ 92k7vpaGhTX/8HZKBSs6ltoZ+OPsNWAE+zw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrfeejfedgvddvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedtjeeiieefhedtfffgvdelteeufeefheeujefgueetfedttdei kefgkeduhedtgfenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh hrohhmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Feedback-ID: i47234305:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 23 May 2023 06:16:32 -0400 (EDT) From: Thomas Monjalon To: Yunjian Wang Cc: dev@dpdk.org, stable@dpdk.org, honnappa.nagarahalli@arm.com, konstantin.v.ananyev@yandex.ru, luyicai@huawei.com Subject: Re: [dpdk-dev] [PATCH v3] ring: fix use after free in ring release Date: Tue, 23 May 2023 12:16:31 +0200 Message-ID: <3193564.aV6nBDHxoP@thomas> In-Reply-To: <21867862766caee191228a5fe438fde899e6fd7f.1683268586.git.wangyunjian@huawei.com> References: <21867862766caee191228a5fe438fde899e6fd7f.1683268586.git.wangyunjian@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org 05/05/2023 08:48, Yunjian Wang: > After the memzone is freed, it is not removed from the 'rte_ring_tailq'. > If rte_ring_lookup is called at this time, it will cause a use-after-free > problem. This change prevents that from happening. > > Fixes: 4e32101f9b01 ("ring: support freeing") > Cc: stable@dpdk.org > > Signed-off-by: Yunjian Wang > Acked-by: Konstantin Ananyev > Reviewed-by: Honnappa Nagarahalli Applied, thanks. That's a real pleasure to see reliability improved :)