ESP32 Test Flash Encryption
Posted: Mon Apr 15, 2019 3:50 pm
Hello,
I want to implement a modified flash encryption feature onto my ESP32 that uses a user-supplied 256-bit key to encrypt and decrypt flash contents, rather than eFuse Block 1. The reason for this is that I want to be able to test flash encryption functionality without making any permanent changes to the chip.
I understand that the user can disable flash encryption a number of times after enabling it. However, there is a limit to this, and it still writes the key to eFuse Block 1, which is what I want to avoid.
I looked at the ESP32 technical reference manual and saw that the chip defines a key generator function that derives from Block 1 and some other settings. So I guess if I could override this key generator function, I could implement my desired functionality. But I have no idea how feasible this is, or if it's feasible at all. Are there any other potential solutions for this?
Thanks in advance.
I want to implement a modified flash encryption feature onto my ESP32 that uses a user-supplied 256-bit key to encrypt and decrypt flash contents, rather than eFuse Block 1. The reason for this is that I want to be able to test flash encryption functionality without making any permanent changes to the chip.
I understand that the user can disable flash encryption a number of times after enabling it. However, there is a limit to this, and it still writes the key to eFuse Block 1, which is what I want to avoid.
I looked at the ESP32 technical reference manual and saw that the chip defines a key generator function that derives from Block 1 and some other settings. So I guess if I could override this key generator function, I could implement my desired functionality. But I have no idea how feasible this is, or if it's feasible at all. Are there any other potential solutions for this?
Thanks in advance.