Skip to content

Update dependency bcrypt to v3.1.22 [SECURITY]#877

Merged
Taucher2003 merged 1 commit intomainfrom
renovate/rubygems-bcrypt-vulnerability
Apr 6, 2026
Merged

Update dependency bcrypt to v3.1.22 [SECURITY]#877
Taucher2003 merged 1 commit intomainfrom
renovate/rubygems-bcrypt-vulnerability

Conversation

@renovate
Copy link
Copy Markdown
Contributor

@renovate renovate bot commented Mar 19, 2026

This PR contains the following updates:

Package Change Age Adoption Passing Confidence Diffend
bcrypt 3.1.213.1.22 age adoption passing confidence Diff

GitHub Vulnerability Alerts

CVE-2026-33306

Impact

An integer overflow in the Java BCrypt implementation for JRuby can cause zero iterations in the strengthening loop. Impacted applications must be setting the cost to 31 to see this happen.

The JRuby implementation of bcrypt-ruby (BCrypt.java) computes the key-strengthening round count as a signed 32-bit integer. When cost=31 (the maximum allowed by the gem), signed integer overflow causes the round count to become negative, and the strengthening loop executes zero iterations. This collapses bcrypt from 2^31 rounds of exponential key-strengthening to effectively constant-time computation — only the initial EksBlowfish key setup and final 64x encryption phase remain.

The resulting hash looks valid ($2a$31$...) and verifies correctly via checkpw, making the weakness invisible to the application. This issue is triggered only when cost=31 is used or when verifying a $2a$31$ hash.

Patches

This problem has been fixed in version 3.1.22

Workarounds

Set the cost to something less than 31.


Configuration

📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot added the dependencies This updates dependency files label Mar 19, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 19, 2026

GitLab Pipeline Action

General information

Link to pipeline: https://gitlab.com/code0-tech/development/sagittarius/-/pipelines/2432797894

Status: Passed
Duration: 4 minutes

Job summaries

rspec: [ee]

Coverage report available at https://code0-tech.gitlab.io/-/development/sagittarius/-/jobs/13800066129/artifacts/tmp/coverage/index.html
Test summary available at https://gitlab.com/code0-tech/development/sagittarius/-/pipelines/2432797894/test_report
Finished in 24.82 seconds (files took 13.33 seconds to load)
1333 examples, 0 failures
Line Coverage: 92.64% (4306 / 4648)
[TEST PROF INFO] Time spent in factories: 00:12.802 (40.85% of total time)

rspec: [ce]

Coverage report available at https://code0-tech.gitlab.io/-/development/sagittarius/-/jobs/13800066127/artifacts/tmp/coverage/index.html
Test summary available at https://gitlab.com/code0-tech/development/sagittarius/-/pipelines/2432797894/test_report
Finished in 24.86 seconds (files took 10.7 seconds to load)
1286 examples, 0 failures
Line Coverage: 92.1% (4138 / 4493)
[TEST PROF INFO] Time spent in factories: 00:13.292 (42.66% of total time)

docs:preview

Documentation preview available at https://code0-tech.gitlab.io/-/development/telescopium/-/jobs/13800098043/artifacts/out/index.html

rubocop

735 files inspected, no offenses detected

@renovate renovate bot changed the title Update dependency bcrypt to v3.1.22 [SECURITY] Update dependency bcrypt to v3.1.22 [SECURITY] - autoclosed Mar 27, 2026
@renovate renovate bot closed this Mar 27, 2026
@renovate renovate bot deleted the renovate/rubygems-bcrypt-vulnerability branch March 27, 2026 01:44
@renovate renovate bot changed the title Update dependency bcrypt to v3.1.22 [SECURITY] - autoclosed Update dependency bcrypt to v3.1.22 [SECURITY] Mar 30, 2026
@renovate renovate bot reopened this Mar 30, 2026
@renovate renovate bot force-pushed the renovate/rubygems-bcrypt-vulnerability branch 2 times, most recently from 8b0cfe8 to b9569c1 Compare March 30, 2026 20:37
@Taucher2003 Taucher2003 enabled auto-merge April 6, 2026 20:50
@Taucher2003 Taucher2003 merged commit dc5788d into main Apr 6, 2026
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies This updates dependency files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant