Add support for Ultralight emulation. - #215
Conversation
|
You are welcome to add an entry to the CHANGELOG.md as well |
|
Perfect👍 |
|
There is currently some memory corruption bug that in some cases overwrites the |
Built artifacts for commit 25a1230FirmwareClient |
This version only emulates MF0ICU1 properly.
|
I've tested that this works with a proxmark so looks good to me. If someone could test this thoroughly as well it would be nice. Currently I've tested:
Problems:
|
|
Should we support the ASCII mirror function of NTAG? |
|
I could add this as well. |
OK, and you can reuse 'STATUS_PAR_ERR'. |
I'll check what the original cards reply. So far Ultralight cards mostly ignore bad commands while NTAGs reply with NAKs. |
Indeed. I'll compare with an original card and patch that. |
Where exactly do you want me to reuse this status, @xianglin1998? Isn't it more clear what the message is when the statuses are different? Also in some places this helps to understand whether wrong slot type is chosen or arguments are invalid. |
NAKs returned by both Ultralight and NTAG cards were 0 in my tests and Ultralights didn't respond to invalid commands at all.
|
@taichunmin get/set counter is done, NAKs seem to be fixed and now work like real cards, NTAG counter index fixed. |
|
Is there support for 7B ULEV1? pm3 shows such cards as |
Are you sure about the UID size? The code for slot initialization sets 7 byte size explicitly. Did you initialize the slot by doing 48 bytes mean the amount of memory usable as general-purpose storage, the tag has more memory than that. |
…ution data from being updated sometimes.
|
I've fixed some bugs and added support for NTAG 210/212. So far all commands seem to be tested. Each MFU compatible tag type is properly detected by proxmark. Controlling counters and version/signature works. Loading and saving dumps from emulator also works. The only thing that is missing is Ultralight C authentication, but that's something that I think can be done in a follow up PR. |
|
Perfect!!! Can i merge it? |
|
@xianglin1998 yes, let's merge. I'll add Ultralight C auth and more cards in another PR or two. |
This PR adds support for Mifare Ultralight emulation.
Currently it's a bit untested and lacks functionality of newer ultralight versions and NTAGs (e.g. password auth). I'll convert it from a WIP PR when it's ready. In the current state it can emulate the original Ultralight and the UID magic mode works.