Merge pull request #6772 from bandi13/zd16449_more_fixes

Zd16449 more fixes
This commit is contained in:
JacobBarthelmeh
2023-09-14 09:35:01 -06:00
committed by GitHub
2 changed files with 15 additions and 13 deletions

View File

@ -75,7 +75,7 @@ function Test() {
function Remove() {
UnlinkFiles
rm -rf ./async
rm -rf ${ASYNC_DIR}
}
if [ "$#" -gt 1 ]; then

View File

@ -8665,19 +8665,21 @@ static int SendTls13CertificateVerify(WOLFSSL* ssl)
}
EncodeSigAlg(ssl->options.hashAlgo, args->sigAlgo, args->verify);
if (ssl->hsType == DYNAMIC_TYPE_RSA) {
int sigLen = MAX_SIG_DATA_SZ;
if (args->length > MAX_SIG_DATA_SZ)
sigLen = args->length;
args->sigData = (byte*)XMALLOC(sigLen, ssl->heap,
DYNAMIC_TYPE_SIGNATURE);
}
else {
args->sigData = (byte*)XMALLOC(MAX_SIG_DATA_SZ, ssl->heap,
DYNAMIC_TYPE_SIGNATURE);
}
if (args->sigData == NULL) {
ERROR_OUT(MEMORY_E, exit_scv);
if (ssl->hsType == DYNAMIC_TYPE_RSA) {
int sigLen = MAX_SIG_DATA_SZ;
if (args->length > MAX_SIG_DATA_SZ)
sigLen = args->length;
args->sigData = (byte*)XMALLOC(sigLen, ssl->heap,
DYNAMIC_TYPE_SIGNATURE);
}
else {
args->sigData = (byte*)XMALLOC(MAX_SIG_DATA_SZ, ssl->heap,
DYNAMIC_TYPE_SIGNATURE);
}
if (args->sigData == NULL) {
ERROR_OUT(MEMORY_E, exit_scv);
}
}
/* Create the data to be signed. */