Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clamp MSS to the MTU of the source only.
Currently, tinc clamps MSS to the minimum of the MTU of both the source and the destination of the packet containing the MSS option. This is slightly suboptimal, because both the MTU and the MSS can differ based on the direction of travel. For example, if the MTU from A to B is 1500, and the MTU from B to A is 1000, then tinc will clamp MSS in *both* directions to 960, despite the fact that A to B could use a 1460 MSS. RFC 793 defines the MSS option as follows: If this option is present, then it communicates the maximum receive segment size at the TCP which sends this segment. It follows that the MSS should be clamped to the MTU *to* the *sender* of the MSS segment. It should not be clamped to the MTU to the destination of the MSS segment.
- Loading branch information