0

I am trying to build a RFID tag emulator on android using Flutter framework. The RFID reader that I am working with uses the UID for identification. It then sends this UID back to a server and authenticates whether it is a valid RFID or not. I know that Android devices cannot generate a fixed UID from NFC controller.

What I want to achieve is when the RFID reader reads the UID, I want to get the same UID from the android code and send this to my backend from the Client side. In this flow, the UID sent by RFID reader and the Client will be cross checked and this would complete the auth.

Is there any way through which I can get the same UID that the RFID reader read from my phone?

Note: I am trying to get the UID of my own device and not some other Tag or Card when the RFID reader triggers the NFC controller.

I looked into the following repos and articles but couldn't find anything: https://github.com/underwindfall/NFCAndroid https://github.com/ryanhz/nfc_emulator https://www.zeromolecule.com/blog/host-card-emulation-hce-with-android-and-flutter/ https://developer.android.com/guide/topics/connectivity/nfc/hce

  • The UID is random for security purposes and because just using the UID is so insecure. NFC != RFID . The only way to do this is to root your phone, build a custom rom for it with a modified NFC stack to give a static UID. – Andrew May 15 '23 at 09:40
  • Hi @Andrew. Thanks for the clarification. I am not trying to fix the UID. I am just trying to get the UID, even if it changes every time I scan. – Mohit Jain May 15 '23 at 11:44
  • You cannot read your own UID as really the UID in NFC is just for a reader to differentiate between multiple NFC Tags that are in range, when emulating a Tag the UID has no meaning and the hardware is not operating in reader mode. – Andrew May 15 '23 at 13:11
  • Thanks a lot for the information. I would really appreciate it if you could also provide some reference for the same. – Mohit Jain May 16 '23 at 05:42

0 Answers0