forked from wolfSSL/wolfssl
macro guard for redefinition warning
This commit is contained in:
@ -1555,10 +1555,12 @@ WOLFSSL_LOCAL int SetCipherList(WOLFSSL_CTX*, Suites*, const char* list);
|
|||||||
typedef unsigned int (*wc_psk_server_callback)(WOLFSSL*, const char*,
|
typedef unsigned int (*wc_psk_server_callback)(WOLFSSL*, const char*,
|
||||||
unsigned char*, unsigned int);
|
unsigned char*, unsigned int);
|
||||||
#endif /* PSK_TYPES_DEFINED */
|
#endif /* PSK_TYPES_DEFINED */
|
||||||
#ifdef WOLFSSL_DTLS
|
#if defined(WOLFSSL_DTLS) && defined(WOLFSSL_SESSION_EXPORT) && \
|
||||||
|
!defined(WOLFSSL_DTLS_EXPORT_TYPES)
|
||||||
typedef int (*wc_dtls_export)(WOLFSSL* ssl,
|
typedef int (*wc_dtls_export)(WOLFSSL* ssl,
|
||||||
unsigned char* exportBuffer, unsigned int sz, void* userCtx);
|
unsigned char* exportBuffer, unsigned int sz, void* userCtx);
|
||||||
#endif
|
#define WOLFSSL_DTLS_EXPORT_TYPES
|
||||||
|
#endif /* WOLFSSL_DTLS_EXPORT_TYPES */
|
||||||
|
|
||||||
|
|
||||||
/* wolfSSL Cipher type just points back to SSL */
|
/* wolfSSL Cipher type just points back to SSL */
|
||||||
@ -2330,8 +2332,8 @@ struct WOLFSSL_CTX {
|
|||||||
CallbackIOSend CBIOSend;
|
CallbackIOSend CBIOSend;
|
||||||
#ifdef WOLFSSL_DTLS
|
#ifdef WOLFSSL_DTLS
|
||||||
CallbackGenCookie CBIOCookie; /* gen cookie callback */
|
CallbackGenCookie CBIOCookie; /* gen cookie callback */
|
||||||
wc_dtls_export dtls_export; /* export function for DTLS session */
|
|
||||||
#ifdef WOLFSSL_SESSION_EXPORT
|
#ifdef WOLFSSL_SESSION_EXPORT
|
||||||
|
wc_dtls_export dtls_export; /* export function for DTLS session */
|
||||||
CallbackGetPeer CBGetPeer;
|
CallbackGetPeer CBGetPeer;
|
||||||
CallbackSetPeer CBSetPeer;
|
CallbackSetPeer CBSetPeer;
|
||||||
#endif
|
#endif
|
||||||
@ -3425,7 +3427,9 @@ struct WOLFSSL {
|
|||||||
DtlsMsg* dtls_rx_msg_list;
|
DtlsMsg* dtls_rx_msg_list;
|
||||||
void* IOCB_CookieCtx; /* gen cookie ctx */
|
void* IOCB_CookieCtx; /* gen cookie ctx */
|
||||||
word32 dtls_expected_rx;
|
word32 dtls_expected_rx;
|
||||||
|
#ifdef WOLFSSL_SESSION_EXPORT
|
||||||
wc_dtls_export dtls_export; /* export function for session */
|
wc_dtls_export dtls_export; /* export function for session */
|
||||||
|
#endif
|
||||||
#ifdef WOLFSSL_SCTP
|
#ifdef WOLFSSL_SCTP
|
||||||
word16 dtlsMtuSz;
|
word16 dtlsMtuSz;
|
||||||
#endif /* WOLFSSL_SCTP */
|
#endif /* WOLFSSL_SCTP */
|
||||||
|
@ -443,8 +443,13 @@ WOLFSSL_API WOLFSSL_METHOD *wolfTLSv1_2_client_method(void);
|
|||||||
|
|
||||||
#ifdef WOLFSSL_SESSION_EXPORT
|
#ifdef WOLFSSL_SESSION_EXPORT
|
||||||
#ifdef WOLFSSL_DTLS
|
#ifdef WOLFSSL_DTLS
|
||||||
|
|
||||||
|
#ifndef WOLFSSL_DTLS_EXPORT_TYPES
|
||||||
typedef int (*wc_dtls_export)(WOLFSSL* ssl,
|
typedef int (*wc_dtls_export)(WOLFSSL* ssl,
|
||||||
unsigned char* exportBuffer, unsigned int sz, void* userCtx);
|
unsigned char* exportBuffer, unsigned int sz, void* userCtx);
|
||||||
|
#define WOLFSSL_DTLS_EXPORT_TYPES
|
||||||
|
#endif /* WOLFSSL_DTLS_EXPORT_TYPES */
|
||||||
|
|
||||||
WOLFSSL_API int wolfSSL_dtls_import(WOLFSSL* ssl, unsigned char* buf,
|
WOLFSSL_API int wolfSSL_dtls_import(WOLFSSL* ssl, unsigned char* buf,
|
||||||
unsigned int sz);
|
unsigned int sz);
|
||||||
WOLFSSL_API int wolfSSL_CTX_dtls_set_export(WOLFSSL_CTX* ctx,
|
WOLFSSL_API int wolfSSL_CTX_dtls_set_export(WOLFSSL_CTX* ctx,
|
||||||
|
Reference in New Issue
Block a user