# CVE-2026-54905: Ruby concurrent-ruby mutual exclusion bypass in ReentrantReadWriteLock

Source: https://junglewise.ai/threats/cve-2026-54905-ruby-concurrent-ruby-mutual-exclusion-bypass-in  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-06-24. Updated: 2026-06-24  
License: CC BY 4.0 with a link back

CVE-2026-54905 · Severity: low · CVSS 3.1 · Published 2026-06-24

A flaw in the concurrent-ruby library, a tool used by Ruby developers to manage multi-threaded tasks, can cause data protection mechanisms to fail. Specifically, if a program performs a very high number of repeated read operations, the system may incorrectly grant a "write lock" that is supposed to be exclusive. This means two different parts of a program could modify and read the same data simultaneously, potentially leading to data corruption or unpredictable application behavior.

Technologies: [concurrent-ruby (RubyGems)](https://junglewise.ai/threats/technologies/concurrent-ruby). Vendors: [RubyGems](https://junglewise.ai/threats/vendors/rubygems).

## Quick answers

**Is CVE-2026-54905 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-54905 being exploited in the wild.

**How severe is CVE-2026-54905?** Low severity, with a CVSS score of 3.1, published 24 June 2026.

**Which products and versions are affected?** concurrent-ruby (RubyGems) < 1.3.7, ECOSYSTEM:introduced=0,fixed=1.3.7.

**Is there a fix for CVE-2026-54905?** Yes. concurrent-ruby (RubyGems): upgrade to 1.3.7 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-54905 attacked?** It is attacked with local access, in a software library.

**Am I affected by CVE-2026-54905?** Check whether you run concurrent-ruby (RubyGems) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- concurrent-ruby (RubyGems): upgrade to 1.3.7 or later

  ```sh
  bundle update concurrent-ruby
  ```


## Technical details

A wrap-around error (CWE-128) exists in the Concurrent::ReentrantReadWriteLock implementation where local read and write hold counts are stored in a single integer. The low 15 bits track the read hold count, while bit 15 represents the WRITE_LOCK_HELD flag. When a thread acquires a read lock 32,768 times, the counter overflows into bit 15. Subsequent calls to try_write_lock observe this bit, incorrectly conclude the thread already holds the write lock, and return true without setting the global RUNNING_WRITER bit. This allows other threads to continue acquiring read locks while the primary thread believes it has exclusive write access, leading to race conditions. The issue is fixed in version 1.3.7.

## Affected products

- ruby-concurrency concurrent-ruby < 1.3.7

## Identifiers

- CVE-2026-54905
- GHSA-wv3x-4vxv-whpp

## Timeline

- 2026-06-16: advisory: GitHub Security Advisory published
- 2026-06-24: disclosed: NVD publication date
- 2026-06-24: patched: Fix released in version 1.3.7

## References

- [https://github.com/ruby-concurrency/concurrent-ruby/security/advisories/GHSA-wv3x-4vxv-whpp](https://github.com/ruby-concurrency/concurrent-ruby/security/advisories/GHSA-wv3x-4vxv-whpp)

## Related threats

- [ruby-concurrency concurrent-ruby improper locking in ReadWriteLock](https://junglewise.ai/threats/cve-2026-54906-ruby-concurrency-concurrent-ruby-improper-locking-in)
- [ruby-concurrency concurrent-ruby denial of service in AtomicReference](https://junglewise.ai/threats/cve-2026-54904-ruby-concurrency-concurrent-ruby-denial-of-service-in)
