github-af / SmartPGP

SmartPGP is a JavaCard implementation of the OpenPGP card specifications
GNU General Public License v2.0
232 stars 48 forks source link

NFC Usage "Conditions of use not satisfied" #24

Closed jank04 closed 4 years ago

jank04 commented 4 years ago

Hello

Problem-Description

I am encountering issues by using this applet via NFC. On my phone with OpenKeychain PGP does work fine (encrypting/decrypting). However, when I try to decrypt an email on my computer via NFC and this card I am getting this error code: "Conditions of use not satisfied".

When I try to change some stats like sex or language or even the PUK (reset-code) I get the same error (gpg.exe) but list card information works (gpg.exe --card-status). *edit gpg --card-edit verify leads to the same error.

When I do not use NFC and use the physical contacts, everything works fine. With other applets the NFC interface works like the physical contacts.

Is this a applet related problem or maybe a faulty smartcard reader / gpg software?

Thank you

Outputs: gpg.exe --card-status

PS C:> gpg --card-status Reader ...........: REINER SCT cyberJack RFID standard USB 1 Application ID ...: D276000124010303FF01xx Version ..........: 3.3 Manufacturer .....: unmanaged S/N range Serial number ....: 4Axx Name of cardholder: xx Language prefs ...: de Sex ..............: männlich URL of public key : https://xxxx Login data .......: xx Signature PIN ....: zwingend Key attributes ...: rsa2048 rsa2048 rsa2048 Max. PIN lengths .: 127 127 127 PIN retry counter : 3 3 3 Signature counter : 145 KDF setting ......: on Signature key ....: EDxx created ....: 2019-10-16 19:52:04 Encryption key....: 4Dxx created ....: 2019-10-16 19:52:04 Authentication key: 84xx created ....: 2019-10-16 19:52:04 General key info..: pub rsa2048/xx 2019-10-16 jan.xx@xx.net sec> rsa2048/35xx erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01xx ssb> rsa2048/E8xx erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 xx ssb> rsa2048/E9xx erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 xx

gpg.exe passwd

gpg/card> passwd gpg: OpenPGP Karte Nr. D2xx erkannt

1 - change PIN 2 - unblock PIN 3 - change Admin PIN 4 - set the Reset Code Q - quit

Ihre Auswahl? 4 Error setting the Reset Code: Nutzungsvorraussetzungen nicht erfüllt (Condition of use not satisfied)

gp.exe --info (NXP J3D081 JCOP v2.4.2 R2 80 KB (JavaCard 3.0.1 Classic))

PS C:> gp.exe --info GlobalPlatformPro 19.06.16-0-gbaccf34 Running on Windows 10 10.0 amd64, Java 1.8.0_251 by Oracle Corporation Reader: REINER SCT cyberJack RFID standard USB 1 ATR: 3B8980014A434F5032343252324A More information about your card: http://smartcard-atr.appspot.com/parse?ATR=3B8980014A434F5032343252324A

[WARN] GPData - Invalid CPLC date: 3B30 CPLC: ICFabricator=4790 ICType=5183 OperatingSystemID=4791 OperatingSystemReleaseDate=2081 (2012-03-21) OperatingSystemReleaseLevel=3B00 ICFabricationDate=2283 (2012-10-09) ICSerialNumber=00312596 ICBatchIdentifier=3643 ICModuleFabricator=0000 ICModulePackagingDate=0000 (2010-01-01) ICCManufacturer=0000 ICEmbeddingDate=0000 (2010-01-01) ICPrePersonalizer=0916 ICPrePersonalizationEquipmentDate=3B30 (invalid date format) ICPrePersonalizationEquipmentID=33313235 ICPersonalizer=0000 ICPersonalizationDate=0000 (2010-01-01) ICPersonalizationEquipmentID=00000000

Card Data: Tag 6: 1.2.840.114283.1 -> Global Platform card Tag 60: 1.2.840.114283.2.2.2 -> GP Version: 2.2 Tag 63: 1.2.840.114283.3 Tag 64: 1.2.840.114283.4.2.85 -> GP SCP02 i=55 Tag 65: 1.3.656.840.100.2.1.3 Tag 66: 1.3.6.1.4.1.42.2.110.1.2 -> JavaCard v2 Card Capabilities: Version: 1 (0x01) ID: 1 (0x01) type: DES3 length: 16 Version: 1 (0x01) ID: 2 (0x02) type: DES3 length: 16 Version: 1 (0x01) ID: 3 (0x03) type: DES3 length: 16

af-anssi commented 4 years ago

Which branch and version of the SmartPGP applet do you use ?

jank04 commented 4 years ago

I compiled this applet about half a year ago. I can not remember for sure but I think it was from a Release and I have chosen the right (3.0.1) version. I sill have the source files, but I can not find there any information about the version. Is there any information inside some files given, where I can look?

Is it possible, that I have choosen 3.0.4 and everything works (NFC on my phone/physical contact) only except of nfc on my pc? My SmartCard reader on my PC is a Pin-Pad with display. When I use the physical contacts, the reader shows in the display to enter the pin, and this works.

af-anssi commented 4 years ago

Do you remember if you followed the Setting up secure messaging with OpenKeychain ?

jank04 commented 4 years ago

I did not read this. I created my keys and email setup with gpg itself (by using Kleopatra). I am able to encrypt and decrypt emails physicly on my computer and contactless on my phone using OpenKeychain (in combination with K9-Mail; there is an integration) but not contactless on my computer. I provided a public-key URL inside my card from which OpenKeychain imported everything properly. (Just hold the card to the phone, Openkeychain recognizes it, look up the url and import the public key from the webserver, then ask for the user pin and voila my Smartcard works on my phone) My usecase has nothing to do with CAs and so on but only with pure gpg email sign and en/decrypt functionality.

*edited

af-anssi commented 4 years ago

If you did not activate the SecureMessaging on your card, I think the problem is not the applet. If you activated the SecureMessaging feature on your card, this is "normal" that you have a problem in contactless with GnuPG as GnuPG does not support the SecureMessaging.

jank04 commented 4 years ago

When I did not follow those instructions "Setting up secure messaging with OpenKeychain" SecureMessaging is deactivated? That means my card reader or GnuPG is the problem here (which can not handle NFC connections). In fact pkcs#11 applets are working on my pc via contactless.

