forked from wolfSSL/wolfssl
Addressing PR comments
TODO should not have been in the changes indentation of #ifdef moved in line with the 'if' conditional
This commit is contained in:
@ -7588,16 +7588,16 @@ int wolfSSL_EVP_MD_type(const WOLFSSL_EVP_MD* type)
|
|||||||
|
|
||||||
if (ctx == NULL || ((src == NULL || dst == NULL) &&
|
if (ctx == NULL || ((src == NULL || dst == NULL) &&
|
||||||
(TRUE
|
(TRUE
|
||||||
#ifdef HAVE_AESGCM
|
#ifdef HAVE_AESGCM
|
||||||
&& ctx->cipherType != AES_128_GCM_TYPE &&
|
&& ctx->cipherType != AES_128_GCM_TYPE &&
|
||||||
ctx->cipherType != AES_192_GCM_TYPE &&
|
ctx->cipherType != AES_192_GCM_TYPE &&
|
||||||
ctx->cipherType != AES_256_GCM_TYPE
|
ctx->cipherType != AES_256_GCM_TYPE
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_AESCCM
|
#ifdef HAVE_AESCCM
|
||||||
&& ctx->cipherType != AES_128_CCM_TYPE &&
|
&& ctx->cipherType != AES_128_CCM_TYPE &&
|
||||||
ctx->cipherType != AES_192_CCM_TYPE &&
|
ctx->cipherType != AES_192_CCM_TYPE &&
|
||||||
ctx->cipherType != AES_256_CCM_TYPE
|
ctx->cipherType != AES_256_CCM_TYPE
|
||||||
#endif
|
#endif
|
||||||
))) {
|
))) {
|
||||||
WOLFSSL_MSG("Bad argument.");
|
WOLFSSL_MSG("Bad argument.");
|
||||||
return WOLFSSL_FATAL_ERROR;
|
return WOLFSSL_FATAL_ERROR;
|
||||||
@ -7793,7 +7793,7 @@ int wolfSSL_EVP_MD_type(const WOLFSSL_EVP_MD* type)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
if (ret == AES_GCM_AUTH_E) { // todo: check this
|
if (ret == AES_GCM_AUTH_E) {
|
||||||
WOLFSSL_MSG("wolfSSL_EVP_Cipher failure: bad AES-GCM tag.");
|
WOLFSSL_MSG("wolfSSL_EVP_Cipher failure: bad AES-GCM tag.");
|
||||||
}
|
}
|
||||||
WOLFSSL_MSG("wolfSSL_EVP_Cipher failure");
|
WOLFSSL_MSG("wolfSSL_EVP_Cipher failure");
|
||||||
|
Reference in New Issue
Block a user