Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Authorisation support for NFC cards #321

Open
3 of 21 tasks
pefka opened this issue Nov 12, 2024 · 4 comments
Open
3 of 21 tasks

feat: Authorisation support for NFC cards #321

pefka opened this issue Nov 12, 2024 · 4 comments

Comments

@pefka
Copy link

pefka commented Nov 12, 2024

Plugin(s)

  • Android Foreground Service
  • Android Battery Optimization
  • App Update
  • Background Task
  • Badge
  • Bluetooth Low Energy
  • Cloudinary
  • Datetime Picker
  • File Compressor
  • File Opener
  • File Picker
  • Live Update
  • Managed Configurations
  • NFC
  • Photo Editor
  • Printer
  • Screen Orientation
  • Speech Recognition
  • Zip

Current problem

I can't find a way to make communication between the card and smartphone encrypted.

Preferred solution

There is a MiFare desFire card, it supports encrypted communication through authorisation.

Can you add to your plugin the possibility of read with authorisation and write with authorisation?

Alternative options

No response

Additional context

No response

Before submitting

@pefka pefka added feature Feature request needs: triage labels Nov 12, 2024
@robingenz
Copy link
Member

robingenz commented Nov 13, 2024

Thank you for reaching out! Which platforms must be supported?

@pefka
Copy link
Author

pefka commented Nov 13, 2024

iOS and Android

@robingenz
Copy link
Member

I'm not sure if it's possible on iOS. Core NFC only offers two methods for MiFare tags:

  1. sendMiFareCommand
  2. sendMiFareISO7816Command

The first is already available via the plugin. You may simply have to send a special command to the tag. However, I have never tested this myself. Feel free to give it a try using the transceive(...) method of the plugin.

Android, on the other hand, offers the following two methods:

  1. authenticateSectorWithKeyA
  2. authenticateSectorWithKeyB

I guess these are the methods you are looking for. Both should be easy to implement.

@robingenz
Copy link
Member

@pefka Have you had a chance to test the transceive(...) on iOS? Are you interested in using the other two methods on Android? If so, I would put that on my todo list.

@robingenz robingenz self-assigned this Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants