Resolve DTLS cookie and version before session resumption.
authorDavid Benjamin <davidben@google.com>
Sun, 6 Mar 2016 05:19:59 +0000 (00:19 -0500)
committerKurt Roeckx <kurt@roeckx.be>
Sun, 27 Mar 2016 21:59:00 +0000 (23:59 +0200)
commit1ed6587154eaa45c21460177731bd03975af906e
treee1d93bbcaecf7398cdda315a95abd578f2ece196
parent71ccf961af181fcfceb8d155272b8e8f328a0919
Resolve DTLS cookie and version before session resumption.

Session resumption involves a version check, so version negotiation must
happen first. Currently, the DTLS implementation cannot do session
resumption in DTLS 1.0 because the ssl_version check always checks
against 1.2.

Switching the order also removes the need to fixup ssl_version in DTLS
version negotiation.

Signed-off-by: Kurt Roeckx <kurt@roeckx.be>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
RT: #4392, MR: #2452
ssl/statem/statem_srvr.c