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 9747EA0032; Thu, 16 Dec 2021 16:04:11 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8C43941104; Thu, 16 Dec 2021 16:04:11 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id C202840696; Thu, 16 Dec 2021 16:04:09 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1639667050; x=1671203050; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=uLoLLU8q78SubU6LaXBIocuWe22IYR1gxi2Cnh+byQ0=; b=nvyxhLdDUfC0U+KMqVqxRm5oPHU0wRgKi3pTganehVYvz9Xj5Uj/jHeT OO7Jj+eO6+0CHYj2Z/fEBHTfbAyOO0oTwgi9B9S7XLco6wVvI26OYpkuP lQCtqAKjVJXwVQ7Gk0wrVHvYhTH1eoAnat+iTq/zPAPO6AjGBpX7nQKbx L92eNn/mietDfWmqP6w7nB5wsQy29dus6kdD6FBpuMPz1GjQHJ3xioRNQ UP3s3LOt16c7awn6pO++fO7jg1La1y6IM4qcF1L+/vTffaVk5WawjXLzq O1lrUnAGmVBST2rFS1jh9H9qMIfpsVIeOr1c1KIZ58SnjuG8tjbKaGZ6j w==; X-IronPort-AV: E=McAfee;i="6200,9189,10199"; a="325794552" X-IronPort-AV: E=Sophos;i="5.88,211,1635231600"; d="scan'208";a="325794552" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Dec 2021 07:03:00 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,211,1635231600"; d="scan'208";a="611494701" Received: from orsmsx606.amr.corp.intel.com ([10.22.229.19]) by fmsmga002.fm.intel.com with ESMTP; 16 Dec 2021 07:03:00 -0800 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX606.amr.corp.intel.com (10.22.229.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Thu, 16 Dec 2021 07:02:59 -0800 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20 via Frontend Transport; Thu, 16 Dec 2021 07:02:59 -0800 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.170) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.20; Thu, 16 Dec 2021 07:02:59 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FA4FOFAbTLVLGhgc2wNzbWbN/IHS7+xLieeJBcHyCTM47q1Tr5mAHUD9FWnmEhksfohrh5ieuLM3lkd2hjdaoISTItoDckfC9eU+pKhNeaMF4f+F2AkseOtjmsjUHUqiZwnU2Yw27febxcUgkgtBRsGLwudSQTWUYVxEAVTHdFbbVuJ9lFx9ZVtpYxEXxEQlAoEvn0YXmWG2k6ESWqv8sfe4FCk68G0V+AG8gNX8p4Y1IppVbgMDtrALTGEFQQJZWnAFl1mAinNG+OmNyPvrBWfrVZgk4jVRJQI178C5INSs/ppITz6RqNvQSZq4+K2/AGBqlV9/TktcMCBkRxgz3Q== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=uLoLLU8q78SubU6LaXBIocuWe22IYR1gxi2Cnh+byQ0=; b=R0RPw+o67AFoeEOzJCciyW5mfEGw82LSfMexLaMPWbCZR/rkoQXfp8eENe4B14a3bVgks8kjHcFxls028ykqgI7C+co3B+X68LYhaMvtM8hNrZZhG1DJ71sWvHivcDuRSX+8zZr43mn23F+grrUmbDlc1P9yI9/EnhvtfeAcng3Ug9tNuD6O75Uf4ad2eLULkYcGDnVZRhQJDzCHZtF8GiLvsv4baFUh5Hhxv+LIP6lE1u6UUcYMsvcXproeoeLv467KSNf1EleHb8Ax29TYn4m5ZZ+aa8f6kwWAvXAKN2X1+OMKsFHUnFCsl8tIIFkRjZB46w+46tQGmYz0GyU66g== 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 Received: from MW5PR11MB5809.namprd11.prod.outlook.com (2603:10b6:303:197::6) by MWHPR11MB1455.namprd11.prod.outlook.com (2603:10b6:301:9::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4778.17; Thu, 16 Dec 2021 15:02:57 +0000 Received: from MW5PR11MB5809.namprd11.prod.outlook.com ([fe80::6044:ba49:2592:68c5]) by MW5PR11MB5809.namprd11.prod.outlook.com ([fe80::6044:ba49:2592:68c5%2]) with mapi id 15.20.4778.017; Thu, 16 Dec 2021 15:02:57 +0000 From: "Zhang, Roy Fan" To: "Power, Ciara" , "dev@dpdk.org" CC: "stable@dpdk.org" , "Mcnamara, John" , "De Lara Guarch, Pablo" Subject: RE: [PATCH 1/3] crypto/ipsec_mb: fix qp setup null pointer dereference Thread-Topic: [PATCH 1/3] crypto/ipsec_mb: fix qp setup null pointer dereference Thread-Index: AQHX7c+rnhGd1rT1K0itOEXby4RTK6w1QEQw Date: Thu, 16 Dec 2021 15:02:57 +0000 Message-ID: References: <20211210140952.2907974-1-ciara.power@intel.com> In-Reply-To: <20211210140952.2907974-1-ciara.power@intel.com> Accept-Language: zh-Hans-HK, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.6.200.16 dlp-reaction: no-action dlp-product: dlpe-windows authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 37ce1a1a-32e5-448e-adec-08d9c0a524ee x-ms-traffictypediagnostic: MWHPR11MB1455:EE_ x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: MZpWe/JDiGqKV0pWTiN/yjfGVX6ySTn9X6NBP5nKhzZ+NN2TtNzFZWPhwPACxt6MPX0YuF/dFp2y7RyziAf2TL8MQWJbjUZxNRufPX3VToAzwVCsEPuuKPPSN62Ie+IYU8+MGVuhx3rYivJGZrLS/hDIYi2O9ThR8sNfkWtMicTW16P9jV7ZEFWQWn1eUaAJxE5IW05/zlDDRuMTSMEsKN8fpPkdHM8wPNnCu9E4j2kEgvsSjdeYvOKNE9TP7IjusUDnAVRlp4Cc5Hx34NEJk54Et2oTob4atEXizs6HjTWHi8+GHkzMpLivmgJLyhQpwFU5062J/KDLQdwPij4uXcp00ptzRydjdKK4L/7Y+0TD+Z258H5CYc6DNRE1gE6RtdjobbMdVMEU7Soez6v4lQcvprm5vg0Ur5OrM6oiLkRKCsXWkYpssqbpDrwSXA1kSGpwRmY6nipk1mdT1sqU4pTW1NFW8BiTCePWEYAnJ/igYiHbcwme1V62u3RN8rzsGEGJACmZxsuxQ821ecqbm9Dt5JeDKXbjjHWjoc37TwOzLEzB5q/jJj6Gueka95z6+OuzWVGeycZxw1xaIMY4eMb119vGlp8OmmviBAivMFYPmS4ZU3bNDltFfvj8rKZrun9BPUxMh2BZKwDquKRzDleUzGzzin7T+YMRkwsOGwt4VcfUrIWSWzfp0qjgaL2sMWCIUz5HyFhZ1m5JtOxmMw== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MW5PR11MB5809.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(2906002)(66946007)(38070700005)(6506007)(66476007)(186003)(107886003)(26005)(66556008)(8676002)(508600001)(7696005)(55016003)(450100002)(83380400001)(53546011)(66446008)(5660300002)(71200400001)(33656002)(9686003)(8936002)(76116006)(52536014)(4326008)(122000001)(82960400001)(64756008)(316002)(86362001)(54906003)(110136005)(38100700002); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?Windows-1252?Q?jDB5/hhfW/w23xiFciyWQv1L5jEJfqaGK397ivZg7egQYWicZN288NCr?= =?Windows-1252?Q?qCJG5Il2QsPP130fhi1KKr3q34qnTFeTs7Ny2b97hqJMuob78mZlcLAb?= =?Windows-1252?Q?O0O0yeIER7hJyA0souSmBDJp9ggl41O5B4QOMXLvWKnsdZn6ohzh3V4i?= =?Windows-1252?Q?b3ruaB9sPauk3mPw4TQaoGOqVQrb/Utg7nhSYhDE6GKkpmp0mQAVANQP?= =?Windows-1252?Q?WMDvpaYYv3ljIEiRKGyBeHe31QJQa8uTeS8nrkRmUa/u2iKD95pM4T+r?= =?Windows-1252?Q?PAIhbFGPWiMjuwnMYmBU065xB9JiBphpATSWqytnPOHkPGfz/nHL/6LC?= =?Windows-1252?Q?Z3Fq0VlBxSSGkrtG6xG+RscFiE7bryHjFmOMi249hui2ZlV4RwJ/zsx6?= =?Windows-1252?Q?BOmad8U0fbfMc6LDLxGJJ9O+gGgcJfRy7uhLCyymCUfwYVmZA5W8gIwz?= =?Windows-1252?Q?nda+zccXr60IwdA9TPgvCld//FNYW98S/LcNljMrkxnqBi4cNInrkFO8?= =?Windows-1252?Q?+Zi/hHIwFVIsOpZaGbXL/Kw5jkmbCSNH9W39zyJC6LpUzIuJpaOtiYHh?= =?Windows-1252?Q?wbr5IHzWuvZ57hyP8FEPY0+ahJjUIur1h62Qg0hVaQmPffSo7xpU+EFO?= =?Windows-1252?Q?biEAjqS0iW+YwpPGP7KZoWXlHlVqmmUSb9Oip0Ke1QbtwmXzHwb9cNYh?= =?Windows-1252?Q?WKFpPBNKoTnW/6k0fhB4yfLBjeWdX1rBfSaOQxLTVNJPbCUr+WBAR+k6?= =?Windows-1252?Q?ut9ykziYFZghAGVOSDG1QYRL8Oaj8AkePZOc5NuRSsqGP/zukbKwYl0S?= =?Windows-1252?Q?h2ni4Mz+743nBVGDyyrL/LJJbqENpeG0ubmXl0+DezCkY0i/KotG3ENN?= =?Windows-1252?Q?UJKoQdVitmKKxJsA7qeNU5ZQ02ruwLxEndsScO1wLQy0qpO+t88qRYfD?= =?Windows-1252?Q?RKNKzfwYgYwjv2xKRtG0zUK5VUOkwSLE+8upy5+1V2WgLOsQfKmW5fXX?= =?Windows-1252?Q?oPN/yAA4/ZDpOydDmcXj/3sFa4c9WQbeW4E9RQZtY8s49cSu0w0ViW3W?= =?Windows-1252?Q?UAjrKC070um7Gv2iC+fkuCFzbo4ePFTPVWz7Z/4qV07odxvNWU4QqZv6?= =?Windows-1252?Q?KTbkOXXnzsLYEgzslSlXBO8HO6IVTSIR7PRmYp0KtzNBGRZPZxRo3r22?= =?Windows-1252?Q?hkjoPt9Z0IuQkYdtuYU78lb9bNHQiON4PvDlouUScurpydSYd3ddIxqn?= =?Windows-1252?Q?PahpINauHdDhgctx5gapizd6ao/nxKXf559+BL/CC0CJaRJ+cXDjJSzM?= =?Windows-1252?Q?8pAAD1ch9/0swG4wNCJxv+eiR0xuJyUMExt1a6xK/F3Z0Y499zL6jKqt?= =?Windows-1252?Q?Nws1VrNLvp3ttGD9JNQ7lAINq+ZwVMeEAm3xspt80ZWnSqO4NRA4cmjC?= =?Windows-1252?Q?zrsoQ2kQbHgzZwJBcVnujZuRspSlTu/RDYEebeRtZJr+ZvF4XdnPrbkh?= =?Windows-1252?Q?LV5l4lvnSp8wQCUxVosde64J5dH5CHQMulcyjGGOCBAHYTFmGwxH0M3j?= =?Windows-1252?Q?Ym7AJM1sAH16izZ+CEoaMF2XtinGLdd2uJRa9r0qRzVZ9kdmvOqdxRNT?= =?Windows-1252?Q?AUi79h3DVTvhk+3nayUvP5p0yxjG+aTNJvVi8brL4hrXu1HJBJhOzcRP?= =?Windows-1252?Q?PfZf3w+7cGUVG0J+V6esSanoFJhf9VJY6SmS38MyUhNaFGJEo+/HLSBv?= =?Windows-1252?Q?In5n7N/HcWtxLagiXjM=3D?= Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MW5PR11MB5809.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 37ce1a1a-32e5-448e-adec-08d9c0a524ee X-MS-Exchange-CrossTenant-originalarrivaltime: 16 Dec 2021 15:02:57.0769 (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: TT+3KqpVX8zcTU/UK/RE1shTiRUhH43RAdn3MAzYAY/LZAR1tpOKLbflAxfBvGneOn+UhOCkFTfPGiTFA0bQtA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR11MB1455 X-OriginatorOrg: intel.com 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 > -----Original Message----- > From: Power, Ciara > Sent: Friday, December 10, 2021 2:10 PM > To: dev@dpdk.org > Cc: stable@dpdk.org; Mcnamara, John ; Zhang, > Roy Fan ; Power, Ciara ; > De Lara Guarch, Pablo > Subject: [PATCH 1/3] crypto/ipsec_mb: fix qp setup null pointer dereferen= ce >=20 > When setting up a qp in a secondary process, the local qp pointer is set > to the stored device qp, configured by the primary process for that > device, but only if that device qp is not NULL. > If the device qp was not set up correctly by the primary process and has > a NULL value, the local qp variable stays at the default initialised > value, NULL. This causes a NULL pointer dereference later in the > function when using the qp value. >=20 > This is fixed by always setting the local qp to the value of the device > qp stored, and then checking if qp is NULL, returning an error if it is. >=20 > Coverity issue: 374382 > Fixes: 72a169278a56 ("crypto/ipsec_mb: support multi-process") > Cc: stable@dpdk.org >=20 > Signed-off-by: Ciara Power Acked-by: Fan Zhang