Skip to content

Commit

Permalink
Fix the redundant scheduler issue.
Browse files Browse the repository at this point in the history
Previously redsched_correct_skb_pointers set red_p->skb = NULL when red_p->skb_start_seq == meta_tp->snd_una.
This issue causes the redundant scheduler keep sending reinjected packets.
Replace !after with before in line 192.

Closes: multipath-tcp#474
Fixes: 7835e78 ("mptcp: Fix use-after-free in the redundant scheduler")
Signed-off-by: ytxing <[email protected]>
  • Loading branch information
ytxing authored Apr 21, 2022
1 parent 7d37219 commit f71edfb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/mptcp/mptcp_redundant.c
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ static void redsched_correct_skb_pointers(struct sock *meta_sk,
struct tcp_sock *meta_tp = tcp_sk(meta_sk);

if (red_p->skb &&
(!after(red_p->skb_start_seq, meta_tp->snd_una) ||
(before(red_p->skb_start_seq, meta_tp->snd_una) ||
after(red_p->skb_end_seq, meta_tp->snd_nxt)))
red_p->skb = NULL;
}
Expand Down

0 comments on commit f71edfb

Please sign in to comment.