1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-29 11:41:15 +03:00

DTLS depends on TIMING_C for now

This commit is contained in:
Manuel Pégourié-Gonnard
2014-10-14 20:03:35 +02:00
committed by Paul Bakker
parent e698f59a25
commit 8e704f0f74
4 changed files with 15 additions and 17 deletions

View File

@ -223,8 +223,9 @@
#endif
#if defined(POLARSSL_SSL_PROTO_DTLS) && ( \
!defined(POLARSSL_SSL_PROTO_TLS1_1) && \
!defined(POLARSSL_SSL_PROTO_TLS1_2) )
( !defined(POLARSSL_SSL_PROTO_TLS1_1) && \
!defined(POLARSSL_SSL_PROTO_TLS1_2) ) || \
!defined(POLARSSL_TIMING_C) )
#error "POLARSSL_SSL_PROTO_DTLS defined, but not all prerequisites"
#endif

View File

@ -908,6 +908,11 @@
*
* Requires: POLARSSL_SSL_PROTO_TLS1_1
* or POLARSSL_SSL_PROTO_TLS1_2
* POLARSSL_TIMING_C
*
* \note Dependency on TIMING_C may be replaced by something more flexible
* (callbacks or abstraction layer in the next major version). Please contact
* us if you're having issues with this dependency.
*
* Comment this macro to disable support for DTLS
*/

View File

@ -76,7 +76,7 @@
#include "zlib.h"
#endif
#if defined(POLARSSL_TIMING_C)
#if defined(POLARSSL_SSL_PROTO_DTLS)
#include "timing.h"
#endif
@ -830,14 +830,11 @@ struct _ssl_context
ssl_transform *transform_negotiate; /*!< transform params in negotiation */
/*
* Timers (WIP)
* Timers
*/
#if defined(POLARSSL_TIMING_C)
struct hr_time time_info;
unsigned long time_limit;
#endif
#if defined(POLARSSL_SSL_PROTO_DTLS)
struct hr_time time_info; /*!< timer context */
unsigned long time_limit; /*!< limit for the running timer */
uint32_t hs_timeout_min; /*!< initial value of the handshake
retransmission timeout */
uint32_t hs_timeout_max; /*!< maximum value of the handshake