Table of Contents

Smart cards

Contact Smart Card

Dmesg

[1110228.380130] usb 1-3: new full-speed USB device number 87 using xhci_hcd
[1110228.537039] usb 1-3: New USB device found, idVendor=076b, idProduct=3021, bcdDevice= 3.02
[1110228.537054] usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[1110228.537061] usb 1-3: Product: Smart Card Reader USB
[1110228.537066] usb 1-3: Manufacturer: OMNIKEY AG

Open SC

# opensc-tool --list-readers
# Detected readers (pcsc)
Nr.  Card  Features  Name
0    Yes             OMNIKEY AG CardMan 3121 00 00

# opensc-tool --list-readers
# Detected readers (pcsc)
Nr.  Card  Features  Name
0    No              OMNIKEY AG CardMan 3121 00 00
# 
# opensc-tool --reader 0 --atr
3b:9f:95:81:31:fe:9f:00:65:46:53:05:30:06:71:df:00:00:00:81:61:0e:d8

# opensc-tool --reader 0 --name
entersafe

# opensc-explorer
OpenSC Explorer version 0.20.0
Using reader with a card: OMNIKEY AG CardMan 3121 00 00
OpenSC [3F00]> ls
unable to receive file listing: Not supported
OpenSC [3F00]> help
Supported commands:
  echo [<string> ...]                        display arguments
  ls [<pattern> ...]                         list files in the current DF



[root@cube ~]# opensc-tool --verbose --info
opensc 0.12.2 [gcc  4.1.2 20080704 (Red Hat 4.1.2-51)]
Enabled features: zlib readline openssl pcsc(libpcsclite.so.1)
[root@cube ~]# opensc-tool -l
# Detected readers (pcsc)
Nr.  Card  Features  Name
0    Yes             OmniKey CardMan 3121 00 00

[root@cube ~]# opensc-tool --atr
Using reader with a card: OmniKey CardMan 3121 00 00
3b:9f:95:81:31:fe:9f:00:65:46:53:05:30:06:71:df:00:00:00:80:6a:82:5e
[root@cube ~]#
[root@cube ~]# opensc-tool --serial
Using reader with a card: OmniKey CardMan 3121 00 00
30 64 49 45 09 26 05 11 0dIE.&..
[root@cube ~]#


[root@cube ~]# pkcs15-init --create-pkcs15 --profile pkcs15+onepin --use-default-transport-key --pin 0000 --puk 111111 --label "Andrew Stringer"
Using reader with a card: OmniKey CardMan 3121 00 00
[root@cube ~]#

[root@cube ~]# pkcs15-tool --dump
Using reader with a card: OmniKey CardMan 3121 00 00
PKCS#15 Card [Andrew Stringer]:
        Version        : 0
        Serial number  : 3064494509260511
        Manufacturer ID: EnterSafe
        Last update    : 20121204011429Z
        Flags          : EID compliant

PIN [User PIN]
        Object Flags   : [0x3], private, modifiable
        ID             : 01
        Flags          : [0x32], local, initialized, needs-padding
        Length         : min_len:4, max_len:16, stored_len:16
        Pad char       : 0x00
        Reference      : 1
        Type           : ascii-numeric
        Path           : 3f005015

[root@cube ~]#              

[root@cube ~]# pkcs15-tool --list-pins

Using reader with a card: OmniKey CardMan 3121 00 00 PIN [User PIN]

      Object Flags   : [0x3], private, modifiable
      ID             : 01
      Flags          : [0x32], local, initialized, needs-padding
      Length         : min_len:4, max_len:16, stored_len:16
      Pad char       : 0x00
      Reference      : 1
      Type           : ascii-numeric
      Path           : 3f005015

[root@cube ~]#

http://www.gooze.eu/howto/smartcard-quickstarter-guide/managing-pin-codes

 
linux/smartcards.txt · Last modified: 2021/09/30 09:16 by andrew