Get card data with nfc_manager?
Asked Answered
W

0

7

I'm using the nfc_manager package to scan my transportation card. I've found similar apps on the playstore that were able to get transaction history, card serial number and other details from the app. However, using the nfc_manager package, I've only been able to obtain isodep and nfcB data. Below is the printed outputs of the isodep and nfcb data.

{identifier: [123, 123,123,123], hiLayerResponse: [], historicalBytes: null, isExtendedLengthApduSupported: true, maxTransceiveLength: 12312, timeout: 123}
{identifier: [123,123,123,123], applicationData: [0, 0, 0, 0], maxTransceiveLength: 123, protocolInfo: [123,123,123]}

(the values were changed to 123 because I'm not sure if the data is sensitive) How do I go about obtaining data such as transportation history and all that from the data I have here? Or is that a limitation of the package?

here is the code used:

 NfcManager.instance.startSession(onDiscovered: (NfcTag tag) async {
       print(tag.data['isodep']);
       print(tag.data['nfcb']);

       IsoDep isoDep = IsoDep.from(tag);
       print(isoDep.historicalBytes);
     });

Thank you for your help!

Wist answered 6/8, 2021 at 8:41 Comment(5)
Usually data on such cards is encoded. Also I would suspect that your travel history is not stored on the card itself but on a server. The cards usually only have a few kb storage. Are you sure the card holds the transportation history?Sexagenary
I've used similar apps with wifi turned off and they are able to obtain the data.Wist
Hello, did you get any solution?Biquarterly
not yet, do share one if you end up finding it though!Wist
@Wist did you find a solution on this ?Buckshee

© 2022 - 2024 — McMap. All rights reserved.