cancel
Showing results for 
Search instead for 
Did you mean: 

SBSFU for STM32H743: SBSFU hangs in the SE_VerifyHeaderSignature() function.

mr.1
Associate III

I am using the SBSFU STM32CubeExpansion_SBSFU_V2.6.2 version for my custom board STM32H743VI controller. I have ported the STM32H7B3I-DK project for H743 controller for COM port and changed the crypto scheme to SECBOOT_ECCDSA_WITHOUT_ENCRYPT_SHA256.

I am getting below logs and hangs. It hangs in the below code,

SE_ErrorStatus SE_VerifyHeaderSignature(SE_StatusTypeDef *peSE_Status, SE_FwRawHeaderTypeDef *pxFwRawHeader)

{

 SE_ErrorStatus e_ret_status;

 uint32_t primask_bit; /*!< interruption mask saved when disabling ITs then restore when re-enabling ITs */

 /* Check if the call is coming from SFU code */

 __IS_SFU_RESERVED();

#ifdef SFU_ISOLATE_SE_WITH_MPU

 if (0x0U != SE_IsUnprivileged())

 {

  TRACE("\r\n inside privilege");

  uint32_t params[1] = {(uint32_t)pxFwRawHeader};

  SE_SysCall(&e_ret_status, SE_CRYPTO_HL_AUTHENTICATE_METADATA, peSE_Status, &params);

  TRACE("\r\n after secall");

 }

After SE_SysCall() call, there is no message. Please suggest the next steps to debug it.

Let me know if you need more information.

Regards,

Rakkumuthu R


_legacyfs_online_stmicro_images_0693W00000bia7TQAQ.png

1 ACCEPTED SOLUTION

Accepted Solutions
Jocelyn RICARD
ST Employee

Hello Rakkumuthu,

The SBSFU package provides an example for STM32H753 which is the crypto version of STM32H743.

With this example you should have a setup directly working.

If you still want to use the STM32H7B3 example, you will need to adapt the flash driver because it is different (8KB sectors instead of 128KB).

You can get flash driver from STM32H753 example though.

In any case, you should be able to use debugger to understand what happens precisely.

You would only need to add secure engine symbols in addition to the SBSFU symbols to be able to continue debugging inside secure engine.

Best regards

Jocelyn

View solution in original post

2 REPLIES 2
Jocelyn RICARD
ST Employee

Hello Rakkumuthu,

The SBSFU package provides an example for STM32H753 which is the crypto version of STM32H743.

With this example you should have a setup directly working.

If you still want to use the STM32H7B3 example, you will need to adapt the flash driver because it is different (8KB sectors instead of 128KB).

You can get flash driver from STM32H753 example though.

In any case, you should be able to use debugger to understand what happens precisely.

You would only need to add secure engine symbols in addition to the SBSFU symbols to be able to continue debugging inside secure engine.

Best regards

Jocelyn

Used STM32H753 example to solve it.