kokke / tiny-AES-c

Small portable AES128/192/256 in C
The Unlicense
4.3k stars 1.3k forks source link

HOW TO IMPLEMENT IN STM32 MICROCONTROLLERS #217

Closed DHONI123456 closed 1 year ago

DHONI123456 commented 1 year ago

Sir, I am beginner in programming with microcontrollers. As part of my project work, I need to implement AES Encryption for a 124 byte data in STM32F407 microcntroler (running at 168Mhz clock) . The specified controller doesn't have cryptograhic peripherals and cryptographic libraries. Hence I searched for application codes in C which implements AES. I found this code understandable and I was trying to implement the code in my microcontroller. By doing this AES encryption, I wanted to find out the time taken for encrypting 124 byte data. But I didn't find the main() function in the code. As I am a novice in programming a microcontroller using C, I am not very aware of how to run this code in stm32. Are there any changes I need to make. It would be very helpful if you can tell me how to run the code in the microcontroller without the main function (or actually which all part of the code can I move into the main() function). Looking forward for your reply. Thanks & Regards

kokke commented 1 year ago

Hi @DHONI123456 and thanks for your interest in this project :)

It sounds like you need help with more basic concepts in C, such as calling functions and compiling multiple files.

Such discussions are a bad fit for GitHub-issues. I will close this issue and recommend you try asking on stackoverflow.com instead.

Note: This library is not particularly fast compared to larger implementations. There are other AES-libraries available, that do table-based lookups and thereby trade memory for speed.