mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-30 10:47:28 +02:00
Merge pull request #4585 from kareem-wolfssl/encryptMacFix
Fix building Import/ExportOptions with HAVE_ENCRYPT_THEN_MAC undefined.
This commit is contained in:
@ -1186,10 +1186,12 @@ static int ExportOptions(WOLFSSL* ssl, byte* exp, word32 len, byte ver,
|
|||||||
exp[idx++] = options->asyncState;
|
exp[idx++] = options->asyncState;
|
||||||
|
|
||||||
if (type == WOLFSSL_EXPORT_TLS) {
|
if (type == WOLFSSL_EXPORT_TLS) {
|
||||||
|
#ifdef HAVE_ENCRYPT_THEN_MAC
|
||||||
exp[idx++] = options->disallowEncThenMac;
|
exp[idx++] = options->disallowEncThenMac;
|
||||||
exp[idx++] = options->encThenMac;
|
exp[idx++] = options->encThenMac;
|
||||||
exp[idx++] = options->startedETMRead;
|
exp[idx++] = options->startedETMRead;
|
||||||
exp[idx++] = options->startedETMWrite;
|
exp[idx++] = options->startedETMWrite;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/* version of connection */
|
/* version of connection */
|
||||||
@ -1362,10 +1364,12 @@ static int ImportOptions(WOLFSSL* ssl, const byte* exp, word32 len, byte ver,
|
|||||||
options->asyncState = exp[idx++];
|
options->asyncState = exp[idx++];
|
||||||
|
|
||||||
if (type == WOLFSSL_EXPORT_TLS) {
|
if (type == WOLFSSL_EXPORT_TLS) {
|
||||||
|
#ifdef HAVE_ENCRYPT_THEN_MAC
|
||||||
options->disallowEncThenMac = exp[idx++];
|
options->disallowEncThenMac = exp[idx++];
|
||||||
options->encThenMac = exp[idx++];
|
options->encThenMac = exp[idx++];
|
||||||
options->startedETMRead = exp[idx++];
|
options->startedETMRead = exp[idx++];
|
||||||
options->startedETMWrite = exp[idx++];
|
options->startedETMWrite = exp[idx++];
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/* version of connection */
|
/* version of connection */
|
||||||
|
Reference in New Issue
Block a user