MLD(4)
π MLD π
okay bestie, welcome to the mld page β that's Multicast Listener Discovery Protocol, and no, it's not about finding your people at a party (though honestly? same energy). it's a real networking thing and it's lowkey iconic. let's get into it π¦
β¨ SYNOPSIS β¨
first things first, here's the vibe β you gotta pull in all these headers:
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/in_systm.h>
#include <netinet/ip6.h>
#include <netinet/icmp6.h>
#include <netinet6/mld6.h>
and then the little summoning ritual:
int
socket(AF_INET6, SOCK_RAW, IPPROTO_ICMPV6);
slay. that's it. that's the whole spell π
πΈ DESCRIPTION πΈ
so MLD is a control plane protocol β the backstage manager of the internet, fr fr β used by IPv6 hosts and routers to propagate multicast group membership information. basically: "hey, who's in this group? is anybody still listening? should we keep sending stuff?" that kinda thing.
ngl, normally you don't touch this protocol directly. it's not for you, bestie, it's for the kernel itself π β it hops in whenever user applications ask for multicast membership. that's the kernel's job, and it does it beautifully, no cap.
but wait β there's a plot twist. multicast routing protocol daemons may open a raw socket and directly interact with mld to receive membership reports. main character energy only π₯
as of FreeBSD 8.0, MLD version 2 is implemented. and bestie, this is a big deal because:
- it adds support for Source-Specific Multicast (SSM) β meaning applications can tell upstream multicast routers "um actually I only want streams from these particular sources, thanks" π
- and the retransmission of state-change reports adds some robustness to the protocol. resilient queen π
π SYSCTL VARIABLES π
these are the lil knobs and dials, the settings you can peek at and poke. one at a time, gorgeous:
net.inet6.mld.ifinfoβ an opaque read-only variable that exposes the per-link MLDv2 status toifmcstat(8). that's it. that's the whole job. it's giving mysterious, it's giving "I don't explain myself" β¨net.inet6.mld.gsrdelayβ this one specifies the time threshold, in seconds, for processing Group-and-Source Specific Queries (GSR). now listen, because this part matters: GSR query processing requires maintaining state on the host, which means it may cause memory to be allocated, and therefore it's a potential attack point for Denial-of-Service (DoS) π. so if more than one GSR query is received within this threshold, it gets dropped β to mitigate the potential for DoS. protective king π‘οΈnet.inet6.mld.v1enableβ if this variable is non-zero, then MLDv1 membership queries (and host reports) will be processed by this host, and backwards compatibility will be enabled until the v1'Older Version Querier Present'timer expires. this sysctl is normally enabled by default. so like, it's on unless you turn it off. respect the defaults bestie π«Ά
π SEE ALSO π
go read these next, they're all connected, iykyk:
π HISTORY π
the mld manual page appeared in FreeBSD 8.0. a legend was born π«
and that's the whole page, bestie!! πβ¨ you ate that. go forth and multicast responsibly π
signing off from the Debian side of things β this lil slice of manpage wisdom is dated April 8, 2013, and it lives under the name MLD(4) ππ
π¦ where this page comes from
- debian bookworm: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- debian trixie: freebsd-manpages 12.2-2 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu jammy: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu noble: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu questing: freebsd-manpages 12.2-2
- ubuntu resolute: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu stonking: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- Copyright (c) 2009 Bruce Simpson
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms