Bug 2183207
| Summary: | Images built with stig profile remediation fail to boot with FIPS error | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 8 | Reporter: | Lark Gordon <lagordon> |
| Component: | osbuild-composer | Assignee: | Image Builder team <osbuilders> |
| Status: | CLOSED MIGRATED | QA Contact: | Release Test Team <release-test-team-automation> |
| Severity: | high | Docs Contact: | |
| Priority: | high | ||
| Version: | 8.7 | CC: | cllang, gzuccare, hasibul.haque, jcastran, sbarcomb |
| Target Milestone: | rc | Keywords: | MigratedToJIRA |
| Target Release: | --- | Flags: | pm-rhel:
mirror+
|
| Hardware: | Unspecified | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2023-09-18 13:53:01 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: | |||
I have the same issue. Either of these customizations causes the image rendered unbootable. [customizations.kernel] append = "fips=1" [customizations.openscap] datastream = "/usr/share/xml/scap/ssg/content/ssg-rhel8-ds.xml" profile_id = "xccdf_org.ssgproject.content_profile_stig" Boot error: [ 9.190130] GPT: Use GNU Parted to correct GPT errors. [ 9.193832] xvda: xvda1 xvda2 xvda3 [ 9.692694] dracut: Scanning devices xvda2 for LVM volume groups [ 9.772169] dracut: WARNING: locking_type (4) is deprecated, using --sysinit --readonly. [ 9.781534] dracut: Found volume group "rootvg" using metadata type lvm2 [ 9.873230] dracut: WARNING: locking_type (4) is deprecated, using --sysinit --readonly. [ 9.880888] dracut: Allowing activation with --readonly --sysinit. [ 10.614354] dracut: 3 logical volume(s) in volume group "rootvg" now active [ 10.970638] SGI XFS with ACLs, security attributes, quota, no debug enabled [ 10.984423] XFS (dm-0): Mounting V5 Filesystem [ 12.066757] XFS (dm-0): Ending clean mount [ 12.303164] dracut: Remounting /dev/disk/by-uuid/5f81dff6-56a8-4249-b4bc-d4ee16789136 with -o defaults [ 12.734329] dracut: Mounted root filesystem /dev/mapper/rootvg-rootlv [ 12.754858] dracut: Checking integrity of kernel [ 12.766024] dracut Warning: /boot//.vmlinuz-4.18.0-477.10.1.el8_8.x86_64.hmac does not exist dracut Warning: [ 12.775482] dracut: FATAL: FIPS integrity test failed /boot//.vmlinuz-[ 12.782589] dracut: Refusing to continue 4.18.0-477.10.1.el8_8.x86_64.hmac does not exist [ 12.792898] dracut Warning: Signal caught! [ 12.804047] dracut Warning: dracut: FATAL: FIPS integrity test failed [ 12.804143] dracut Warning: dracut: Refusing to continue dracut Warning: Signal caught! dracut Warning: dracut: FATAL: FIPS integrity test failed dracut Warning: dracut: Refusing to continue %G%Gdracut Warning: /boot//.vmlinuz-4.18.0-477.10.1.el8_8.x86_64.hmac does not exist dracut Warning: Signal caught! dracut Warning: dracut: FATAL: FIPS integrity test failed dracut Warning: dracut: Refusing to continue Generating "/run/initramfs/rdsosreport.txt" You might want to save "/run/initramfs/rdsosreport.txt" to a USB stick or /boot after mounting them and attach it to a bug report. To get more debug information in the report, reboot with "rd.debug" added to the kernel command line. Dropping to debug shell. dracut:/# Hi, to follow up on this. unfortunately, fips mode isn't supported by image-builder at present. You can add the kernel parameter to enable it manually, but the issue is that the `/boot` directory is on a different partition. So overall, this would be a feature request. We had a similar issue and discussion upstream with the OpenSCAP team and their blueprint generation tool [1]. There is an upstream issue for this as the OpenSCAP team was configuring the kernel parameter in the blueprint generation but, ultimately, they disabled the fips rule group. [1] https://github.com/ComplianceAsCode/content/issues/9559 Issue migration from Bugzilla to Jira is in process at this time. This will be the last message in Jira copied from the Bugzilla bug. This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there. Due to differences in account names between systems, some fields were not replicated. Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information. To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "RHEL-" followed by an integer. You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like: "Bugzilla Bug" = 1234567 In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information. |
Created attachment 1954709 [details] blueprint used Description of problem: Images built with composer/image builder fail to boot with an error: Warning: /boot//.vmlinuz-<kernel version>.x86_64.hmac does not exist FATAL: FIPS integrity test failed Refusing to continue Version-Release number of selected component (if applicable): osbuild-composer-core-62-3.el8_7.x86_64 osbuild-composer-dnf-json-62-3.el8_7.x86_64 osbuild-composer-worker-62-3.el8_7.x86_64 cockpit-composer-41-1.el8.noarch osbuild-composer-62-3.el8_7.x86_64 genisoimage-1.1.11-39.el8.x86_64 How reproducible: Every time an image is built with xccdf_org.ssgproject.content_profile_stig profile Steps to Reproduce: 1. Create a blueprint with the following: [customizations.openscap] datastream = "/usr/share/xml/scap/ssg/content/ssg-rhel8-ds-1.2.xml" profile_id = "xccdf_org.ssgproject.content_profile_stig" 2. Build the image (tested with both qcow2 and vmdk) 3. Boot the image Actual results: System fails to boot with an error that the .hmac for the kernel does not exist Expected results: The system should boot Additional info: I've tested with and without a scap user and got the same results: [[customizations.user]] name = "scap-security-guide" description = "Admin account" password = "hash" home = "/home/scap-security-guide" group = ["wheel"] I booted the system from an ISO and confirmed that the .hmac file does exist, as does the scap user. However the scap user is not part of the wheel group, not sure why or if that's relevant to the issue. System boots fine if FIPS is disabled. Manually enabling FIPS after installation with "fips-mode-setup --enable" works fine. Since the error message says the system is looking for an hmac at /boot//.vmlinuz, I'm wondering if this is an issue with the path it's using?