cancel
Showing results for 
Search instead for 
Did you mean: 

STSAFE-A110, Key Establish and Wrap/Unwrap example doesn't work

sunghwan
Associate

Hi,

I have issue on Key Establish and Wrap/Unwrap example.

I have X-NUCLEO-SAFEA1 and NUCLEO-L476RG for testing.

I downloaded X-CUBE-SAFEA1 from ST web site, version is V1.2.2.

 

Here's what I tried.

  • I ran paring example.
    • I commented out "_FORCE_DEFAULT_FLASH_" like "//#define _FORCE_DEFAULT_FLASH_"
    • it works successfully.
  • I ran All_Use_Cases example in Example_X-Cube_Cryptolib.
    • Authentication worked.
    • Key-pair generation worked.
    • Key establish is failed.
      • it fails at step 5, "5. Verify if shared secret is identical (0 means success): 49"
        • StSafeA_AssignLVBuffer() function returns STSAFEA_INVALID_RESP_LENGTH
        • pDestLVBuffer->Length was 16927 (looks like garbage value), but ExpectedLen was 32
    • Wrap/unwrap is failed.
      • it also fails at step 5, "5. Local envelope Local envelope demonstration result (0x0 means success): 0x6"
        • StSafeA_ReceiveBytes() function returns STSAFEA_BUFFER_LENGTH_EXCEEDED
        • pOutBuffer->LV.Length was 65009 (garbage value), but STSAFEA_BUFFER_DATA_PACKET_SIZE 507

Could you help me to understand what's going on?

 

Sung

 

1 REPLY 1
Billy OWEN
ST Employee

Hi @sunghwan 

 

This post has been escalated to the ST Online Support Team for additional assistance.  We'll contact you directly.

 

Regards,

Billy