Skip to content

CNF-21212: RAN Hardening (5.0) - PAM Empty Passwords (H2)#821

Open
sebrandon1 wants to merge 1 commit into
openshift-kni:mainfrom
sebrandon1:compliance/5.0/h2-pam-nullok
Open

CNF-21212: RAN Hardening (5.0) - PAM Empty Passwords (H2)#821
sebrandon1 wants to merge 1 commit into
openshift-kni:mainfrom
sebrandon1:compliance/5.0/h2-pam-nullok

Conversation

@sebrandon1

@sebrandon1 sebrandon1 commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds MachineConfig to remove the nullok option from PAM authentication on both master and worker nodes.

This addresses a HIGH severity finding from the ACSC Essential Eight compliance profile — the no_empty_passwords rule requires preventing authentication with empty passwords.

  • Deploys the correct RHCOS 9 /etc/pam.d/system-auth with nullok removed
  • Uses the actual RHCOS 9 PAM stack (not the broken operator-generated RHEL 8 template)
  • Separate master and worker MachineConfig files

Upstream

We have an open PR to fix this in the RHCOS base image so this MachineConfig remediation would no longer be needed:

We also have an upstream fix for the broken compliance-operator remediation:

Remediation Group

Files

  • 75-pam-auth-high-master.yaml
  • 75-pam-auth-high-worker.yaml

Verification

After applying to a cluster, verify with:

oc debug node/ -- chroot /host grep nullok /etc/pam.d/system-auth
# Expected: no output (nullok removed)

Jira

Supersedes #736 — migrated from compliance/4.22/* to compliance/5.0/* branch naming.

OCP 5.0 Verification (2026-06-22)

Cluster: cnfdt16 — OCP 5.0.0-0.nightly-2026-06-18-000016, RHCOS 10.2

Finding: Hardening still needed. RHCOS 10 authselect templates still ship with nullok.

$ grep nullok /etc/authselect/system-auth
auth        sufficient    pam_unix.so nullok
password    sufficient    pam_unix.so yescrypt shadow nullok use_authtok

$ grep nullok /etc/authselect/password-auth
auth        sufficient    pam_unix.so nullok
password    sufficient    pam_unix.so yescrypt shadow nullok use_authtok

$ authselect current
Profile ID: local
Enabled features: None     # without-nullok NOT enabled

