> - Let's allow kernel to expire CLOSE-WAIT if the application didn't send anything for more than 60 seconds.
No, that's not sane either. If the application wants to expire the CLOSE_WAIT socket, it can close it; at which point, a FIN will be sent, the state will go to LAST_ACK, while waiting for the peer to ACK the FIN, at which point the socket is totally done. It violates the RFC, but is perfectly reasonable for LAST_ACK to have a timeout if the other peer is non-responsive, as the alternative is sockets living forever when the peer goes away (same with FIN_WAIT's).
> - Let's allow kernel to expire CLOSE-WAIT if the application didn't send anything for more than 60 seconds.
No, that's not sane either. If the application wants to expire the CLOSE_WAIT socket, it can close it; at which point, a FIN will be sent, the state will go to LAST_ACK, while waiting for the peer to ACK the FIN, at which point the socket is totally done. It violates the RFC, but is perfectly reasonable for LAST_ACK to have a timeout if the other peer is non-responsive, as the alternative is sockets living forever when the peer goes away (same with FIN_WAIT's).