This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

EK-TM4C129EXL: AES GCM and GMAC encryption modes with wolfSSL 5.6.4

Part Number: EK-TM4C129EXL

I'm trying to use the hardware encryption feature of the TM4C129E with wolfSSL, but I am running into issues when trying to establish a TLS connection. With some effort, I was able to run the crypto tests from the wolfSSL package, which shows that the AES-GCM and GMAC test fail. I suspect the issue is related to the various mode selection bits in the AES_CTRL register. The GCM field in that register shows 3 different modes for dealing with H and Y0 in different ways, but I'm not sure how those relate to GCM vs GMAC operation.

Various support topics at both TI and wolfSSL talk about seeing success with much older versions of wolfSSL, but has anyone been successful with a recent version?

  • Hi,

    I suspect the issue is related to the various mode selection bits in the AES_CTRL register. The GCM field in that register shows 3 different modes for dealing with H and Y0 in different ways, but I'm not sure how those relate to GCM vs GMAC operation.

      Sorry, I'm not an expert on the AES module. There are gcm examples at C:\ti\TivaWare_C_Series-2.2.0.295\examples\boards\dk-tm4c129x\aes_gcm_encrypt and C:\ti\TivaWare_C_Series-2.2.0.295\examples\boards\dk-tm4c129x\aes_gcm_decrypt. Going through the code, the aes_gcm_encrypt example has a setting with GCM field equal to 0x3 which is autonomous GHASH. I I don't have the knowledge to explain how each mode will affects GCM vs. GMAC operation. I will suggest you run the bare metal AES examples first with different GCM field in the AES_CTRL register. I don't think AES module is the problem. It is most likely how WolfSSL interprets or support the data generated in different modes. WolfSSL is another area where I don't have experience. If you think the older version of WolfSSL works then I really suggest you consult with WolfSSL for guidance. As much as I'd like help, I just don't have the experience with the 3rd party WolfSSL.