Revert "bridge: only expire the mdb entry when query is received"
Subsystems (3)
PATCH 1/1 Revert "bridge: only expire the mdb entry when query is received"
While this commit was a good attempt to fix issues occuring when no multicast querier is present, this commit still has two more issues:
1) There are cases where mdb entries do not expire even if there is a querier present. The bridge will unnecessarily continue flooding multicast packets on the according ports.
2) Never removing an mdb entry could be exploited for a Denial of Service by an attacker on the local link, slowly, but steadily eating up all memory.
Actually, this commit became obsolete with
"bridge: disable snooping if there is no querier" (b00589af3b) which included fixes for a few more cases.
Therefore reverting the following commits (the commit stated in the commit message plus three of its follow up fixes):
---
Revert "bridge: update mdb expiration timer upon reports." This reverts commit f144febd93d5ee534fdf23505ab091b2b9088edc. Revert "bridge: do not call setup_timer() multiple times" This reverts commit 1faabf2aab1fdaa1ace4e8c829d1b9cf7bfec2f1. Revert "bridge: fix some kernel warning in multicast timer" This reverts commit c7e8e8a8f7a70b343ca1e0f90a31e35ab2d16de1. Revert "bridge: only expire the mdb entry when query is received" This reverts commit 9f00b2e7cf241fa389733d41b615efdaa2cb0f5b.
---
--- net/bridge/br_mdb.c | 2 +- net/bridge/br_multicast.c | 47 ++++++++++++++++++++++++++------------------- net/bridge/br_private.h | 1 - 3 files changed, 28 insertions(+), 22 deletions(-)
net/bridge/br_mdb.c +1 -1
@@ -453,7 +453,7 @@ static int __br_mdb_del(struct net_bridge *br, struct br_mdb_entry *entry)call_rcu_bh (&p->rcu, br_multicast_free_pg); err =0 ; -if (!mp->ports && !mp->mglist && mp->timer_armed && +if (!mp->ports && !mp->mglist &&netif_running (br->dev))mod_timer (&mp->timer, jiffies);break ;
net/bridge/br_multicast.c +27 -20
124 lines not on this page · raw message
net/bridge/br_private.h +0 -1
@@ -126,7 +126,6 @@ struct net_bridge_mdb_entrystruct timer_list timer;struct br_ip addr;bool mglist; -bool timer_armed; };struct net_bridge_mdb_htable
Signature · 1 line
1.7.10.4
David Miller
maintainerFrom: Linus Lüssing <[email protected]>
Date: Sun, 20 Oct 2013 00:58:57 +0200
Quoted 18 lines
While this commit was a good attempt to fix issues occuring when no multicast querier is present, this commit still has two more issues:
1) There are cases where mdb entries do not expire even if there is a querier present. The bridge will unnecessarily continue flooding multicast packets on the according ports.
2) Never removing an mdb entry could be exploited for a Denial of Service by an attacker on the local link, slowly, but steadily eating up all memory.
Actually, this commit became obsolete with
"bridge: disable snooping if there is no querier" (b00589af3b) which included fixes for a few more cases.Therefore reverting the following commits (the commit stated in the commit message plus three of its follow up fixes):
Quoted 10 lines
---
Revert "bridge: update mdb expiration timer upon reports." This reverts commitf144febd93d5ee534fdf23505ab091b2b9088edc. Revert "bridge: do not callsetup_timer()multiple times" This reverts commit1faabf2aab1fdaa1ace4e8c829d1b9cf7bfec2f1. Revert "bridge: fix some kernel warning in multicast timer" This reverts commitc7e8e8a8f7a70b343ca1e0f90a31e35ab2d16de1. Revert "bridge: only expire the mdb entry when query is received" This reverts commit9f00b2e7cf241fa389733d41b615efdaa2cb0f5b.
---
Cong, and other bridge folks, please review this revert.
Thanks.
Vladislav Yasevich
Reviewed-byQuoted 32 lines · David Miller
From: Linus Lüssing <[email protected]>
Date: Sun, 20 Oct 2013 00:58:57 +0200Quoted 18 lines
While this commit was a good attempt to fix issues occuring when no multicast querier is present, this commit still has two more issues:
1) There are cases where mdb entries do not expire even if there is a querier present. The bridge will unnecessarily continue flooding multicast packets on the according ports.
2) Never removing an mdb entry could be exploited for a Denial of Service by an attacker on the local link, slowly, but steadily eating up all memory.
Actually, this commit became obsolete with
"bridge: disable snooping if there is no querier" (b00589af3b) which included fixes for a few more cases.Therefore reverting the following commits (the commit stated in the commit message plus three of its follow up fixes):
Quoted 10 lines
---
Revert "bridge: update mdb expiration timer upon reports." This reverts commitf144febd93d5ee534fdf23505ab091b2b9088edc. Revert "bridge: do not callsetup_timer()multiple times" This reverts commit1faabf2aab1fdaa1ace4e8c829d1b9cf7bfec2f1. Revert "bridge: fix some kernel warning in multicast timer" This reverts commitc7e8e8a8f7a70b343ca1e0f90a31e35ab2d16de1. Revert "bridge: only expire the mdb entry when query is received" This reverts commit9f00b2e7cf241fa389733d41b615efdaa2cb0f5b.
---
Quoted 2 lines
Cong, and other bridge folks, please review this revert.
Makes sense and make the implementation better follow the spec. Looks like the issues seen before are resolved by the revert.
Quoted 32 lines · David Miller
From: Linus Lüssing <[email protected]>
Date: Sun, 20 Oct 2013 00:58:57 +0200Quoted 18 lines
While this commit was a good attempt to fix issues occuring when no multicast querier is present, this commit still has two more issues:
1) There are cases where mdb entries do not expire even if there is a querier present. The bridge will unnecessarily continue flooding multicast packets on the according ports.
2) Never removing an mdb entry could be exploited for a Denial of Service by an attacker on the local link, slowly, but steadily eating up all memory.
Actually, this commit became obsolete with
"bridge: disable snooping if there is no querier" (b00589af3b) which included fixes for a few more cases.Therefore reverting the following commits (the commit stated in the commit message plus three of its follow up fixes):
Quoted 10 lines
---
Revert "bridge: update mdb expiration timer upon reports." This reverts commitf144febd93d5ee534fdf23505ab091b2b9088edc. Revert "bridge: do not callsetup_timer()multiple times" This reverts commit1faabf2aab1fdaa1ace4e8c829d1b9cf7bfec2f1. Revert "bridge: fix some kernel warning in multicast timer" This reverts commitc7e8e8a8f7a70b343ca1e0f90a31e35ab2d16de1. Revert "bridge: only expire the mdb entry when query is received" This reverts commit9f00b2e7cf241fa389733d41b615efdaa2cb0f5b.
---
Quoted 2 lines
Cong, and other bridge folks, please review this revert.
t http://vger.kernel.org/majordomo-info.html
Quoted 1 line
Makes sense and make the implementation better follow the spec. Looks like the issues seen before are resolved by the revert.
-vlad
Quoted 11 lines · Linus Lüssing
While this commit was a good attempt to fix issues occuring when no multicast querier is present, this commit still has two more issues:
1) There are cases where mdb entries do not expire even if there is a querier present. The bridge will unnecessarily continue flooding multicast packets on the according ports.
2) Never removing an mdb entry could be exploited for a Denial of Service by an attacker on the local link, slowly, but steadily eating up all memory.
I raised the first issue too when I sent the patch, but Herbert said it is not a problem. So, I will leave this to Herbert to decide.
For me, your patch makes sense.
Thanks.
From: Linus Lüssing <[email protected]>
Date: Sun, 20 Oct 2013 00:58:57 +0200
Quoted 29 lines
While this commit was a good attempt to fix issues occuring when no multicast querier is present, this commit still has two more issues:
1) There are cases where mdb entries do not expire even if there is a querier present. The bridge will unnecessarily continue flooding multicast packets on the according ports.
2) Never removing an mdb entry could be exploited for a Denial of Service by an attacker on the local link, slowly, but steadily eating up all memory.
Actually, this commit became obsolete with
"bridge: disable snooping if there is no querier" (b00589af3b) which included fixes for a few more cases.Therefore reverting the following commits (the commit stated in the commit message plus three of its follow up fixes):
---
Revert "bridge: update mdb expiration timer upon reports." This reverts commitf144febd93d5ee534fdf23505ab091b2b9088edc. Revert "bridge: do not callsetup_timer()multiple times" This reverts commit1faabf2aab1fdaa1ace4e8c829d1b9cf7bfec2f1. Revert "bridge: fix some kernel warning in multicast timer" This reverts commitc7e8e8a8f7a70b343ca1e0f90a31e35ab2d16de1. Revert "bridge: only expire the mdb entry when query is received" This reverts commit9f00b2e7cf241fa389733d41b615efdaa2cb0f5b.
---
Quoted 2 lines
CC Cong Wang <[email protected]>Signed-off-by Linus Lüssing <[email protected]>
Applied, thanks a lot.