Bug 2096911

Summary: Add support for rules `lock root account` and `allow root ssh login with password`
Product: Red Hat Enterprise Linux 9 Reporter: Marek Haicman <mhaicman>
Component: oscap-anaconda-addonAssignee: Matěj Týč <matyc>
Status: CLOSED MIGRATED QA Contact: Release Test Team <release-test-team-automation>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 9.0CC: jstodola, mhaicman, wsato
Target Milestone: rcKeywords: MigratedToJIRA, TestCaseNeeded, Triaged
Target Release: ---Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-08-31 10:02:44 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 Marek Haicman 2022-06-14 14:30:49 UTC
Description of problem:
Anaconda added option to "Allow root SSH login with password" into GUI to circumvent default change in the SSH. As the `scap-security-guide` profiles in many cases require `PermitRootLogin no`, we are directly countering this option. Given the paradigm that whatever is configured by Anaconda is integrated as a special Anaconda-based check, we need it as well.

Version-Release number of selected component (if applicable):
2.0.0-8.el9

How reproducible:
reliably

Steps to Reproduce:
1. begin GUI installation of RHEL9
2. select OSPP profile
3. create root password, tick "allow root ssh login with password"
4. start installation
5. finish installation

Actual results:
no issue is encountered, /etc/ssh/sshd_config contains line
PermitRootLogin no

Expected results:
Installation won't start, as there's conflict of requirements

Additional info:
Anaconda team plans to add kickstart support via Bug 2033849 into 9.1

Comment 2 Marek Haicman 2022-06-15 17:12:20 UTC
To extend expected result:
When the misalignment happens (i.e. profile selected is opinionated about the option and the configuration in the "root password" spoke is not align with that), the addon hub icon should reflect the issue (or the issue can be represented any other way), and installation should not be allowed to start.

Comment 8 RHEL Program Management 2023-08-31 06:59:29 UTC
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.

Comment 9 RHEL Program Management 2023-08-31 10:02:44 UTC
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.

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.

Users watching this BZ may not be automatically added to the Jira ticket.  Be sure to add yourself to the Watchers field in the Jira issue if you desire to continue following this issue.