Fix for size calculation for encrypt then mac without openssl extra enabled. Fix for cast warning.

This commit is contained in:
David Garske
2022-05-02 16:06:18 -07:00
committed by Jacob Barthelmeh
parent 6f5be32d3a
commit 628a91efda
2 changed files with 4 additions and 4 deletions

View File

@ -18320,10 +18320,10 @@ int BuildMessage(WOLFSSL* ssl, byte* output, int outSz, const byte* input,
}
else
#endif
{
args->pad = (args->sz - args->headerSz) % blockSz;
#ifdef OPENSSL_EXTRA
if(args->pad != 0)
#endif
}
if (args->pad != 0)
args->pad = blockSz - args->pad;
args->sz += args->pad;
}

View File

@ -37749,7 +37749,7 @@ int wolfSSL_ASN1_STRING_canon(WOLFSSL_ASN1_STRING* asn_out,
ret = len;
}
WOLFSSL_LEAVE("wolfSSL_OBJ_length", ret);
WOLFSSL_LEAVE("wolfSSL_OBJ_length", (int)ret);
return ret;
}