The without-nullok authselect feature exists but is not enabled by default. Upstream PRs (coreos/rhel-coreos-config#255, ComplianceAsCode/content#14602) remain open.

@openshift-ci-robot

openshift-ci-robot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

@sebrandon1: This pull request references CNF-21212 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.0.0" version, but no target version was set.

Details

In response to this:

Summary

Adds MachineConfig to remove the nullok option from PAM authentication on both master and worker nodes.

This addresses HIGH severity E8 compliance check rhcos4-e8-no-empty-passwords which requires preventing authentication with empty passwords.

  • Deploys the correct RHCOS 9 /etc/pam.d/system-auth with nullok removed
  • Uses the actual RHCOS 9 PAM stack (not the broken operator-generated RHEL 8 template)
  • Separate master and worker MachineConfig files

Upstream

We have an open PR to fix this in the RHCOS base image so this MachineConfig remediation would no longer be needed:

We also have an upstream fix for the broken compliance-operator remediation:

Remediation Group

Files

  • 75-pam-auth-high-master.yaml
  • 75-pam-auth-high-worker.yaml

Verification

After applying to a cluster, verify with:

oc debug node/ -- chroot /host grep nullok /etc/pam.d/system-auth
# Expected: no output (nullok removed)

Jira

Supersedes #736 — migrated from compliance/4.22/* to compliance/5.0/* branch naming.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci Bot requested review from sabbir-47 and yuvalk June 22, 2026 17:00
@openshift-ci

openshift-ci Bot commented Jun 22, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: sebrandon1
Once this PR has been reviewed and has the lgtm label, please assign irinamihai for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@coderabbitai

coderabbitai Bot commented Jun 22, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@sebrandon1, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 59 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Enterprise

Run ID: 916bb8e8-bf07-47cf-9c5d-86d3cf244216

📥 Commits

Reviewing files that changed from the base of the PR and between 78962de and 3a79a7a.

📒 Files selected for processing (2)
  • telco-ran/configuration/kube-compare-reference/informational/hardening/75-pam-auth-high-master.yaml
  • telco-ran/configuration/kube-compare-reference/informational/hardening/75-pam-auth-high-worker.yaml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@openshift-ci-robot

openshift-ci-robot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

@sebrandon1: This pull request references CNF-21212 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.0.0" version, but no target version was set.

Details

In response to this:

Summary

Adds MachineConfig to remove the nullok option from PAM authentication on both master and worker nodes.

This addresses HIGH severity E8 compliance check rhcos4-e8-no-empty-passwords which requires preventing authentication with empty passwords.

  • Deploys the correct RHCOS 9 /etc/pam.d/system-auth with nullok removed
  • Uses the actual RHCOS 9 PAM stack (not the broken operator-generated RHEL 8 template)
  • Separate master and worker MachineConfig files

Upstream

We have an open PR to fix this in the RHCOS base image so this MachineConfig remediation would no longer be needed:

We also have an upstream fix for the broken compliance-operator remediation:

Remediation Group

Files

  • 75-pam-auth-high-master.yaml
  • 75-pam-auth-high-worker.yaml

Verification

After applying to a cluster, verify with:

oc debug node/ -- chroot /host grep nullok /etc/pam.d/system-auth
# Expected: no output (nullok removed)

Jira

Supersedes #736 — migrated from compliance/4.22/* to compliance/5.0/* branch naming.

OCP 5.0 Verification (2026-06-22)

Cluster: cnfdt16 — OCP 5.0.0-0.nightly-2026-06-18-000016, RHCOS 10.2

Finding: Hardening still needed. RHCOS 10 authselect templates still ship with nullok.

$ grep nullok /etc/authselect/system-auth
auth        sufficient    pam_unix.so nullok
password    sufficient    pam_unix.so yescrypt shadow nullok use_authtok

$ grep nullok /etc/authselect/password-auth
auth        sufficient    pam_unix.so nullok
password    sufficient    pam_unix.so yescrypt shadow nullok use_authtok

$ authselect current
Profile ID: local
Enabled features: None     # without-nullok NOT enabled

The without-nullok authselect feature exists but is not enabled by default. Upstream PRs (coreos/rhel-coreos-config#255, ComplianceAsCode/content#14602) remain open.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot

openshift-ci-robot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

@sebrandon1: This pull request references CNF-21212 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.0.0" version, but no target version was set.

Details

In response to this:

Summary

Adds MachineConfig to remove the nullok option from PAM authentication on both master and worker nodes.

This addresses a HIGH severity finding from the ACSC Essential Eight compliance profile — the no_empty_passwords rule requires preventing authentication with empty passwords.

  • Deploys the correct RHCOS 9 /etc/pam.d/system-auth with nullok removed
  • Uses the actual RHCOS 9 PAM stack (not the broken operator-generated RHEL 8 template)
  • Separate master and worker MachineConfig files

Upstream

We have an open PR to fix this in the RHCOS base image so this MachineConfig remediation would no longer be needed:

We also have an upstream fix for the broken compliance-operator remediation:

Remediation Group

Files

  • 75-pam-auth-high-master.yaml
  • 75-pam-auth-high-worker.yaml

Verification

After applying to a cluster, verify with:

oc debug node/ -- chroot /host grep nullok /etc/pam.d/system-auth
# Expected: no output (nullok removed)

Jira

Supersedes #736 — migrated from compliance/4.22/* to compliance/5.0/* branch naming.

OCP 5.0 Verification (2026-06-22)

Cluster: cnfdt16 — OCP 5.0.0-0.nightly-2026-06-18-000016, RHCOS 10.2

Finding: Hardening still needed. RHCOS 10 authselect templates still ship with nullok.

$ grep nullok /etc/authselect/system-auth
auth        sufficient    pam_unix.so nullok
password    sufficient    pam_unix.so yescrypt shadow nullok use_authtok

$ grep nullok /etc/authselect/password-auth
auth        sufficient    pam_unix.so nullok
password    sufficient    pam_unix.so yescrypt shadow nullok use_authtok

$ authselect current
Profile ID: local
Enabled features: None     # without-nullok NOT enabled

The without-nullok authselect feature exists but is not enabled by default. Upstream PRs (coreos/rhel-coreos-config#255, ComplianceAsCode/content#14602) remain open.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@sebrandon1 sebrandon1 force-pushed the compliance/5.0/h2-pam-nullok branch 2 times, most recently from 64092b7 to fe65996 Compare June 26, 2026 18:06
Remove nullok from PAM system-auth and password-auth on both
master and worker nodes.
@sebrandon1 sebrandon1 force-pushed the compliance/5.0/h2-pam-nullok branch from fe65996 to 3a79a7a Compare June 29, 2026 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants