diff options
| author | Stefan Baranoff <[email protected]> | 2018-07-10 21:25:20 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2018-07-12 21:33:45 +0000 |
| commit | 21684dc46c598e477707487c009f9773f7c0382d (patch) | |
| tree | e32dc7d79947a09fc058069de742ea476db4cc83 /net/nsh/nsh.c | |
| parent | sch_fq_codel: zero q->flows_cnt when fq_codel_init fails (diff) | |
| download | kernel-21684dc46c598e477707487c009f9773f7c0382d.tar.gz kernel-21684dc46c598e477707487c009f9773f7c0382d.zip | |
tcp: fix sequence numbers for repaired sockets re-using TIME-WAIT sockets
This patch fixes a bug where the sequence numbers of a socket created using
TCP repair functionality are lower than set after connect is called.
This occurs when the repair socket overlaps with a TIME-WAIT socket and
triggers the re-use code. The amount lower is equal to the number of times
that a particular IP/port set is re-used and then put back into TIME-WAIT.
Re-using the first time the sequence number is 1 lower, closing that socket
and then re-opening (with repair) a new socket with the same addresses/ports
puts the sequence number 2 lower than set via setsockopt. The third time is
3 lower, etc. I have not tested what the limit of this acrewal is, if any.
The fix is, if a socket is in repair mode, to respect the already set
sequence number and timestamp when it would have already re-used the
TIME-WAIT socket.
Signed-off-by: Stefan Baranoff <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/nsh/nsh.c')
0 files changed, 0 insertions, 0 deletions
