Skip to main content
AKama.2
Associate
August 17, 2018
Question

STM32 Crypto Library

  • August 17, 2018
  • 0 replies
  • 592 views

I am using the STM32F071RB microcontroller and trying to use the en.stm32-cryp-lib to encrypt and decrypt using AES128-CBC. The encryption and decryption functions return expected data when using data that is a multiple of 16 bytes, but don't when the data isn't a multiple of the block size.

I read in the user manual that the library uses Cipher-text stealing when the data isn't a multiple of the block size, but in my application, the data to be sent/received should be padded with 0x00's. I even tried padding the data with 0x00's to make it a multiple of the block size, but that didn't work, either.

Any suggestions?

This topic has been closed for replies.