Skip to content

OCPBUGS-85497: only check password hash in /etc/shadow#6030

Open
cheesesashimi wants to merge 1 commit into
openshift:mainfrom
cheesesashimi:zzlotnik/fix-testnoreboot
Open

OCPBUGS-85497: only check password hash in /etc/shadow#6030
cheesesashimi wants to merge 1 commit into
openshift:mainfrom
cheesesashimi:zzlotnik/fix-testnoreboot

Conversation

@cheesesashimi
Copy link
Copy Markdown
Member

- What I did

In #5889, some changes were introduced to how password changes are done. This had the side-effect of breaking the TestNoReboot E2E test. The root cause of the test failure is that the E2E test was considering the entire line in /etc/shadow when it should only consider whether the password hash changed.

The reason why is because the 3rd column changed during the password change to reflect the day of the password change. Technically speaking, if one were to change their password multiple times in a single day, this value would only change oncee. By comparison, the E2E test should only consider whether the password hash was changed without giving consideration to when it was changed.

This PR remedies this situation.

- How to verify it

Run the /test e2e-gcp-op-part1 on this PR and ensure that TestNoReboot passes.

- Description for the changelog
TestNoReboot should only consider the password hash

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: LGTM mode

@openshift-ci-robot openshift-ci-robot added jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. labels May 12, 2026
When usermod -P is used, the last password change field is changed. When
the MachineConfig is rolled back, this value remains the same even
though the actual password value has been changed back to its previous
value. Consequently, the E2E test should only compare the password hashes instead of the full line.

Assisted-By: Claude Opus 4.6
@openshift-ci-robot openshift-ci-robot added the jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. label May 12, 2026
@openshift-ci-robot
Copy link
Copy Markdown
Contributor

@cheesesashimi: This pull request references Jira Issue OCPBUGS-85497, which is invalid:

  • expected the bug to target either version "5.0." or "openshift-5.0.", but it targets "4.23" instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

- What I did

In #5889, some changes were introduced to how password changes are done. This had the side-effect of breaking the TestNoReboot E2E test. The root cause of the test failure is that the E2E test was considering the entire line in /etc/shadow when it should only consider whether the password hash changed.

The reason why is because the 3rd column changed during the password change to reflect the day of the password change. Technically speaking, if one were to change their password multiple times in a single day, this value would only change oncee. By comparison, the E2E test should only consider whether the password hash was changed without giving consideration to when it was changed.

This PR remedies this situation.

- How to verify it

Run the /test e2e-gcp-op-part1 on this PR and ensure that TestNoReboot passes.

- Description for the changelog
TestNoReboot should only consider the password hash

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.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 12, 2026

Warning

Rate limit exceeded

@cheesesashimi has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 36 minutes and 16 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 92c6744f-3cb5-4785-b415-61d1aecb2c7c

📥 Commits

Reviewing files that changed from the base of the PR and between 99cb8a4 and 749f4e3.

📒 Files selected for processing (1)
  • test/e2e-1of2/mcd_test.go
✨ 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 and usage tips.

@openshift-ci openshift-ci Bot requested review from RishabhSaini and djoshy May 12, 2026 19:28
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented May 12, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cheesesashimi

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

The pull request process is described 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

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 12, 2026
@cheesesashimi cheesesashimi force-pushed the zzlotnik/fix-testnoreboot branch from 4286cd2 to 749f4e3 Compare May 12, 2026 19:29
@cheesesashimi
Copy link
Copy Markdown
Member Author

/test e2e-gcp-op-part1

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented May 12, 2026

@cheesesashimi: all tests passed!

Full PR test history. Your PR dashboard.

Details

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 kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants