Yubico Forum
https://forum.yubico.com/

NEO not recognized as smart card reader
https://forum.yubico.com/viewtopic.php?f=26&t=1669
Page 1 of 1

Author:  syzzer [ Thu Dec 18, 2014 11:25 pm ]
Post subject:  NEO not recognized as smart card reader

My newly received NEO is not recognized as a smartcard reader by opensc on ubuntu 14.10:
Code:
$ opensc-tool -l
No smart card readers found.
and
Code:
$ pkcs11-tool --module /usr/lib/x86_64-linux-gnu/opensc-pkcs11.so --list-mechanisms
No slot with a token was found.

This is a faily recent version of opensc:
Code:
$ opensc-tool -i
opensc 0.13.0 [gcc  4.8.2]
Enabled features: zlib readline openssl pcsc(libpcsclite.so.1)

I already set the device to OTP + CCID + U2F mode ('-m86'), which I later confirmed using the neo manager app. I was also successful in creating gpg keys, and using those:
Code:
$ gpg --card-status
can't connect to `/run/user/1000/keyring-B9opIK/gpg': No such file or directory
Application ID ...: D2760001240102000006030220490000
Version ..........: 2.0
Manufacturer .....: unknown
Serial number ....: 03022049
Name of cardholder: [not set]
Language prefs ...: [not set]
Sex ..............: unspecified
URL of public key : [not set]
[...etc...]

But I am puzzled why opensc won't recognize the NEO. Any clues?

Edit:
Just tried with the 'latest and greatest' (git master) opensc, but no luck either:
Code:
$ ./opensc-tool -i
OpenSC 0.14.0 [gcc  4.9.1]
Enabled features: zlib openssl pcsc(libpcsclite.so.1)
$ ./opensc-tool -l
No smart card readers found.

Author:  ChrisHalos [ Fri Dec 19, 2014 12:51 am ]
Post subject:  Re: NEO not recognized as smart card reader

Hello Syzzer -

I just wiped my Ubuntu 14.04 install to do some testing on Linux Mint 17. If you were to disable U2F in the NEO Manager and then run the command again, OpenSC should see the NEO as a card reader. As long as you've confirmed that's what happens, you likely haven't added the necessary udev rule yet that allows U2F to work properly. Without the run, applications also don't recognize the NEO as a card reader if U2F mode is also enabled. We have a command to resolve this, but just in case you want to review the code before implementing it: https://raw.githubusercontent.com/Yubic ... -ccid-udev

The command you need to run in order to implement the change is:

sudo sh -c 'wget -q -O - https://raw.githubusercontent.com/Yubic ... -ccid-udev | python'

I've confirmed this works on both Linux Mint and on Ubuntu. A reboot may be required, although it wasn't in my case with Linux Mint 17. You can also find the original post here if you want to read more about it: viewtopic.php?f=26&t=1609#p6270

-Chris

Author:  syzzer [ Fri Dec 19, 2014 1:08 am ]
Post subject:  [SOLVED] Re: NEO not recognized as smart card reader

Thank you Chris! That indeed solved my problem.

For those after me who try copy-pasting from Chris' post: the url is shortened, which will result in the command silently failing. Here's the command with the full URL, copy-pasteable:
Code:
sudo sh -c 'wget -q -O - https://raw.githubusercontent.com/Yubico/yubikey-neo-manager/master/resources/linux-fix-ccid-udev | python'

Page 1 of 1 All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/