Skip to content

OCPBUGS-44505: remove crypto-browserify library and use Crypto instead#14507

Closed
Mylanos wants to merge 2 commits intoopenshift:mainfrom
Mylanos:crypto-browserify-removal-attempt
Closed

OCPBUGS-44505: remove crypto-browserify library and use Crypto instead#14507
Mylanos wants to merge 2 commits intoopenshift:mainfrom
Mylanos:crypto-browserify-removal-attempt

Conversation

@Mylanos
Copy link
Contributor

@Mylanos Mylanos commented Nov 18, 2024

This PR replaces the use of crypto-browserify for generating a hash for a given username with the native Crypto object and its subtle.digest method, which is supported in all browsers compatible with v4.21. This way we not only remove unnecessary dependencies, but also use browser-optimized native cryptographic functionality.

Changes in this PR:

  • Replaced crypto-browserify's createHash function with a newly implemented generateHash function that utilizes browser-native Crypto.subtle.digest.
  • Removed crypto-browserify from the dependencies as this was its sole usage in the codebase.

@openshift-ci-robot openshift-ci-robot added jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Nov 18, 2024
@openshift-ci-robot
Copy link
Contributor

@Mylanos: This pull request references Jira Issue OCPBUGS-44505, which is invalid:

  • expected the bug to target the "4.18.0" version, but no target version was set

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:

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 cajieh and spadgett November 18, 2024 15:02
@openshift-ci openshift-ci bot added the component/shared Related to console-shared label Nov 18, 2024
@Mylanos Mylanos force-pushed the crypto-browserify-removal-attempt branch from abdbd47 to c771cf1 Compare November 19, 2024 11:56
@Mylanos
Copy link
Contributor Author

Mylanos commented Nov 19, 2024

/jira refresh

@openshift-ci-robot openshift-ci-robot added jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. and removed jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Nov 19, 2024
@openshift-ci-robot
Copy link
Contributor

@Mylanos: This pull request references Jira Issue OCPBUGS-44505, which is valid. The bug has been moved to the POST state.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.18.0) matches configured target version for branch (4.18.0)
  • bug is in the state ASSIGNED, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @yapei

Details

In response to this:

/jira refresh

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 a review from yapei November 19, 2024 12:16
@cajieh
Copy link
Contributor

cajieh commented Nov 20, 2024

/retest

2 similar comments
@Mylanos
Copy link
Contributor Author

Mylanos commented Nov 21, 2024

/retest

@Mylanos
Copy link
Contributor Author

Mylanos commented Nov 22, 2024

/retest

Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

👍

@openshift-ci openshift-ci bot added lgtm Indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Nov 22, 2024
@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

10 similar comments
@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d878879 and 2 for PR HEAD c771cf1d2e1dac5526e99c783bc3e402c89210c5 in total

@openshift-ci-robot
Copy link
Contributor

@logonoff: This pull request references Jira Issue OCPBUGS-44505, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.21.0) matches configured target version for branch (4.21.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @yapei

Details

In response to this:

to be honest this looks mergable as-is

/retitle OCPBUGS-44505: remove crypto-browserify library and use Crypto instead
/unhold
/jira refresh
/lgtm

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 removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. labels Oct 2, 2025
@logonoff
Copy link
Member

logonoff commented Oct 2, 2025

/retest

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Oct 2, 2025
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 2, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: logonoff, Mylanos, spadgett

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

@logonoff
Copy link
Member

logonoff commented Oct 2, 2025

/verified later @yapei

@openshift-ci-robot openshift-ci-robot added verified-later verified Signifies that the PR passed pre-merge verification criteria labels Oct 2, 2025
@openshift-ci-robot
Copy link
Contributor

@logonoff: This PR has been marked to be verified later by @yapei.

Details

In response to this:

/verified later @yapei

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
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 1e64b1f and 2 for PR HEAD 51d84f5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 90b613a and 1 for PR HEAD 51d84f5 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 1bae6b5 and 0 for PR HEAD 51d84f5 in total

@openshift-ci-robot
Copy link
Contributor

/hold

Revision 51d84f5 was retested 3 times: holding

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 4, 2025
@logonoff
Copy link
Member

/retest

@jhadvig
Copy link
Member

jhadvig commented Dec 2, 2025

Screenshot 2025-12-02 at 16 08 32

/retest

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Dec 2, 2025

@Mylanos: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-gcp-console 51d84f5 link true /test e2e-gcp-console

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.

@openshift-bot
Copy link
Contributor

/jira refresh

The requirements for Jira bugs have changed (Jira issues linked to PRs on main branch need to target different OCP), recalculating validity.

@openshift-ci-robot openshift-ci-robot added jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. and removed jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Dec 12, 2025
@openshift-ci-robot
Copy link
Contributor

@openshift-bot: This pull request references Jira Issue OCPBUGS-44505, which is invalid:

  • expected the bug to be open, but it isn't
  • expected the bug to target either version "4.22." or "openshift-4.22.", but it targets "4.21.0" instead
  • expected the bug to be in one of the following states: NEW, ASSIGNED, POST, but it is Closed (Done) 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:

/jira refresh

The requirements for Jira bugs have changed (Jira issues linked to PRs on main branch need to target different OCP), recalculating validity.

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
Contributor

coderabbitai bot commented Dec 12, 2025

Important

Review skipped

Auto reviews are limited based on label configuration.

🚫 Review skipped — only excluded labels are configured. (1)
  • do-not-merge/work-in-progress

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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

@logonoff
Copy link
Member

/close

Removed in #15892 but in another way

@openshift-merge-robot openshift-merge-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 17, 2026
@openshift-merge-robot
Copy link
Contributor

PR needs rebase.

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.

@openshift-ci openshift-ci bot closed this Jan 17, 2026
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 17, 2026

@logonoff: Closed this PR.

Details

In response to this:

/close

Removed in #15892 but in another way

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.

@openshift-ci-robot
Copy link
Contributor

@Mylanos: This pull request references Jira Issue OCPBUGS-44505. The bug has been updated to no longer refer to the pull request using the external bug tracker.

Details

In response to this:

This PR replaces the use of crypto-browserify for generating a hash for a given username with the native Crypto object and its subtle.digest method, which is supported in all browsers compatible with v4.21. This way we not only remove unnecessary dependencies, but also use browser-optimized native cryptographic functionality.

Changes in this PR:

  • Replaced crypto-browserify's createHash function with a newly implemented generateHash function that utilizes browser-native Crypto.subtle.digest.
  • Removed crypto-browserify from the dependencies as this was its sole usage in the codebase.

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.

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. component/core Related to console core functionality component/shared Related to console-shared do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. verified Signifies that the PR passed pre-merge verification criteria verified-later

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants