Skip to main content
lowpowermcu
Associate III
April 22, 2011
Question

Crypto using STM32: what is the best solution

  • April 22, 2011
  • 2 replies
  • 1060 views
Posted on April 22, 2011 at 12:49

Crypto using STM32: what is the best solution

#crypto-backup-sram
This topic has been closed for replies.

2 replies

Tesla DeLorean
Guru
May 17, 2011
Posted on May 17, 2011 at 14:32

I need to know how to keep the encryption key secure.

Don't tell anyone what it is.

Which of the steps are visible to the user?

Where is the image enciphered?

Do all devices have the same key?

Can you use the BKP registers with tamper protection?

Can you use the device unique ID?

Can you use ROP?

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
jpeacock23
Associate
May 17, 2011
Posted on May 17, 2011 at 14:32

First, don't put the crypto key in flash.  Keep it in a battery-backed RAM location and use tamper detect circuitry to shut off battery power (to erase the SRAM).  This protects the key if the unit isn't powered.  Otherwise generate an interrupt from the tamper to erase the key when the unit is running.

Never store the key in regular SRAM.  Always keep it in a register when using it.  Processors can be halted and the contents of regular SRAM dumped by any good reverse engineering company.

  Jack Peacock