I have read somewhere, that maybe the card reader misinterprets the VERIFY command, or any command, that response with a pin promt and then fails. For a very short amount of time the card reader promts to enter a pin, but than crashes because maybe some returned values to the reader are misinterpreted. I am still wondering why the contact method works and the contactless method does not. This are the same commands, but only different transreceiving-methods/interfaces, right?

Maybe I try your newer releases one day, when I have a new card.

af-anssi commented 4 years ago

By default SecureMesaging is disabled. I have not had a look recently to OpenKeychain, but I don't think it activates it without any user consent. The commands are indeed the same in contact and in contactless modes. However, the software on your computer which drives the card (windows, libopensc-pkcs11, gnupg, ...) needs to do some operations to activate and use the pinpad. If you do encounter the problem only with GnuPG, my guess is this is a problem between GnuPG and your contactless reader because of the pinpad. Could you retry the operation which fails in contactless, and immediately after execute only gpg.exe --card-status ? You should see the PIN retry counter is decremented (there should be a 2 instead of a 3 on the line). It will indicate this is actually a problem with the VERIFY command, and thus that the problem is indeed between GnuPG and your reader.

jank04 commented 4 years ago

Ok. But what makes me wondering is in fact, that both the pin-pad and display are working in contact mode, so if the commands are the same, which they should be, this should also work in contactless mode. I have tried your suggestion and there is no retry counter decrementing.

What I have done

Looks like the pin command fails and the device does not send any login credentials back. So stage 1 to transmit login promt to reader fails. I think I only get a E_BAD_PIN and therefor a deincrement retry count, if the device successfully transmits a pin to the card which seems not to be the case here.

I would like to look at the communication between the card and the reader, so we can see which commands and parameters are sent or sent back. I have a scdaemon.exe here, but I dont know how to use it. It is a CLI which gives me no output. With --daemon --verbose I only get a line: scdaemon[6920]: Es wird auf Socket C:\Users\Jan Kleefeld\AppData\Roaming\gnupg\S.scdaemon gehört

jank04 commented 4 years ago

I used APDUTrace from here: https://www.mysmartlogon.com/knowledge-base/trace-apdu-on-windows/ Don't know if this is the correct tool. However this is the output by performing the gpg.exe --edit-card verify command. Maybe this helps. Or maybe you can suggest a better tool.

Contact-Mode & Wrong PIN entered 2020-05-07 18:06:19,00 CA 00 C4 00 2020-05-07 18:06:19,00 7F 7F 7F 03 03 03 90 00 2020-05-07 18:06:26,00 CA 00 6E 00 2020-05-07 18:06:26,6E 81 D9 4F 10 D2 76 00 01 24 01 03 03 FF 01 4A 41 4E 31 00 00 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A 7F 00 00 20 04 80 00 FF 00 00 C1 06 01 08 00 00 11 03 C2 06 01 08 00 00 11 03 C3 06 01 08 00 00 11 03 C4 07 00 7F 7F 7F 02 03 03 C5 3C ED D4 4C D0 7D 7B B2 BE B2 6E BC C3 35 BD AC 6E 5B 69 2B C2 4D 56 BE 94 69 E8 07 59 88 A1 70 08 E9 6F A1 A1 F3 BE 83 93 84 F3 EE EB 9B 70 82 4D 07 1C A2 6A E8 2E D8 F8 30 0D F6 B8 C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5D A7 74 E4 5D A7 74 E4 5D A7 74 E4 90 00 2020-05-07 18:06:26,00 CA 00 C4 00 2020-05-07 18:06:26,00 7F 7F 7F 02 03 03 90 00 2020-05-07 18:06:26,00 CA 00 7A 00 2020-05-07 18:06:26,93 03 00 00 91 90 00


Contactless-Mode (PIN entry crashed/not shown) 2020-05-07 18:09:23,00 CA 00 C4 00 2020-05-07 18:09:23,00 7F 7F 7F 02 03 03 90 00 2020-05-07 18:09:24,00 CA 00 6E 00 2020-05-07 18:09:24,6E 81 D9 4F 10 D2 76 00 01 24 01 03 03 FF 01 4A 41 4E 31 00 00 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A 7F 00 00 20 04 80 00 FF 00 00 C1 06 01 08 00 00 11 03 C2 06 01 08 00 00 11 03 C3 06 01 08 00 00 11 03 C4 07 00 7F 7F 7F 02 03 03 C5 3C ED D4 4C D0 7D 7B B2 BE B2 6E BC C3 35 BD AC 6E 5B 69 2B C2 4D 56 BE 94 69 E8 07 59 88 A1 70 08 E9 6F A1 A1 F3 BE 83 93 84 F3 EE EB 9B 70 82 4D 07 1C A2 6A E8 2E D8 F8 30 0D F6 B8 C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5D A7 74 E4 5D A7 74 E4 5D A7 74 E4 90 00 2020-05-07 18:09:24,00 CA 00 C4 00 2020-05-07 18:09:24,00 7F 7F 7F 02 03 03 90 00 2020-05-07 18:09:24,00 CA 00 7A 00 2020-05-07 18:09:24,93 03 00 00 91 90 00


martinpaljak commented 4 years ago

Maybe the reader rejects plain PIN commands on contactless interface? Would be similarly a sane option, if it already featured a firewall (as speculated). Nevertheless, this might be of interest: https://ccid.apdu.fr/ccid/disabled.html#0x0C4B0x0500

jank04 commented 4 years ago

Okey I guess you mean that the entered PIN-Code is plain transmitted via NFC und therefor this feature is disabled? I heard something about Secoder 2 and "firewall". But why can I use the contactless function in another applet? It is a pkcs#11 applet and when I use it for ssh auth for example, I can use it contactless. In addition the Pin-Entry is not on the pin-pad, but in a Windows Pin-Promt. See attachment image

*edit: Yes this is exactly my card reader.

af-anssi commented 4 years ago

Could you checkout any branch of the projet, execute the following command from the bindirectory with your card "on" your reader, and publish here the result of the command ?

./smartpgp-cli -I -o pub.der get-sm-key

This command retrieves the current secure messaging public key from the card, if it exists. If such key exists in the card, it means secure messaging is activated in the applet and it explains the problem you encounter. If there is no key defined, then the problem does not come from the applet.

jank04 commented 4 years ago

Input: C:\SmartCard\SmartPGP\bin>python ./smartpgp-cli -I -o pub.der get-sm-key Unknown command 'get-sm-key' Run './smartpgp-cli -h' for help

Output of command-list of help: positional arguments: command The command. Valid commands are: unblock-pin, decrypt- aes, put-auth-certificate, switch-bp512, get-kdf, switch-bp256, put-sm-certificate, switch-bp384, switch-p384, full-reset, put-sm-key, set-kdf, generate-sm-key, switch-p521, put-sign-certificate, switch-rsa, encrypt-aes, reset, get-sm-certificate, switch-p256, put-aes-key, set-resetting-code, list- readers'

Then I tryed: python ./smartpgp-cli -I -o pub.der get-sm-certificate Output: Select OpenPGP Applet 90 00 Selecting SM certificate 90 00 Receiving SM certificate chunk 6A 88

Created pub.der file is emty.

However the -I, --interactive Ask Admin PIN interactively parameter does not come into play.

__ I also tryed python smartpgp-cli set-resetting-code -r 0 -i 123456789123 -o output.txt -I Output: Select OpenPGP Applet 90 00 Enter Admin PIN: Verify Admin PIN 90 00 Enter PUK PIN: Define the resetting code (PUK) 90 00

I wanted to see, if the PIN-Pad is working in interactive mode. However the admin-pin is beeing asked but it does not show up on pin-pad. The question now is, why can't I enter the pin wehen asked for decryption (for mail decryption for example) either on the pin pad or a pin promt?

af-anssi commented 4 years ago

I just committed the get-sm-key command this morning; cand you checkout (or pull) and execute the command ?

jank04 commented 4 years ago

Of course.

Input python smartpgp-cli -I -o pub.der get-sm-key

output Select OpenPGP Applet 90 00 Get SM key 6A 80 get_sm_key failed

af-anssi commented 4 years ago

Ok so you have no secure messaging setup in the applet. So the "conditions not satisfied" message do not come from the applet. I suspect GnuPG/scdaemon.

jank04 commented 4 years ago

Do you know, if there is any possibility to debug this? Maybe catching information from scdeamon?

Thank you very much for your assistence so far.

af-anssi commented 4 years ago

You can manually launch scdaemon with --daemon --debug-level advanced --log-file scdaemon.log. You have to ensure there is no other running scdaemon before to launch it manually.

Be carfeul with this command because it will expose sensitive data (e.g. PIN codes) in the log file.

jank04 commented 4 years ago

Thanks. Unfortunately GnuPG starts a new instance of scdaemon.exe. I have killed scdaemon and startet it with above paramerts manually. But GPG starts another scdaemon.exe and does not use "my" scdaemon. As a result, I get no output and cannot debug. However this has nothing to do with this applet. Of course I am glad, if you have another advice, but I want you to know, that I do not want to abuse this issue thread for other problems.

jaredvacanti commented 4 years ago

I apologize for originally opening a separate issue, but after re-reading this thread I think they may be related. I initially thought @jank04 was accessing the card on a desktop through an NFC-chip reader using https://github.com/nfc-tools/libnfc or some other tool. If the connection is over CCID, then I believe they are the same issue. I am using a uTrust 3700 F Contactless Smart Card Reader with NFC support, which is CCID-compliant.

Should there be any distinction between NFC and NFC over CCID? It seems like I get a "massaged" ATR instead of using an NFC controller to get something like an ATS from an NFC tag.

af-anssi commented 4 years ago

@jank04 could you dump (without too sensitive information) the output of gpg.exe --card-status in contact mode AND then in contactless mode ?

jank04 commented 4 years ago

Sure.

PS C:\> gpg.exe --card-status

Contact-Mode Reader ...........: REINER SCT cyberJack RFID standard USB 1 Application ID ...: D276000124010303FF014A414XXX0000 Version ..........: 3.3 Manufacturer .....: unmanaged S/N range Serial number ....: 4A414XXX Name of cardholder: Jan XXXX Language prefs ...: de Sex ..............: männlich URL of public key : https://XXX/public/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.asc Login data .......: Jan XXXX Signature PIN ....: zwingend Key attributes ...: rsa2048 rsa2048 rsa2048 Max. PIN lengths .: 127 127 127 PIN retry counter : 3 3 3 Signature counter : 181 KDF setting ......: on Signature key ....: XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX created ....: 2019-10-16 19:52:04 Encryption key....: XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX created ....: 2019-10-16 19:52:04 Authentication key: XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX created ....: 2019-10-16 19:52:04 General key info..: pub rsa2048/35BDAC6E5B69XXXX 2019-10-16 XXX@XXX sec> rsa2048/35BDAC6E5B69XXXX erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 4A414XXX ssb> rsa2048/E82ED8F8300DXXXX erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 4A414XXX ssb> rsa2048/E96FA1A1F3BEXXXX erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 4A414XXX

Contactless-Mode Reader ...........: REINER SCT cyberJack RFID standard USB 1 Application ID ...: D276000124010303FF014A414XXX0000 Version ..........: 3.3 Manufacturer .....: unmanaged S/N range Serial number ....: 4A414XXX Name of cardholder: Jan XXXXX Language prefs ...: de Sex ..............: männlich URL of public key : https://XXX/public/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.asc Login data .......: Jan XXXXX Signature PIN ....: zwingend Key attributes ...: rsa2048 rsa2048 rsa2048 Max. PIN lengths .: 127 127 127 PIN retry counter : 3 3 3 Signature counter : 181 KDF setting ......: on Signature key ....: XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX created ....: 2019-10-16 19:52:04 Encryption key....: XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX created ....: 2019-10-16 19:52:04 Authentication key: XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX created ....: 2019-10-16 19:52:04 General key info..: pub rsa2048/35BDAC6E5B692BC2 2019-10-16 XXX@XXX sec> rsa2048/35BDAC6E5B69XXXX erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 4A414XXX ssb> rsa2048/E82ED8F8300DXXXX erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 4A414XXX ssb> rsa2048/E96FA1A1F3BEXXXX erzeugt: 2019-10-16 verfällt: niemals Kartennummer:FF01 4A414XXX

22h49 commented 4 years ago

Having the same issue here, I'm also using a REINERSCT Cyberjack Standard reader (It's dual interface) And when I insert my card into the contact slot I can sign things and I can use passwd, however if I insert the card into the contactless slot this happends when I try to sign something:

gpg: signing failed: Conditions of use not satisfied gpg: signing failed: Conditions of use not satisfied

