linux/net/mptcp
Matthieu Baerts (NGI0) e212899b19 mptcp: fully established after ADD_ADDR echo on MPJ
commit d67c5649c1 upstream.

Before this patch, receiving an ADD_ADDR echo on the just connected
MP_JOIN subflow -- initiator side, after the MP_JOIN 3WHS -- was
resulting in an MP_RESET. That's because only ACKs with a DSS or
ADD_ADDRs without the echo bit were allowed.

Not allowing the ADD_ADDR echo after an MP_CAPABLE 3WHS makes sense, as
we are not supposed to send an ADD_ADDR before because it requires to be
in full established mode first. For the MP_JOIN 3WHS, that's different:
the ADD_ADDR can be sent on a previous subflow, and the ADD_ADDR echo
can be received on the recently created one. The other peer will already
be in fully established, so it is allowed to send that.

We can then relax the conditions here to accept the ADD_ADDR echo for
MPJ subflows.

Fixes: 67b12f792d ("mptcp: full fully established support after ADD_ADDR")
Cc: stable@vger.kernel.org
Reviewed-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Link: https://patch.msgid.link/20240731-upstream-net-20240731-mptcp-endp-subflow-signal-v1-1-c8a9b036493b@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
[ Conflicts in options.c, because the context has changed in commit
  b3ea6b272d ("mptcp: consolidate initial ack seq generation"), which
  is not in this version. This commit is unrelated to this
  modification. ]
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-08-19 06:00:06 +02:00
..
bpf.c bpf: Add bpf_skc_to_mptcp_sock_proto 2022-05-20 15:29:00 -07:00
crypto_test.c mptcp: move crypto test to KUNIT 2020-06-26 16:21:39 -07:00
crypto.c kunit: mptcp: adhere to KUNIT formatting standard 2021-04-16 17:10:40 -07:00
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: mib: count MPJ with backup flag 2024-08-14 13:53:00 +02:00
mib.h mptcp: mib: count MPJ with backup flag 2024-08-14 13:53:00 +02:00
mptcp_diag.c tcp: Access &tcp_hashinfo via net. 2022-09-20 10:21:49 -07:00
options.c mptcp: fully established after ADD_ADDR echo on MPJ 2024-08-19 06:00:06 +02:00
pm_netlink.c mptcp: pm: do not ignore 'subflow' if 'signal' flag is also set 2024-08-19 06:00:02 +02:00
pm_userspace.c mptcp: pass addr to mptcp_pm_alloc_anno_list 2024-08-19 06:00:02 +02:00
pm.c mptcp: pm: fix backup support in signal endpoints 2024-08-14 13:53:01 +02:00
protocol.c mptcp: fix bad RCVPRUNED mib accounting 2024-08-11 12:36:02 +02:00
protocol.h mptcp: pass addr to mptcp_pm_alloc_anno_list 2024-08-19 06:00:02 +02:00
sockopt.c mptcp: fix full TCP keep-alive support 2024-06-16 13:41:32 +02:00
subflow.c mptcp: pm: fix backup support in signal endpoints 2024-08-14 13:53:01 +02:00
syncookies.c mptcp: don't return sockets in foreign netns 2021-09-24 10:51:36 +01:00
token_test.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