rutoken ECP + linux (архитектура arm)
Здравствуйте, у меня не получается проинициализировать токен. pkcs15-init --erase-card отрабаетывает нормально (как и pkcs11-data --add-provider=/usr/lib/opensc-pkcs11.so --prompt-prog /tmp/prompt.sh --cmd=import/export --file=$key_file --token=$id --application=DISK --label=N900 ), но pkcs15-init --create-pkcs15 --so-pin "87654321" --so-puk "" выдает такой лог:
[pkcs15-init] ctx.c:735:sc_context_create: ===================================
[pkcs15-init] ctx.c:736:sc_context_create: opensc version: 0.11.13
[pkcs15-init] reader-pcsc.c:879:pcsc_detect_readers: Probing pcsc readers
[pkcs15-init] reader-pcsc.c:901:pcsc_detect_readers: Establish pcsc context
[pkcs15-init] reader-pcsc.c:951:pcsc_detect_readers: Found new pcsc reader 'Aktiv Rutoken ECP 00 00'
[pkcs15-init] sc.c:196:sc_detect_card_presence: called
[pkcs15-init] sc.c:201:sc_detect_card_presence: returning with: 1
Using reader with a card: Aktiv Rutoken ECP 00 00
[pkcs15-init] sc.c:196:sc_detect_card_presence: called
[pkcs15-init] sc.c:201:sc_detect_card_presence: returning with: 1
[pkcs15-init] card.c:110:sc_connect_card: called
[pkcs15-init] reader-pcsc.c:532:pcsc_connect: After connect protocol = 2
[pkcs15-init] reader-pcsc.c:551:pcsc_connect: Requesting reader features ...
[pkcs15-init] reader-pcsc.c:621:pcsc_connect: Returned PIN properties structure has bad length (8)
[pkcs15-init] card-gemsafeV1.c:120:gemsafe_match_card: called
[pkcs15-init] card-piv.c:1761:piv_match_card: called
[pkcs15-init] card-piv.c:493:piv_find_aid: called
[pkcs15-init] iso7816.c:99:iso7816_check_sw: Function not supported
[pkcs15-init] iso7816.c:99:iso7816_check_sw: Function not supported
[pkcs15-init] card-piv.c:576:piv_find_aid: returning with: -1208
[pkcs15-init] card-entersafe.c:101:entersafe_match_card: called
[pkcs15-init] card-rutoken.c:120:rutoken_match_card: called
[pkcs15-init] card-rutoken.c:126:rutoken_match_card: returning with: 0
[pkcs15-init] card-rtecp.c:53:rtecp_match_card: returning with: 1
[pkcs15-init] card.c:221:sc_connect_card: card info: Rutoken ECP card, 0, 0x0
[pkcs15-init] card.c:222:sc_connect_card: returning with: 0
[pkcs15-init] card.c:675:sc_card_ctl: card_ctl(4) not supported
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f0050154946
[pkcs15-init] iso7816.c:99:iso7816_check_sw: File not found
[pkcs15-init] card-rtecp.c:306:rtecp_select_file: : File not found
[pkcs15-init] card.c:554:sc_select_file: returning with: -1201
[pkcs15-init] profile.c:306:sc_profile_load: Using profile directory '/usr/share/opensc'.
[pkcs15-init] profile.c:306:sc_profile_load: Using profile directory '/usr/share/opensc'.
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f00, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f002f00, size=128
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f00
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f001000, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f001000
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f0010001000, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f0010001000
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f00100010006001, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f0010001000
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f00100010006002, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f0010001000
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f00100010006003, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f0010001000
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f00100010006004, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f0010001000
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f00100010006005, size=0
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] card.c:532:sc_select_file: called; type=2, path=3f00
[pkcs15-init] card.c:554:sc_select_file: returning with: 0
[pkcs15-init] card.c:362:sc_create_file: called; type=2, path=3f005000, size=5000
[pkcs15-init] card.c:367:sc_create_file: returning with: 0
[pkcs15-init] pkcs15-rtecp.c:171:rtecp_create_pin: called
[pkcs15-init] card.c:362:sc_create_file: called; type=0, path=, size=8
[pkcs15-init] iso7816.c:99:iso7816_check_sw: Incorrect parameters in the data field
[pkcs15-init] card-rtecp.c:564:rtecp_create_file: returning with: Incorrect parameters in APDU
[pkcs15-init] card.c:367:sc_create_file: returning with: Incorrect parameters in APDU
[pkcs15-init] pkcs15-rtecp.c:209:rtecp_create_pin: returning with: Incorrect parameters in APDU
Failed to create PKCS #15 meta structure: Incorrect parameters in APDU
[pkcs15-init] card.c:236:sc_disconnect_card: called
[pkcs15-init] card.c:251:sc_disconnect_card: returning with: 0
[pkcs15-init] ctx.c:765:sc_release_context: called
У меня в pkcs11-data на arm уже вылезала ошибка в ихнем враппере fork'а, я в ней еще детально не разбирался. Просто временный workaround, но грешу на их обветку мютексов...
подскажите, пожалуйста, в какую сторону копать?