Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
When a system is fips enabled python on RHEL 8 is still able to load non-fips compliant modules (specifically md5 has been identified, but unsure about others that may be available)
Version-Release number of selected component (if applicable):
python36-3.6.8-2.module+el8.0.0+2975+e0f02136.x86_64
How reproducible:
Always
Steps to Reproduce:
1. Install a system with FIPS enabled or run the following:
[root@localhost ~]# fips-mode-setup --enable && reboot
2. Confirm system has FIPS mode enabled:
[root@localhost ~]# update-crypto-policies --show
FIPS
[root@localhost ~]# sysctl -a | grep fips
crypto.fips_enabled = 1
[root@localhost ~]# fips-mode-setup --check
FIPS mode is enabled.
3. Load up python3 and import md5 from hashlib and then attempt to access it.
[root@localhost ~]# python3
Python 3.6.8 (default, Jan 11 2019, 02:17:16)
[GCC 8.2.1 20180905 (Red Hat 8.2.1-3)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from hashlib import md5
>>> print(md5("password".encode("utf-8")))
<_md5.md5 object at 0x7fe4d8c19570>
Actual results:
>>> print(md5("password".encode("utf-8")))
<_md5.md5 object at 0x7fe4d8c19570>
Expected results:
Previously on RHEL 7 and earlier we get the expected results
>>> print(md5("password".encode("utf-8")))
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ValueError: error:060800A3:digital envelope routines:EVP_DigestInit_ex:disabled for fips
Additional info:
Looks like the hashlib patch that provides fips compliance was removed initially because of an incompatibility with openssl 1.1.0 and then we never restored it. Here's the relevant Fedora bug:
https://bugzilla.redhat.com/show_bug.cgi?id=1486212
Comment 5Petr Viktorin (pviktori)
2019-08-13 13:12:47 UTC
We're handling FIPS mode in bug #1731424
*** This bug has been marked as a duplicate of bug 1731424 ***