I have an Identiv uTrust 3700 F CL Reader that I can't setup with on macOS Catalina 10.15.4. I would like to read NDEF Tags, use U2F (FIDO2 CTAP1) via NFC, and emulate a card from the reader (for other readers to read, like an Android or iOS device) where my host acts as the secure element.
My reader works great with opensc-tools
to list the reader. I suspect multiple processes are competing for the USB device.
This section from libnfc indicates a related device (the SCL3711, which is another Identiv contactless-only USB reader) can either choose to not use the proprietary driver or to disable PCSC entirely to use with nfc-tools. However this does not work for me on macOS (or Ubuntu). With the driver installed:
% LIBNFC_LOG_LEVEL=3 nfc-list -v
debug libnfc.config key: [allow_intrusive_scan], value: [yes]
debug libnfc.config Unable to open directory: /usr/local/Cellar/libnfc/1.7.1/etc/nfc/devices.d
debug libnfc.general log_level is set to 3
debug libnfc.general allow_autoscan is set to true
debug libnfc.general allow_intrusive_scan is set to true
debug libnfc.general 0 device(s) defined by user
nfc-list uses libnfc 1.7.1
debug libnfc.general 0 device(s) found using arygon driver
debug libnfc.general 0 device(s) found using pn532_uart driver
debug libnfc.general 0 device(s) found using ACR122S driver
debug libnfc.general 0 device(s) found using acr122_usb driver
debug libnfc.driver.acr122_pcsc PCSC device [Identiv uTrust 3700 F CL Reader] is not NFC capable or not supported by libnfc.
debug libnfc.general 0 device(s) found using acr122_pcsc driver
debug libnfc.general 0 device(s) found using pn53x_usb driver
No NFC device found.
With the driver uninstalled:
% sudo LIBNFC_LOG_LEVEL=3 nfc-list -v
debug libnfc.config key: [allow_intrusive_scan], value: [yes]
debug libnfc.config Unable to open directory: /usr/local/Cellar/libnfc/1.7.1/etc/nfc/devices.d
debug libnfc.general log_level is set to 3
debug libnfc.general allow_autoscan is set to true
debug libnfc.general allow_intrusive_scan is set to true
debug libnfc.general 0 device(s) defined by user
nfc-list uses libnfc 1.7.1
debug libnfc.general 0 device(s) found using arygon driver
debug libnfc.general 0 device(s) found using pn532_uart driver
debug libnfc.general 0 device(s) found using ACR122S driver
debug libnfc.general 0 device(s) found using acr122_usb driver
debug libnfc.general 0 device(s) found using acr122_pcsc driver
debug libnfc.general 0 device(s) found using pn53x_usb driver
No NFC device found.
This S.O. question is seems to offer the same advice:
... you could use the PC/SC based libnfc driver for the ACR122U (libnfc.driver.acr122_pcsc). This driver uses the system PC/SC daemon to access the reader instead of taking control over the USB interface directly. For this option to work, you need to configure lib-nfc to use the PC/SC driver instead of the direct USB driver. When you compile libnfc yourself, you could do this by explicitly activating only the PC/SC based driver:
/configure --with-drivers=acr122_pcsc make
However, note that this driver has been depreciated and libnfc authors strongly discourage its use.
I can't find the chip in my device but I suspect it is the popular pn53x (device 04e6:5790
).
Is there a preferred method today? Are other tools available to use on Linux and macOS to communicate with NFC readers and tags?
Edit: Although an answer to this question would be required to get NFC to work on macOS, it appears no browser currently supports this on desktop.
Right now I can access the card reader as a regular contactless smartcard reader (CCID via PC/SC) on macOS and Linux, but how can I use an NFC controller to get something like an ATS from an NFC tag instead of an ATR?