Bug 1949436
Summary: | scp/sftp/git with PKCS11 fails with "read_passphrase: stdin is not a tty" | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Allison Karlitskaya <allison.karlitskaya> |
Component: | openssh | Assignee: | Dmitry Belyavskiy <dbelyavs> |
Status: | CLOSED WONTFIX | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | 36 | CC: | crypto-team, dbelyavs, dwalsh, jjelen, lkundrak, mattias.ellert, plautrba, tm |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2022-11-08 12:33:17 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Allison Karlitskaya
2021-04-14 09:49:37 UTC
Can I help with this bug in any way? Do you have a suggested idea for how we should approach patching this? Please, open a upstream bug in https://bugzilla.mindrot.org/ until it is resolved, we should probably revert the chunk in the pkcs11-uri patch. Dima, can you have a look into that? Here's how anyone can reproduce this with SoftHSM: $ rm -rf /tmp/tokens/ ~/.config/softhsm2 $ mkdir /tmp/tokens ~/.config/softhsm2 $ echo directories.tokendir = /tmp/tokens > ~/.config/softhsm2/softhsm2.conf $ softhsm2-util --init-token --slot 0 --label ssh --so-pin 9876 --pin 1234 The token has been initialized and is reassigned to slot 1411391513 $ ssh-keygen -D /lib64/softhsm/libsofthsm.so # working correctly Enter PIN for 'ssh': cannot read public key from pkcs11 ^ The error is expected since there is no key generated, but we can see that the token was successfully unlocked. $ ssh-keygen -D /lib64/softhsm/libsofthsm.so < /dev/null # demonstrates the bug ssh_askpass: exec(/usr/libexec/openssh/ssh-askpass): No such file or directory login failed cannot read public key from pkcs11 ^ Here we don't even get the chance Upstream bug is here: https://bugzilla.mindrot.org/show_bug.cgi?id=3314 Forgot to mention, of course, in the SoftHSM scenario, that these are working, in the same way as above: $ env -u DISPLAY ssh-keygen -D /lib64/softhsm/libsofthsm.so < /dev/null $ SSH_ASKPASS_REQUIRE=never ssh-keygen -D /lib64/softhsm/libsofthsm.so < /dev/null Gentle ping. Upstream closed the bug by adjusting the comment (ie: no functional changes) which is a pretty clear indication that they consider the current (questionable) behaviour to be the correct one, meaning that the patch carried in Fedora is then unambiguously incorrect and needs to be modified or removed. Still worth doing, moving to rawhide This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle. Changing version to 36. Sorry, closing this issue. Upstream is quite reluctant to deal with any PKCS11 stuff, considers this behavior nornal, and we also don't have enough capacity for it. For the record: this is not an upstream issue. This issue is introduced, downstream, by the patch openssh-8.0p1-pkcs11-uri.patch, which is still present in the latest version. Dropping that patch would fix this issue. I leave this marked as "WONTFIX" because of "we also don't have enough capacity for it". That's not my decision to make. |