mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2026-01-06 11:41:12 +03:00
Also compiles / runs without time-based functions in OS
Can now run without need of time() / localtime() and gettimeofday()
This commit is contained in:
@@ -46,7 +46,9 @@ typedef struct _ssl_cache_entry ssl_cache_entry;
|
||||
*/
|
||||
struct _ssl_cache_entry
|
||||
{
|
||||
#if defined(POLARSSL_HAVE_TIME)
|
||||
time_t timestamp; /*!< entry timestamp */
|
||||
#endif
|
||||
ssl_session session; /*!< entry session */
|
||||
#if defined(POLARSSL_X509_PARSE_C)
|
||||
x509_buf peer_cert; /*!< entry peer_cert */
|
||||
@@ -87,6 +89,7 @@ int ssl_cache_get( void *data, ssl_session *session );
|
||||
*/
|
||||
int ssl_cache_set( void *data, const ssl_session *session );
|
||||
|
||||
#if defined(POLARSSL_HAVE_TIME)
|
||||
/**
|
||||
* \brief Set the cache timeout
|
||||
* (Default: SSL_CACHE_DEFAULT_TIMEOUT (1 day))
|
||||
@@ -97,6 +100,7 @@ int ssl_cache_set( void *data, const ssl_session *session );
|
||||
* \param timeout cache entry timeout
|
||||
*/
|
||||
void ssl_cache_set_timeout( ssl_cache_context *cache, int timeout );
|
||||
#endif /* POLARSSL_HAVE_TIME */
|
||||
|
||||
/**
|
||||
* \brief Set the cache timeout
|
||||
|
||||
Reference in New Issue
Block a user