2407831_en-US

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

2407831_en-US

2407831_en-US

SCP03 Authentication Failure on SE050C2

Hi everyone,

I am currently working on a project using the SE050C2 secure element alongside an ESP32. I am using ESP-IDF and the Plug and Trust middleware.

I am trying to enable Platform SCP03 authentication. According to the middleware, the default OEF keys for the SE050C2 variant are already defined in the headers.

I have configured my firmware to use these exact keys. However, when I try to open a session, the SCP03 authentication fails, and I get a MAC verification error 7042.

It seems the keys expected by my application do not match the keys physically present inside the chip.

I have a few questions regarding this issue:

  1. Are the default middleware keys correct for this specific chip version?

  2. If this chip is part of a development board, is it possible that it comes pre-provisioned with different keys like DEVKIT A1F4 keys or standard test keys?

  3. Is there a safe way to identify the actual SCP03 keys on my chip, or a procedure to reset them if they were inadvertently changed?

Any guidance on how to resolve this issue would be greatly appreciated.

Thank you

online debugRe: SCP03 Authentication Failure on SE050C2Hi,

Thank you for the guidance.

Regarding the log information, here is the full trace I get right before and during the MAC verification error:

sss :INFO :atr (Len=35)
00 A0 00 00 03 96 04 03 E8 00 FE 02 0B 03 E8 08 01 00 00 00 00 64 00 00 0A 4A 43 4F 50 34 20 41 54 50 4F
scp :ERROR: RESPONSE MAC DID NOT VERIFY 7042
sss :WARN :nxEnsure:'ret == SM_OK' failed. At Line:6291 Function:sss_se05x_TXn
sss :WARN :nxEnsure:'status == SM_OK' failed. At Line:5119 Function:sss_se05x_cipher_one_go

Regarding reading the OEF ID: I am using an ESP32 as the host MCU, not an NXP evaluation board like FRDM or iMX. Therefore, I cannot directly flash the pre-built binaries or easily use the Windows VCOM / ssscli methods you mentioned.

Since I am on ESP-IDF, can I simply compile and run the "se05x_GetInfo" example provided inside the simw-top middleware directly on my ESP32 to read the OEF ID?

Alternatively, is there a simple C function I can temporarily add to my current main.c (before SCP03 is initialized) to print the OEF ID and UID to the console?

Thank you for your support.
Re: SCP03 Authentication Failure on SE050C2

MAC verification error 7042 seems to be confused to understand, can you share more log information?

Please check below for OEF ID read tools setting:

======================================

10.7 How to get SE Platform Information and UID
Follow any one of the following methods to get the SE platform information.
10.7.1 Using TeraTerm and pre-built binary
A pre-built binary for se05x_GetInfo is available in binaries directory for FRDM-K64F and iMX-RT1060.
You would need to install a serial terminal application, like TeraTerm.
• Install TeraTerm on your system. To setup TeraTerm, refer
• Flash the pre-built binary on your hardware.
• View the logs on TeraTerm.

The highlighted log is the SE UID, OEF ID and JCOP Platform ID.

10.7.2 Using VCOM and binary
Plug & Trust MW Documentation
• Flash VCOM binary present in binaries directory accorfing to your board.
• Check VCOM Port number in device manager.
• Build project se05x_GetInfo with the following configuration:– SMCOM: VCOM– Host: PCWindows
• Run the built binary as:
se05x_GetInfo.exe COMxx
Where COMxx is the VCOM port number obtained from step 2.
The highlighted log is the SE UID, OEF ID and JCOP Platform ID

10.7.3 Using ssscli Tool
Plug & Trust MW Documentation
• Flash VCOM binary present in binaries directory accorfing to your board.
• Check VCOM Port number in device manager.
• Run the following commands in binaries/PCWindows/ssscli directory:
ssscli.exe connect se050 vcom COMxx
ssscli.exe se05x uid
ssscli.exe disconnect
Where COMxx is the VCOM Port number obtained in step 2.
The highlighted log is the SE UID

Re: SCP03 Authentication Failure on SE050C2Thank you for providing the table. I have carefully checked the key values in my application.

The keys I am using in my C code exactly match the SE050C2 row in your table:
ENC: BD 1D E2 0A 81 EA B2 BF 3B 70 9A 9D 69 A3 12 54
MAC: 9A 76 1B 8D BA 6B ED F2 27 41 E4 5D 8D 42 36 F5
DEK: 9B 99 3B 60 0F 1C 64 F5 AD C0 63 19 2A 96 C9 47

There is no bit difference at all. I am passing these exact byte arrays to the middleware. However, I still get the MAC verification error 7042.

Because the keys perfectly match the documentation but fail on the hardware, I strongly suspect my specific SE050 chip might be pre-provisioned with different keys. For example, it might be using the Development Board keys shown in the last row of your table, or standard test keys.

Is there a specific command or middleware function I can run without SCP03 to safely read the chip's actual OEF ID, or to check if it is provisioned as a Development Board

Thanks again for your help.
Re: SCP03 Authentication Failure on SE050C2

Please check below for default key of SE050C2. If you report MAC error, can you check the key value for your application? How may bit difference to cause this MAC verification error 7042 

db16122_0-1787634676992.pngdb16122_0-1787634676992.pngdb16122_0-1787634676992.png


タグ(1)
評価なし
バージョン履歴
最終更新日:
10 時間前
更新者: