linux-stable/net/mptcp
Paolo Abeni 1e161339f5 mptcp: fix duplicate data handling
commit 68cc924729 upstream.

When a subflow receives and discards duplicate data, the mptcp
stack assumes that the consumed offset inside the current skb is
zero.

With multiple subflows receiving data simultaneously such assertion
does not held true. As a result the subflow-level copied_seq will
be incorrectly increased and later on the same subflow will observe
a bad mapping, leading to subflow reset.

Address the issue taking into account the skb consumed offset in
mptcp_subflow_discard_data().

Fixes: 04e4cd4f7c ("mptcp: cleanup mptcp_subflow_discard_data()")
Cc: stable@vger.kernel.org
Link: https://github.com/multipath-tcp/mptcp_net-next/issues/501
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Reviewed-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-08-11 12:36:02 +02:00
..
bpf.c bpf: Add bpf_skc_to_mptcp_sock_proto 2022-05-20 15:29:00 -07:00
crypto.c kunit: mptcp: adhere to KUNIT formatting standard 2021-04-16 17:10:40 -07:00
crypto_test.c
ctrl.c mptcp: Add a per-namespace sysctl to set the default path manager type 2022-04-29 17:25:14 -07:00
diag.c mptcp: fix possible deadlock in subflow diag 2024-03-06 14:45:12 +00:00
Kconfig kunit: mptcp: adhere to KUNIT formatting standard 2021-04-16 17:10:40 -07:00
Makefile Merge https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2022-05-23 16:07:14 -07:00
mib.c mptcp: add more offered MIBs counter 2022-05-05 19:00:16 -07:00
mib.h mptcp: add more offered MIBs counter 2022-05-05 19:00:16 -07:00
mptcp_diag.c tcp: Access &tcp_hashinfo via net. 2022-09-20 10:21:49 -07:00
options.c mptcp: distinguish rcv vs sent backup flag in requests 2024-08-11 12:36:01 +02:00
pm.c mptcp: update userspace pm infos 2023-06-14 11:15:27 +02:00
pm_netlink.c mptcp: pm: only set request_bkup flag when sending MP_PRIO 2024-08-11 12:36:02 +02:00
pm_userspace.c mptcp: map v4 address to v6 when destroying subflow 2024-03-06 14:45:11 +00:00
protocol.c mptcp: fix bad RCVPRUNED mib accounting 2024-08-11 12:36:02 +02:00
protocol.h mptcp: distinguish rcv vs sent backup flag in requests 2024-08-11 12:36:01 +02:00
sockopt.c mptcp: fix full TCP keep-alive support 2024-06-16 13:41:32 +02:00
subflow.c mptcp: fix duplicate data handling 2024-08-11 12:36:02 +02:00
syncookies.c mptcp: don't return sockets in foreign netns 2021-09-24 10:51:36 +01:00
token.c mptcp: full disconnect implementation 2022-01-07 11:27:06 +00:00
token_test.c mptcp: don't return sockets in foreign netns 2021-09-24 10:51:36 +01:00