Rutoken ECP pkcs11-tool Segmentation fault в ArchLinux как победить?
Rutoken ECP рабочий, с ключами и сертификатами; без проблем работал в Ubuntu, MacOS, Windows...
Пришла производственная пора приучить его к ArchLinux 5.6.14 (x86_64).
Пакет librtpkcs11ecp_2.0.4.0-1_amd64.deb пересобран с PKGBUILD и без ошибок установлен.
Необходимые библиотеки (ccid, pcsclite, pcsc-tools, opensс установлены из репозитория).
При попытке просмотреть модуль через pkcs11-tool выдает Segmentation fault...
Подскажите что делать, куда копать? Буду признателен за помощь.
Логи и вывод программ:
1) pcscd -afddd
00000000 debuglog.c:299:DebugLogSetLevel() debug level=debug
00000067 debuglog.c:299:DebugLogSetLevel() debug level=debug
00000032 debuglog.c:299:DebugLogSetLevel() debug level=debug
00000020 debuglog.c:299:DebugLogSetLevel() debug level=debug
00000085 utils.c:81:GetDaemonPid() Can't open /run/pcscd/pcscd.pid: No such file or directory
00000228 configfile.l:293:DBGetReaderListDir() Parsing conf directory: /etc/reader.conf.d
00000047 configfile.l:329:DBGetReaderListDir() Skipping non regular file: .
00000021 configfile.l:329:DBGetReaderListDir() Skipping non regular file: ..
00000020 configfile.l:369:DBGetReaderList() Parsing conf file: /etc/reader.conf.d/libccidtwin
00000108 pcscdaemon.c:663:main() pcsc-lite 1.8.26 daemon ready.
00010113 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/003/001
00000470 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/004/001
00000463 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/001/001
00000264 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/001/001
00000285 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x17EF, PID: 0x1000, path: /dev/bus/usb/001/002
00000458 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/005/001
00000303 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/005/001
00000278 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x0A89, PID: 0x0030, path: /dev/bus/usb/005/002
00000020 hotplug_libudev.c:440:HPAddDevice() Adding USB device: Aktiv Rutoken ECP
00000075 readerfactory.c:1074:RFInitializeReader() Attempting startup of Aktiv Rutoken ECP 00 00 using /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Linux/libccid.so
00000382 readerfactory.c:950:RFBindFunctions() Loading IFD Handler 3.0
00000040 ifdhandler.c:2008:init_driver() Driver version: 1.4.32
00001230 ifdhandler.c:2025:init_driver() LogLevel: 0x0003
00000018 ifdhandler.c:2036:init_driver() DriverOptions: 0x0000
00000334 ifdhandler.c:110:CreateChannelByNameOrChannel() Lun: 0, device: usb:0a89/0030:libudev:0:/dev/bus/usb/005/002
00000024 ccid_usb.c:302:OpenUSBByName() Using: /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist
00001204 ccid_usb.c:320:OpenUSBByName() ifdManufacturerString: Ludovic Rousseau (ludovic.rousseau@free.fr)
00000017 ccid_usb.c:321:OpenUSBByName() ifdProductString: Generic CCID driver
00000015 ccid_usb.c:322:OpenUSBByName() Copyright: This driver is protected by terms of the GNU Lesser General Public License version 2.1, or (at your option) any later version.
00097989 ccid_usb.c:659:OpenUSBByName() Found Vendor/Product: 0A89/0030 (Aktiv Rutoken ECP)
00000031 ccid_usb.c:661:OpenUSBByName() Using USB bus/device: 5/2
00000015 ccid_usb.c:722:OpenUSBByName() bNumDataRatesSupported is 0
00007859 ifdhandler.c:380:IFDHGetCapabilities() tag: 0xFB3, usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00000039 readerfactory.c:391:RFAddReader() Using the pcscd polling thread
00002116 ifdhandler.c:380:IFDHGetCapabilities() tag: 0xFAE, usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00000041 ifdhandler.c:476:IFDHGetCapabilities() Reader supports 1 slot(s)
00001269 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/006/001
00001073 hotplug_libudev.c:299:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/002/001
00000515 readerfactory.c:1409:RFWaitForReaderInit() Waiting init for reader: Aktiv Rutoken ECP 00 00
00000949 ifdhandler.c:1166:IFDHPowerICC() action: PowerUp, usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00001991 eventhandler.c:289:EHStatusHandlerThread() powerState: POWER_STATE_POWERED
00000045 Card ATR: 3B 8B 01 52 75 74 6F 6B 65 6E 20 44 53 20 C1
00404939 ifdhandler.c:1166:IFDHPowerICC() action: PowerDown, usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00001995 eventhandler.c:482:EHStatusHandlerThread() powerState: POWER_STATE_UNPOWERED
04735995 pcscdaemon.c:193:signal_thread() Received signal: 2
00000028 pcscdaemon.c:227:signal_thread() Preparing for suicide
00001618 hotplug_libudev.c:717:HPStopHotPluggables() Hotplug stopped
01000106 readerfactory.c:1353:RFCleanupReaders() entering cleaning function
00000031 readerfactory.c:1361:RFCleanupReaders() Stopping reader: Aktiv Rutoken ECP 00 00
00000024 readerfactory.c:610:RFRemoveReader() UnrefReader() count was: 1
00000021 eventhandler.c:175:EHDestroyEventHandler() Stomping thread.
00000021 ifdhandler.c:380:IFDHGetCapabilities() tag: 0xFB1, usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00000020 ifdhandler.c:380:IFDHGetCapabilities() tag: 0xFB2, usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00000019 eventhandler.c:204:EHDestroyEventHandler() Waiting polling thread
00306223 eventhandler.c:504:EHStatusHandlerThread() Die
00000136 eventhandler.c:215:EHDestroyEventHandler() Thread stomped.
00000044 readerfactory.c:1125:RFUnInitializeReader() Attempting shutdown of Aktiv Rutoken ECP 00 00.
00000034 ifdhandler.c:283:IFDHCloseChannel() usb:0a89/0030:libudev:0:/dev/bus/usb/005/002 (lun: 0)
00002762 ccid_usb.c:189:close_libusb_if_needed() libusb_exit
00000278 readerfactory.c:987:RFUnloadReader() Unloading reader driver.
00000249 winscard_svc.c:155:ContextsDeinitialize() remaining threads: 0
00000035 pcscdaemon.c:787:at_exit() cleaning /run/pcscd
2) pcsc_scan
Using reader plug'n play mechanism
Scanning present readers...
0: Aktiv Rutoken ECP 00 00
[2D [2D
Tue May 26 21:21:18 2020
[2D [2D Reader 0: Aktiv Rutoken ECP 00 00
Event number: 0
Card state: Card inserted,
ATR: 3B 8B 01 52 75 74 6F 6B 65 6E 20 44 53 20 C1
ATR: 3B 8B 01 52 75 74 6F 6B 65 6E 20 44 53 20 C1
+ TS = 3B --> Direct Convention
+ T0 = 8B, Y(1): 1000, K: 11 (historical bytes)
TD(1) = 01 --> Y(i+1) = 0000,[35m Protocol T = 1 [0m
-----
+ Historical bytes: 52 75 74 6F 6B 65 6E 20 44 53 20
Category indicator byte: 52 (proprietary format)
+ TCK = C1 (correct checksum)
Possibly identified card (using /usr/share/pcsc/smartcard_list.txt):
3B 8B 01 52 75 74 6F 6B 65 6E 20 44 53 20 C1
[34m Aktiv Rutoken ECP[0m
[34m https://www.rutoken.ru/products/all/rutoken-ecp/[0m
[3D - [3D \ [3D | [3D / [3D - [2D [2D
3) ccid
Repository : community
Name : ccid
Version : 1.4.32-1
Description : A generic USB Chip/Smart Card Interface Devices driver
Architecture : x86_64
URL : https://ccid.apdu.fr/
Licenses : LGPL GPL
Groups : None
Provides : None
Depends On : pcsclite libusb flex
Optional Deps : None
Conflicts With : None
Replaces : None
Download Size : 75.30 KiB
Installed Size : 253.68 KiB
Packager : Christian Hesse <arch@eworm.de>
Build Date : Sat May 23 23:28:25 2020
Validated By : MD5 Sum SHA-256 Sum Signature
4) opensc
Repository : community
Name : opensc
Version : 0.20.0-1
Description : Tools and libraries for smart cards
Architecture : x86_64
URL : https://github.com/OpenSC/OpenSC/wiki
Licenses : LGPL
Groups : None
Provides : None
Depends On : pcsclite glib2 libltdl
Optional Deps : None
Conflicts With : None
Replaces : None
Download Size : 1208.11 KiB
Installed Size : 4105.59 KiB
Packager : Christian Rebischke <Chris.Rebischke@archlinux.org>
Build Date : Tue Mar 3 03:32:09 2020
Validated By : MD5 Sum SHA-256 Sum Signature
5) pcsclite
Repository : community
Name : pcsclite
Version : 1.8.26-1
Description : PC/SC Architecture smartcard middleware library
Architecture : x86_64
URL : https://pcsclite.apdu.fr/
Licenses : BSD
Groups : None
Provides : None
Depends On : python systemd
Optional Deps : None
Conflicts With : None
Replaces : None
Download Size : 98.48 KiB
Installed Size : 302.50 KiB
Packager : Christian Hesse <arch@eworm.de>
Build Date : Fri Jan 10 15:38:19 2020
Validated By : MD5 Sum SHA-256 Sum Signature
6) pkcs11-tools
Repository : community
Name : pcsc-tools
Version : 1.5.6-1
Description : PC/SC Architecture smartcard tools
Architecture : x86_64
URL : http://ludovic.rousseau.free.fr/softwares/pcsc-tools/
Licenses : GPL
Groups : None
Provides : None
Depends On : pcsclite pcsc-perl glib-perl
Optional Deps : perl-gtk3: gscriptor
Conflicts With : None
Replaces : None
Download Size : 122.97 KiB
Installed Size : 458.98 KiB
Packager : Felix Yan <felixonmars@archlinux.org>
Build Date : Mon Mar 16 01:38:57 2020
Validated By : MD5 Sum SHA-256 Sum Signature