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 102E0A0C4D for ; Tue, 27 Jul 2021 11:16:39 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0482A410F8; Tue, 27 Jul 2021 11:16:39 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by mails.dpdk.org (Postfix) with ESMTP id ADAC3410EC; Tue, 27 Jul 2021 11:16:36 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10057"; a="191998321" X-IronPort-AV: E=Sophos;i="5.84,272,1620716400"; d="scan'208";a="191998321" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Jul 2021 02:16:32 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,272,1620716400"; d="scan'208";a="474361657" Received: from orsmsx605.amr.corp.intel.com ([10.22.229.18]) by fmsmga008.fm.intel.com with ESMTP; 27 Jul 2021 02:16:28 -0700 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX605.amr.corp.intel.com (10.22.229.18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.4; Tue, 27 Jul 2021 02:16:27 -0700 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.10; Tue, 27 Jul 2021 02:16:27 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.10 via Frontend Transport; Tue, 27 Jul 2021 02:16:27 -0700 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (104.47.58.100) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2242.10; Tue, 27 Jul 2021 02:16:26 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fdOSV+L42SBpxJ77RuHX7f7cpIMRcnan4x9+n14TN0m9xmalNNgTsgEIGiqpYKmT49gnn8pFpQ8+7aryIu5ZezRHjvmzh5cLx/zcfOdFirVr7/f7T0PQqMc9wf9w+pg3eHqz9n5mXePUwsNumtJVENgv5UiZzTrp7HDojioRYiOMqh7ot8NypBcNsZ8R2+w5eIRh+dOU2HEocRuj9hCtZIG0ZbidHD4r172qRqF1yijyy/wgWnpd3F+6rYQs2witxqlxKad0k69qLOZbSqvzF0TU6CRdNfOyDBIdobHr1EM1WlP7xLy2bugeKJ/ZYimfxXrjsAOxIpFRUHFn0cnC6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TZrMtIkVbLAWz8Oeu9ETm613Dd6oSo8O0AWLjwTRvAE=; b=cGlLH6p8lhyP/nNEB2HJ7i63/kDSZYzx5qgYrOq28Fn88vHDPjdPwF9VKWbaJZ/ZgsXqWJvwS/HS/nF2kW4d5g2q6dfzMxKCU6ouuhxwdJU3cqBzrB/OT4jF+zO+8YDgAgwyQW4Hdjdu6+UfyOzPLmqcA/sXesBWV5Q1m/WnEM4iiXMVd/BVSnuUPniFcMFOcbBRLt1aC4kFn3ZhxV8w6BxjcjGRFkgkpm+AVwoIO2wbyT3B9xI43Ekkf4Uyqjq80OBPceS0lRoscYWpWrAsWtQN57pZN4PqZ1V9dYd+5ENwsFYzV7q+/3o2tbC54K2DwRcJ8DZ10Uf8SMzwMsFeMw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TZrMtIkVbLAWz8Oeu9ETm613Dd6oSo8O0AWLjwTRvAE=; b=ddQOKLLAra/zfka1PIxAiDZQDxgT1gF9gJHbWY11wREyHEFFSa14JPmt2CwLcdeMp8Ai7p0eokBdIplrrlPl1a0AlWKQ2Wv9phsL/6U+eyy+uLAi0KPCiAWUbABIhB69HEy0Y3LzlJkLJMxhbi884U4/Ej/U44DUxT1cr1vaVrw= Received: from BN9PR11MB5258.namprd11.prod.outlook.com (2603:10b6:408:133::13) by BN6PR1101MB2228.namprd11.prod.outlook.com (2603:10b6:405:52::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4352.31; Tue, 27 Jul 2021 09:16:25 +0000 Received: from BN9PR11MB5258.namprd11.prod.outlook.com ([fe80::c73:8099:7af4:1f09]) by BN9PR11MB5258.namprd11.prod.outlook.com ([fe80::c73:8099:7af4:1f09%8]) with mapi id 15.20.4373.018; Tue, 27 Jul 2021 09:16:25 +0000 From: "Singh, Jasvinder" To: "Yu, DapengX" , "Dumitrescu, Cristian" CC: "dev@dpdk.org" , "stable@dpdk.org" Thread-Topic: [PATCH] net/softnic: fix null pointer dereference Thread-Index: AQHXgr+PY+ngXvHtFUKoNWsG2DFGKqtWimng Date: Tue, 27 Jul 2021 09:16:25 +0000 Message-ID: References: <20210727081459.1145664-1-dapengx.yu@intel.com> In-Reply-To: <20210727081459.1145664-1-dapengx.yu@intel.com> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.5.1.3 dlp-reaction: no-action dlp-product: dlpe-windows authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: efc2d52b-bab7-4437-6164-08d950df358f x-ms-traffictypediagnostic: BN6PR1101MB2228: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:2958; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: B5YMKXi0nYumgIUgqU6nSQF+C0zP1W5ikifEaGhflvMlQO/nKVH1HrAqmN0VrmhZDonBi/6miSN10EHiafTdFIQnPjsA11XsX3KOYmbCmvJqmHze3zQ449Wxn83tymoE6qnggNMUq6RstndyHGGH5BxbNAxQF/OaDI+WS0dUaOF9UXQJQL6GW45zQuN7pcpuej+UBtP8Y3rPEyCVm5G4qMCglOgmqCpy+f9oexTL+EbAjLIcU0vSEJG3sJTXb4xsQUNP8DFgWR/XtBzlTIHG8UW+I9zKQv6eWFrbtYGAL3D0ZDr6KwDPEdZEKNPHdGTqfZYHRKC9TY5UrxR2fQEgmp8lpfG3VACXPqoddYlHcErlzo7+Tze+UF2+UgOXR2lgO1r7mxsc0I0TeJvP4aF4UI5maq90yG5v+RWH5gS5k7iL5NraG10UPaFQDiGpoTD/u+3MK1r2Pudle9AAZKvsCnOVD4i/WprjwGSbbV9yJN743/VCJXQHSG/wIQnpP7R4v+Yhpy9M1//qTT84UR3KXebQ2V+y6vIaCb2CQ+qmhQqR2I5Nb+1Kw1RjKQLUz4XPFLJnIVfONq+fLVq2WDWOCZ956oYbUwl+wvvxCo9qwepixhxATPDnfnh01TGxGhj80V7kCPgCZJ8p0w1E5tI+1TvsNXwEkiVYVoAqI71jA1Xq0boSEkZ4V6A/HNfTlyzNbzXNo0IRuGU2WSVfRQsfrA== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BN9PR11MB5258.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(66946007)(66476007)(64756008)(9686003)(54906003)(186003)(110136005)(6636002)(52536014)(76116006)(7696005)(66446008)(66556008)(5660300002)(2906002)(6506007)(53546011)(26005)(508600001)(55016002)(4744005)(71200400001)(450100002)(33656002)(122000001)(86362001)(8936002)(316002)(4326008)(8676002)(38100700002)(83380400001)(38070700004); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?ciP86Q8DAgJAt/XsYaAsJfNaATcruJr54O7JLxFYWSqpM2G+EzZu4fmNseYn?= =?us-ascii?Q?p+q7eXdyuUFDO/NtIyT/FDU9SDy53yFVcmN0ooajLYZMBWnBeTox3YpaiFok?= =?us-ascii?Q?J6nuyNH2luv1Mf+qyBL9hibEm8VDDROAtF/KPghH8rShmv0F6iIQAnf5uuLj?= =?us-ascii?Q?WD9ez4EUt0WWL5H2oPKvO7wmXLcSu+CzSIaFcjXsRS8yLZg6ndEnond2fjvD?= =?us-ascii?Q?tgLVge8ykQiXJFw1QcYaKlrs7DH/7PgwqvRlJFY1JULsbDw/nwF3mpfeMg5m?= =?us-ascii?Q?wOBLdFG9Ozi5u4/4ujijXtQ7T8OvDIN2eY843eRF5w9Yy1EPjdIFz3cMoiwr?= =?us-ascii?Q?vI6SVYyb/pd3x4XDQyoQgTS2u0e8qhS8VmchmSjoopHmsM2biJl2OqzqMoGn?= =?us-ascii?Q?D3RphF8AJlknWJd5dmtbso4EGGfBlPobG7BX4+BY2FzrY+HngX/8v6s1kQ2X?= =?us-ascii?Q?sgdfPDmqUHoaOtjwch2urTYFUDGzRxTTNzk8Q9yWKyhc3CGfCF0FpZlebMrv?= =?us-ascii?Q?+atEn85lXCzLfYfZisqa2nE/ppyUJ0xzh2nG/MNj6TtQSsqu1LkI7cO5vRs9?= =?us-ascii?Q?ZF9QeV5iauRcQwPjsabFRQbvCT50hCulq1L0l3wpxP2VvTFH2J6RIfOz0Wmj?= =?us-ascii?Q?tuRWi7RA3unk1UB5qsbgnId7Y++c+b7Xk957UVRKSm45cJKRdG0KmeV2mTA5?= =?us-ascii?Q?MUvUJX/gVQvzpBQHasKRReANuY/TFbSpngBVCeOefF3WymesuD6jGovjtx2/?= =?us-ascii?Q?mHPVXSJYnUJoV7npkmnUAEyO75xINKGTQQU9zn0XQvVJyDc5ZNf5hSFEiyXl?= =?us-ascii?Q?iesRSoOHSf9V1AkWIpM7izD+6xGBzJu+ikexyfqTM0+vNJsTd//EYhFs+AK5?= =?us-ascii?Q?LXEAxxHy0uQ63wVd8zTGtDw1GfDwoxBICboJsh0YLCjcU8qy3CKw8DBye3LI?= =?us-ascii?Q?WeyJwzpE0zIVofvniL2pVzjHAttEaRT4kyO2/ubBrKh8AxCVS7PVf+L04V+g?= =?us-ascii?Q?urKOFdMkgZUThMX7dpll5PRwSHvGGsnP4cEaLG736WQ9n9qi4bXPh1q3bFju?= =?us-ascii?Q?tfyRQS7M1xxQsrpA1UrNCq7pm/ZKJVkSuoPInbxuoRIthJccRF9024GGWgUP?= =?us-ascii?Q?MAD0+j9IqBfQOja1zHZUUEIrLKf8CGRhGCb0OJwA78kwGmytMj0LPWTmb9ah?= =?us-ascii?Q?mkf9BPJy8dApxq1vEM35mfNH1olYeAAetNnj0PvhHGE9KFZy79/znwgY/tmf?= =?us-ascii?Q?qsrhEWQKcvJtpCl9EtTMX9CXhrGMcbsjQaqZDq5I9V5A3Mq0LqQhyrhY72wu?= =?us-ascii?Q?PLanv71GxQ7Gn4kZxh8UogaL?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BN9PR11MB5258.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: efc2d52b-bab7-4437-6164-08d950df358f X-MS-Exchange-CrossTenant-originalarrivaltime: 27 Jul 2021 09:16:25.4809 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: EZO+2EaUC7qrdKflaR5n0DlIraO8NXroDUPwnUCB1QQ0ykdprPzJCi8nKH08tPej0T8MyGIGvNmkYs8c8DpIoMt1jnH73gC1iGR3QQKwCqo= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR1101MB2228 X-OriginatorOrg: intel.com Subject: Re: [dpdk-stable] [PATCH] net/softnic: fix null pointer dereference 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 Sender: "stable" > -----Original Message----- > From: Yu, DapengX > Sent: Tuesday, July 27, 2021 9:15 AM > To: Singh, Jasvinder ; Dumitrescu, Cristian > > Cc: dev@dpdk.org; Yu, DapengX ; stable@dpdk.org > Subject: [PATCH] net/softnic: fix null pointer dereference >=20 > From: Dapeng Yu >=20 > When there is no "firmware" in arguments, the "firmware" pointer is null, > and will be dereferenced by rte_strscpy(). >=20 > This patch moves the code block which copies character string from > "firmware" to "p->firmware" into the "if" statements where "firmware" > argument exists and it is duplicated successfully. >=20 > Coverity issue: 372136 > Fixes: d8f852f5f369 ("net/softnic: fix memory leak in arguments parsing") > Cc: stable@dpdk.org >=20 > Signed-off-by: Dapeng Yu > --- Acked-by: Jasvinder Singh