wolfssl
wolfssl copied to clipboard
:[enhancement] Upgrade the Versal Port to use HW GMAC/GHASH Operations
Version
5.6.3
Description
This request is to replace the software GMAC operations with the usage of the hardware cryptographic GMAC operations provided by the AMD Versal software. Additionally, the hardware provides the option GMAC creation as well as GMAC validation so that validation doesn't have to be performed in software. For details on how to perform the GMAC operations see:
https://github.com/Xilinx/embeddedsw/blob/master/lib/sw_services/xilsecure/examples/xilsecure_versal_aes_client_example.c#L425-L514
API summary of calls in order: GMAC creation: XSecure_AesEncryptInit, XSecure_AesGmacUpdateAad (with IsLastChunkSrc set to TRUE), XSecure_AesEncryptFinal. Note that GmacUpdateAdd can be called as many times as needed.
GMAC validation: XSecure_AesDecryptInit, XSecure_AesGmacUpdateAad (with IsLastChunkSrc set to TRUE), XSecure_AesDecryptFinal. Note that GmacUpdateAdd can be called as many times as needed and _AesDecryptFinal will also validate the tag in hardware.