Prepare for checking incoming handshake seqnum

This commit is contained in:
Manuel Pégourié-Gonnard 2014-09-02 18:30:26 +02:00 committed by Paul Bakker
parent 0c4cbc7895
commit d9ba0d96b6
3 changed files with 10 additions and 6 deletions

View file

@ -1292,7 +1292,10 @@ static int ssl_parse_client_hello( ssl_context *ssl )
* Copy the client's handshake message_seq on initial handshakes
*/
if( ssl->renegotiation == SSL_INITIAL_HANDSHAKE )
ssl->handshake->msg_seq = ( ssl->in_msg[4] << 8 ) | ssl->in_msg[5];
{
ssl->handshake->out_msg_seq = ( ssl->in_msg[4] << 8 ) |
ssl->in_msg[5];
}
// TODO: DTLS: check message_seq on non-initial handshakes?
// (or already done in ssl_read_record?)