in reply to Waiting for ACKs and FINs

Perhaps come at the problem from a different angle: rather than try and usurp the TCP stack, use Wireshark or the like to get timings directly from captured packets and then parse its output to get your report.

The cake is a lie.
The cake is a lie.
The cake is a lie.