OpenCloudOS-Kernel/net/mptcp
Geliang Tang 5bc56388c7 mptcp: add port number check for MP_JOIN
This patch adds two new helpers, subflow_use_different_sport and
subflow_use_different_dport, to check whether the subflow's source or
destination port number is different from the msk's port number. When
receiving the MP_JOIN's SYN/SYNACK/ACK, we do these port number checks
and print out the different port numbers.

And furthermore, when receiving the MP_JOIN's SYN/ACK, we also use a new
helper mptcp_pm_sport_in_anno_list to check whether this port number is
announced. If it isn't, we need to abort this connection.

This patch also populates the local address's port field in
local_address.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2021-02-02 18:37:19 -08:00
..
Kconfig mptcp: depends on IPV6 but not as a module 2020-10-21 08:05:40 -07:00
Makefile mptcp: enable JOIN requests even if cookies are in use 2020-07-31 16:55:32 -07:00
crypto.c crypto: sha - split sha.h into sha1.h and sha2.h 2020-11-20 14:45:33 +11:00
crypto_test.c mptcp: move crypto test to KUNIT 2020-06-26 16:21:39 -07:00
ctrl.c mptcp: add a new sysctl add_addr_timeout 2020-11-04 17:45:53 -08:00
diag.c mptcp: allow dumping subflow context to userspace 2020-03-29 22:14:48 -07:00
mib.c mptcp: add the mibs for MP_PRIO 2021-01-09 18:18:44 -08:00
mib.h mptcp: add the mibs for MP_PRIO 2021-01-09 18:18:44 -08:00
mptcp_diag.c mptcp: drop *_max fields in mptcp_pm_data 2021-02-02 18:37:18 -08:00
options.c mptcp: fix length of MP_PRIO suboption 2021-02-02 17:34:02 -08:00
pm.c mptcp: send ack for every add_addr 2021-02-02 18:37:18 -08:00
pm_netlink.c mptcp: add port number check for MP_JOIN 2021-02-02 18:37:19 -08:00
protocol.c mptcp: create the listening socket for new port 2021-02-02 18:37:19 -08:00
protocol.h mptcp: add port number check for MP_JOIN 2021-02-02 18:37:19 -08:00
subflow.c mptcp: add port number check for MP_JOIN 2021-02-02 18:37:19 -08:00
syncookies.c mptcp: fix syncookie build error on UP 2020-08-01 11:52:55 -07:00
token.c mptcp: token: fix unititialized variable 2020-11-03 13:08:30 -08:00
token_test.c mptcp: introduce token KUNIT self-tests 2020-06-26 16:21:39 -07:00