summaryrefslogtreecommitdiffstats
path: root/crypto
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2017-03-13 10:30:49 +0000
committerMatt Caswell <matt@openssl.org>2017-03-13 13:08:01 +0000
commit7321d7944e56e3cf7f5cf80679e6c88a130167f2 (patch)
tree9a2b2340c2deeaced125647ae9dfbea69330f689 /crypto
parentc4bfccfff85cea4dd16d701868e0efa9d80384cc (diff)
Fix DTLSv1_listen() sequence numbers
DTLSv1_listen() is stateless. We never increment the record read sequence while listening, and we reflect the incoming record's sequence number in our write sequence. The logic for doing the write sequence reflection was *after* we had finished processing the incoming ClientHello and before we write the ServerHello. In the normal course of events this is fine. However if we need to write an early alert during ClientHello processing (e.g. no shared cipher), then we haven't done the write sequence reflection yet. This means the alert gets written with the wrong sequence number (it will just be set to whatever value we left it in the last time we wrote something). If the sequence number is less than expected then the client will believe that the incoming alert is a retransmit and will therefore drop it, causing the client to hang waiting for a response from the server. Fixes #2886 Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/2915)
Diffstat (limited to 'crypto')
0 files changed, 0 insertions, 0 deletions