[FFmpeg-devel] [PATCH v2] avformat: enable UDP IPv6 multicast interface selection

Ignjatović, Lazar (RS) Lazar.Ignjatovic at cubic.com
Wed Mar 20 14:35:28 EET 2024


This message has been marked as Public on 03/20/2024 12:35Z.
On Wednesday, March 20, 2024 1:18 PM Rémi Denis-Courmont wrote:

>> In all other cases, determining the interface ID by address should be
>> ok,
>
> No! The only other case is non-LL addressing, which does not require link ID at all.

For IPv4 that is certainly true, but it differs for v6. Specifying egress interface is done by setting the setsockopt(IPV6_MULTICAST_IF) to the value of the interface, not address. On the other hand v4 for the similar option setsockopt(IP_MULTICAST_IF) sets it by definig an address (not interface). Without setting IPV6_MULTICAST_IF to the appropriate interface, default interface is chosen. We want to have control over this, and I cant se how this can be achieved without knowing the interface id.

For ingress IPv6 traffic, the way to filter on which interface is being listened on is by binding to a mcast addres, which has sin6_scope_id properly set.

Lazar Ignjatović
Associate Software Engineer

Cubic Defense
cubic.com


More information about the ffmpeg-devel mailing list