SSH PIV authentication problem(s)

Posted by illumis92@reddit | sysadmin | View on Reddit | 23 comments

Hi people of the internet ;-)

I have a very strange issue:
When connecting to a Windows-server and authenticating Smartcard (Yubikey with PIV) everything is running smooth - yes, a short waiting-time at the logon-screen of 3-5 seconds, but that's okay.
If I connect from this Windows-server to a Linux-server and use again the smartcard for authentication, I have everything between 5 seconds and 40 seconds waiting time for the PIN-request. This does not change, whether I use the ssh-agent or 3rd party tools like open-sc or wincrypt or puttycac as the smartcard-provider.
My colleagues an I analyzed wireshark-traces, used procmon to analyze the things going back and forth, took dubug-logs of the yubico-minidriver, but could not find any real "error". Just a huge amount of smartcard-read-access-entries going on in procmon.
The yubico-log shows also shows the accesses but not giving any indication of a "problem" here.

With ssh-add I can "store" the Pin and this speeds things up, but we do not want to cache/store the Pin for security-reasons.

And furthermore, if I do not store/cache the Pin, I cannot jump from the linux-server further to another machine via ssh - this is only possible when I store the key, as only then the forwarding is really forwarding the keys to the linux-jumpserver.

Does anyone know, what can be the cause or did anyone expereince the same thing and found a solution or knows, why there cannot be a solution?

I am really frustrated currently...

Thank you all guys!