cancel
Showing results for 
Search instead for 
Did you mean: 

How to enable debugging of SECoreBin application

Ikbal
Associate II

Hi,

I tried to execute my custom SBSFU_UserApp.bin on the STM32H7B3I-DK board and I get error for Header signature verification failure in slot SLOT_ACTIVE_1.

I have made changes in se_crypto_bootloader.c file for adding RSA signing verification in place of ECDSA.

I want to debug the changes inside of se_crypto_bootloader.c file of SECoreBin project.

I am using STM32Cube IDE and compiling the applications as per the order mention in the readme file of the STM32H7B3I-DK 1_Image demo project.

Please let me know, what is the debug mechanism for SECoreBin application? How can I enable debug mode of SBSFU Secure Engine application?

Thanks,

Ikbal

15 REPLIES 15

Hello @MKoza.4​,

yes, it is possible.

first time you go step by step in instruction stepping. You go through the SE_CallGate function where you should see symbols.

If not, this means you should double check your debug configuration

Best regards

Jocelyn

Hey @Jocelyn RICARD​ ,

Thanks for your response and confirming I can debug in the callgate. I've set up the debug configuration as suggested (including setting the symbol address of the SECoreBin to 0x00) and stepped into SE calls in instruction stepping mode, but still no luck. Are there settings within project properties for the SBSFU and/or SE projects that I may be missing?0693W00000WIGg2QAH.pngBest,

Matt

Hello Matt,

I made a quick test and with your configuration I confirm it does not work.

To make it work, untick the download of SBSFU and also move the SBSFU line up like this.

0693W00000WIGyBQAX.pngI hope this will work better on your side !

Best regards

Jocelyn

Hi Jocelyn,

I have tried unticking the download of both the SBSFU and SE, but still no success. I can debug the code though the SE_SVC_Handler() but once I step into SE_CallGate() I get "no source available". When I try stepping into SE_CORE_Startup() like in your screenshot, I get the same issue. I made sure that the SECoreBin project is also in the source lookup path in the debugging configuration.

0693W00000WIHLKQA5.png

Hi Matt,

did you move SBSFU line on top in the debug/startup ?

Also, one thing I didn't set "Use symbol address".

Maybe one or other point may help

I'm using version of STM32CubeIDE 1.10.1

Best regards

Jocelyn

Hi Jocelyn,

Finally got it! I had moved the SBSFU to the top line, and then had the symbol box checked, but did not set a value. I am now able to debug in the callgate.

For someone's potential future reference, I am in IDE v1.7.0

Thanks so much for your prompt help!