Bug 1712436
Summary: | MD5 is used when writing password protected PEM | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 8 | Reporter: | Ondrej Moriš <omoris> | |
Component: | openssh | Assignee: | Jakub Jelen <jjelen> | |
Status: | CLOSED ERRATA | QA Contact: | Ondrej Moriš <omoris> | |
Severity: | medium | Docs Contact: | ||
Priority: | high | |||
Version: | 8.0 | CC: | ansasaki, rrelyea, szidek, tmraz | |
Target Milestone: | rc | Flags: | jjelen:
mirror+
|
|
Target Release: | 8.1 | |||
Hardware: | All | |||
OS: | Linux | |||
Whiteboard: | ||||
Fixed In Version: | openssh-8.0p1-1.el8 | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 1713256 (view as bug list) | Environment: | ||
Last Closed: | 2019-11-05 22:41:32 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: | ||||
Bug Depends On: | ||||
Bug Blocks: | 1713256 |
Description
Ondrej Moriš
2019-05-21 14:04:19 UTC
This cannot be fixed on the openssl side. The use of MD-5 for this file format is hardcoded. The modern RSA ENCRYPTED KEY format needs to be used in openssh ssh-keygen instead. Tomas, you mean that in FIPS mode, the PEM format should not be used at all and Ondrej should use the default OpenSSH format? In that case, we can 1) Modify OpenSSH ssh-keygen not to allow PEM key generation in FIPS 2) Document this, since this is certainly a change from RHEL7. OpenSSH should use PEM_write_bio_PrivateKey() function to write the RSA key when the PEM format is requested. Regardless of the FIPS mode. Do I understand this right that reading of the old PEM files will break in FIPS mode completely? The libssh testsuite have several of them embedded in the testsuite and I do not seem to be able to read them in FIPS mode at all with the following errors: [2019/05/23 11:17:55.434672, 2] ssh_pki_import_privkey_base64: Trying to decode privkey passphrase=true [2019/05/23 11:17:55.434700, 1] pki_private_key_from_base64: Parsing private key: error:060800C8:digital envelope routines:EVP_DigestInit_ex:disabled for FIPS I think this is expected, but we will need something to do with the libssh testsuite, which heavily depends on them. But lets follow this discussion in upstream/libssh bug. Yes, that is correct - in FIPS you cannot read PEM files previously generated (in non-FIPS mode). FYI, based on the Fedora bug #1722285 and the progress in the upstream bug [1], I propose to adapt the upstream version of this patch, which allows to generate both legacy PEM files, the new PKCS8 format. [1] https://bugzilla.mindrot.org/show_bug.cgi?id=3013 Unless you modify the upstream patch to always output PKCS8 in FIPS mode, this new patch will not solve this bug. It will just provide a workaround. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2019:3702 |