openssl/ssl
Matt Caswell 0647719d80 Make the checks for an SSLv2 style record stricter
SSLv2 is no longer supported in 1.1.0, however we *do* still accept an SSLv2
style ClientHello, as long as we then subsequently negotiate a protocol
version >= SSLv3. The record format for SSLv2 style ClientHellos is quite
different to SSLv3+. We only accept this format in the first record of an
initial ClientHello. Previously we checked this by confirming
s->first_packet is set and s->server is true. However, this really only
tells us that we are dealing with an initial ClientHello, not that it is
the first record (s->first_packet is badly named...it really means this is
the first message). To check this is the first record of the initial
ClientHello we should also check that we've not received any data yet
(s->init_num == 0), and that we've not had any empty records.

GitHub Issue #1298

Reviewed-by: Emilia Käsper <emilia@openssl.org>
2016-07-29 12:42:40 +01:00
..
record Make the checks for an SSLv2 style record stricter 2016-07-29 12:42:40 +01:00
statem zero pad DHE public key in ServerKeyExchange message for interop 2016-07-25 13:41:33 -04:00
bio_ssl.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
build.info Update build.info files for auto-init/de-init 2016-02-09 15:11:38 +00:00
d1_lib.c Fix a few if(, for(, while( inside code. 2016-07-20 07:21:53 -04:00
d1_msg.c Whitespace cleanup in ssl folder 2016-06-29 09:56:39 -04:00
d1_srtp.c Add checks on sk_TYPE_push() returned result 2016-06-23 14:03:29 +01:00
methods.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
packet_locl.h Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
pqueue.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
s3_cbc.c check return values for EVP_Digest*() APIs 2016-07-15 14:09:05 +01:00
s3_enc.c check return values for EVP_Digest*() APIs 2016-07-15 14:09:05 +01:00
s3_lib.c Sanity check in ssl_get_algorithm2(). 2016-07-20 00:09:46 +01:00
s3_msg.c Always use session_ctx when removing a session 2016-06-08 15:22:41 +01:00
ssl_asn1.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
ssl_cert.c Change all our uses of CRYPTO_THREAD_run_once to use RUN_ONCE instead 2016-07-19 23:49:54 +02:00
ssl_ciph.c Have load_buildtin_compression in ssl/ssl_ciph.c return RUN_ONCE result 2016-07-22 11:56:45 +02:00
ssl_conf.c Spelling... and more spelling 2016-06-22 00:26:10 +02:00
ssl_err.c Check for errors allocating the error strings. 2016-07-20 19:20:53 +02:00
ssl_init.c Change all our uses of CRYPTO_THREAD_run_once to use RUN_ONCE instead 2016-07-19 23:49:54 +02:00
ssl_lib.c Never expose ssl->bbio in the public API. 2016-07-20 13:08:08 +01:00
ssl_locl.h Fix two bugs in clienthello processing 2016-07-19 14:18:03 +02:00
ssl_mcnf.c Whitespace cleanup in ssl folder 2016-06-29 09:56:39 -04:00
ssl_rsa.c fix memory leaks 2016-07-16 12:32:34 -04:00
ssl_sess.c Fix a few if(, for(, while( inside code. 2016-07-20 07:21:53 -04:00
ssl_stat.c SSL test framework: port NPN and ALPN tests 2016-07-19 14:17:48 +02:00
ssl_txt.c Enforce and explicit some const casting 2016-07-25 08:20:00 -04:00
ssl_utst.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
t1_enc.c Spelling... and more spelling 2016-06-22 00:26:10 +02:00
t1_ext.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
t1_lib.c Fix two bugs in clienthello processing 2016-07-19 14:18:03 +02:00
t1_reneg.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00
t1_trce.c Enforce and explicit some const casting 2016-07-25 08:20:00 -04:00
tls_srp.c Copyright consolidation 01/10 2016-05-17 14:19:19 -04:00