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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 903A6C83F15 for ; Wed, 30 Aug 2023 23:00:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344289AbjH3XAB (ORCPT ); Wed, 30 Aug 2023 19:00:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57034 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230350AbjH3XAA (ORCPT ); Wed, 30 Aug 2023 19:00:00 -0400 Received: from Chamillionaire.breakpoint.cc (Chamillionaire.breakpoint.cc [IPv6:2a0a:51c0:0:237:300::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9D6EDE70; Wed, 30 Aug 2023 15:59:33 -0700 (PDT) Received: from fw by Chamillionaire.breakpoint.cc with local (Exim 4.92) (envelope-from ) id 1qbU9h-0004AB-TW; Thu, 31 Aug 2023 00:59:21 +0200 Date: Thu, 31 Aug 2023 00:59:21 +0200 From: Florian Westphal To: Wander Lairson Costa Cc: Pablo Neira Ayuso , Jozsef Kadlecsik , Florian Westphal , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , "open list:NETFILTER" , "open list:NETFILTER" , "open list:NETWORKING [GENERAL]" , open list , Lucas Leong , stable@kernel.org Subject: Re: [PATCH nf] netfilter/osf: avoid OOB read Message-ID: <20230830225921.GA15759@breakpoint.cc> References: <20230830205554.97083-2-wander@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230830205554.97083-2-wander@redhat.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Wander Lairson Costa wrote: > The opt_num field is controlled by user mode and is not currently > validated inside the kernel. An attacker can take advantage of this to > trigger an OOB read and potentially leak information. [..] Can you send a v2 that rejects bogus nf_osf_user_finger structs? nfnl_osf_add_callback() seems to be the right place to refuse it.