Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1289163rdb; Mon, 19 Feb 2024 10:02:21 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCU0+g1L2sKVO3X4uF/c+gAI+Y1wpOU6ZtpuVezFpWOFTQqNSI4ky+Rux4ATXaIim8kQT123eaOxYVZmOsI+HO+kYF2mQHTiA41ydj0gBQ== X-Google-Smtp-Source: AGHT+IGdVISDJ6fRDwvc4fIs7tLIvzzW9yF+juyhTEYqQ1hhmCHJL3KacP2gDOjs5Y83coQgJpTl X-Received: by 2002:a05:6a00:8006:b0:6e4:61cf:337f with SMTP id eg6-20020a056a00800600b006e461cf337fmr5058247pfb.26.1708365741372; Mon, 19 Feb 2024 10:02:21 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708365741; cv=pass; d=google.com; s=arc-20160816; b=Pd5ZP6n9LkaMl2rqgRMvye06k7wDl1X/5q9qQ8QdAmqI4wu49wnOqsL1Ht6HWO9cjQ wwfq5B5UYvDb41JNPqiXWWfddE0HXbOIkSwkmRoipkeU6okQ+aMZ45SERv31LnQQQR0p gAS0fj/omcr9jG/tDzJfLZnB7vIjH2Wh3LYXd02o98oZV1qD7sHhYI/eMZx8/uhYR6ua +I4pyNeUUBbckaPtSN0HSESq2Ov24pRTnMRD898PrbKV3tSaTcYoe5eJs2MC4UfI2OY3 PofiRiXqnh1OehbQ/XeocYAyWkGfkQlo/HwVmMpqgdBj3OGhQuQKy6osr07yEg+ysEo8 UesQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=ti6upGoRyyrC2hvsjOkpJVRvXntoJTVQ7/Zs/uqxjT4=; fh=DTMdhYyrWQKksZJ0bdxaT4GUZTb/M8f2qN69aLuEc3Q=; b=o5kl2S1WTygA9v5Q/EsHNEJCrPbmQOrMPwB4Sc11afss8uJ6Afz9JPfkVJnS5vn+W9 G8DN0OCawLrDUQvJADRHHWCdwG6tMM/EAIW+142+VsndJZyub/djfvBIa/11Qesqqpd1 ZKztv5w4EdRDQkQI2jfEHJpESPljCaP5SfCdlzTvjV6NZoyBm5UavFNhKQau8muvdvjF PEiUB65uQKGRtl3XUyYFSMRkj/qtnHS5gEDoPet224WA8WTQkAo78lb49nPQMDdkA4th uw7ca1yZ+q2OFGKPy2p7dQjOA6ZZm/PFzN5F2LgnRL3L3IQrCcJoa0bFaE89JhNjwhek HZIA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@wanadoo.fr header.s=t20230301 header.b="hL2FC/PY"; arc=pass (i=1 spf=pass spfdomain=wanadoo.fr dkim=pass dkdomain=wanadoo.fr dmarc=pass fromdomain=wanadoo.fr); spf=pass (google.com: domain of linux-kernel+bounces-71790-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-71790-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=wanadoo.fr Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id cp11-20020a056a00348b00b006e3f7e38f78si3302501pfb.59.2024.02.19.10.02.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Feb 2024 10:02:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-71790-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@wanadoo.fr header.s=t20230301 header.b="hL2FC/PY"; arc=pass (i=1 spf=pass spfdomain=wanadoo.fr dkim=pass dkdomain=wanadoo.fr dmarc=pass fromdomain=wanadoo.fr); spf=pass (google.com: domain of linux-kernel+bounces-71790-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-71790-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=wanadoo.fr Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C7DF8284B52 for ; Mon, 19 Feb 2024 18:00:28 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C091D47F76; Mon, 19 Feb 2024 18:00:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wanadoo.fr header.i=@wanadoo.fr header.b="hL2FC/PY" Received: from smtp.smtpout.orange.fr (smtp-14.smtpout.orange.fr [80.12.242.14]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1A7EE40BE3 for ; Mon, 19 Feb 2024 18:00:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=80.12.242.14 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708365619; cv=none; b=L2k2mR+fetqMm6PaHzSWmCIMiGONDuZPCiSWTbhf+YGPsn90PuoVhdrsYTFvesg0CA6r94UePE3RNvsuby5Oxvb1FMdkaM6kOQJQ8gVKo//2G0MmpH/6ChSc2qXAEdDy8AwrFpx8hne0VFRglBRLVb4tOTvfBz6sEKt4V7bGi6I= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708365619; c=relaxed/simple; bh=DdJ+JPoHBEw3IODe8oZcYF1OwcZG3gCPKyYpD6UWBuw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=irm/ixkN3ouOignIRDOBYj2CRFLdn1FT7X23oxpomCVCDuFcL5HTlTQ8Qauuedc3MCOet2ixc9h69sSfbKacACNRxLxjm0FSCCiAC6qoBQfNTjOuQNfSZsbOFmIY7zovfYpFrIa/3NjSBBtpX3EAqDw6WzWbsKc0u+h+7LZpQJ8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=wanadoo.fr; spf=pass smtp.mailfrom=wanadoo.fr; dkim=pass (2048-bit key) header.d=wanadoo.fr header.i=@wanadoo.fr header.b=hL2FC/PY; arc=none smtp.client-ip=80.12.242.14 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=wanadoo.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=wanadoo.fr Received: from [192.168.1.18] ([92.140.202.140]) by smtp.orange.fr with ESMTPA id c7uwr4K1Rb1Jlc7uwrZn6h; Mon, 19 Feb 2024 18:59:05 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wanadoo.fr; s=t20230301; t=1708365545; bh=ti6upGoRyyrC2hvsjOkpJVRvXntoJTVQ7/Zs/uqxjT4=; h=Date:Subject:To:Cc:References:From:In-Reply-To; b=hL2FC/PYBaouzvlBBq79Hga/FRp5lg0G/W0pv0oEN7ZYTyC6Gf3gvHnHNw0Chyxy3 FEBM012Ssb3ZtdercwRyvz8fiFGb/WOFilLBBKWlE//OA8lgUKJ9csKadViwxkI0ry t6h6RUTjQLA0vzgEG5S5pymbbZLTHLuX45NWMKnn7JTrIbTkZXPIGrjWBufil8a87Q Q3EbREOG9yH1CFM3FTepq/D7O8VcQnCYZiD+AsuA4vqGnDdep+v7gGh2yhnrYRnUUH bJSAvWeNGVO49Iznz8JoOuCSirJw5+4S/PA0MLr0oSlnvzzprX0Ji6NcET/oWbYYCw mFmzV1c/a833Q== X-ME-Helo: [192.168.1.18] X-ME-Auth: Y2hyaXN0b3BoZS5qYWlsbGV0QHdhbmFkb28uZnI= X-ME-Date: Mon, 19 Feb 2024 18:59:05 +0100 X-ME-IP: 92.140.202.140 Message-ID: <3fe4c327-b69b-464e-8e4e-005fa1813279@wanadoo.fr> Date: Mon, 19 Feb 2024 18:59:02 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] udmabuf: Fix a potential (and unlikely) access to unallocated memory To: Dan Carpenter Cc: gustavo@embeddedor.com, keescook@chromium.org, Gerd Hoffmann , Sumit Semwal , =?UTF-8?Q?Christian_K=C3=B6nig?= , Daniel Vetter , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-media@vger.kernel.org, linaro-mm-sig@lists.linaro.org References: <91d964c2-3d5a-4e96-a4db-e755455c5b5c@moroto.mountain> Content-Language: en-MW From: Christophe JAILLET In-Reply-To: <91d964c2-3d5a-4e96-a4db-e755455c5b5c@moroto.mountain> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Le 19/02/2024 à 09:37, Dan Carpenter a écrit : > On Sun, Feb 18, 2024 at 06:46:44PM +0100, Christophe JAILLET wrote: >> If 'list_limit' is set to a very high value, 'lsize' computation could >> overflow if 'head.count' is big enough. >> > > The "list_limit" is set via module parameter so if you set that high > enough to lead to an integer overflow then you kind of deserve what > you get. > > This patch is nice for kernel hardening and making the code easier to > read/audit but the real world security impact is negligible. Agreed. That is what I meant by "and unlikely". Maybe the commit message could be more explicit if needed. Let me know if ok as-is or if I should try to re-word the description. CJ > > regards, > dan carpenter > > >