buglwIP - A Lightweight TCP/IP stack - Bugs: bug #55590, Zero window probe breaks incoming...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #55590: Zero window probe breaks incoming TCP stream

Submitted by:  Puneet <puneetsharma>
Submitted on:  Mon 28 Jan 2019 02:00:00 PM UTC  
 
Category:  TCP Severity:  3 - Normal
Item Group:  Faulty Behaviour Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open Planned Release:  None
lwIP version:  git head

Sat 08 Feb 2020 12:49:46 PM UTC, comment #2: 

It's still valid! This has been a while, though. What I can add:

- The main reference here is Bug #49128, which contains more details about the issue I reported at the time;
- As the bug report shows, the problem was easily reproduced and very clear-cut, whereas the solution I came up with was.. not something I was fully confident about, and quite possibly incomplete or even wrong;
- When I looked into this, I noted down the following link with some background information, although I don't know how valuable it really is here:

  https://www.mail-archive.com/wireshark-dev@wireshark.org/msg03801.html

- Using zero-length zero window probes is probably a much better idea, but will obviously also require an even better look at the current code;
- I don't really see how wireshark would draw the "previous segment not captured" conclusion though, seeing as the byte was in fact sent, or am I reading that wrong?

David van Moolenbroek <dcvmoole>
Tue 04 Feb 2020 09:04:34 PM UTC, comment #1: 

Hmm, I can' tell why we're using 1 byte probes. But looking at commit 9ba9dee2, I can also not understand it.

So what we'd need is a unit test proving either this bug or the one David tried to fix at that time.

I've added David to CC (if that address is still valid).

Simon Goldschmidt <goldsimon>
Project Administrator
Mon 28 Jan 2019 02:00:00 PM UTC, original submission:  

<h3>
In tcp_zero_window_probe, below patch updates snd_nxt without updating  pcb->unacked list.</font>
Change introduced in commit : 9ba9dee2aa809624eda0e96c96abd8abff29539e

Due to this change, if lwIP receives any data from peer while lwIP is performing Zero Window probe, lwIP ACKs with sequence = snd_nxt +1 and while len=0.

I see there is difference between Zero window probe implementation of lwIP and linux.
Linux doesn't send any data in zero window probe.
While lwIP sends 1 byte of data in zero window probe. Even though lwIP sends 1 byte in zero window probe,it doesn't split unsent segment after window update has been received.

118 16.312644000 192.168.0.3 192.168.0.2 TCP 1514 [TCP Window Full] 5249\u219244878 [ACK] Seq=94463 Ack=1 Win=59392 Len=1460
119 16.351201000 192.168.0.2 192.168.0.3 TCP 54 [TCP ZeroWindow] 44878\u21925249 [ACK] Seq=1 Ack=95923 Win=0 Len=0
120 17.083572000 192.168.0.3 192.168.0.2 TCP 55 [TCP ZeroWindowProbe] 5249\u219244878 [ACK] Seq=95923 Ack=1 Win=59392 Len=1
121 17.083614000 192.168.0.2 192.168.0.3 TCP 54 [TCP ZeroWindowProbeAck] [TCP ZeroWindow] 44878\u21925249 [ACK] Seq=1 Ack=95923 Win=0 Len=0
122 17.266698000 192.168.0.2 192.168.0.3 TCP 254 [TCP ZeroWindow] 44878\u21925249 [PSH, ACK] Seq=1 Ack=95923 Win=0 Len=200
<font color="red">
123 17.335240000 192.168.0.3 192.168.0.2 TCP 54 [TCP Previous segment not captured] 5249\u219244878 [ACK] Seq=95924 Ack=201 Win=59136 Len=0
</font>
124 17.335293000 192.168.0.2 192.168.0.3 TCP 54 [TCP ZeroWindow] 44878\u21925249 [ACK] Seq=201 Ack=95923 Win=0 Len=0
125 17.467214000 192.168.0.2 192.168.0.3 TCP 254 [TCP ZeroWindow] 44878\u21925249 [PSH, ACK] Seq=201 Ack=95923 Win=0 Len=200
126 17.587074000 192.168.0.3 192.168.0.2 TCP 54 5249\u219244878 [ACK] Seq=95924 Ack=401 Win=58880 Len=0

</h3>

Puneet <puneetsharma>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by dcvmoole (Posted a comment)
  • -email is unavailable- added by goldsimon (Posted a comment)
  • -email is unavailable- added by goldsimon
  • -email is unavailable- added by puneetsharma (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-02-04 goldsimon Carbon-Copy- => Added david van moolenbroek <david@minix3.org>

    Back to the top


    Powered by Savane 3.5