diff options
| author | Florian Westphal <[email protected]> | 2020-04-29 18:43:20 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2020-04-29 19:39:49 +0000 |
| commit | 42c556fef92361bbc58be22f91b1c49db0963c34 (patch) | |
| tree | e077ddcb5cadbe3ed663100a8a0bd2c2060f72a6 /net/ipv4/tcp_input.c | |
| parent | net: dsa: mv88e6xxx: remove duplicate assignment of struct members (diff) | |
| download | kernel-42c556fef92361bbc58be22f91b1c49db0963c34.tar.gz kernel-42c556fef92361bbc58be22f91b1c49db0963c34.zip | |
mptcp: replace mptcp_disconnect with a stub
Paolo points out that mptcp_disconnect is bogus:
"lock_sock(sk);
looks suspicious (lock should be already held by the caller)
And call to: tcp_disconnect(sk, flags); too, sk is not a tcp
socket".
->disconnect() gets called from e.g. inet_stream_connect when
one tries to disassociate a connected socket again (to re-connect
without closing the socket first).
MPTCP however uses mptcp_stream_connect, not inet_stream_connect,
for the mptcp-socket connect call.
inet_stream_connect only gets called indirectly, for the tcp socket,
so any ->disconnect() calls end up calling tcp_disconnect for that
tcp subflow sk.
This also explains why syzkaller has not yet reported a problem
here. So for now replace this with a stub that doesn't do anything.
Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/14
Acked-by: Paolo Abeni <[email protected]>
Signed-off-by: Florian Westphal <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/ipv4/tcp_input.c')
0 files changed, 0 insertions, 0 deletions
