Integrity Error on sending command with MAC

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

Integrity Error on sending command with MAC

1,754件の閲覧回数
amrin-hexondata
Contributor II

Hello, I'm trying to communicate with desfire ev3 after auth using authenticateEV2First function.
The key has been changed to AES, and I believe I manage to authenticate using the authenticateEV2First.

However I'm stuck at sending new command with MAC. In my example I try to get version (0x60) but I keep getting Integrity Error. I have CMAC function to calculate the values needed, and according to examples i found on the internet my function does calculate correctly.

I'm though not sure if my sessionkeys are generated the right way or not. 
authenticateEV2First - Pastebin.com
Functions that relates to mac - Pastebin.com
Output - Pastebin.com

I include my auth function, MAC related function and whole output. All code is written in Javascript.

Thank you.

0 件の賞賛
返信
3 返答(返信)

1,735件の閲覧回数
Fabian_R
NXP TechSupport
NXP TechSupport

This is Fabian, I've been assigned to support your case.

I appreciate your interest in our products.

Could you please clarify if you have an NDA and, access to the MIFARE DESFire EV3 secure files?

Unfortunately, I'm not able to provide full support for a javascript-based application, but the issue you are having may be related to the endianness of the frames.

Best Regards,
Fabian
0 件の賞賛
返信

1,729件の閲覧回数
amrin-hexondata
Contributor II
Hi Fabian, yup I do have access to desfire ev3 nda file DS487033.
In my app, i first create the app, create files, then I change the key.
Should I change the key first just then create the files?
0 件の賞賛
返信

1,713件の閲覧回数
Fabian_R
NXP TechSupport
NXP TechSupport

Hello sir,
There is a document called: MIFARE DESFire EV3 features and hints, which has some examples of particular use cases. Please take a look at section 4.1.3.1 which shows a similar use case of yours.
Unfortunately, I'm, not able to publish further information since this is a public community thread, and the information is secured.

Best Regards,
Fabian
0 件の賞賛
返信