Reader ...........: REINER SCT cyberJack RFID standard (9934036502) 00 00 Application ID ...: D276000124010304BEEF000000000007 Application type .: OpenPGP Version ..........: 3.4 Manufacturer .....: unknown Serial number ....: 00000000 Name of cardholder: [not set] Language prefs ...: en Salutation .......: URL of public key : [not set] Login data .......: [not set] Signature PIN ....: forced Key attributes ...: rsa4096 rsa4096 rsa3072 Max. PIN lengths .: 127 127 127 PIN retry counter : 3 0 3 Signature counter : 1 KDF setting ......: off Signature key ....: 20D5 5D9F 1664 6D60 48FB FF97 3BE4 B14B F07D 708B created ....: 2020-09-14 15:52:07 Encryption key....: E967 86E8 FB78 A997 67B4 1D04 C6CA 0D65 7CAC EB90 created ....: 2020-09-14 15:57:31 Authentication key: 07A2 F7DA 9FC5 33CB 2B60 06B6 9041 483E 3635 C070 created ....: 2020-09-14 15:56:36 General key info..: pub rsa4096/3BE4B14BF07D708B 2020-09-14 sec> rsa4096/3BE4B14BF07D708B created: 2020-09-14 expires: never card-no: BEEF 00000000 ssb> rsa3072/9041483E3635C070 created: 2020-09-14 expires: never card-no: BEEF 00000000 ssb> rsa4096/C6CA0D657CACEB90 created: 2020-09-14 expires: never card-no: BEEF 00000000

22h49 commented 4 years ago

I too have secure messaging disabled.

I don't know if this helps but here are log dumps:

Card's list command (same on both interfaces):

Reader ...........: REINER SCT cyberJack RFID standard (9934036502) 00 00
Application ID ...: D276000124010304BEEF000000000007
Application type .: OpenPGP
Version ..........: 3.4
Manufacturer .....: unknown
Serial number ....: 00000000
Name of cardholder: bac  
Language prefs ...: en
Salutation .......: 
URL of public key : [not set]
Login data .......: [not set]
Signature PIN ....: not forced
Key attributes ...: rsa4096 rsa4096 rsa3072
Max. PIN lengths .: 127 127 127
PIN retry counter : 3 0 3
Signature counter : 4
KDF setting ......: off
Signature key ....: 0353 CB0B 67EA AADE 39A5  B54F E8D6 EC89 1A92 2CE4
      created ....: 2020-11-13 18:32:45
Encryption key....: 03FC FCB0 49FF E397 337B  4B3F F9BE BBC9 CCB3 DEA9
      created ....: 2020-11-13 18:32:45
Authentication key: 526C E0A2 9AC4 F6B3 F6D1  2B67 BADC ADFD C2AC 5D9F
      created ....: 2020-11-13 18:32:45
General key info..: 
pub  rsa4096/E8D6EC891A922CE4 2020-11-13 Test key
sec>  rsa4096/E8D6EC891A922CE4  created: 2020-11-13  expires: never     
                                card-no: BEEF 00000000
ssb>  rsa3072/BADCADFDC2AC5D9F  created: 2020-11-13  expires: never     
                                card-no: BEEF 00000000
ssb>  rsa4096/F9BEBBC9CCB3DEA9  created: 2020-11-13  expires: never     
                                card-no: BEEF 00000000

Pcscd_scan when Taking the card and exchanging interfaces:

0: REINER SCT cyberJack RFID standard (9934036502) 00 00

Fri Nov 13 19:43:53 2020
 Reader 0: REINER SCT cyberJack RFID standard (9934036502) 00 00
  Event number: 2
  Card state: Card removed, 

Fri Nov 13 19:43:57 2020
 Reader 0: REINER SCT cyberJack RFID standard (9934036502) 00 00
  Event number: 3
  Card state: Card inserted, 
  ATR: 3B 94 95 81 01 46 54 56 01 C4

ATR: 3B 94 95 81 01 46 54 56 01 C4
+ TS = 3B --> Direct Convention
+ T0 = 94, Y(1): 1001, K: 4 (historical bytes)
  TA(1) = 95 --> Fi=512, Di=16, 32 cycles/ETU
    125000 bits/s at 4 MHz, fMax for Fi = 5 MHz => 156250 bits/s
  TD(1) = 81 --> Y(i+1) = 1000, Protocol T = 1 
-----
  TD(2) = 01 --> Y(i+1) = 0000, Protocol T = 1 
-----
+ Historical bytes: 46 54 56 01
  Category indicator byte: 46 (proprietary format)
+ TCK = C4 (correct checksum)

Possibly identified card (using /usr/share/pcsc/smartcard_list.txt):
3B 94 95 81 01 46 54 56 01 C4
    blank J3H145 card (Other)

Fri Nov 13 19:43:59 2020
 Reader 0: REINER SCT cyberJack RFID standard (9934036502) 00 00
  Event number: 4
  Card state: Card removed, 

Fri Nov 13 19:44:02 2020
 Reader 0: REINER SCT cyberJack RFID standard (9934036502) 00 00
  Event number: 5
  Card state: Card inserted, 
  ATR: 3B 80 80 01 01

ATR: 3B 80 80 01 01
+ TS = 3B --> Direct Convention
+ T0 = 80, Y(1): 1000, K: 0 (historical bytes)
  TD(1) = 80 --> Y(i+1) = 1000, Protocol T = 0 
-----
  TD(2) = 01 --> Y(i+1) = 0000, Protocol T = 1 
-----
+ Historical bytes: 
+ TCK = 01 (correct checksum)

Possibly identified card (using /usr/share/pcsc/smartcard_list.txt):
3B 80 80 01 01
    ISO 14443 Type B without historical bytes
    Electronic Passport
    Spanish passport (2012)
    Canadian Passport
    Venez_Prox

Here are the commands I typed and their respective output

Contact:

h39@Auriel ~/Downloads > gpg -vvv -s testfile
gpg: using character set 'utf-8'
gpg: writing to 'testfile.gpg'
gpg: pinentry launched (51412 gnome3 1.1.0 /dev/pts/0 xterm-256color :1)
gpg: RSA/SHA512 signature from: "E8D6EC891A922CE4 Test key"

Contactless:

