Ruby security updates fix seven memory-safety flaws

Ruby has released 4.0.10, 3.4.13 and 3.3.14 to address seven vulnerabilities in regular expressions and string case conversion. Its security team says proof-of-concept exploits demonstrate remote…

SSophie Harrington2 min read

Ruby has released 4.0.10, 3.4.13 and 3.3.14 to address seven vulnerabilities in regular expressions and string case conversion. Its security team says proof-of-concept exploits demonstrate remote code execution for some of the flaws and strongly recommends upgrading.

The official advisory carries an 18 November page date and records its original publication as 19 November at 00:00 UTC. This is a runtime update for teams operating Ruby applications, including commerce integrations built on Rails; it is not evidence that every Rails app is exploitable.

Exposure depends on what the application processes

One critical advisory describes a one-byte heap buffer overflow during case conversion in certain single-byte encodings, including ISO-8859-1 and Windows-1252. Other findings concern operations on regular expressions, with several depending on an application compiling attacker-controlled patterns. These are different paths through the runtime, so a check of one encoding or input handler is not a substitute for applying the fixes.

The official pages reviewed for this report identify the vulnerabilities by GHSA IDs and say CVE assignments are pending. We are using those identifiers rather than treating a CVE number circulating in social reports as confirmed by Ruby.

Choose the patched release for your branch

Ruby’s affected-version list covers 3.3.13 and earlier, 3.4.0 through 3.4.12, and 4.0.0 through 4.0.9. The corresponding fixes are 3.3.14, 3.4.13 and 4.0.10. Ruby 3.2 and earlier are end of life and will not receive these fixes, according to the project.

For an app team, our practical checklist is to update the runtime declaration and deployment image, rebuild, run the application’s regression tests and redeploy. Verify the version in the running service and in background workers, not only in CI. Updating gems alone does not replace the Ruby binary.

Prioritise a review of code that accepts user-supplied regular expressions or converts untrusted text into legacy encodings. Keep any investigation of affected input paths alongside the upgrade, rather than delaying the upgrade until every possible path has been ruled out. Merchants using a hosted app should ask its operator about deployment status instead of assuming they control the underlying runtime.

ℹ️
Ruby 3.2 and earlier will not receive these fixes. If you still operate an end-of-life branch, plan a move to a supported patched branch.
Filed underNews

More from News

See all →