forked from wolfSSL/wolfssl
Merge pull request #4114 from dgarske/secrene_extmst
Check for insecure build combination of secure renegotiation and no extended master secret
This commit is contained in:
@@ -2464,6 +2464,27 @@ extern void uITRON4_free(void *p) ;
|
|||||||
#undef WOLFSSL_DH_EXTRA
|
#undef WOLFSSL_DH_EXTRA
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* Check for insecure build combination:
|
||||||
|
* secure renegotiation [enabled]
|
||||||
|
* extended master secret [disabled]
|
||||||
|
* session resumption [enabled]
|
||||||
|
*/
|
||||||
|
#if defined(HAVE_SECURE_RENEGOTIATION) && !defined(HAVE_EXTENDED_MASTER) && \
|
||||||
|
(defined(HAVE_SESSION_TICKET) || !defined(NO_SESSION_CACHE))
|
||||||
|
/* secure renegotiation requires extended master secret with resumption */
|
||||||
|
#ifndef _MSC_VER
|
||||||
|
#warning Extended master secret must be enabled with secure renegotiation and session resumption
|
||||||
|
#else
|
||||||
|
#pragma message("Warning: Extended master secret must be enabled with secure renegotiation and session resumption")
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Note: "--enable-renegotiation-indication" ("HAVE_RENEGOTIATION_INDICATION")
|
||||||
|
* only sends the secure renegotiation extension, but is not actually supported.
|
||||||
|
* This was added because some TLS peers required it even if not used, so we call
|
||||||
|
* this "(FAKE Secure Renegotiation)"
|
||||||
|
*/
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
|
Reference in New Issue
Block a user