From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E70761F868E for ; Fri, 27 Dec 2024 21:15:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1735334118; cv=none; b=HJktVBO3C4xQ9HxDx5z7uI5SNiExg1hL8OJufbFOoILx07Oxid+l91qO2X+xtqCrH7UNwDSdAWjyo0yOfAigpSvUsUpwUuLJrPCVboh/4pRoc4p8YqsF0mnDce4MjGPAiLy87lgaeSPvFur3WKnNKKTHunlmewD0NuAnSog7Op8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1735334118; c=relaxed/simple; bh=EJCFd/qfgAI3lxqp8taLMBhSb4IVP6BjURVbcX9Y/H8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=AHDYcaWh2ju3wHfwdbexgh33tXAbVaxDs8NJhr7jCf4JQxY/e6Ap2AmUXtvqbKok9rfAZTwN2u9lClW4tux4kPZYDdCNmF3piat7h0GwL3/hj8AhywXyw8qRprboEDrjXdb9EmicZkk9R9Dixe0/Kd2NU5gjP+OVRmdgVejZtek= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Zg2oW7Px; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Zg2oW7Px" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E6089C4CED0; Fri, 27 Dec 2024 21:15:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1735334116; bh=EJCFd/qfgAI3lxqp8taLMBhSb4IVP6BjURVbcX9Y/H8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Zg2oW7PxbdarwTyxJH9wFeN/KRQE5bKMoZvHguEodzuf339anAv0NnTCinwBGKkpG JD5S3NAnfzG/v/aqBOv/zNHoDTXU61uiRggbVv6X7WforJjVItTTrADM+TvM1XSF+3 TG888ff4Hwpt5fSmxdEsK3lRxclJ7dGi+9RkwzUE4OweYFgCFW6JuyN0rYoD2FbPLt pmnlMFTvVuXNtUHKwC4gzJdCs8vTpuIPab6i/B466C5IvFN5wfWt/TnbXcleOCqEtW 0bLM1u/r+Gb70YJdUSBvjoHQXUnQqJCw4361TLLEF/YS6WpHAHm5ePgAu9QxcB4Nxs LUkIrybPv1qQw== Date: Fri, 27 Dec 2024 14:15:13 -0700 From: Keith Busch To: Leo Stone Cc: hch@lst.de, sagi@grimberg.me, kch@nvidia.com, csander@purestorage.com, linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org, syzbot+ff4aab278fa7e27e0f9e@syzkaller.appspotmail.com Subject: Re: [PATCH v3] nvmet: Don't overflow subsysnqn Message-ID: References: <20241218185000.17920-2-leocstone@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20241218185000.17920-2-leocstone@gmail.com> On Wed, Dec 18, 2024 at 10:49:57AM -0800, Leo Stone wrote: > nvmet_root_discovery_nqn_store treats the subsysnqn string like a fixed > size buffer, even though it is dynamically allocated to the size of the > string. > > Create a new string with kstrndup instead of using the old buffer. Thanks, applied to nvme-6.13.