mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-05-04 18:24:13 +02:00
Fixes for building AES key wrap and PKCS7 on Windows. Cleanup snprintf to use XSNPRINTF and changed so define is always setup.
This commit is contained in:
+2
-2
@@ -4963,8 +4963,6 @@ int wc_AesKeyWrap(const byte* key, word32 keySz, const byte* in, word32 inSz,
|
||||
int wc_AesKeyUnWrap(const byte* key, word32 keySz, const byte* in, word32 inSz,
|
||||
byte* out, word32 outSz, const byte* iv)
|
||||
{
|
||||
(void)iv;
|
||||
|
||||
Aes aes;
|
||||
byte* r;
|
||||
word32 i, n;
|
||||
@@ -4978,6 +4976,8 @@ int wc_AesKeyUnWrap(const byte* key, word32 keySz, const byte* in, word32 inSz,
|
||||
0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6
|
||||
};
|
||||
|
||||
(void)iv;
|
||||
|
||||
if (key == NULL || in == NULL || inSz < 3 ||
|
||||
out == NULL || outSz < (inSz - KEYWRAP_BLOCK_SIZE))
|
||||
return BAD_FUNC_ARG;
|
||||
|
||||
Regular → Executable
+1
-1
@@ -946,7 +946,7 @@ int wc_PKCS7_EncodeSignedData(PKCS7* pkcs7, byte* output, word32 outputSz)
|
||||
return ret;
|
||||
}
|
||||
esd->contentDigest[0] = ASN_OCTET_STRING;
|
||||
esd->contentDigest[1] = hashSz;
|
||||
esd->contentDigest[1] = (byte)hashSz;
|
||||
ret = wc_HashFinal(&esd->hash, esd->hashType,
|
||||
&esd->contentDigest[2]);
|
||||
if (ret < 0) {
|
||||
|
||||
Reference in New Issue
Block a user