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

error libnfc.driver.acr122_usb Wrong reply #646

Open
amrbt opened this issue Jun 22, 2021 · 14 comments
Open

error libnfc.driver.acr122_usb Wrong reply #646

amrbt opened this issue Jun 22, 2021 · 14 comments

Comments

@amrbt
Copy link

amrbt commented Jun 22, 2021

Hello!

I'm stucked at this point with the libnfc 1.8.0 and do not find information about this error:

nfc-list -v 130 ⨯
nfc-list uses libnfc 1.8.0
NFC device: ACS / ACR122U PICC Interface opened
1 ISO14443A passive target(s) found:
ISO/IEC 14443A (106 kbps) target:
ATQA (SENS_RES): 00 04

  • UID size: single
  • bit frame anticollision supported
    UID (NFCID1): 67 32 64 c3
    SAK (SEL_RES): 08
  • Not compliant with ISO/IEC 14443-4
  • Not compliant with ISO/IEC 18092

Fingerprinting based on MIFARE type Identification Procedure:

  • MIFARE Classic 1K
  • MIFARE Plus (4 Byte UID or 4 Byte RID) 2K, Security level 1
  • SmartMX with MIFARE 1K emulation
    Other possible matches based on ATQA & SAK values:

error libnfc.driver.acr122_usb Wrong reply
0 Felica (212 kbps) passive target(s) found.

error libnfc.driver.acr122_usb Wrong reply
0 Felica (424 kbps) passive target(s) found.

error libnfc.driver.acr122_usb Wrong reply
0 ISO14443B passive target(s) found.

0 ISO14443B' passive target(s) found.

0 ISO14443B-2 ST SRx passive target(s) found.

0 ISO14443B-2 ASK CTx passive target(s) found.

0 ISO14443B iClass passive target(s) found.

error libnfc.driver.acr122_usb Wrong reply
0 ISO14443A-3 Jewel passive target(s) found.

0 ISO14443A-2 NFC Barcode passive target(s) found.

error libnfc.driver.acr122_usb Wrong reply

cat /etc/os-release
PRETTY_NAME="Kali GNU/Linux Rolling"
NAME="Kali GNU/Linux"
ID=kali
VERSION="2021.2"
VERSION_ID="2021.2"
VERSION_CODENAME="kali-rolling"
ID_LIKE=debian
ANSI_COLOR="1;31"
HOME_URL="https://www.kali.org/"
SUPPORT_URL="https://forums.kali.org/"
BUG_REPORT_URL="https://bugs.kali.org/"

uname -r
5.10.0-kali7-amd64

lsusb -v
Bus 002 Device 005: ID 072f:2200 Advanced Card Systems, Ltd ACR122U
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.10
bDeviceClass 0
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x072f Advanced Card Systems, Ltd
idProduct 0x2200 ACR122U
bcdDevice 2.14
iManufacturer 1 ACS
iProduct 2 ACR122U PICC Interface
iSerial 0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x005d
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 200mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 3
bInterfaceClass 11 Chip/SmartCard
bInterfaceSubClass 0
bInterfaceProtocol 0
iInterface 0
ChipCard Interface Descriptor:
bLength 54
bDescriptorType 33
bcdCCID 1.00
nMaxSlotIndex 0
bVoltageSupport 7 5.0V 3.0V 1.8V
dwProtocols 2 T=1
dwDefaultClock 4000
dwMaxiumumClock 4000
bNumClockSupported 0
dwDataRate 10752 bps
dwMaxDataRate 250000 bps
bNumDataRatesSupp. 0
dwMaxIFSD 256
dwSyncProtocols 00000000
dwMechanical 00000000
dwFeatures 00020040
Auto parameter negotiation made by CCID
Short APDU level exchange
dwMaxCCIDMsgLen 271
bClassGetResponse 00
bClassEnvelope 00
wlcdLayout none
bPINSupport 0
bMaxCCIDBusySlots 1
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0008 1x 8 bytes
bInterval 50
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x04 EP 4 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
can't get debug descriptor: Resource temporarily unavailable
Device Status: 0x0000
(Bus Powered)

@davidebeatrici
Copy link

davidebeatrici commented Apr 15, 2023

