<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/tests/sys/netinet/ip6_mrouted.c, branch main</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=main</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2026-03-30T16:08:21Z</updated>
<entry>
<title>tests: Add some simple regression tests for ip_mroute</title>
<updated>2026-03-30T16:08:21Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-03-30T13:32:35Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=09e702ad40af0067017613070b42d72cbc2bec3a'/>
<id>urn:sha1:09e702ad40af0067017613070b42d72cbc2bec3a</id>
<content type='text'>
These use atf_python to create a number of hosts linked to a router.
The router runs pimd (for IPv4) or ip6_mrouter (simplistic IPv6
multicast router that I wrote since I couldn't find one in the ports
tree).  The vnet_host*_handler() methods are invoked in different VNET
jails connected to the router; they register the connected epair with a
multicast group and verify that they can send messages to each other.

The tests are synchronized by sending messages over a unix domain
socket.  The flow is something like:
1) test startup_method() is called, the unix socket is created,
2) the superclass creates jails and links them together using the
   declared topology,
3) we wait for all child jails to start up and send a message on the
   unix socket indicating that they are ready
4) we start the routing daemon in the main jail,
5) the test actually starts; starttest() kicks off the
   vnet_host*_handlers(), which mostly just verify that they can send
   messages to each other using multicast packets
6) once they finish running, they signal their completion, and
   waittest() returns once they're all done

There are two tests, repeated for v4 and v6.  One just exchanges packets
between two hosts, and the other has four hosts divided across two FIBs.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55244
</content>
</entry>
</feed>
