frr icon indicating copy to clipboard operation
frr copied to clipboard

pimd: fix crash when mixing ssm/any-source joins

Open Jafaral opened this issue 1 year ago • 4 comments

Fixes: #15630

There is no reason to call igmp_anysource_forward_stop() inside a call to igmp_get_source_by_addr(). The decision to start/stop forwarding is already handled correctly by pim outside igmp_get_source_by_addr(). That call was left there from the days pim was initially imported in.

The problem was happening because igmp_find_source_by_addr() would fail to find the group/source combo when mixing (*, G) and (S, G), so a new entry is correctly created, but igmp_anysource_forward_stop(group) always stops (and eventually frees) (*, G) , but leaving a bad state because the new entry for (S, G) shouldn't have caused (*, G) to go away.

Tested the fix with multiple receivers on the same interface with several ssm and any source senders and receivers with various combination of start/stop orders and they all worked correctly.

Jafaral avatar May 30 '24 17:05 Jafaral

@mergifyio backport stable/8.4 stable/8.5 stable/9.0 stable/9.1 stable/10.0

Jafaral avatar May 30 '24 17:05 Jafaral

backport stable/8.4 stable/8.5 stable/9.0 stable/9.1 stable/10.0

✅ Backports have been created

mergify[bot] avatar May 30 '24 17:05 mergify[bot]

please put the summary above into the commit directly. It will be lost otherwise

donaldsharp avatar May 31 '24 00:05 donaldsharp

please put the summary above into the commit directly. It will be lost otherwise

I knew you were going to say that! 😁 . Done!

Jafaral avatar May 31 '24 04:05 Jafaral