Possibly related to #666.

lsusb
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               1.10
  bDeviceClass            0 
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x072f Advanced Card Systems, Ltd
  idProduct          0x2200 ACR122U
  bcdDevice            2.14
  iManufacturer           1 ACS
  iProduct                2 ACR122U PICC Interface
  iSerial                 0 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength       0x005d
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0 
    bmAttributes         0x80
      (Bus Powered)
    MaxPower              200mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      bInterfaceClass        11 Chip/SmartCard
      bInterfaceSubClass      0 
      bInterfaceProtocol      0 
      iInterface              0 
      ChipCard Interface Descriptor:
        bLength                54
        bDescriptorType        33
        bcdCCID              1.00
        nMaxSlotIndex           0
        bVoltageSupport         7  5.0V 3.0V 1.8V 
        dwProtocols             2  T=1
        dwDefaultClock       4000
        dwMaxiumumClock      4000
        bNumClockSupported      0
        dwDataRate          10752 bps
        dwMaxDataRate      250000 bps
        bNumDataRatesSupp.      0
        dwMaxIFSD             256
        dwSyncProtocols  00000000 
        dwMechanical     00000000 
        dwFeatures       00020040
          Auto parameter negotiation made by CCID
          Short APDU level exchange
        dwMaxCCIDMsgLen       271
        bClassGetResponse      00
        bClassEnvelope         00
        wlcdLayout           none
        bPINSupport             0 
        bMaxCCIDBusySlots       1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0008  1x 8 bytes
        bInterval              50
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x04  EP 4 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0

With #678 applied on top of 42de50f:

