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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A4C03C433F5 for ; Mon, 16 May 2022 15:02:11 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id C355283F36; Mon, 16 May 2022 17:02:08 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=konsulko.com header.i=@konsulko.com header.b="poSya94r"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 59D5684184; Mon, 16 May 2022 17:02:06 +0200 (CEST) Received: from mail-qk1-x72d.google.com (mail-qk1-x72d.google.com [IPv6:2607:f8b0:4864:20::72d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id E3D6283F00 for ; Mon, 16 May 2022 17:02:02 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qk1-x72d.google.com with SMTP id c1so12400289qkf.13 for ; Mon, 16 May 2022 08:02:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=UbJVL/lp7ByK32tCYZuRxspHq/OMG48nvmHrKiS+59E=; b=poSya94ryg/fk2Wdj7Abi0nOf4+9Wd1EMUTFG3JWPH1tgpkrMa7YYTd738fQwRc0XT 9TwI9s7XYfDEl3wC5pCCtkUBIqM5NFgSi5wPkCGoyud0KgsUB+0MZt74fkQjJK8VcL59 Blsk2nI0qBpY8aP4iRUabC+erm7aoQ4xJXpRo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=UbJVL/lp7ByK32tCYZuRxspHq/OMG48nvmHrKiS+59E=; b=hWoDwMH4f3afnrAqjioH9plmheJWTE5Vr4ka2xYSNaUzY/NI3viIaYhqEw4ph1U+Mm a0Ugk/gEzh/zqRIJpoo6TJ/Qq8VUBOkI/E0cB8odDgwM/w2GV5se3qlNCdDpkdghxKGF Ahja071RflWDOSuVH9pIAWFfk/uH0dTSBG2rlBipjsAZ6fQZZwvtuljC/LR8Il63DOif DFtaV2AbjKsU3cx0nKaDSLKauDUo6DJ/jxyL5CnV8d/QvCYud/tTTtHE7H9E5dPA6711 OV+vpk47Lp7+sTEwZrjmh4OuQ3krNcd6l6xEbKPdJi6SV+ZRmkf1nn+UdT0ct3ep1z5n n1FQ== X-Gm-Message-State: AOAM533XSa5vWepkeefFCq1HtSQV9JdsicXVJ+i2NY1T87+4EocJwuzc ZKl/5azbbWr56RG7KD4UMpfCIFPhjje3vQ== X-Google-Smtp-Source: ABdhPJzAjHqjy8t0Y+/rdB5HnscQz5r52q9DBBxe7IzQzaCMV4kMnQs+VEB/OFMq+R16kM0nZGLX3g== X-Received: by 2002:a05:620a:448b:b0:6a0:3266:f6ef with SMTP id x11-20020a05620a448b00b006a03266f6efmr12960591qkp.427.1652713321467; Mon, 16 May 2022 08:02:01 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b01-4500-9498-43b2-2ef8-85ee.res6.spectrum.com. [2603:6081:7b01:4500:9498:43b2:2ef8:85ee]) by smtp.gmail.com with ESMTPSA id x10-20020ac86b4a000000b002f39b99f679sm5982275qts.19.2022.05.16.08.02.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 May 2022 08:02:00 -0700 (PDT) Date: Mon, 16 May 2022 11:01:58 -0400 From: Tom Rini To: Andrea zi0Black Cappa Cc: u-boot@lists.denx.de Subject: Re: [PATCH] Fix CVE-2022-30767 (old CVE-2019-14196) Message-ID: <20220516150158.GP3901321@bill-the-cat> References: <20220516143345.1892-1-zi0Black@protonmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="4VWgGltm/5syTS5r" Content-Disposition: inline In-Reply-To: <20220516143345.1892-1-zi0Black@protonmail.com> X-Clacks-Overhead: GNU Terry Pratchett X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean --4VWgGltm/5syTS5r Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, May 16, 2022 at 02:33:33PM +0000, Andrea zi0Black Cappa wrote: > Signed-off-by: Andrea zi0Black Cappa > --- > net/nfs.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) >=20 > diff --git a/net/nfs.c b/net/nfs.c > index 3c01cebd96..9152ab742e 100644 > --- a/net/nfs.c > +++ b/net/nfs.c > @@ -52,7 +52,7 @@ static const ulong nfs_timeout =3D CONFIG_NFS_TIMEOUT; >=20 > static char dirfh[NFS_FHSIZE]; /* NFSv2 / NFSv3 file handle of directory= */ > static char filefh[NFS3_FHSIZE]; /* NFSv2 / NFSv3 file handle */ > -static int filefh3_length; /* (variable) length of filefh when NFSv3 */ > +static unsigned int filefh3_length; /* (variable) length of filefh when = NFSv3 */ >=20 > static enum net_loop_state nfs_download_state; > static struct in_addr nfs_server_ip; > @@ -573,8 +573,6 @@ static int nfs_lookup_reply(uchar *pkt, unsigned len) > filefh3_length =3D ntohl(rpc_pkt.u.reply.data[1]); > if (filefh3_length > NFS3_FHSIZE) > filefh3_length =3D NFS3_FHSIZE; > - if (((uchar *)&(rpc_pkt.u.reply.data[0]) - (uchar *)(&rpc_pkt) + filef= h3_length > ) > len) > - return -NFS_RPC_DROP; > memcpy(filefh, rpc_pkt.u.reply.data + 2, filefh3_length); > } Thanks. Can you please elaborate on the issue, and how this fixes it, in the commit message? --=20 Tom --4VWgGltm/5syTS5r Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmKCZ2MACgkQFHw5/5Y0 tyyCmgwAhfXTfxQg19whGe89umkrnLb4PD+XokrggY1w+PHLyIAKBfqt+zSgPzzd XZAo/wXf0cysJvz1gjorcEq/jDGCWZrWtVOisVFQPN4hwTiczdOT8UPi7Y3CyOxH +x9IAhXIMjjvPvnOzaHkfLLgHCfGfO3J4cFiQFa89K9nspgRZYFWhsEcF97eck3k 6WeztyjoBtYT7flwBl8rcMYx2VJCzIeV4AU16aehZlbs2IeekAMmG9G6U6tyWaOA MYjibZRBhMJTH23rWyZedij5ETiJ+plpdg8MZBw7I7VG38HqOmvgQwdyt5yv/rvM K0skJvK2WK6nY9X63zv0HdSpK5yhWMc8QF1myEW7wTUjowb9UvjGO0Qpbr4ZyPqT f+C+f/2JTUkEotsWwbrDwIbgv1zQNMiQQ6MOKsACdSyCs0GaboI81ybWFUBm+B7k 7Cx7Xs7//KABU82NU4+3fCHzmdGhu/Rd+DiyEz+QNhwGsQA2L4oxxX7A63Q1zy8d wnQRJjWi =Vd75 -----END PGP SIGNATURE----- --4VWgGltm/5syTS5r--