bridge: multicast: enable snooping on general queries only
authorLinus Lüssing <linus.luessing@web.de>
Mon, 10 Mar 2014 21:25:25 +0000 (22:25 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 14 Apr 2014 13:47:19 +0000 (06:47 -0700)
commita00acd077a49721fc399f89f4950c3dc597ef3d6
treee2fc584e3cd329b5fe08e84594b582570aa0833d
parent3bc6750d9d2f02fcf4b92408fdd624ad48c13491
bridge: multicast: enable snooping on general queries only

[ Upstream commit 20a599bec95a52fa72432b2376a2ce47c5bb68fb ]

Without this check someone could easily create a denial of service
by injecting multicast-specific queries to enable the bridge
snooping part if no real querier issuing periodic general queries
is present on the link which would result in the bridge wrongly
shutting down ports for multicast traffic as the bridge did not learn
about these listeners.

With this patch the snooping code is enabled upon receiving valid,
general queries only.

Signed-off-by: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/bridge/br_multicast.c