From nobody Mon Jan 20 22:26:34 2025 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4YcQ163bnWz5l3W2; Mon, 20 Jan 2025 22:26:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4YcQ16325hz4MQk; Mon, 20 Jan 2025 22:26:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1737411994; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bf44mUCweZEZUUc4+vIUNgOya69SnVBlIp18c/9oE54=; b=gYrE/zBx+CB11aZ45lmBoswoC9F2z1OAhNVR0G4JenhVcBKgN4+90d3z8ZEFyAA9gzthet e4FbfJizegagtTDNpbfaStu3WSYf8hlcCNlduKj9ZwM1FK3/PGn2dcTfQfqLXuVGHxgPYV 01tVUybKZXfjhby7zp2AD0nWbF8a69FSW/wFd0V8gKrDOX7at3gXq9hfbsFLGgOwlEW++4 IqaEqWP5Gxkic7XNZ5K4wqHymQFVXltoDBLZi3pMnUv3B5WcH4zkVqMCO4SDyR7SjZnDNO vS2Lsv9zXocYEnlMnuU+PEZoRlle6ryzVSRGi6gcGjNXPcvQKssrIFO388Vu9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1737411994; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bf44mUCweZEZUUc4+vIUNgOya69SnVBlIp18c/9oE54=; b=TWNBbpWROc5gvq9MCxPrXz76dVrEae8wt/ihBVxOr7U+iyhnRO+Sph9JmLcGQvohUL3z4q Ri5iP2Xtnqp1Mc85jJGPKUEUNurTW4Xre8+zRZw2F/8ybG6NtCc96De7d5KHrFx5OkkzpK wTHLwTSd5AxP7/V9kGiVwshbG5KnuFL0piNvCehCYhO31Bv2l8ZXYnXUhyXEfhERpOJNk6 2lyq2fEOYMSvjCIq6DFCkh7YV9if4Md7RtYYxRBEs1815nWOAvAP4ZEfQ8Be1ochPCASXU g/sLp08OBPrn8QCH/8HrSY9gee7G0nl7jaYiIhqqNzQoxTXL4KU8sUgtSKfzCQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1737411994; a=rsa-sha256; cv=none; b=OYXR57gnXsFmmxIxK9Nb+3zYCJOUaRK4ADlCINHjSW2mqU6ecQ0uxnTdLTjfLJPhuRANt9 t0xfpPvXMbyuMtIaMMv8GnlwJwzcZR7DXvFJEG9fpZc2RKxH9V+Wut2Huy7U1DakseH9+K /AQ5Xj2OfO9bXEYSk4gVVmb9+LWL0n/FyENEUF3o0Z4f9IH+Hh7L8HHbqSlZwfmLt+zMbI p1I9M5px3DuO4y1Rpfl6r6MjOufkltjPAsRZMOWUvkUv9pq9WjZVr6QqYgx+3XFauaOz2H fDI1tocEAH0/Y05XRGWnmyuKxKEeSBnJcUpPC2aodoUr5R8rlDwi3CF1aT8fFg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4YcQ1627lQzg7R; Mon, 20 Jan 2025 22:26:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 50KMQYqV088267; Mon, 20 Jan 2025 22:26:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 50KMQYdY088264; Mon, 20 Jan 2025 22:26:34 GMT (envelope-from git) Date: Mon, 20 Jan 2025 22:26:34 GMT Message-Id: <202501202226.50KMQYdY088264@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: e758e5512005 - stable/13 - nfscl: fix uninitialized memory in nfsv4_loadattr List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: e758e5512005abdc30285e95e39f98c01ae12d85 Auto-Submitted: auto-generated The branch stable/13 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=e758e5512005abdc30285e95e39f98c01ae12d85 commit e758e5512005abdc30285e95e39f98c01ae12d85 Author: Alan Somers AuthorDate: 2024-09-08 20:42:38 +0000 Commit: Alan Somers CommitDate: 2025-01-20 22:16:11 +0000 nfscl: fix uninitialized memory in nfsv4_loadattr When processing an RPC response that did not include any Owner attribute, nfsv4_loadattr would return na_uid and na_gid uninitialized. The uninitialized values could then make their way into the NFS attribute cache via nfscl_loadattrcache. PR: 281279 Reported by: KMSAN Reviewed by: rmacklem Sponsored by: Axcient (cherry picked from commit 44328abfb7aca8150b07b83ff502c9185677e3fb) --- sys/fs/nfs/nfs_commonsubs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/fs/nfs/nfs_commonsubs.c b/sys/fs/nfs/nfs_commonsubs.c index ebed4a4b5905..e35fd8d1185f 100644 --- a/sys/fs/nfs/nfs_commonsubs.c +++ b/sys/fs/nfs/nfs_commonsubs.c @@ -1280,6 +1280,7 @@ nfsv4_loadattr(struct nfsrv_descript *nd, vnode_t vp, * Just set default values to some of the important ones. */ if (nap != NULL) { + VATTR_NULL(&nap->na_vattr); nap->na_type = VREG; nap->na_mode = 0; nap->na_rdev = (NFSDEV_T)0;