Hi,
I recently try to store the AES-256 key into the SE050, however I got the response code 0x6D00 instead of 0x9000. I use the document of AN12313 SE050 APDU Specification, I couldn't found any solution from the forum too.
Firstly, I soft reset the secure element before sending the APDU command. I think the problem should be on the APDU command instead of T=1 protocol. Anyone can help to tackle the issue?
Thanks.
typedef struct
{
uint8_t cla;
uint8_t ins;
uint8_t p1;
uint8_t p2;
uint8_t lc;
uint8_t data[256];
uint8_t le;
} ApduCommand;
static ApduCommand write_aeskey = {
.cla = 0x80,
.ins = 0x01,
.p1 = 0x03,
.p2 = 0x00,
.lc = 0x28,
.data = {
0x41, 0x04, 0x00, 0x00, 0x00, 0x05,
0x43, 0x20, 0x66, 0x49, 0x38, 0x55, 0x40, 0x59, 0x64, 0x6F, 0x61, 0x22, 0x52, 0x57, 0x35, 0x48, 0x34, 0x79,
0x32, 0x4C, 0x68, 0x50, 0x6C, 0x37, 0x4B, 0x6B, 0x77, 0x60, 0x79, 0x36, 0x47, 0x35, 0x74, 0x72},
.le = 0x00
};
Hi @liexin00 ,
Did you develop your application based on the MW or just following the UM11225? Was the log a part of the communication or the whole log out of POR? Please kindly clarify.
Have a great day,
Kan
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi @Kan_Li ,
Thanks for the reply. FYI, I am using STM32 to communicate with secure element. Since MW is not supported, thus I just followed the UM11225 to develop only the AES functions. The log only shows that I send the write symmetry key (AES) APDU command, then it response 0x6D00. Before sending this command, I have sent the soft reset and applet selection commands, both got the expected response as in UM11225
Hi @liexin00 ,
Thanks for the info! Would you please specify which variant you are playing with? SE050E2? Please kindly clarify.
Have a great day,
Kan
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------