b3qvk3dP1k18sRRyfazpE3JLNq12jEupTG6jjOm9Lanc4cG0N8w25p16h uVuyLJqjg0s3s1VYpb4xejnTbapLpOv6tuOREey+CEivcAzEi+i+ER1448JSgFmbsr4wcq W/wEKTvE0ipuhmAskwOUKpfFnyVchPNACRjdkXwuxYugDhzoDF39BuW0mra+y8MI7xcXkP VCQCF20Ox7sKM2+YMtBXl0I2L/KFJci5DRLdv/ldpSZe6jYd9FzlIKo+pZJ+pVRJ9IMYWG Ij9DC8jwyBzBuAH29U3uIa8t9MdvcgmLnRbv8aEde/5FnFgcGL8tqIJE9T9EfA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1781032653; 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=cDmL4q+PNmWxCb3i7zPY+LpNC2NSIxKEB9dLDR7iX5U=; b=Q+svQnYt7Ad50sPSQj9QrHLK/qDaTaVYhTRw3BjhcV9T8IulL/c9xE9uKval8cM+Fr9hoT EfoJYCyn/j+EKLkpo1x5YRrYqhv0WKcv0EXoyb5Lvh+WqyE5rg+3SLKnBSiFQJZJGubGSs SePy29nzPatcuU6BT8B1FNcoJscT1Gf2I+d/tTC0Govlz9fcBHoTwkqzvXo4YXAXCpHpKC GzfFCf5lJpPdkZOSiKEaDs3rRz1U5akwxnuzjF9BIsYCB6FuCWuUfmdglPhX5rKBxc1QWw n+eqPsbj2u/3PTfXb1XQ4uG9Q2Wg9wi3fMjuJoYYjKvyphh0KgJdbIQz+7Z0bg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4gZdvx2Jkpzn9V for ; Tue, 09 Jun 2026 19:17:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3cd76 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 09 Jun 2026 19:17:33 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 3ac9726c4269 - stable/15 - linux: Correct the issetugid check in copyout_auxargs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 3ac9726c42693822c538367fd80f45b606a59ddf Auto-Submitted: auto-generated Date: Tue, 09 Jun 2026 19:17:33 +0000 Message-Id: <6a2866cd.3cd76.55b07417@gitrepo.freebsd.org> The branch stable/15 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=3ac9726c42693822c538367fd80f45b606a59ddf commit 3ac9726c42693822c538367fd80f45b606a59ddf Author: Mark Johnston AuthorDate: 2026-05-29 21:41:35 +0000 Commit: Mark Johnston CommitDate: 2026-06-09 19:15:24 +0000 linux: Correct the issetugid check in copyout_auxargs The runtime linker in glibc relies on the AT_SECURE auxv entry to know whether the executable is set-ugid, if so then various dangerous functionality such as LD_PRELOAD is disabled. The check added in commit 669414e4fb74 failed to take into account the fact that during execve, P_SUGID may not yet be set for a set-ugid process. Correct the test. Approved by: so Security: FreeBSD-SA-26:30.linux Security: CVE-2026-49413 Reported by: Minseong Kim Fixes: 669414e4fb74 ("Implement AT_SECURE properly.") Reviewed by: kib Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D57350 --- sys/compat/linux/linux_elf.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sys/compat/linux/linux_elf.c b/sys/compat/linux/linux_elf.c index c9eb6aea8373..6c9f785c97e7 100644 --- a/sys/compat/linux/linux_elf.c +++ b/sys/compat/linux/linux_elf.c @@ -492,11 +492,9 @@ __linuxN(copyout_auxargs)(struct image_params *imgp, uintptr_t base) struct thread *td = curthread; Elf_Auxargs *args; Elf_Auxinfo *aarray, *pos; - struct proc *p; int error, issetugid; - p = imgp->proc; - issetugid = p->p_flag & P_SUGID ? 1 : 0; + issetugid = imgp->credential_setid ? 1 : 0; args = imgp->auxargs; aarray = pos = malloc(LINUX_AT_COUNT * sizeof(*pos), M_TEMP, M_WAITOK | M_ZERO);