Provide a default value for max_early_data
authorMatt Caswell <matt@openssl.org>
Thu, 23 Feb 2017 16:41:15 +0000 (16:41 +0000)
committerMatt Caswell <matt@openssl.org>
Thu, 2 Mar 2017 17:44:15 +0000 (17:44 +0000)
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2737)

ssl/ssl_lib.c

index 2f62f4b0e1bfa24854e54b1b1d5edc7d6e31d6ff..49b43543bc76fc5e05669cbaa339aab4bb03262b 100644 (file)
@@ -2772,6 +2772,12 @@ SSL_CTX *SSL_CTX_new(const SSL_METHOD *meth)
 
     ret->ext.status_type = TLSEXT_STATUSTYPE_nothing;
 
+    /*
+     * Default max early data is a fully loaded single record. Could be split
+     * across multiple records in practice
+     */
+    ret->max_early_data = SSL3_RT_MAX_PLAIN_LENGTH;
+
     return ret;
  err:
     SSLerr(SSL_F_SSL_CTX_NEW, ERR_R_MALLOC_FAILURE);