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 EBB6943330; Wed, 15 Nov 2023 01:07:42 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 89FDB4027B; Wed, 15 Nov 2023 01:07:42 +0100 (CET) Received: from mail-pf1-f169.google.com (mail-pf1-f169.google.com [209.85.210.169]) by mails.dpdk.org (Postfix) with ESMTP id 3368940261 for ; Wed, 15 Nov 2023 01:07:41 +0100 (CET) Received: by mail-pf1-f169.google.com with SMTP id d2e1a72fcca58-6b2018a11efso6454481b3a.0 for ; Tue, 14 Nov 2023 16:07:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1700006860; x=1700611660; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=0KETpsWT+7elm5fOxgMHtz0zuVQkT25A+7V/mA2aCVI=; b=w8y7S3Lq8EZIynCVSFSykuqxRgy8S8Ogyz0r79gd/Zx1DTITnjIlsXlyTM8EKM0BfZ LoDLNBveqJwCh9S4h4qtZZy9ROpHWDsh2oHIEACfY/Ch/ddyiUDKe1T+eictJh6VLc5s bZsUpEUw2F8RxbFJCNHlQQSnfEkLxyYppByVWGcJijc5y4gAg+mb1wqoLKcV10bx4WMq D6P6/mXgrj85C42OqNsdn5J87j77PgYEQ12s/D0hh+i4+VXsZFvoeMhVb75cJW6Yf773 StGuCn0ILVZINg4efvaovKrJxAmJaaBhXci5idnp+Ag/iKvJyWQ/qN0uutQDqzRA8jL9 mxrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700006860; x=1700611660; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0KETpsWT+7elm5fOxgMHtz0zuVQkT25A+7V/mA2aCVI=; b=ZsKXMnokjR+TQXhdzfEL+Q9MHmcjqoH7Y02Ggq4tstDEY6W82OHY9z2d3/RDve4s1u lpZyG4ErI0p6jIk2pWh/huDoKbIvfe7Ojx3f5lwc7gLGLYlIELVt5/zxMV/atqOW0kas MrLANf6dGYgRo/Bkaygtusi+4Lnkne/dYobeXWPv1opKJSF8gvUu3Mqt4tK5f3oQpcK0 aXOho9l5q+yx3ZXDtiE0emLtHj+79cW/TTgjtLJetfK6lbiSmygrg1ZMWcXoSzuGVOeA GHfRQ84CGpB9ICajB+50Uq2Uk37XhevxK41SX0RHO5x85UmETGhSGo7tFP/OuYK4XQHG zemw== X-Gm-Message-State: AOJu0Yw3gzO89xV6LwP/e+QpHZvTytOaKr9EbqUfLNEYxRE7Px4jDyHs pcbXtBMRR730lfkdkATvPcCggg== X-Google-Smtp-Source: AGHT+IER+u6ENuhBS36RYii5mgFjernUyWVxq+MtJKHLcoYEyrXtEgAqda50a/Q8nkHaH/HLFHo7ng== X-Received: by 2002:a05:6a20:8e25:b0:186:8024:90dd with SMTP id y37-20020a056a208e2500b00186802490ddmr8820844pzj.18.1700006860093; Tue, 14 Nov 2023 16:07:40 -0800 (PST) Received: from hermes.local (204-195-123-141.wavecable.com. [204.195.123.141]) by smtp.gmail.com with ESMTPSA id mp20-20020a17090b191400b0027722832498sm7763441pjb.52.2023.11.14.16.07.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Nov 2023 16:07:39 -0800 (PST) Date: Tue, 14 Nov 2023 16:07:37 -0800 From: Stephen Hemminger To: Jie Hai Cc: , Sunil Kumar Kori , Rakesh Kudurumalla , Nithin Dabilpuram , Jerin Jacob , , Subject: Re: [PATCH v3 01/22] app/graph: replace strtok with reentrant version Message-ID: <20231114160737.45d83bb9@hermes.local> In-Reply-To: <20231114110006.91148-2-haijie1@huawei.com> References: <20231113104550.2138654-1-haijie1@huawei.com> <20231114110006.91148-1-haijie1@huawei.com> <20231114110006.91148-2-haijie1@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Tue, 14 Nov 2023 18:59:45 +0800 Jie Hai wrote: > Multiple threads calling the same function may cause condition > race issues, which often leads to abnormal behavior and can cause > more serious vulnerabilities such as abnormal termination, denial > of service, and compromised data integrity. > > The strtok() is non-reentrant, it is better to replace it with a > reentrant version. > > Fixes: 5c59002a34f3 ("app/graph: add graph commands") > Fixes: 984a315a5804 ("app/graph: add parser utility") NAK These are only called from graph CLI which must be single threaded