by lathiat · 3y ago · 0 comments
I would be remiss to mention there are existing SSH TPM projects, not sure how this one differentiates. It seems to at least have the user experience pretty simple, similar to yubikey-agent (and secretive), and unlike some of the existing solutions which have quite a few extra steps:
https://github.com/tpm2-software/tpm2-pkcs11/blob/master/doc...
I really love it when projects like this address there are "competitors" or other software in the space and provide a fair comparison. It would be great to see one of those here :) For example you can easily use SSH FIDO keys but they aren't supported by all server sides, ECDSA keys often are (though not always!) etc :)
Thanks for those pointers!
ykcs11 allows you to use the native SSH agent (or even no agent at all for individual ssh invocations) with an ssh key on a yubikey using their pkcs11 provider.
https://developers.yubico.com/PIV/Guides/SSH_with_PIV_and_PK...
Side-loading so-names into your security critical apps is probably something you should be more critical of as well.
both variants, whether it's using a PKCS11 provider using a standardized interface, or using a completely custom SSH agent, will need to deal with secret material.
although I'm no expert on the inner workings of SSH, I'd expect there to not be much difference between having the OpenSSH agent interface with ykcs11 (which is also open source and can be reviewed) and using an alternative agent with piv capabilities that was found on github.
No, as they never get loaded into the ssh binary and are external programs communicating over an interface.
Consider reading over the recent qualys vulnerability report on how messy this dloading of pkcs11 actually is.
https://www.qualys.com/2023/07/19/cve-2023-38408/rce-openssh...
>both variants, whether it's using a PKCS11 provider using a standardized interface, or using a completely custom SSH agent, will need to deal with secret material.
`ssh-tpm-agent` is not dealing with secret material. That is delegated to the TPM and we are only in the business of telling the TPM to sign stuff for us. Yubikey-agent does create a private key on the machine before inserting it into the yubikey.
I would not call these two things equal and there are a difference to what the potential impact is.
>although I'm no expert on the inner workings of SSH, I'd expect there to not be much difference between having the OpenSSH agent interface with ykcs11 (which is also open source and can be reviewed) and using an alternative agent with piv capabilities that was found on github.
There is a separation of concerns here though.