LIBNFC_LOG_LEVEL=3
error   libnfc.driver.acr122_usb        PN532 init failed, trying again...
error   libnfc.driver.acr122_usb        Unexpected Status Word (SW1: 3b SW2: 00)
error   libnfc.driver.acr122_usb        PN532 init failed, trying again...
NFC device: ACS / ACR122U PICC Interface opened
error   libnfc.driver.acr122_usb        Command Code verification failed
error   libnfc.driver.acr122_usb        Wrong reply
error   libnfc.driver.acr122_usb        Wrong reply
error   libnfc.driver.acr122_usb        Wrong reply
error   libnfc.driver.acr122_usb        Command Code verification failed
error   libnfc.chip.pn53x       Buffer size is too short: 1 available(s), 2 needed
error   libnfc.driver.acr122_usb        Command Code verification failed
error   libnfc.driver.acr122_usb        Command Code verification failed
error   libnfc.driver.acr122_usb        Wrong reply
error   libnfc.driver.acr122_usb        Wrong reply
info    libnfc.config   Unable to open file: /etc/nfc/libnfc.conf
debug   libnfc.config   Unable to open directory: /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 false
debug   libnfc.general  0 device(s) defined by user
debug   libnfc.driver.acr122_usb        device found: Bus 003 Device 007 Name ACS ACR122
debug   libnfc.general  1 device(s) found using acr122_usb driver
debug   libnfc.driver.acr122_usb        3 element(s) have been decoded from "acr122_usb:003:007"
debug   libnfc.driver.acr122_usb        TX: 62 00 00 00 00 00 00 01 00 00 
debug   libnfc.driver.acr122_usb        RX: 80 08 00 00 00 00 00 02 81 00 d5 03 32 01 06 07 90 00 
debug   libnfc.driver.acr122_usb        ACR122 PICC Operating Parameters
debug   libnfc.driver.acr122_usb        TX: 6f 05 00 00 00 00 00 00 00 00 ff 00 51 00 00 
debug   libnfc.driver.acr122_usb        RX: 80 02 00 00 00 00 00 00 81 00 3b 00 
debug   libnfc.chip.pn53x       GetFirmwareVersion
debug   libnfc.driver.acr122_usb        TX: 6f 07 00 00 00 00 00 00 00 00 ff 00 00 00 02 d4 02 
debug   libnfc.driver.acr122_usb        RX: 80 08 00 00 00 00 00 02 81 00 d5 03 32 01 06 07 90 00 
debug   libnfc.chip.pn53x       SetParameters
debug   libnfc.driver.acr122_usb        TX: 6f 08 00 00 00 00 00 00 00 00 ff 00 00 00 03 d4 12 14 
debug   libnfc.driver.acr122_usb        RX: 80 04 00 00 00 00 00 02 81 00 d5 13 90 00 
debug   libnfc.general  "ACS / ACR122U PICC Interface" (acr122_usb:003:007) has been claimed.
debug   libnfc.general  set_property_bool NP_ACTIVATE_FIELD False
debug   libnfc.chip.pn53x       ReadRegister
debug   libnfc.driver.acr122_usb        TX: 6f 11 00 00 00 00 00 00 00 00 ff 00 00 00 0c d4 06 63 02 63 03 63 0d 63 38 63 3d 
debug   libnfc.driver.acr122_usb        RX: 80 09 00 00 00 00 00 02 81 00 d5 07 80 80 00 00 00 90 00 
debug   libnfc.chip.pn53x       RFConfiguration
debug   libnfc.driver.acr122_usb        TX: 6f 09 00 00 00 00 00 00 00 00 ff 00 00 00 04 d4 32 01 00 
debug   libnfc.driver.acr122_usb        RX: 80 04 00 00 00 00 00 02 81 00 d5 33 90 00 
debug   libnfc.general  set_property_bool NP_ACTIVATE_FIELD True
debug   libnfc.chip.pn53x       RFConfiguration
debug   libnfc.driver.acr122_usb        TX: 6f 09 00 00 00 00 00 00 00 00 ff 00 00 00 04 d4 32 01 01 
debug   libnfc.driver.acr122_usb        RX: 80 04 00 00 00 00 00 02 81 00 d5 33 90 00 
debug   libnfc.general  set_property_bool NP_INFINITE_SELECT True
debug   libnfc.chip.pn53x       RFConfiguration
debug   libnfc.driver.acr122_usb        TX: 6f 0b 00 00 00 00 00 00 00 00 ff 00 00 00 06 d4 32 05 ff ff ff 
debug   libnfc.driver.acr122_usb        RX: 80 04 00 00 00 00 00 02 81 00 d5 33 90 00 
debug   libnfc.general  set_property_bool NP_AUTO_ISO14443_4 True
debug   libnfc.general  set_property_bool NP_FORCE_ISO14443_A True
debug   libnfc.general  set_property_bool NP_FORCE_SPEED_106 True
debug   libnfc.general  set_property_bool NP_ACCEPT_INVALID_FRAMES False
debug   libnfc.general  set_property_bool NP_ACCEPT_MULTIPLE_FRAMES False
NFC reader: ACS / ACR122U PICC Interface opened
NFC device will poll during 36000 ms (20 pollings of 300 ms for 6 modulations)
debug   libnfc.chip.pn53x       ReadRegister
debug   libnfc.driver.acr122_usb        TX: 6f 13 00 00 00 00 00 00 00 00 ff 00 00 00 0e d4 06 63 02 63 03 63 05 63 38 63 3c 63 3d 
debug   libnfc.driver.acr122_usb        RX: 80 0a 00 00 00 00 00 02 81 00 d5 07 80 80 43 00 00 00 90 00 
debug   libnfc.chip.pn53x       PN53X_REG_CIU_Control (Contains miscellaneous control bits)
debug   libnfc.chip.pn53x       WriteRegister
debug   libnfc.driver.acr122_usb        TX: 6f 0a 00 00 00 00 00 00 00 00 ff 00 00 00 05 d4 08 63 3c 10 
debug   libnfc.driver.acr122_usb        RX: 80 04 00 00 00 00 00 02 81 00 d5 09 90 00 
debug   libnfc.chip.pn53x       InAutoPoll
debug   libnfc.chip.pn53x       No timeout
debug   libnfc.driver.acr122_usb        TX: 6f 10 00 00 00 00 00 00 00 00 ff 00 00 00 0b d4 60 14 02 20 10 03 11 12 04 03 
debug   libnfc.driver.acr122_usb        RX: 80 00 00 00 00 00 00 02 81 00 
error   libnfc.driver.acr122_usb        Wrong reply
nfc_initiator_poll_target: Input / Output Error
debug   libnfc.driver.acr122_usb        ACR122 Abort
debug   libnfc.driver.acr122_usb        TX: 6f 07 00 00 00 00 00 00 00 00 ff 00 00 00 02 d4 02 
debug   libnfc.driver.acr122_usb        RX: 80 08 00 00 00 00 00 02 81 00 d5 03 32 01 06 07 90 00 
debug   libnfc.chip.pn53x       InRelease
debug   libnfc.driver.acr122_usb        TX: 6f 08 00 00 00 00 00 00 00 00 ff 00 00 00 03 d4 52 00 
debug   libnfc.driver.acr122_usb        RX: 80 00 00 00 00 00 00 02 81 00 
error   libnfc.driver.acr122_usb        Wrong reply
Device

