openssl/openssl — pull request #66 by peterdettman (2014-04-14 04:16:27+00:00)
Title: Remove the random data from the heartbeat payload.

While the padding is mandated to include at least 16 bytes of random data, the inclusion of another 16 bytes in the payload is gratuitous, and indeed suspect in the light of DUAL_EC/Extended-Random considerations, the moreso as openssl has been enabling heartbeats during the handshake.

Furthermore, the response processor was failing to validate that the random payload data in the response matches that in the request. Removing it entirely makes this moot.

This change also gives a named constant to the minimum heartbeat padding size and validates that the constructed messages are of the expected length, plus some changes for consistency b/w the TLS/DTLS versions.