[openssl-commits] [openssl] master update
kaduk at mit.edu
kaduk at mit.edu
Wed Jun 28 19:57:00 UTC 2017
The branch master has been updated
via eed3ec90478af1e1fd3a2733293c751d2181f7f7 (commit)
from 3668721d3af2648aaa4c443b9d7a5b0e4bdd200f (commit)
- Log -----------------------------------------------------------------
commit eed3ec90478af1e1fd3a2733293c751d2181f7f7
Author: Todd Short <tshort at akamai.com>
Date: Mon Jun 26 09:21:20 2017 -0400
ssl_session_dup() missing ext.alpn_session
Properly copy ext.alpn_session in ssl_session_dup()
Use OPENSSL_strndup() as that's used in ssl_asn1.c
Reviewed-by: Matt Caswell <matt at openssl.org>
Reviewed-by: Ben Kaduk <kaduk at mit.edu>
(Merged from https://github.com/openssl/openssl/pull/3770)
-----------------------------------------------------------------------
Summary of changes:
ssl/ssl_sess.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/ssl/ssl_sess.c b/ssl/ssl_sess.c
index df992bd..e7fe714 100644
--- a/ssl/ssl_sess.c
+++ b/ssl/ssl_sess.c
@@ -122,6 +122,7 @@ SSL_SESSION *ssl_session_dup(SSL_SESSION *src, int ticket)
dest->ext.supportedgroups = NULL;
#endif
dest->ext.tick = NULL;
+ dest->ext.alpn_selected = NULL;
#ifndef OPENSSL_NO_SRP
dest->srp_username = NULL;
#endif
@@ -212,6 +213,15 @@ SSL_SESSION *ssl_session_dup(SSL_SESSION *src, int ticket)
dest->ext.ticklen = 0;
}
+ if (src->ext.alpn_selected) {
+ dest->ext.alpn_selected =
+ (unsigned char*)OPENSSL_strndup((char*)src->ext.alpn_selected,
+ src->ext.alpn_selected_len);
+ if (dest->ext.alpn_selected == NULL) {
+ goto err;
+ }
+ }
+
#ifndef OPENSSL_NO_SRP
if (src->srp_username) {
dest->srp_username = OPENSSL_strdup(src->srp_username);
More information about the openssl-commits
mailing list