batman-adv: mcast: don't send link-local multicast to mcast routers
authorLinus Lüssing <linus.luessing@c0d3.blue>
Sat, 1 Jan 2022 05:27:13 +0000 (06:27 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 11 Jan 2022 14:25:00 +0000 (15:25 +0100)
commit4c34d5fd8c96a088098c24b09f0f18dc17ee76ed
tree971f228487932dd3260e834272be100e24fda619
parentf403b5f96e9a153f00d1f3503b4e4dbb066601f8
batman-adv: mcast: don't send link-local multicast to mcast routers

commit 938f2e0b57ffe8a6df71e1e177b2978b1b33fe5e upstream.

The addition of routable multicast TX handling introduced a
bug/regression for packets with a link-local multicast destination:
These packets would be sent to all batman-adv nodes with a multicast
router and to all batman-adv nodes with an old version without multicast
router detection.

This even disregards the batman-adv multicast fanout setting, which can
potentially lead to an unwanted, high number of unicast transmissions or
even congestion.

Fixing this by avoiding to send link-local multicast packets to nodes in
the multicast router list.

Fixes: 11d458c1cb9b ("batman-adv: mcast: apply optimizations for routable packets, too")
Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/batman-adv/multicast.c
net/batman-adv/multicast.h
net/batman-adv/soft-interface.c