rename `ticket_creation` to `ticket_creation_time`
Signed-off-by: Jerry Yu <jerry.h.yu@arm.com>
diff --git a/library/ssl_ticket.c b/library/ssl_ticket.c
index 5fef4eb..0277bfa 100644
--- a/library/ssl_ticket.c
+++ b/library/ssl_ticket.c
@@ -498,7 +498,7 @@
#if defined(MBEDTLS_SSL_PROTO_TLS1_3)
if (session->tls_version == MBEDTLS_SSL_VERSION_TLS1_3) {
/* Check for expiration */
- mbedtls_ms_time_t ticket_age = mbedtls_ms_time() - session->ticket_creation;
+ mbedtls_ms_time_t ticket_age = mbedtls_ms_time() - session->ticket_creation_time;
mbedtls_ms_time_t ticket_lifetime = ctx->ticket_lifetime * 1000;
if (ticket_age < 0 || ticket_age > ticket_lifetime) {
diff --git a/library/ssl_tls.c b/library/ssl_tls.c
index d727636..42d1b86 100644
--- a/library/ssl_tls.c
+++ b/library/ssl_tls.c
@@ -2457,7 +2457,7 @@
* uint32 max_early_data_size;
* select ( endpoint ) {
* case client: ClientOnlyData;
- * case server: uint64 start_time;
+ * case server: uint64 ticket_creation_time_time;
* };
* } serialized_session_tls13;
*
@@ -2537,7 +2537,7 @@
#if defined(MBEDTLS_HAVE_TIME) && defined(MBEDTLS_SSL_SRV_C)
if (session->endpoint == MBEDTLS_SSL_IS_SERVER) {
- MBEDTLS_PUT_UINT64_BE((uint64_t) session->ticket_creation, p, 0);
+ MBEDTLS_PUT_UINT64_BE((uint64_t) session->ticket_creation_time, p, 0);
p += 8;
}
#endif /* MBEDTLS_HAVE_TIME */
@@ -2616,7 +2616,7 @@
if (end - p < 8) {
return MBEDTLS_ERR_SSL_BAD_INPUT_DATA;
}
- session->ticket_creation = MBEDTLS_GET_UINT64_BE(p, 0);
+ session->ticket_creation_time = MBEDTLS_GET_UINT64_BE(p, 0);
p += 8;
}
#endif /* MBEDTLS_HAVE_TIME */
diff --git a/library/ssl_tls13_server.c b/library/ssl_tls13_server.c
index 5c606e4..c9c0e1f 100644
--- a/library/ssl_tls13_server.c
+++ b/library/ssl_tls13_server.c
@@ -193,15 +193,15 @@
#if defined(MBEDTLS_HAVE_TIME)
now = mbedtls_ms_time();
- if (now < session->ticket_creation) {
+ if (now < session->ticket_creation_time) {
MBEDTLS_SSL_DEBUG_MSG(
3, ("Invalid ticket start time ( now = %" MBEDTLS_PRINTF_MS_TIME
", start = %" MBEDTLS_PRINTF_MS_TIME " )",
- now, session->ticket_creation));
+ now, session->ticket_creation_time));
goto exit;
}
- server_age = now - session->ticket_creation;
+ server_age = now - session->ticket_creation_time;
/* RFC 8446 section 4.6.1
*
@@ -2878,7 +2878,7 @@
MBEDTLS_SSL_DEBUG_MSG(2, ("=> prepare NewSessionTicket msg"));
#if defined(MBEDTLS_HAVE_TIME)
- session->ticket_creation = mbedtls_ms_time();
+ session->ticket_creation_time = mbedtls_ms_time();
#endif
/* Set ticket_flags depends on the advertised psk key exchange mode */