From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4D6DDC6FA86 for ; Thu, 22 Sep 2022 13:56:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id D3C3440167; Thu, 22 Sep 2022 13:56:49 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org D3C3440167 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org; s=default; t=1663855009; bh=3s1Z7mcPDACT386Sejr58Vk84L1tI3yfxXm8qkcx1cU=; h=From:To:References:Date:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: Cc:From; b=Bdl7RVrj/ne16U6rhjc1oBts3T0AuAHnDN/mgA9HhahxNgpsPhtxPtim6VvseqtYD 5QH6qsAiy+PqFFxl1QPvL1XGjD0cYNqSSUU1ZdhcKlc/a5wll3uug+Exzm5cOXEd3b xNAvlRXyL8RFZxj/nPO0PmA2cxJiOAfGOH7yKwTRQ60OcPOK6UODUaEtzwl29ptIHY W15vuElpbAQDAWioA0DEq6Vbfg+qn+eiPWrxm8x9LhNp4u8GwCYpi2pmk0VNiYvNWK TMuASwy7DpyjO6bzh3kmRGXDzj9RR467RgiBZpjB1ZWtCamOB/c82LzH2Cmc7cNVG2 EaqtseO9Q5s3w== X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PWx9Fv5d-a-J; Thu, 22 Sep 2022 13:56:48 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id AFC9E40184; Thu, 22 Sep 2022 13:56:47 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org AFC9E40184 Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 121261BF36F for ; Thu, 22 Sep 2022 04:19:07 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id DF9A141899 for ; Thu, 22 Sep 2022 04:19:06 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org DF9A141899 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Detu5SONAzfc for ; Thu, 22 Sep 2022 04:19:05 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org C4B2A4189C Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by smtp4.osuosl.org (Postfix) with ESMTPS id C4B2A4189C for ; Thu, 22 Sep 2022 04:19:05 +0000 (UTC) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id B54286338F; Thu, 22 Sep 2022 04:19:04 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4C3BEC433D6; Thu, 22 Sep 2022 04:18:55 +0000 (UTC) From: Kalle Valo To: Kees Cook References: <20220922031013.2150682-1-keescook@chromium.org> <20220922031013.2150682-11-keescook@chromium.org> Date: Thu, 22 Sep 2022 07:18:51 +0300 In-Reply-To: <20220922031013.2150682-11-keescook@chromium.org> (Kees Cook's message of "Wed, 21 Sep 2022 20:10:11 -0700") Message-ID: <87fsgk6nys.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 X-Mailman-Approved-At: Thu, 22 Sep 2022 13:56:46 +0000 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1663820344; bh=8xodEWMTndBecZO1JG0sANGtdcIZJhdCKz1ZoOkxjMk=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=uW+exXsXSGrew87ZojaTnnu2Pv1UtGXzQqjjLX2b7oGph4+PQelJUJX11FgjpqatQ ELoqv5pR8bSV3/7535PDpBw6BVY4bi59s4BaKlJSIYVXzNRY6aDLmLKhJLPFtzieTO iB7297vU052/FKz0Dc21FYTixE1ykO1VrtaDUUK3SkYuK3biSXS0J7OKhhQjo/eWra 7mj2sPUPAmfSHWCc1MV6VYkGtcRnMWzr/LNBb6lPibVdaMWLqUzHsztksp0W4hjZYv zIN6846mujkb0CwMdnKoomN+OWU5pYCeMqp4QWw7CJvtecSieKja+ya7GWiRyAj90B 2nqT/vaz2aB1w== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=uW+exXsX Subject: Re: [Intel-wired-lan] [PATCH 10/12] iwlwifi: Track scan_cmd allocation size explicitly X-BeenThere: intel-wired-lan@osuosl.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Wired Ethernet Linux Kernel Driver Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-wireless@vger.kernel.org, llvm@lists.linux.dev, dri-devel@lists.freedesktop.org, linux-mm@kvack.org, Eric Dumazet , linux-hardening@vger.kernel.org, Gregory Greenman , Sumit Semwal , dev@openvswitch.org, x86@kernel.org, intel-wired-lan@lists.osuosl.org, David Rientjes , Miguel Ojeda , Jakub Kicinski , Paolo Abeni , linux-media@vger.kernel.org, Jacob Shin , Marco Elver , Johannes Berg , Josef Bacik , linaro-mm-sig@lists.linaro.org, Yonghong Song , David Sterba , Andrew Morton , Vlastimil Babka , Alex Elder , Greg Kroah-Hartman , Nick Desaulniers , linux-kernel@vger.kernel.org, Christian =?utf-8?Q?K=C3=B6nig?= , Pekka Enberg , Daniel Micay , netdev@vger.kernel.org, linux-fsdevel@vger.kernel.org, Joonsoo Kim , "David S. Miller" , linux-btrfs@vger.kernel.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: intel-wired-lan-bounces@osuosl.org Sender: "Intel-wired-lan" Kees Cook writes: > In preparation for reducing the use of ksize(), explicitly track the > size of scan_cmd allocations. This also allows for noticing if the scan > size changes unexpectedly. Note that using ksize() was already incorrect > here, in the sense that ksize() would not match the actual allocation > size, which would trigger future run-time allocation bounds checking. > (In other words, memset() may know how large scan_cmd was allocated for, > but ksize() will return the upper bounds of the actually allocated memory, > causing a run-time warning about an overflow.) > > Cc: Gregory Greenman > Cc: Kalle Valo > Cc: Johannes Berg > Cc: linux-wireless@vger.kernel.org > Cc: netdev@vger.kernel.org > Signed-off-by: Kees Cook Via which tree is this iwlwifi patch going? Normally via wireless-next or something else? -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches _______________________________________________ Intel-wired-lan mailing list Intel-wired-lan@osuosl.org https://lists.osuosl.org/mailman/listinfo/intel-wired-lan