smoltcp
smoltcp copied to clipboard
Incomplete TCP Handshake/Teardown Handling
When a TCP connection experiences an incomplete handshake or teardown (FIN) packet reception, the protocol stack remains in the connected state and continues to send FIN+ACK packets. The mainstream approach is if a TCP connection does not receive a complete handshake or teardown sequence, it should transition to a closed state after sending a specified number of probe packets. Currently, smoltcp maintains the connection state and sends FIN+ACK packets indefinitely, which can lead to resource leaks and unexpected behavior in applications relying on proper TCP state management.
You have to configure a timeout in the socket for it to timeout.