h39@Auriel ~/Downloads> gpg -vvv -s testfile
gpg: using character set 'utf-8'
File 'testfile.gpg' exists. Overwrite? (y/N) y
gpg: writing to 'testfile.gpg'
gpg: pinentry launched (51454 gnome3 1.1.0 /dev/pts/0 xterm-256color :1)
gpg: signing failed: Conditions of use not satisfied
gpg: signing failed: Conditions of use not satisfied

And finnaly pcscd's log:

03900506 [140366865852160] hotplug_libudev.c:655:HPEstablishUSBNotifications() USB Device add
00000234 [140366865852160] hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x0C4B, PID: 0x0500, path: /dev/bus/usb/001/014
00000016 [140366865852160] hotplug_libudev.c:440:HPAddDevice() Adding USB device: REINER SCT cyberJack RFID standard
00000054 [140366865852160] readerfactory.c:1074:RFInitializeReader() Attempting startup of REINER SCT cyberJack RFID standard (9934036502) 00 00 using /usr/lib/pcsc/drivers/libifd-cyberjack.bundle/Contents/Linux/libifd-cyberjack.so
CYBERJACK: Started
00001790 [140366865852160] readerfactory.c:950:RFBindFunctions() Loading IFD Handler 3.0
02092822 [140366865852160] readerfactory.c:391:RFAddReader() Using the pcscd polling thread
07477005 [140366770595584] eventhandler.c:406:EHStatusHandlerThread() powerState: POWER_STATE_POWERED
00000032 [140366770595584] eventhandler.c:423:EHStatusHandlerThread() Card inserted into REINER SCT cyberJack RFID standard (9934036502) 00 00
00000026 [140366770595584] Card ATR: 3B 80 80 01 01 
00400366 [140366770595584] eventhandler.c:482:EHStatusHandlerThread() powerState: POWER_STATE_UNPOWERED
02424729 [140366770595584] eventhandler.c:358:EHStatusHandlerThread() Card Removed From REINER SCT cyberJack RFID standard (9934036502) 00 00
01587089 [140366770595584] eventhandler.c:406:EHStatusHandlerThread() powerState: POWER_STATE_POWERED
00000022 [140366770595584] eventhandler.c:423:EHStatusHandlerThread() Card inserted into REINER SCT cyberJack RFID standard (9934036502) 00 00
00000010 [140366770595584] Card ATR: 3B 94 95 81 01 46 54 56 01 C4 
00400575 [140366770595584] eventhandler.c:482:EHStatusHandlerThread() powerState: POWER_STATE_UNPOWERED
03735577 [140366874249152] winscard_msg_srv.c:256:ProcessEventsServer() Common channel packet arrival
00000031 [140366874249152] winscard_msg_srv.c:267:ProcessEventsServer() ProcessCommonChannelRequest detects: 14
00000012 [140366874249152] pcscdaemon.c:133:SVCServiceRunLoop() A new context thread creation is requested: 14
00000176 [140366762202880] winscard_svc.c:340:ContextThread() Authorized PC/SC client
00000013 [140366762202880] winscard_svc.c:343:ContextThread() Thread is started: dwClientID=14, threadContext @0x560a0ee01f20
00000011 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_VERSION from client 14
00000007 [140366762202880] winscard_svc.c:373:ContextThread() Client is protocol version 4:4
00000004 [140366762202880] winscard_svc.c:396:ContextThread() CMD_VERSION rv=0x0 for client 14
00000086 [140366762202880] winscard_svc.c:361:ContextThread() Received command: ESTABLISH_CONTEXT from client 14
00000114 [140366762202880] winscard.c:215:SCardEstablishContext() Establishing Context: 0xA6D81FD
00000006 [140366762202880] winscard_svc.c:461:ContextThread() ESTABLISH_CONTEXT rv=0x0 for client 14
00000085 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_GET_READERS_STATE from client 14
00000071 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_GET_READERS_STATE from client 14
00000140 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CONNECT from client 14
00000023 [140366762202880] winscard_svc.c:499:ContextThread() Authorized client for 'REINER SCT cyberJack RFID standard (9934036502) 00 00'
00000009 [140366762202880] winscard.c:258:SCardConnect() Attempting Connect to REINER SCT cyberJack RFID standard (9934036502) 00 00 using protocol: 3
00000012 [140366762202880] readerfactory.c:821:RFReaderInfo() RefReader() count was: 1
00044154 [140366762202880] winscard.c:332:SCardConnect() power up complete.
00000026 [140366762202880] Card ATR: 3B 94 95 81 01 46 54 56 01 C4 
00000008 [140366762202880] winscard.c:352:SCardConnect() powerState: POWER_STATE_IN_USE
00000007 [140366762202880] prothandler.c:107:PHSetProtocol() Attempting PTS to T=1
00011078 [140366762202880] winscard.c:430:SCardConnect() Active Protocol: T=1
00000023 [140366762202880] winscard.c:456:SCardConnect() hCard Identity: 5ed3ae47
00000009 [140366762202880] winscard.c:518:SCardConnect() UnrefReader() count was: 2
00000010 [140366762202880] winscard_svc.c:513:ContextThread() CONNECT rv=0x0 for client 14
00000135 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CONTROL from client 14
00000018 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000025 [140366762202880] winscard.c:1359:SCardControl() UnrefReader() count was: 2
00000005 [140366762202880] winscard_svc.c:735:ContextThread() CONTROL rv=0x0 for client 14
00000102 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_GET_READERS_STATE from client 14
00000108 [140366762202880] winscard_svc.c:361:ContextThread() Received command: STATUS from client 14
00000012 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000004 [140366762202880] winscard.c:1300:SCardStatus() UnrefReader() count was: 2
00000004 [140366762202880] winscard_svc.c:632:ContextThread() STATUS rv=0x0 for client 14
00000073 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000008 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000077 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000009 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000076 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000011 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000007 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000007 [140366762202880] APDU: 00 A4 00 0C 02 3F 00 
00184823 [140366762202880] SW: 6A 86 
00000020 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000135 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000021 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000006 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 A4 04 00 06 D2 76 00 01 24 01 
00015298 [140366762202880] SW: 90 00 
00000020 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000136 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000021 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000006 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 CA 00 4F 00 
00016731 [140366762202880] SW: D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 90 00 
00000022 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000013 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000113 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000023 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000008 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000008 [140366762202880] APDU: 00 CA 5F 52 00 
00015652 [140366762202880] SW: 00 C1 C5 73 C0 01 80 05 90 00 90 00 
00000019 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000011 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000147 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000025 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000010 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000010 [140366762202880] APDU: 00 CA 00 C4 00 
00017123 [140366762202880] SW: 01 7F 7F 7F 03 00 03 90 00 
00000019 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000114 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000021 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 CA 00 6E 00 
00047584 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000022 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000009 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000115 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000014 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000004 [140366762202880] APDU: 00 CA 7F 74 00 
00012896 [140366762202880] SW: 6A 88 
00000018 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000097 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000021 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000006 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 00 5E 00 
00011747 [140366762202880] SW: 90 00 
00000021 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000008 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000086 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000018 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000008 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000008 [140366762202880] APDU: 00 CA 00 6E 00 
00047658 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000039 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000019 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000196 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000037 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000013 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000013 [140366762202880] APDU: 00 CA 00 6E 00 
00047564 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000028 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000008 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000101 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000016 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 CA 00 6E 00 
00047566 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000025 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000208 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000020 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001122 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000052 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000011 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000085 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000618 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000024 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000009 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000009 [140366762202880] APDU: 00 CA 00 6E 00 
00047574 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000029 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000010 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00002711 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000022 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000008 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000008 [140366762202880] APDU: 00 CA 00 7A 00 
00015633 [140366762202880] SW: 93 03 00 00 05 90 00 
00000021 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000178 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000023 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000009 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000008 [140366762202880] APDU: 00 CA 00 C4 00 
00017131 [140366762202880] SW: 01 7F 7F 7F 03 00 03 90 00 
00000021 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000097 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000015 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 00 65 00 
00018460 [140366762202880] SW: 5B 10 74 65 73 74 3C 3C 63 61 72 64 68 6F 6C 64 65 72 5F 2D 02 65 6E 5F 35 01 30 90 00 
00000021 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00054002 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CONTROL from client 14
00000060 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
03264154 [140366762202880] winscard.c:1359:SCardControl() UnrefReader() count was: 2
00000010 [140366762202880] winscard_svc.c:735:ContextThread() CONTROL rv=0x0 for client 14
00000625 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000009 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000002 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000007 [140366762202880] APDU: 00 2A 9E 9A 53 30 51 30 0D 06 09 60 86 48 01 65 03 04 02 03 05 00 04 40 D7 32 A1 3D FB 5D 89 B4 50 AD E8 59 02 54 FF D0 D6 B9 EE F6 AF 53 E7 9A A9 1E 6A CC 2B D4 A0 2E EB 7F 7A 9C EA 90 2E 0D 0D B3 8D 71 C4 A9 3B BB F0 53 4A 8F 58 D4 0E 2F 5B 12 23 8C A4 55 AF 63 00 
01108360 [140366762202880] SW: 0A 09 22 41 94 1A C4 5C AC 26 D2 E7 60 83 5B A1 C4 4D 0C 5A 57 FD 3D EC E8 73 30 44 89 11 09 CE A6 0C 95 A7 6C 80 EC 7C 3A 9B 5F B6 70 C5 D1 01 F4 D6 2E D1 AB 84 58 F3 48 3D D2 9A 75 C7 F2 15 D3 B6 28 43 63 0F 7B 7F 8D 4F D6 6C 5A 83 69 80 8B 0C 98 66 8A 9D 08 BE 91 98 3A 65 BF FE 64 9B 4C 23 83 C4 26 C1 F7 8E F5 9A 46 10 FE 05 05 FD 97 C1 8C A3 80 A1 97 F5 C3 82 AA 80 CA D9 DE FB DE 4A 9F 0A 87 49 6B A7 CE E6 74 3B 53 8D 0A FC C9 64 72 FC FB 01 06 97 39 1B A3 8B CE A8 43 6C DD E6 F1 B4 C3 C8 99 FC AC 89 22 CB 2C E4 58 00 4F C4 9F 19 45 35 D9 47 98 07 F1 13 6F E9 86 1E B2 42 25 D3 EE C9 01 53 89 FC BD FE B6 96 8B 07 42 BE 1E 68 84 B4 E7 39 CA CA E2 62 AF DC 0A 2B 85 D5 99 CE 44 33 6A 93 AF D4 32 10 F2 F4 DB 57 46 C4 57 76 57 9F F2 7F D6 E4 F8 03 01 64 61 22 61 FF 
00000026 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000012 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000150 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000025 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000006 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000007 [140366762202880] APDU: 00 C0 00 00 FF 
00032566 [140366762202880] SW: 31 52 FF 43 66 DF 62 16 2E D1 50 91 18 4F B9 99 36 90 67 CC 9F A1 85 54 11 D4 4E 1A E5 F0 2E 88 E0 D1 CB 4F 45 9E 77 5D 1A 2C 8B 91 65 2D BB DA 97 92 F1 C3 17 87 43 52 06 EE FE FC B1 8B AC 48 C8 79 19 C0 C5 E6 3F C5 31 94 76 33 63 1D 1E B1 F5 8F CE 81 BA 49 3E 60 54 16 20 5E 9C 19 6F 6E 37 5E 96 81 9C 69 A2 E7 EF 5D E6 09 5D 42 C1 29 FC B6 90 7A 9D EA 91 89 16 4F 8E 1A F4 CB 3F 3D CE 9F 6B 72 6B A4 9A E9 25 DE AC AB 01 F7 82 F7 69 B3 B7 37 E9 2C 82 11 A1 51 03 22 FF 2A 12 B4 2D 54 E8 41 A8 63 F6 52 A4 AE 78 C3 26 A2 7F 50 0F 99 F7 A5 36 BD 44 94 0B 36 5C 9D DE CD 04 63 85 22 6E 8F 9A CB 98 18 3D 39 29 EC C6 4C 0C 7E AD 69 25 1E 1B 32 94 20 5F CA EE 1A C8 35 A6 2D C7 5D 6B 8A 46 FA C5 24 21 69 90 D5 64 4C 74 79 F2 C0 4E 12 5C EF 16 3E 9D 1F 65 E7 2C AF E2 61 01 
00000033 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000020 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000174 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000036 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000010 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000009 [140366762202880] APDU: 00 C0 00 00 01 
00010334 [140366762202880] SW: F6 90 00 
00000019 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000191 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000019 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001105 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000019 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000107 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000021 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000114 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000020 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500705 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000036 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001120 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000028 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000135 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000030 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000124 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000021 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500611 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000026 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001131 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000021 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000129 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000128 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000019 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500680 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000026 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001103 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000020 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000058 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000013 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000089 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000019 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500656 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000023 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001129 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000123 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000017 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000124 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500619 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000012 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001021 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000005 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000080 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000014 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000003 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500696 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000039 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001204 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000027 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000177 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000026 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000155 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000026 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00500638 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000027 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001121 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000026 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000062 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000017 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000145 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000029 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00044124 [140366770595584] eventhandler.c:358:EHStatusHandlerThread() Card Removed From REINER SCT cyberJack RFID standard (9934036502) 00 00
00456534 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000027 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000106 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000022 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000328 [140366762202880] winscard_svc.c:361:ContextThread() Received command: DISCONNECT from client 14
00000024 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000007 [140366762202880] winscard.c:881:SCardDisconnect() Active Contexts: -1
00000005 [140366762202880] winscard.c:882:SCardDisconnect() dwDisposition: 0
00000005 [140366762202880] winscard.c:1017:SCardDisconnect() powerState: POWER_STATE_GRACE_PERIOD
00000011 [140366762202880] winscard.c:1043:SCardDisconnect() UnrefReader() count was: 2
00000010 [140366762202880] winscard_svc.c:550:ContextThread() DISCONNECT rv=0x0 for client 14
00000064 [140366762202880] winscard_svc.c:361:ContextThread() Received command: RELEASE_CONTEXT from client 14
00000012 [140366762202880] winscard.c:229:SCardReleaseContext() Releasing Context: 0xA6D81FD
00000005 [140366762202880] winscard_svc.c:476:ContextThread() RELEASE_CONTEXT rv=0x0 for client 14
00000036 [140366762202880] winscard_svc.c:354:ContextThread() Client die: 14
00000025 [140366762202880] winscard_svc.c:1055:MSGCleanupClient() Thread is stopping: dwClientID=14, threadContext @0x560a0ee01f20
00000007 [140366762202880] winscard_svc.c:1063:MSGCleanupClient() Freeing SCONTEXT @0x560a0ee01f20
00343238 [140366770595584] eventhandler.c:494:EHStatusHandlerThread() powerState: POWER_STATE_POWERED
00400571 [140366770595584] eventhandler.c:482:EHStatusHandlerThread() powerState: POWER_STATE_UNPOWERED
00170077 [140366770595584] eventhandler.c:406:EHStatusHandlerThread() powerState: POWER_STATE_POWERED
00000017 [140366770595584] eventhandler.c:423:EHStatusHandlerThread() Card inserted into REINER SCT cyberJack RFID standard (9934036502) 00 00
00000008 [140366770595584] Card ATR: 3B 80 80 01 01 
00400587 [140366770595584] eventhandler.c:482:EHStatusHandlerThread() powerState: POWER_STATE_UNPOWERED
01123888 [140366874249152] winscard_msg_srv.c:256:ProcessEventsServer() Common channel packet arrival
00000021 [140366874249152] winscard_msg_srv.c:267:ProcessEventsServer() ProcessCommonChannelRequest detects: 14
00000006 [140366874249152] pcscdaemon.c:133:SVCServiceRunLoop() A new context thread creation is requested: 14
00000143 [140366762202880] winscard_svc.c:340:ContextThread() Authorized PC/SC client
00000015 [140366762202880] winscard_svc.c:343:ContextThread() Thread is started: dwClientID=14, threadContext @0x560a0ee01f20
00000011 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_VERSION from client 14
00000006 [140366762202880] winscard_svc.c:373:ContextThread() Client is protocol version 4:4
00000004 [140366762202880] winscard_svc.c:396:ContextThread() CMD_VERSION rv=0x0 for client 14
00000038 [140366762202880] winscard_svc.c:361:ContextThread() Received command: ESTABLISH_CONTEXT from client 14
00000013 [140366762202880] winscard.c:215:SCardEstablishContext() Establishing Context: 0xF640E7B
00000004 [140366762202880] winscard_svc.c:461:ContextThread() ESTABLISH_CONTEXT rv=0x0 for client 14
00000031 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_GET_READERS_STATE from client 14
00000037 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_GET_READERS_STATE from client 14
00000066 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CONNECT from client 14
00000011 [140366762202880] winscard_svc.c:499:ContextThread() Authorized client for 'REINER SCT cyberJack RFID standard (9934036502) 00 00'
00000004 [140366762202880] winscard.c:258:SCardConnect() Attempting Connect to REINER SCT cyberJack RFID standard (9934036502) 00 00 using protocol: 3
00000004 [140366762202880] readerfactory.c:821:RFReaderInfo() RefReader() count was: 1
00170139 [140366762202880] winscard.c:332:SCardConnect() power up complete.
00000016 [140366762202880] Card ATR: 3B 80 80 01 01 
00000003 [140366762202880] winscard.c:352:SCardConnect() powerState: POWER_STATE_IN_USE
00000007 [140366762202880] prothandler.c:107:PHSetProtocol() Attempting PTS to T=1
00000010 [140366762202880] winscard.c:430:SCardConnect() Active Protocol: T=1
00000005 [140366762202880] winscard.c:456:SCardConnect() hCard Identity: 6cc0d626
00000007 [140366762202880] winscard.c:518:SCardConnect() UnrefReader() count was: 2
00000008 [140366762202880] winscard_svc.c:513:ContextThread() CONNECT rv=0x0 for client 14
00000044 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CONTROL from client 14
00000008 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000173 [140366762202880] winscard.c:1359:SCardControl() UnrefReader() count was: 2
00000010 [140366762202880] winscard_svc.c:735:ContextThread() CONTROL rv=0x0 for client 14
00000031 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_GET_READERS_STATE from client 14
00000036 [140366762202880] winscard_svc.c:361:ContextThread() Received command: STATUS from client 14
00000008 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000003 [140366762202880] winscard.c:1300:SCardStatus() UnrefReader() count was: 2
00000002 [140366762202880] winscard_svc.c:632:ContextThread() STATUS rv=0x0 for client 14
00000021 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000005 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000019 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000006 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000024 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000008 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000004 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 A4 00 0C 02 3F 00 
00024905 [140366762202880] SW: 6A 86 
00000032 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000018 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000169 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000044 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000014 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000015 [140366762202880] APDU: 00 A4 04 00 06 D2 76 00 01 24 01 
00015151 [140366762202880] SW: 90 00 
00000034 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000015 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000178 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000040 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000019 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000017 [140366762202880] APDU: 00 CA 00 4F 00 
00015945 [140366762202880] SW: D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 90 00 
00000017 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000009 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000143 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000018 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 5F 52 00 
00015242 [140366762202880] SW: 00 C1 C5 73 C0 01 80 05 90 00 90 00 
00000019 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000011 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000110 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000018 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000007 [140366762202880] APDU: 00 CA 00 C4 00 
00016816 [140366762202880] SW: 01 7F 7F 7F 03 00 03 90 00 
00000017 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000007 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000104 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000015 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000006 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 00 6E 00 
00032907 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000025 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000008 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000098 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000017 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000006 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 CA 7F 74 00 
00013046 [140366762202880] SW: 6A 88 
00000015 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000127 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000019 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 00 5E 00 
00011872 [140366762202880] SW: 90 00 
00000015 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000117 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000018 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 00 6E 00 
00032903 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000026 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000008 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000103 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000016 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000007 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000006 [140366762202880] APDU: 00 CA 00 6E 00 
00032934 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000019 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000129 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000019 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000004 [140366762202880] APDU: 00 CA 00 6E 00 
00032916 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000022 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000104 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000018 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001089 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000015 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000040 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000009 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000109 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000014 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000567 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000019 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000005 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000005 [140366762202880] APDU: 00 CA 00 6E 00 
00033060 [140366762202880] SW: 6E 81 D9 4F 10 D2 76 00 01 24 01 03 04 BE EF 00 00 00 00 00 07 5F 52 0A 00 C1 C5 73 C0 01 80 05 90 00 73 81 B7 C0 0A FF 03 00 20 04 80 00 FF 00 00 C1 06 01 10 00 00 11 03 C2 06 01 10 00 00 11 03 C3 06 01 0C 00 00 11 03 C4 07 01 7F 7F 7F 03 00 03 C5 3C 03 53 CB 0B 67 EA AA DE 39 A5 B5 4F E8 D6 EC 89 1A 92 2C E4 03 FC FC B0 49 FF E3 97 33 7B 4B 3F F9 BE BB C9 CC B3 DE A9 52 6C E0 A2 9A C4 F6 B3 F6 D1 2B 67 BA DC AD FD C2 AC 5D 9F C6 3C 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD 0C 5F AE D1 4D 5F AE D1 4D 5F AE D1 4D 90 00 
00000024 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000006 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00466806 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000032 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001150 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000028 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000146 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000027 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00000145 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000027 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00400686 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000045 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000018 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000017 [140366762202880] APDU: 00 CA 00 7A 00 
00015576 [140366762202880] SW: 93 03 00 00 06 90 00 
00000030 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000019 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000217 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000038 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000014 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000015 [140366762202880] APDU: 00 CA 00 C4 00 
00016894 [140366762202880] SW: 01 7F 7F 7F 03 00 03 90 00 
00000027 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000015 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00000141 [140366762202880] winscard_svc.c:361:ContextThread() Received command: TRANSMIT from client 14
00000021 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000012 [140366762202880] winscard.c:1595:SCardTransmit() Send Protocol: T=1
00000014 [140366762202880] APDU: 00 CA 00 65 00 
00017052 [140366762202880] SW: 5B 10 74 65 73 74 3C 3C 63 61 72 64 68 6F 6C 64 65 72 5F 2D 02 65 6E 5F 35 01 30 90 00 
00000015 [140366762202880] winscard.c:1640:SCardTransmit() UnrefReader() count was: 2
00000005 [140366762202880] winscard_svc.c:685:ContextThread() TRANSMIT rv=0x0 for client 14
00048211 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CONTROL from client 14
00000016 [140366762202880] readerfactory.c:848:RFReaderInfoById() RefReader() count was: 1
00000849 [140366762202880] winscard.c:1359:SCardControl() UnrefReader() count was: 2
00000013 [140366762202880] winscard_svc.c:735:ContextThread() CONTROL rv=0x0 for client 14
00000718 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14
00000016 [140366762202880] winscard_svc.c:834:MSGSendReaderStates() Send reader states: 14
00001065 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_STOP_WAITING_READER_STATE_CHANGE from client 14
00000012 [140366762202880] winscard_svc.c:442:ContextThread() CMD_STOP_WAITING_READER_STATE_CHANGE rv=0x0 for client 14
00000026 [140366762202880] winscard_svc.c:361:ContextThread() Received command: CMD_WAIT_READER_STATE_CHANGE from client 14

