Received: by 2002:ab2:3141:0:b0:1ed:23cc:44d1 with SMTP id i1csp1824595lqg; Mon, 4 Mar 2024 05:12:10 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXktvJamecyde23g1lZN3S/x8k07X72P/SC9XLMAXiasQfjZH9aTR63w/yM7IG0ovuODmOepbw95VmE9MIyPbh3Sx28WxSBuNdueF5eZA== X-Google-Smtp-Source: AGHT+IFJBXUSEZtIOqJDhXlN7NS5CLBAdnoM6RCE/xwyUZHybsEIIcDqO/4BllVRQ+h4SxtqsZNs X-Received: by 2002:a05:6a20:841f:b0:1a0:a098:5855 with SMTP id c31-20020a056a20841f00b001a0a0985855mr11393002pzd.17.1709557929778; Mon, 04 Mar 2024 05:12:09 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709557929; cv=pass; d=google.com; s=arc-20160816; b=i36zRNos3B1AJ+PrlgR2vf9/Cl5/thWtFuBy1Tn71zXThDCBgNKh+d48ddhKYtQ/Tu VGxqG9wMoyLkRmUtS7UXqyVhVeynMSdaLkELWPFdzQxMaQaieXyPcjLU3iMFhVJbBD7u SMzd1v4TNGsB/4Rax6QGzgnPHesSU2e5tvU22VNhA07ZKnlW1EkuiMCn4/NACJBaNhR+ 3mKcipBM+JWmjFk1mEoHc1eeyXI91LBC3byS3BTP4V4lPgsx2H41BM85wK+E5VZCk22u tRJsHB5CoIHZnYZ+h5WCR1PyU6BqWySkSF0lPd5tomZNnhVCOz7ZJkjl0/VEc4kqAXGx aQRg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature:dkim-signature; bh=s0PGTHwpKytd1sDB5eULtOYAf6TaSfVYWh98iQ/exoU=; fh=XatHpjtHtPaDBtdxScke3HsiBKXIuEGt2CkHlziwC44=; b=CzJAz79jvaK6491w1mnDIL+PL6tSWjW5T1NWUiYSsF2DjPQOkVu9NCDYS6wGAwAEXI 5EpQ/Tp7SQ222WQ8g4bKp6bwiKtsqVOIFsfgnglzJBTCGATSqEYCn1WTVvRwXKZ7v7Vv dexEmITVUV8xiCQvIoBBWmv2dncnG+pQGatrNVp+T0Dkp3/On5oUkQ0/AtL8bpHQSNsh c54SnCnzGRaSJfxGi1kuSc4JJsBSvWXsQrYIfm5++pFOdGtoIGWX+nqSfsw+7PNhCrNo inLqcuICeAsgAOjsDjqyYGWngiMhnc6k2/xYtABL5ot5sfletLnfvMrdRdwTlA2MkdD2 1K7Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@codewreck.org header.s=2 header.b=KS8rKyFk; dkim=pass header.i=@codewreck.org header.s=2 header.b=DnWsJ5MP; arc=pass (i=1 spf=pass spfdomain=codewreck.org dkim=pass dkdomain=codewreck.org dkim=pass dkdomain=codewreck.org dmarc=pass fromdomain=codewreck.org); spf=pass (google.com: domain of linux-kernel+bounces-90618-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-90618-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=codewreck.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id i68-20020a639d47000000b005cd8b5dfe9csi8402970pgd.491.2024.03.04.05.12.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Mar 2024 05:12:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-90618-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@codewreck.org header.s=2 header.b=KS8rKyFk; dkim=pass header.i=@codewreck.org header.s=2 header.b=DnWsJ5MP; arc=pass (i=1 spf=pass spfdomain=codewreck.org dkim=pass dkdomain=codewreck.org dkim=pass dkdomain=codewreck.org dmarc=pass fromdomain=codewreck.org); spf=pass (google.com: domain of linux-kernel+bounces-90618-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-90618-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=codewreck.org 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 9A0A6281669 for ; Mon, 4 Mar 2024 13:11:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1534D3DB97; Mon, 4 Mar 2024 13:09:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=codewreck.org header.i=@codewreck.org header.b="KS8rKyFk"; dkim=pass (2048-bit key) header.d=codewreck.org header.i=@codewreck.org header.b="DnWsJ5MP" Received: from nautica.notk.org (nautica.notk.org [91.121.71.147]) (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 F3F5E3D3B4 for ; Mon, 4 Mar 2024 13:09:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.121.71.147 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709557789; cv=none; b=SvmIsx3U0svzA+onNn0VtMh1q+VUKt6a18Zdv6xIOatP+Gia3RjWnzP3c0lrUqb8Lnq3JPQX2w5VUE5xx5DRmSfcyiiU26f0GJjJvnTxhok8gOd/DZIlC32qLPZXEzC2Tmd5qgRxIYrCZ4t/M8PAIEqBdmMbikz52qzuSLgJ/Fw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709557789; c=relaxed/simple; bh=RR2NSLWwbVW4/3Rvbk2rFQ2Ov8AclpNWaKYE0SK02wE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=cTe8h/qWeP1NH06FNqQD6d7Q0V2dyxc6WmX39DWmebYYz5q/717tMYZWh0i9iXWpBheGAdDidblyp+YFtiYluENJMQUPjB9c96xvIpGGYq6s+ZhUm6px+WSptCW3811mnOQ3ZlOsyZphshTwUGFXcXjOAwZy6fyDlPQoI15SGOs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=codewreck.org; spf=pass smtp.mailfrom=codewreck.org; dkim=pass (2048-bit key) header.d=codewreck.org header.i=@codewreck.org header.b=KS8rKyFk; dkim=pass (2048-bit key) header.d=codewreck.org header.i=@codewreck.org header.b=DnWsJ5MP; arc=none smtp.client-ip=91.121.71.147 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=codewreck.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=codewreck.org Received: by nautica.notk.org (Postfix, from userid 108) id 8AEFCC021; Mon, 4 Mar 2024 14:09:46 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=codewreck.org; s=2; t=1709557786; bh=s0PGTHwpKytd1sDB5eULtOYAf6TaSfVYWh98iQ/exoU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=KS8rKyFks8qka7PDdM4gKUeuoX/J15GeZC6j86CDoVYo319zNvyv4zJMi99gXneZI rQ4VhyVKNDfpSk9ADuxjDO3tTyE5O1dBnSz/y3d1Md0H4aVMUyQsGiiIrebyOwE7P/ xnMxaNMjFJmzRcTtgqrG/drO2CZITGmrbXfD8XhxPWDQOXRNH29zSNGaU4bIVqggCr pkb2wygNlPq0Ey0e8CcVwpaxVebStpt+h1X2r3hUmE5Khxkm5fyAS7L4sQV/mIXjZ3 E+qrAml0Pp2h17ZIZ7t9qLDEvOVDMFBL0d/Uuh2VZzu+Mmk1xGL1CAX9zlgKzRf166 XbrlAQzBOm19A== X-Spam-Level: Received: from gaia.codewreck.org (localhost [127.0.0.1]) by nautica.notk.org (Postfix) with ESMTPS id 3F2A9C009; Mon, 4 Mar 2024 14:09:42 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=codewreck.org; s=2; t=1709557785; bh=s0PGTHwpKytd1sDB5eULtOYAf6TaSfVYWh98iQ/exoU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=DnWsJ5MP/7YQwdz2XJKyblT78LnUgcyimuioPR7RDmw93HExCrRM8PySPELnvxrdt CYuPioAOyAFZnzUCnIgrMopnIwsfbdTSHxeYqR9g5pYBIr0GHB1um2aJ8zaTmTvqxe MT8RqRmOMnyTMCkQQ4e5F4HOT1DcvbyX3ugSn998ugqIHy0VSDDTQJUnUpvLFeqLrG DPkWFJFbwdEQNVICUghXbswq3fehLxDLy+v4Z8mRxHCGJbEvw5cIAsUUPkzI5om0wf ltl8wkIQ99AdAe2UThj0C2ycDYkbwZtzrNaDqAbuZeGz45fdNDER6bIPSM4A9aFaDG dJw7ZB62oRLHw== Received: from localhost (gaia.codewreck.org [local]) by gaia.codewreck.org (OpenSMTPD) with ESMTPA id de9c5528; Mon, 4 Mar 2024 13:09:37 +0000 (UTC) Date: Mon, 4 Mar 2024 22:09:22 +0900 From: Dominique Martinet To: Fedor Pchelkin Cc: Christian Schoenebeck , Eric Van Hensbergen , Latchesar Ionkov , Venkateswararao Jujjuri , "Aneesh Kumar K.V" , v9fs@lists.linux.dev, linux-kernel@vger.kernel.org, Alexey Khoroshilov , lvc-project@linuxtesting.org, syzbot+56fdf7f6291d819b9b19@syzkaller.appspotmail.com, syzbot+a83dc51a78f0f4cf20da@syzkaller.appspotmail.com, Pavel Skripkin Subject: Re: [PATCH] fs: 9p: avoid warning during xattr allocation Message-ID: References: <20240202121319.21743-1-pchelkin@ispras.ru> 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=utf-8 Content-Disposition: inline In-Reply-To: <20240202121319.21743-1-pchelkin@ispras.ru> Fedor Pchelkin wrote on Fri, Feb 02, 2024 at 03:13:17PM +0300: > An invalid server may reply with an xattr size which still fits into > ssize_t but is large enough to cause splat during kzalloc(). Ah, sorry for not replying to this earlier.. and I had forgotten about it when something similar came up just now. I've submitted a patch to limit such allocations to 64k: https://lkml.kernel.org/r/20240304-xattr_maxsize-v1-1-322357ec6bdf@codewreck.org Would you agree this makes this patch obsolete? I'll go ahead and add the reported-by/closes you cited in this mail to my commit. -- Dominique Martinet | Asmadeus