mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-30 18:57:27 +02:00
Merge pull request #6603 from JacobBarthelmeh/xilinx
fix for AES-GCM use with petalinux
This commit is contained in:
@ -9802,7 +9802,7 @@ int wc_AesInit(Aes* aes, void* heap, int devId)
|
|||||||
aes->heap, devId);
|
aes->heap, devId);
|
||||||
#endif /* WOLFSSL_ASYNC_CRYPT */
|
#endif /* WOLFSSL_ASYNC_CRYPT */
|
||||||
|
|
||||||
#ifdef WOLFSSL_AFALG
|
#if defined(WOLFSSL_AFALG) || defined(WOLFSSL_AFALG_XILINX_AES)
|
||||||
aes->alFd = WC_SOCK_NOTSET;
|
aes->alFd = WC_SOCK_NOTSET;
|
||||||
aes->rdFd = WC_SOCK_NOTSET;
|
aes->rdFd = WC_SOCK_NOTSET;
|
||||||
#endif
|
#endif
|
||||||
|
@ -71,7 +71,11 @@ static int wc_AesSetup(Aes* aes, const char* type, const char* name, int ivSz, i
|
|||||||
aes->rdFd = WC_SOCK_NOTSET;
|
aes->rdFd = WC_SOCK_NOTSET;
|
||||||
return WC_AFALG_SOCK_E;
|
return WC_AFALG_SOCK_E;
|
||||||
}
|
}
|
||||||
|
#ifdef WOLFSSL_AFALG_XILINX_AES
|
||||||
|
ForceZero(key, sizeof(aes->msgBuf));
|
||||||
|
#else
|
||||||
ForceZero(key, sizeof(aes->key));
|
ForceZero(key, sizeof(aes->key));
|
||||||
|
#endif
|
||||||
|
|
||||||
/* set up CMSG headers */
|
/* set up CMSG headers */
|
||||||
XMEMSET((byte*)&(aes->msg), 0, sizeof(struct msghdr));
|
XMEMSET((byte*)&(aes->msg), 0, sizeof(struct msghdr));
|
||||||
|
Reference in New Issue
Block a user