🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: muc.lists.freebsd.emulation
Article #14

[Bug 297426] linuxulator: linprocfs /proc/self/exe host path breaks execve under Linux ABI

#14
From: bugzilla-noreply
Date: Sun, 18 Oct 2026 15:49
70 lines
5340 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=297426

--- Comment #44 from commit-hook@FreeBSD.org ---
A commit in branch main references this bug:

URL:
https://cgit.FreeBSD.org/src/commit/?id=23b326728778fd3a6c37b33686dea98d010eb1cf

commit 23b326728778fd3a6c37b33686dea98d010eb1cf
Author:     Devin Teske <dteske@FreeBSD.org>
AuthorDate: 2026-10-18 15:44:12 +0000
Commit:     Devin Teske <dteske@FreeBSD.org>
CommitDate: 2026-10-18 15:44:12 +0000

    namei: retry absolute symlink expansions from the native root

    For a Linux ABI process, namei() resolves a path first under the ABI
    root (compat.linux.emul_path) and, if that fails, restarts the walk
    of the original path from the native root.  Since 459ac3044b51 an
    absolute symlink target found during the ABI pass stays under the
    ABI root, so self-contained Linux userlands resolve their own
    symlinks correctly (PR 289739); but when the target names a file
    that exists only in the native namespace, the walk fails and the
    restart cannot recover: it re-walks the original path, whose
    ABI-visible prefix (the symlink itself) does not exist natively.

    Casualties are the absolute symlinks planted under the emulator root
    to integrate the host into the Linux namespace -- among them
    linux-rl9-fontconfig's /compat/linux/etc/fonts ->
    /usr/local/etc/fonts (Linux fontconfig cannot load its
    configuration, degrading font matching to arbitrary results) and
    similar links from linux-rl9-alsa-lib and linux-rl9-ca-certificates
    -- and linprocfs' /proc/<pid>/exe, whose target is a host path:
    following it fails for any Linux binary whose text lives outside the
    emulator root (Chromium-based browsers execve /proc/self/exe to
    spawn helpers), unless procfs(5) mounted at the native /proc masks
    the failure.

    Remember the expansion produced while following an absolute symlink
    during the ABI pass and, when that pass fails with ENOENT before the
    target has resolved, perform the one allowed native restart walking
    the saved expansion in place of the original path.  The target has
    resolved once the walk has consumed it, leaving no more than the
    suffix appended past it; an ENOENT after that point restarts from
    the original path as it always has.  Lookups that succeed under the
    ABI root are unaffected, preserving 459ac3044b51; lockless lookups
    are unaffected because cache_fplookup_symlink() already aborts to
    the locked path for absolute symlinks whenever an ABI root is
    active.

    PR:             297426
    Fixes:          459ac3044b51 ("namei: Preserve ABI root for absolute
symlinks before fallback")
    MFC after:      1 month
    Reviewed by:    kib
    Differential Revision:  https://reviews.freebsd.org/D58855

 sys/kern/vfs_lookup.c | 106 +++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 105 insertions(+), 1 deletion(-)

-- 
You are receiving this mail because:
You are the assignee for the bug.

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-admin@muc.de
Technical Details
Message-ID: <bug-297426-4077-U6RnrNjlBS@https.bugs.freebsd.org/bugzilla/>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!2.eu.feeder.erje.net!feeder.erje.net!news2.arglkargh.de!news.karotte.org!news.space.net!news.muc.de!.POSTED.news.muc.de!not-for-mail
References: <bug-297426-4077@https.bugs.freebsd.org/bugzilla/>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!2.eu.feeder.erje.net!feeder.erje.net!news2.arglkargh.de!news.karotte.org!news.space.net!news.muc.de!.POSTED.news.muc.de!not-for-mail
From: bugzilla-noreply@freebsd.org
Newsgroups: muc.lists.freebsd.emulation
Subject: [Bug 297426] linuxulator: linprocfs /proc/self/exe host path breaks
 execve under Linux ABI
Date: Sun, 18 Oct 2026 15:49:55 +0000
Organization: Newsgate at muc.de e.V.
Sender: owner-freebsd-emulation@FreeBSD.org
Approved: news-admin@muc.de
Distribution: world
Message-ID: <bug-297426-4077-U6RnrNjlBS@https.bugs.freebsd.org/bugzilla/>
References: <bug-297426-4077@https.bugs.freebsd.org/bugzilla/>
MIME-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Injection-Info: news.muc.de; posting-host="news.muc.de:193.149.48.2";
	logging-data="72801"; mail-complaints-to="news-admin@muc.de"
X-Original-To: emulation@mlmmj.nyi.freebsd.org
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim;
	t=1792338596;
	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:
	 in-reply-to:in-reply-to:references:references;
	bh=eiVwTJYqmCKvGDZCRwS+iov5c6SoBXlZiBWnb5GKHiw=;
	b=ICmoREhCiL/vRh/AiqSOTwamrqG5eTl+7Y2BYR7LXuD8yTyqDbeMsRaUV2VyaA0Rb//QqF
	vT5FkH0vkILFDeXMh19657uYcXRusKzS/4yRejf0LQn+KZIn4SxIeKBOp2JitYrL6HAFpu
	Q36A3HYoT5WGGBGkC0xVOfEb228a7yTenTYnyOV4kbAu/l7bJyeAkhb1VNe+r1L868Lr0Z
	GIn96PcK+isdy9Oip6aEEHpJDIOdMM25AGP1hLLp7novroB5KRTH4j/hJuHi/QAMCZFutB
	e90LCaM0RXIPUB4aTidvuScvfcm8yMuPtGO8Kxb4PTnQoaxzghcOJuh/6e5KXw==
X-Authentication-Warning: kenobi.freebsd.org: bugzilla set sender to bugzilla-noreply@freebsd.org using -f
In-Reply-To: <bug-297426-4077@https.bugs.freebsd.org/bugzilla/>
Auto-Submitted: auto-generated
Precedence: list
X-Newsgate-Id: f02c70b8849f+
X-No-Archive: Yes