From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 12CF258F094 for ; Fri, 11 Sep 2026 20:02:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789156978; cv=none; b=jATytF4f2lTw65XlUYtOM8nFkom/WeMKKAZ6QzC547Jb6D/vGxmUaluyBp+ryCY2VQV87USFdkLzLS0uQXv1+QemC4kdbrsLX5MNVRXMhYABWOQfvoWF0IP2lxQbZzxvQaQ8rsm3oChz8LnMiW+Ga5/ljFc8vxzwYP4gz4Dyyes= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789156978; c=relaxed/simple; bh=idBQ41M6aU/JxXAXM7zmJEoz1RF4CwOjk5gAOuG8DHg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=TfoPyJTRpDvcsY2VBHVBnUiBP1FiOauvNcZA2BHDQXyY6rs5PtNg4R+Z39MOg8N2Mb8Lei/iPxStRZ71H4pYgjKZFPgoChzn/48QDUZkIhB8a62JWRbWaeWitXPaUn5p1E4v6LiLiWGHDu1NTz7JzQOthIigzMvfMSFIh9KPjE8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=vrHhs5Yn; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="vrHhs5Yn" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 62A291F0089B; Fri, 11 Sep 2026 20:02:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1789156967; bh=a4hZ4EJPtLzzFAx3h0yqS2YqcVUsgVkGFYWXcYsnTAg=; h=From:To:Cc:Subject:Date:Reply-To; b=vrHhs5YnduprKk/xu19p4+00PbqbH1arS2nRfDv1FRIbeRMpgIGwnOd/Cmz/8W0z6 qg857s+Lm1z9yiSh4IW0OT/6933bUv2XV+bOfN7AG6Znt5wtT555eaf20gMkO7MtqK kc8DmWmQYBIDlAXyQNKiOkgzwUeun32hVZrM9N9s= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-89665: nfsd: reject out-of-range useconds in NFSv2 SETATTR/CREATE Date: Fri, 11 Sep 2026 21:45:54 +0200 Message-ID: <2026091147-CVE-2026-89665-e747@gregkh> X-Mailer: git-send-email 2.55.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=4390; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=M5YFVKZLwtNCSEMs1rCDg9UuyfwEsCwCOSoGB5KaOjQ=; b=owGbwMvMwCRo6H6F97bub03G02pJDFlLIqtjuKzELzov+fRd91f2ZY5fLDszFBnnS1+5fttpi l8kz+zpHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjAR4TSGOTxv1um9WqWWcOXj 8dWdUe4VvW2/hRgW3DDY4TnVPzpZK14ny+yJf6vntQgNAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: nfsd: reject out-of-range useconds in NFSv2 SETATTR/CREATE The NFSv2 sattr decoder converts the wire useconds to nanoseconds in svcxdr_decode_sattr(): iap->ia_atime.tv_nsec = tmp2 * NSEC_PER_USEC; tmp2 is a u32 and NSEC_PER_USEC is 1000, so the product is computed in unsigned long. On ILP32 that is 32 bits, and an out-of-range useconds value such as 4294968 wraps to tv_nsec == 704. The corruption therefore happens during decode, before any proc function can inspect the value, and a later range check on tv_nsec would see an in-range result and accept it. Rejecting in the decoder yields an RPC GARBAGE_ARGS reply. NFSv2 defines no NFSERR_INVAL, so there is no NFS-level status to return for a malformed time argument, and the check cannot move to the proc function the way the v3/v4 nsec range checks do. Guard the raw useconds before the multiplication and reject values greater than 1000000. useconds == 1000000 is kept: it is the Sun convention for "set to the current server time", and the in-tree Linux NFSv2 client emits it in both the atime and the mtime field for a plain touch / utimes(file, NULL) (see encode_sattr() and xdr_encode_current_server_time() in fs/nfs/nfs2xdr.c). Rejecting 1000000 would turn that common operation into a hard decode failure for both SETATTR and CREATE. 1000000 * NSEC_PER_USEC is 10^9, which does not wrap on ILP32, so the Sun convention value passes through safely. Only genuinely out-of-range values (> 1000000) are rejected. The atime and mtime guards are therefore symmetric. The decoder only applied the Sun convention in the mtime block, which clears ATTR_ATIME_SET|ATTR_MTIME_SET when mtime useconds == 1000000. If a client puts 1000000 in the atime field but not in the mtime field, the atime block stored an out-of-range tv_nsec (10^9) and left ATTR_ATIME_SET set, so the bogus value reached the filesystem. Apply the convention in the atime block as well, clearing ATTR_ATIME_SET so the server uses its current time and ignores the value. Only ATTR_ATIME_SET is cleared there. The mtime block keeps its existing behavior, where 1000000 means "set both atime and mtime to now". [ cel: various tweaks, addenda, and clean-ups ] The Linux kernel CVE team has assigned CVE-2026-89665 to this issue. Affected and fixed versions =========================== Issue introduced in 2.6.12 with commit 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 and fixed in 6.12.109 with commit a937dd1aa2d92291fe0a1860d17e90d8f206cd22 Issue introduced in 2.6.12 with commit 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 and fixed in 6.18.50 with commit ad02d095439f89cbd6629420c7e3ba476457b83b Issue introduced in 2.6.12 with commit 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 and fixed in 7.2.4 with commit 1195483965a5f63d2dde18054ec7e50a23b9071c Issue introduced in 2.6.12 with commit 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 and fixed in 7.3-rc1 with commit 26709c8ffe73772eb69e68d553ac71d91228dccc Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-89665 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: fs/nfsd/nfsxdr.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/a937dd1aa2d92291fe0a1860d17e90d8f206cd22 https://git.kernel.org/stable/c/ad02d095439f89cbd6629420c7e3ba476457b83b https://git.kernel.org/stable/c/1195483965a5f63d2dde18054ec7e50a23b9071c https://git.kernel.org/stable/c/26709c8ffe73772eb69e68d553ac71d91228dccc