Page MenuHomeFreeBSD

tcp: fix simultaneous open and refine e80062a2d43
ClosedPublic

Authored by glebius on Sep 21 2022, 3:24 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Sep 27, 5:40 PM
Unknown Object (File)
Sat, Sep 21, 10:18 AM
Unknown Object (File)
Sat, Sep 21, 9:14 AM
Unknown Object (File)
Sun, Sep 8, 7:01 PM
Unknown Object (File)
Sun, Sep 8, 10:39 AM
Unknown Object (File)
Sat, Sep 7, 9:32 PM
Unknown Object (File)
Aug 18 2024, 12:52 AM
Unknown Object (File)
Aug 17 2024, 8:08 AM
Subscribers

Details

Summary
  • The soisconnected() call on transition from SYN_RCVD to ESTABLISHED is also necessary for a half-synchronized connection. Fix that just setting the flag, when we transfer SYN-SENT -> SYN-RECEIVED.
  • Provide a comment that explains at what conditions the call to soisconnected() is necessary.
  • Hence mechanically rename the TF_INCQUEUE flag to TF_SONOTCONN.
  • Extend the change to the BBR and RACK stacks.

Note: the interaction between the accept_filter(9) and the socket layer
is not fully consistent, yet. For most accept filters this call to
soisconnected() will not move the connection from the incomplete queue
to the complete. The move would happen only when the filter has received
the desired data, and soisconnected() would be called once again from
sorwakeup(). Ideally, we should mark socket as connected only there,
and leave the soisconnected() from SYN_RCVD->ESTABLISHED only for the
simultaneous open case. However, this doesn't yet work.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable