From 57723135b3108e070df1031d6fb38535ca7d5cca Mon Sep 17 00:00:00 2001 From: Hanno Becker Date: Sun, 1 Aug 2021 19:40:44 +0100 Subject: [PATCH] Document temporary overlap of TLS version in SSL context and session Signed-off-by: Hanno Becker --- include/mbedtls/ssl.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/mbedtls/ssl.h b/include/mbedtls/ssl.h index 4f6b448e9..26edecfda 100644 --- a/include/mbedtls/ssl.h +++ b/include/mbedtls/ssl.h @@ -927,6 +927,9 @@ struct mbedtls_ssl_session unsigned char exported; + /* This field is temporarily duplicated with mbedtls_ssl_context.minor_ver. + * Once runtime negotiation of TLS 1.2 and TLS 1.3 is implemented, it needs + * to be studied whether one of them can be removed. */ unsigned char MBEDTLS_PRIVATE(minor_ver); /*!< The TLS version used in the session. */ #if defined(MBEDTLS_X509_CRT_PARSE_C) @@ -1247,6 +1250,10 @@ struct mbedtls_ssl_context #endif /* MBEDTLS_SSL_RENEGOTIATION */ int MBEDTLS_PRIVATE(major_ver); /*!< equal to MBEDTLS_SSL_MAJOR_VERSION_3 */ + + /* This field is temporarily duplicated with mbedtls_ssl_context.minor_ver. + * Once runtime negotiation of TLS 1.2 and TLS 1.3 is implemented, it needs + * to be studied whether one of them can be removed. */ int MBEDTLS_PRIVATE(minor_ver); /*!< one of MBEDTLS_SSL_MINOR_VERSION_x macros */ unsigned MBEDTLS_PRIVATE(badmac_seen); /*!< records with a bad MAC received */