Also there exists another issue, for example when my admin PIN is made up of characters I have no way of inputing it from the reader's pinentry and I know of no way to switch to the on-screen pinentry.

I think that the way to resolve this issue is to force GPG to use the on-screen Pinentry but I do not know how to do that I tried a couple of different ways and none seem to work.

Big Thanks for any help, 22h49

22h49 commented 4 years ago

As I have expected this problem is solved by diabling the readers pinpad this can be done by writing:

disable-pinpad

to ~/.gnupg/scdaemon.conf

This resolves the problem since in now asks for the pin on-screen and succesfully uses the card.

You can close this issue.

af-anssi commented 4 years ago

Thank you for this investigation. I close the issue.

jank04 commented 4 years ago

As I have expected this problem is solved by diabling the readers pinpad this can be done by writing:

disable-pinpad

to ~/.gnupg/scdaemon.conf

This resolves the problem since in now asks for the pin on-screen and succesfully uses the card.

You can close this issue.

Hi, I could not find such config file, but I found out, that there is maybe a global config in Windows. I created the file: "C:\ProgramData\GNU\etc\gnupg\gpgconf.conf" with content: * scdaemon disable-pinpad. Still have the issue.

PS C:\Program Files (x86)\GnuPG\bin> .\gpgconf.exe --list-config k:*: r:::scdaemon:disable-pinpad::

Any ideas? Otherwise I have to accept, that there is no solution and have to live with it.

jank04 commented 3 years ago

I can confirm the solution. For Windows I had to create a file scdaemon.conf to %APPDATA%\gnupg\ with content disable-pinpad.

However gpgconf.exe --list-config scdaemon.conf prints out gpgconf: missing rule at 'scdaemon.conf', line 1, it does still work. The correct way with rulesets k:*: (user/group ruleset) and r::: seem to be not applicable for windows systems.