ACR122U

@davidebeatrici
Copy link

davidebeatrici commented Apr 16, 2023

Please note that the device appears to be working just fine with pcscd and https://github.com/Flowtter/py-acr122u:

However, shutting down the daemon doesn't seem to be "resetting" the device as it just goes into timeout upon relaunching, with the green LED stuck.

@davidebeatrici
Copy link

davidebeatrici commented Apr 21, 2023

I acquired another seemingly identical device, this time with a mini CD included. Here's the SDK that is provided: ACR122U_SDK.zip

The problem is that this other device works just fine with #678 applied. I wonder whether we're dealing with a defective and/or fake chip batch...

Alternatively, it could have different factory settings. On the device that is working the LED never turns on, on the other one it's red and turns to green when it detects an NFC tag.

@dkdk22
Copy link

dkdk22 commented Dec 11, 2023

Is the mentioned error resolved? I'm experiencing the same issue.

@Gapoly
Copy link

Gapoly commented Feb 26, 2024

Same problem here. I've tried using my ACR122U on 4 diffirents OS, 2 different machines:

  • Kali 2023.4
  • Debian 12
  • Ubuntu Server 22.04.4 LTS
  • Kubuntu 22.04.4 LTS

All with the same problem, "error libnfc.driver.acr122_usb Wrong reply"
Hopefully the problem comes from the device and getting another one will fix my issue.

@Gapoly
Copy link

Gapoly commented Feb 29, 2024

Update: I've bought a new one and I don't have the error anymore. Either the other guy sold me a fake or it was damaged.

@davidebeatrici
Copy link

Could you send here a picture of the device's back, please?

@Gapoly
Copy link

Gapoly commented Mar 3, 2024

Could you send here a picture of the device's back, please?

Same back as the old one I had
IMG_20240303_153957

@davidebeatrici
Copy link

Interesting... in that case there may be no easy way to determine whether a specific reader is going to work.

@italodeveloper
Copy link

Could you send here a picture of the device's back, please?

Same back as the old one I had IMG_20240303_153957

Is this the device working or defective? I bought a defective one the serial number starts with RR171-XX

@davidebeatrici
Copy link

My non-working device's serial number begins with RR171- too (#646 (comment)).

Now that I'm rereading the comments I realized @Gapoly's one is unclear. Back when I replied I assumed he meant the fake/defective had the same SN prefix.

@italodeveloper
Copy link

O número de série do meu dispositivo que não funciona começa com RR171-( #646 (comentário) ).

Agora que estou relendo os comentários percebi@Gapoly's one não está claro. Quando respondi, presumi que ele queria dizer que o falso/defeituoso tinha o mesmo prefixo SN.

That's right, my reader with the problem is also the RR171-XX. This reader that he posted in the photo is not clear if it has the problem or if it was the one that worked, I got it with the same initial serial number to buy RR545-XX but it didn't I wanted to waste time, if I answer if this RR545 model works I would be grateful

@davidebeatrici
Copy link

Please note that I have a working device also beginning with RR171-.

@Gapoly
Copy link

Gapoly commented Nov 20, 2024

I just recently went back to NFC and I found the problem. Yes, I had a bad ACR then bought another one which works. The main problem is that I bought some Mifare Classic 1K Gen1 (bad product from aliexpress), you can't change UID on Gen1.

I bought some Gen2 that works on Mifare Classic Tool only and it works, I can change the UID. I'm looking for some Mifare Classic 1K Gen2 that works with nfc-mfclassic. Not a lot of choice in Europe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants