Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp4608336imm; Mon, 17 Sep 2018 17:46:50 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZCWpkB11OshgVwRuVU/EgkmIFXt/yb6Lgd5B3pPX5WmX0m8ACjTyJZlPOgo68wU9xXMA2O X-Received: by 2002:a62:7d8d:: with SMTP id y135-v6mr27798628pfc.259.1537231609998; Mon, 17 Sep 2018 17:46:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537231609; cv=none; d=google.com; s=arc-20160816; b=tOg2AJ+U4NTVslsdeRo4beQoi3KYO+pmbxcC8NlL9rTPMNaEK3qzgFcHWAnrcB2tPY oV9w6L/m4blSfRTVnVslNp9CF8OvZlmgJJZuwta0oi5XMQSijDeeSNOvGQiN+aF+hNug S10x7E+uY4vdPRNpP1bG3XlUQFxykEUaxzNPXl2/57B7t5liq6qLRT6ZO0/JQ56h8c2T 3zXBclGxIN+HsBkgRiLjR7ZSKpZaYNA8eo4QHK0E83fzpdQ+qT1atNaEJv/23fW0zfHo 2t3zhVFVZpxAW4l+Cxu0E5dE4KKnWXgblzm8c1WdW0wbocCRDwdsjyXNWOeJgVERl40K MSXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :content-id:spamdiagnosticmetadata:spamdiagnosticoutput :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=NbN4tw0OZl0xugJ0oQqU3OMqIKPWv9jyXhBuyH+9dtE=; b=seg3Ga6rV1FMe68ZDxpL0ByCgd9329LIgWFAjLHcURsie5PV25L73oq7DslVNyOY9E 76sHyx1pQfTL8cPDZRbDEIpYUlq83gTGKfondiyi195SgyyQqp1iRG4VlF4dHk1oPddy D34XB309dGvzuUb8GazdaA/fCw4ikiMd7KU6WgtL0zxvqyE35ovEM/XVDUYSgTKkD7hI 8JOzP0Bbu2VZQMx8N2Pps8acnw3lciZzJWNhsp2v3hCeyEb0N/loTrBNW7I/wPp4R8PU wOhzrrCfaFbT3kIt+CORRsvc4dLAq4yfT358TI/yHrrURmh4TGCD4gS7da0Sgg+K13Yg nzMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@catalogicsoftware.com header.s=mimecast20180821 header.b=hes4RDjt; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s136-v6si17808554pfs.255.2018.09.17.17.46.35; Mon, 17 Sep 2018 17:46:49 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@catalogicsoftware.com header.s=mimecast20180821 header.b=hes4RDjt; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728592AbeIRGOy (ORCPT + 99 others); Tue, 18 Sep 2018 02:14:54 -0400 Received: from us-smtp-delivery-107.mimecast.com ([63.128.21.107]:37790 "EHLO us-smtp-delivery-107.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726501AbeIRGOx (ORCPT ); Tue, 18 Sep 2018 02:14:53 -0400 X-Greylist: delayed 467 seconds by postgrey-1.27 at vger.kernel.org; Tue, 18 Sep 2018 02:14:53 EDT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=catalogicsoftware.com; s=mimecast20180821; t=1537231500; h=from:from:sender: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=NbN4tw0OZl0xugJ0oQqU3OMqIKPWv9jyXhBuyH+9dtE=; b=hes4RDjtsUeSBB26Bd+QeVbG2XbKnjDU1/2hAyeH1BeFDKD8WYr5ZY6vbWNJd6LZ3Ob/7wEiVH0+dQg0ZDOyo0iznvm/eC7Qsu8UtxXlaxF3kPkC/ozJ6e6MrpEY2Nk3EA5sWRTHVdKFGB2XyNUTTkOzxxGcAkw5yeW2MmDAERI= Received: from NAM03-DM3-obe.outbound.protection.outlook.com (mail-dm3nam03lp0016.outbound.protection.outlook.com [207.46.163.16]) (Using TLS) by us-smtp-1.mimecast.com with ESMTP id us-mta-294-xG7ZdLJXOjqiV231qHIAIQ-1; Mon, 17 Sep 2018 20:37:13 -0400 Received: from DM5PR01MB2348.prod.exchangelabs.com (10.168.192.138) by DM5PR01MB2699.prod.exchangelabs.com (10.172.185.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1143.15; Tue, 18 Sep 2018 00:37:11 +0000 Received: from DM5PR01MB2348.prod.exchangelabs.com ([fe80::55fd:2d5a:fdbc:51a1]) by DM5PR01MB2348.prod.exchangelabs.com ([fe80::55fd:2d5a:fdbc:51a1%6]) with mapi id 15.20.1143.017; Tue, 18 Sep 2018 00:37:11 +0000 From: "Ly, Bryant" To: Laura Abbott CC: "Bryant G. Ly" , Michael Cyr , Kees Cook , "James E.J. Bottomley" , "Martin K. Petersen" , "linux-scsi@vger.kernel.org" , "target-devel@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCHv3 1/2] scsi: ibmvscsis: Fix a stringop-overflow warning Thread-Topic: [PATCHv3 1/2] scsi: ibmvscsis: Fix a stringop-overflow warning Thread-Index: AQHUTue8XqW/6HgMhUG27FT8Dl/7Jw== Date: Tue, 18 Sep 2018 00:37:11 +0000 Message-ID: References: <20180911192226.3620-1-labbott@redhat.com> <20180911192226.3620-2-labbott@redhat.com> In-Reply-To: <20180911192226.3620-2-labbott@redhat.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [96.42.214.145] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM5PR01MB2699;20:sVQ05ui/P6dRlGByIT2QnLuP4MwMfGFOsZ0X1AxXqCT4V4qGua7Dd2EPIn5OCGhNJAyRtfRao42b3eLtYZKcw/GJC7JAR7Cl8OmxphXRp56zLoimt2RjdFKrDYroxqu+5da6u86qrPTuAzbBZpDcD6f0/W6Pu4ywazeVnxm72IM= x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-correlation-id: 85654288-5ee4-40ee-94f9-08d61cfedf6e x-microsoft-antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989137)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(2017052603328)(7153060)(7193020);SRVR:DM5PR01MB2699; x-ms-traffictypediagnostic: DM5PR01MB2699: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(104084551191319); x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(6040522)(2401047)(8121501046)(5005006)(10201501046)(3231355)(944501410)(52105095)(3002001)(93006095)(93001095)(149027)(150027)(6041310)(20161123558120)(20161123560045)(20161123564045)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699050);SRVR:DM5PR01MB2699;BCL:0;PCL:0;RULEID:;SRVR:DM5PR01MB2699; x-forefront-prvs: 0799B1B2D7 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(396003)(366004)(136003)(39840400004)(376002)(346002)(189003)(199004)(486006)(6506007)(53546011)(33656002)(86362001)(81166006)(6916009)(81156014)(2900100001)(54906003)(6246003)(99286004)(478600001)(446003)(4326008)(14444005)(68736007)(305945005)(256004)(11346002)(476003)(2616005)(14454004)(316002)(7736002)(106356001)(2906002)(6512007)(97736004)(53936002)(25786009)(26005)(8936002)(82746002)(5250100002)(3846002)(6116002)(102836004)(5660300001)(186003)(76176011)(105586002)(6436002)(66066001)(229853002)(83716003)(6486002)(36756003)(8676002);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR01MB2699;H:DM5PR01MB2348.prod.exchangelabs.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; x-microsoft-antispam-message-info: oxP0a1Pis1DpW5SV1WoHaaPyGFf9VqJ+RknGjJ5rQw2CCZK5oZIAGn+VHxzSD5KsX/WaEVCdT8Qx5S2gqEzO3con8noZilsFbuPTcuS2rIqKqNxnTULCvQsCjcinktIh3VQ+rDUhJDXe8VeMmoozeM3gBfXBo4DyQ66Bdo5tKCgcaxRn+OVPNsSrH+WfpsKjk5VckjEb511edA2XsnwcnDYSgq2Kly2LSDxIDhdGmIB2yI93MoZegysp/rIfpRTJ4+eWicI7HgSIxNVGfYsI6hJD9QpJcrzJo6Z8J2krKFYbWgGdrjoFJ2P3UfKz8u6b3cuRxOoyRHkCx4DLLI6XYJb6+9trmSIv4RRkAB6CTns= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-ID: MIME-Version: 1.0 X-OriginatorOrg: catalogicsoftware.com X-MS-Exchange-CrossTenant-Network-Message-Id: 85654288-5ee4-40ee-94f9-08d61cfedf6e X-MS-Exchange-CrossTenant-originalarrivaltime: 18 Sep 2018 00:37:11.4403 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: ea3d63e8-dd40-410b-9496-d2ee49ccddc3 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR01MB2699 X-MC-Unique: xG7ZdLJXOjqiV231qHIAIQ-1 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Sep 11, 2018, at 2:22 PM, Laura Abbott wrote: >=20 > There's currently a warning about string overflow with strncat: >=20 > drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c: In function 'ibmvscsis_probe': > drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c:3479:2: error: 'strncat' specifi= ed > bound 64 equals destination size [-Werror=3Dstringop-overflow=3D] > strncat(vscsi->eye, vdev->name, MAX_EYE); > ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >=20 > Switch to a single snprintf instead of a strcpy + strcat to handle this > cleanly. >=20 > Signed-off-by: Laura Abbott > --- > v3: Make sure there is an extra space in the partition name > --- > drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) >=20 Reviewed-by: Bryant G. Ly bly@catalogicsoftware.com I sent a PR to update my email from bryantly@linux.vnet.ibm.com a week ago. -Bryant