The Ruby team released Ruby 3.3.14, 3.4.13 and 4.0.10 on November 18 to fix seven memory safety flaws, and Ruby says it knows of proofs of concept that turn some of them into remote code execution. The one drawing the most attention is ruby2shell (CVE-2026-132825). Cloudflare said on its blog on November 20 that default Ruby on Rails and classic-style Sinatra apps reach the bug before any login check runs. Details are in Ruby’s security advisory.

What’s new

The main flaw is a one-byte heap overflow in the way Ruby changes the case of strings in older single-byte encodings such as Latin-1 and Windows-1252. Cloudflare, citing the researchers at Veria Labs, explains that an attacker can send a crafted form request that Rails and Sinatra upcase while routing it, before any application code runs. UTF-8 strings take a different code path and aren’t affected.

The same releases fix a related integer overflow and five bugs in Ruby’s regular expression engine. Most of those need an app that compiles or matches a pattern a user typed in, which does happen in search boxes, filter rules and admin tools. Cloudflare has added blocking rules for ruby2shell to its free and paid managed WAF rulesets. Veria Labs plans to publish its own proof of concept about a week after disclosure, so expect scanning to follow.

Who it affects

  • Rails or Sinatra apps on Ruby 3.3.13 or earlier, 3.4.0 to 3.4.12, or 4.0.0 to 4.0.9.
  • Self-hosted products that ship their own Ruby. Cloudflare names GitLab, GitHub Enterprise Server, Mastodon, OpenProject, Discourse and Chatwoot.
  • Anything still on Ruby 3.2 or older. Those versions are past end of life and won’t get these fixes.

Sites on WordPress or a hosted builder don’t run a Ruby runtime you manage, so there’s nothing for you to patch there. If you run WordPress, this week’s PHP security release is the one to check instead.

Our take

If a developer built you a Rails app, or you self-host a help desk like Chatwoot or a community forum on Discourse, ask this week which Ruby version it runs. We’re telling clients to upgrade to 3.3.14, 3.4.13 or 4.0.10, restart every Ruby process including background workers, and rebuild any Docker images. If the app sits behind Cloudflare, confirm the managed ruleset is switched on and lock the origin server so traffic can’t go around it. A WAF buys time; the upgrade is the fix.

Want someone to check your stack and keep it patched? Our website maintenance and IT consulting teams can take a look.