Hi @Aurelien_Grange
I hope that you are doing great! I got a couple of points here:
1 Please make sure to test on the latest LPC55s06 SDK version. This to get the latest driver updates on IAP FFR apis, etc.
2 Are you able to get the same issue if you call the the PUF_SetUserKey function to set a new key?
I believe that you already stored in CMPA the AC and USERKEY keycode. I am leaving a pseudocode below where this is ommited.
result = PUF_SetUserKey(PUF, kPUF_KeyIndex_00, s_userKey256, 32, keyCode0, sizeof(keyCode0));
GetRandomData32(&random);
/* Reconstruct key from keyCode0 to HW bus for crypto module */
result = PUF_GetHwKey(PUF, keyCode0, sizeof(keyCode0), kPUF_KeySlot0, random);
HASHCRYPT_Init(HASHCRYPT);
hashcrypt_handle_t m_handle;
/* Encrypt plaintext via Hascrypt using HW secret key */
m_handle.keyType = kHASHCRYPT_SecretKey;
result = HASHCRYPT_AES_SetKey(HASHCRYPT, &m_handle, NULL, 32);
result = HASHCRYPT_AES_EncryptEcb(HASHCRYPT, &m_handle, s_EcbPlain, cipher2, sizeof(s_EcbPlain));
3 I want to narrow down your issue. To do so, we would need to check the procedure you used, please help me to check below:
1 Enroll puff and store AC and UserKEK. Which method did you used?
2 Demo program. I recommend to base this on our SDK examples. Which reference you took?
3 Enable Secure Boot. Did you sequentially provision both keys using BLHOST?
.\blhost\win\blhost.exe -V -p COM32,57600 -- key-provisioning set_user_key 3 ".\temp\tempSbkek.bin"
.\blhost\win\blhost.exe -V -p COM32,57600 -- key-provisioning set_user_key 11 ".\temp\UserKek.bin"
My apologies for the delay.
Diego