🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: muc.lists.freebsd.bugs
Article #776

[Bug 301167] rtsock: routing-socket announcements reach classic jails that cannot read the same routes through the query paths

#776
From: bugzilla-noreply
Date: Fri, 27 Nov 2026 07:20
55 lines
4520 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=301167

--- Comment #2 from laamalif@proton.me ---
I built the fanout filter and booted it on 15.1-RELEASE-p7.
The tree was a pristine archive of releng/15.1 bb03631fe3b7.
sys/net/rtsock.c after the patch is sha256
21c16d04ba39c88c6e8d92cf96413a31fa2dbfe032f7c9b0e338efd112acd38e.
The kernel is sha256
d0f9c8842b86fee3352535b0d287e92222e04828c195249c59c555cbd5753f0e,
booted as /boot/kernel.rtsock86/kernel. Stock if_ena.ko loaded
from that directory. The patch also applies to main; I have not
booted it there, and I have not built it on 14.4.

A classic jail with ip4.addr=10.27.9.20 still has a one-entry
NET_RT_DUMP (dst 10.27.9.20). While it listened, and while a
host PF_ROUTE socket listened, the host ran route add/delete
-host 172.16.99.81 10.27.9.1 and ifconfig ena0 alias
172.16.99.90/32 before that address was on the jail's list.
The host socket received both. The jail received neither. Same
result as uid 65534.

After jail -m added 172.16.99.90 to the jail, ifconfig ena0
-alias and alias of that address produced RTM_DELADDR,
RTM_DELETE, RTM_NEWADDR, and RTM_ADD on the jail socket, root
and uid 65534. ifconfig lo0 mtu 16383 and back to 16384
produced two RTM_IFINFO messages on the jail socket and on the
host socket. SIOCSIFFLAGS does not call rt_ifmsg, so a promisc
toggle is not a test of that path. route -n get 10.27.9.20 in
the jail prints the host route. route -n get 1.2.3.4 returns
"route: route has not been found" and does not block.

RTM_IFINFO and RTM_IFANNOUNCE are delivered. NET_RT_IFLIST
already emits IFINFO for every interface, and SIOCGIFCONF
already returns every name. RTM_IEEE80211 and RTM_IPFWLOG are
dropped for a jailed_without_vnet socket. I did not generate
either of those, and I did not test a vnet jail or IPv6.

The patch also applies to current main b29084ae698f, to
stable/15, and to releng/14.4; I built and booted it on
15.1-RELEASE-p7 only. The lock order the fanout adds
(rtsock_mtx then the prison mtx via prison_if()) has no
reverse path in the source, but the booted kernel had no
WITNESS, so the order is source-checked and not
witness-tested.

The patch is rtsock-jail-filter.patch, sys/net/rtsock.c only.

-- 
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-301167-227-y2vqo3FW7K@https.bugs.freebsd.org/bugzilla/>
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!usenet.goja.nl.eu.org!3.eu.feeder.erje.net!feeder.erje.net!news2.arglkargh.de!news.karotte.org!news.muc.de!.POSTED.news.muc.de!not-for-mail
References: <bug-301167-227@https.bugs.freebsd.org/bugzilla/>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!usenet.goja.nl.eu.org!3.eu.feeder.erje.net!feeder.erje.net!news2.arglkargh.de!news.karotte.org!news.muc.de!.POSTED.news.muc.de!not-for-mail
From: bugzilla-noreply@freebsd.org
Newsgroups: muc.lists.freebsd.bugs
Subject: [Bug 301167] rtsock: routing-socket announcements reach classic
 jails that cannot read the same routes through the query paths
Date: Fri, 27 Nov 2026 07:20:33 +0000
Organization: Newsgate at muc.de e.V.
Approved: news-admin@muc.de
Distribution: world
Message-ID: <bug-301167-227-y2vqo3FW7K@https.bugs.freebsd.org/bugzilla/>
References: <bug-301167-227@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="10082"; mail-complaints-to="news-admin@muc.de"
X-Original-To: bugs@mlmmj.nyi.freebsd.org
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim;
	t=1795764033;
	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=LC9lshI5QrOPq00B6/Y6e2YHtUFEh7pYHFU+rl6NJWw=;
	b=pcHXegR/K8orBTW5MarPP4dG/g+PCed9xGH5OMcki/FiTXs2nSM84LqTlpG69ES9xHScoL
	iukW33nIMy5BPdEyhCWDb6ViXuo+fScdKlWF46NaUt01nVe8hB8vQz1s/2PiG3OzRnvrBV
	l8++x4Yed4eRVmFMVHhiArSEAlhiWEjBPrIA5j7urf8y8ijMW38aHzmkNZM5QNUdKcL0ZE
	0ZP/YWMw+mbcAkjW8+Pt2TkVJnFuKn5fY/MhgZrN7jQg5FrwA3GG3xjoEuj55u6VxjI3pE
	G2C/HYf/aiFpCiGG2OrYnJz5HXvXR7UWfyoNe7Lfo4w2HrKG+P2qaXxsiXAMaQ==
X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f
In-Reply-To: <bug-301167-227@https.bugs.freebsd.org/bugzilla/>
Auto-Submitted: auto-generated
Precedence: list
X-Newsgate-Id: f02c70b8849f+
X-No-Archive: Yes