Vulnerability · patch available

Ruby2Shell CVE-2026-132825A crafted form field can put Rails and classic Sinatra applications at risk without authentication

On November 18, 2026, the Ruby project released versions 3.3.14, 3.4.13 and 4.0.10, closing seven flaws. Veria Labs calls the best known of them, CVE-2026-132825, “Ruby2Shell”: when Ruby converts a long sequence of the character “ß” (21 or more) to uppercase in an older single-byte encoding such as ISO-8859-1 or Windows-1252, one byte ends up beyond the reserved memory. According to the discoverers, in Rails and classic Sinatra applications a crafted form field is enough to trigger this, without authentication. According to Ruby, proofs of concept demonstrate code execution in some scenarios; no attacks are known so far.

  • Ruby: critical · CVSS 7.4 (MITRE) · 9.8 (Red Hat, preliminary)
  • Affected: Ruby 2.4.0 up to 3.3.13, 3.4.12 and 4.0.9
  • Fix: Ruby 3.3.14, 3.4.13 and 4.0.10 of November 18, 2026
  • Exposed: Rails (not in API mode) and classic Sinatra

At a glance

What happened and what it means for you

Ruby2Shell is not in a gem but in the Ruby interpreter itself. For 14 older single-byte encodings, including ISO-8859-1 and Windows-1252, Ruby turns “ß” into “SS” when converting to uppercase, but only checks that there is room for one byte. With 21 “ß” characters, Ruby therefore writes one byte past the end of the memory buffer. Three questions determine whether you are affected: Ruby version, framework and whether attackers can inject text in such an encoding. [1][3][4]

  1. The interpreter is affected, not your code. Any application on a vulnerable Ruby can be open to attack if it processes externally supplied text in one of the affected encodings with upcase, swapcase, downcase(:fold) or casecmp?, even if its own code is free of errors.
  2. Rails and Sinatra provide the way in. For forms, Rack, the foundation of both frameworks, reads the _method field, which browsers use to emulate PATCH or DELETE requests, and converts its value to uppercase. In multipart forms, the sender determines the field’s encoding. According to Veria Labs, this is the default configuration in Rails and classic Sinatra; API-only Rails applications do not include this middleware.
  3. Found multiple times, exploits built. According to the Ruby advisory, the flaw was reported by Stephan Lipp (Ada Logics) and Anthropic. Moritz Sanft found it with the AI tool Codex, and OpenAI also reported it to Ruby on November 5; by its own account, Veria Labs found it independently. Sanft and Veria Labs report working exploits against freshly created Rails applications.
  4. The fix is a Ruby update, often hidden in images and products. Container images must be rebuilt and processes restarted, and products with their own Ruby, such as GitLab, Mastodon or GitHub Enterprise Server, need their vendor’s update.
  5. Old versions remain unpatched. Ruby 3.2 and older no longer receive a fix. Here, only an upgrade or distribution packages with a backport help, for example in Debian 12, Ubuntu or Amazon Linux 2023.

What is established

  • On November 18, Ruby released versions 3.3.14, 3.4.13 and 4.0.10; they close seven flaws in the Regexp engine and in case conversion that are described in the advisory.
  • According to Ruby, there are proofs of concept that demonstrate code execution in some scenarios. So far, only proofs of concept that trigger a crash have been made public; Veria Labs plans to publish its exploit against Rails on November 25.
  • Debian, Ubuntu, Alpine, Amazon Linux, Homebrew, the official Docker images, Heroku and GitLab provide patched versions.
  • On November 19, Cloudflare, AWS, Fastly and CrowdSec published WAF rules against the known attack path; Germany’s Federal Office for Information Security (BSI) has issued a warning with the risk rating “high”.
  • The flaw is not in CISA’s KEV catalog; no attacks are known so far.

What remains unclear

  • When Red Hat, SUSE and the stable branches of Fedora and Arch Linux will release patched packages; as of November 21, they had not yet done so.
  • When GitHub Enterprise Server will get a fix; according to Veria Labs, all versions up to 3.22.5 are vulnerable.
  • When AWS will update the managed Lambda runtimes for Ruby.
  • Whether attackers will exploit the flaw widely once the exploit has been published.
  • How the NVD will rate the flaw; it has no score of its own yet.
Attack chain

How a form field turns into a memory error

Moritz Sanft and Veria Labs describe the first three steps publicly, and the source code of Rack and Rails confirms them. The discoverers will only show how the overflow turns into code execution with the announced proof of concept. [4][3][30][47][48]

  1. According to the discoverers

    Crafted form request

    Attackers send a form request (multipart/form-data) with a field named _method. In the field’s header, they set an affected encoding, such as charset=ISO-8859-1, and fill the field with “ß”.

  2. According to the discoverers

    Rack converts to uppercase

    Rack applies the specified encoding to the field content. The Rack::MethodOverride middleware, which lets browsers make PATCH and DELETE requests, reads the field even before routing, the CSRF check and authentication, and converts its value to uppercase with upcase.

  3. According to the discoverers

    One byte past the end

    For the result, Ruby reserves the input length plus 20 bytes, but each “ß” becomes “SS”. With 21 “ß” characters, exactly one byte is left free after the twentieth, but the twenty-first needs two: Ruby writes an “S” past the end of the buffer and reads one byte too many when copying.

  4. According to the discoverers · details withheld

    Shaping memory

    Through the length of the input, attackers control the size of the buffer and thus which data the stray byte hits. According to Moritz Sanft, this worked both with the jemalloc memory allocator and with glibc’s default allocator.

  5. According to the discoverers · details withheld

    Code execution

    According to Veria Labs and Moritz Sanft, the end result is code execution in the application’s process, demonstrated on freshly created Rails applications. VamiSec assessment: failed attempts can crash the process; application servers usually restart workers, so attackers can repeat the attempt.

What Ruby2Shell is not

  • Not a bug in a gem: bundle update alone does not help; the flaw is in the interpreter.
  • Not a UTF-8 flaw: text in UTF-8 takes a different code path and is not affected. It becomes dangerous when attackers can force a single-byte encoding. The sister flaw GHSA-87fm-7w84-j2px also affects UTF-8 but can only be reached via _method up to Rack 3.2.1; the Ruby update closes both.
  • Not reachable from the outside everywhere: according to Veria Labs and Semgrep, Rails in API mode, modular Sinatra, other frameworks and plain Rack are not exposed by default, but your own code can open up the path.

Why the flaw is still urgent

  • A single request without authentication reaches the bug, and Rails is one of the most widely used web frameworks.
  • Several teams have built working exploits. So far, only crash proofs of concept without code execution are public; Veria Labs has announced a code execution PoC for November 25.
  • Ruby is inside products that people do not think of as Ruby, such as GitLab, GitHub Enterprise Server, Mastodon or Discourse.
  • The bug has existed since Ruby 2.4.0 from 2016, so a correspondingly large number of old installations are affected.
Assessment

Why the ratings differ

The scores are far apart because the raters assess the attack path differently. MITRE assumes a local attack with high complexity, while Red Hat and Veria Labs assume an attack over the network without authentication. For reachable Rails and Sinatra applications, the second view is what counts.

CriticalRating by the Ruby project

The advisory on GitHub rates the flaw as critical, without a CVSS score. Veria Labs cites access over the network without authentication. [2][3]

7.4CVSS 3.1 according to MITRE

“High”, with a local attack vector and high complexity. Amazon’s score is 8.1, SUSE’s 7.4; the NVD does not yet have its own score. [5][6][20][16]

9.8CVSS 3.1 according to Red Hat

Preliminary: attack over the network, without authentication and without user interaction. Red Hat rates the flaw as critical. [11]

NoIn the CISA KEV catalog

As of November 21, no known exploitation, EPSS 0.19% (November 20). In its SSVC assessment, CISA rates the potential impact as “total”. [32][31][5]

One byte is enough, with effort

One-byte overflows are well-known building blocks of heap exploits because they can alter the metadata of adjacent memory blocks; here, attackers control the buffer size through the length of their input. Red Hat emphasizes that an attack requires a deliberately shaped memory layout. Moritz Sanft, by contrast, reports code execution even with glibc’s default memory allocator. VamiSec assessment: a failed attempt often goes unnoticed or ends in a crash; however, the Ruby project also confirms that code execution is possible. [4][11]

A legacy from 2016

Since Ruby 2.4.0, upcase and related methods have handled characters beyond ASCII, and according to Veria Labs, the bug has been in the code ever since. Because the affected encodings have no capital “ẞ”, “ß” becomes “SS”: one character turns into two. The conversion, however, only checked for room for one. The fix adds a check for two bytes in 14 encoding files. [33][3][7]

Found multiple times, including with AI

By his own account, Moritz Sanft let OpenAI’s AI tool Codex map Ruby’s attack surface and had several findings after less than 24 hours. The Ruby advisory names Stephan Lipp (Ada Logics) and Anthropic as the reporters; by its own account, Veria Labs found the bug independently. VamiSec assessment: when several teams find the same bug, the time until a public exploit shrinks, and patch processes must keep pace. [4][1][3]

Timeline

From Unicode extension to critical flaw

The faulty code entered Ruby almost ten years ago with an extension and went undetected for a long time. In the fall of 2026, several teams then found it within a few weeks.

  1. Vendor

    Ruby 2.4.0 extends case conversion

    Since this version, upcase, downcase, swapcase and capitalize also convert characters beyond ASCII. According to Veria Labs, this introduced the faulty loop into several ISO-8859 and Windows-125x encodings. [33][3]

  2. Research

    Codex maps Ruby’s attack surface

    Moritz Sanft has the AI tool Codex examine which parts of Ruby can be reached from Rails without authentication. After less than 24 hours, there are several findings, including the “ß” bug. Three days later, his first exploit works against a test application. [4]

  3. Vendor

    The fix is prepared under wraps

    Ruby developer Yusuke Endoh writes the fix for the flaw reported by Stephan Lipp (Ada Logics). It checks for room for two bytes in 14 encodings and only becomes public with the release. [7]

  4. Research

    Code execution against a fresh Rails app

    According to Moritz Sanft, a friend of his who works at OpenAI achieves code execution without authentication against a freshly created Rails application. The same evening, OpenAI reports the flaw and a related bug to the Ruby security team. [4]

  5. Vendor

    Advisory and fix releases

    The Ruby project publishes Ruby 3.3.14, 3.4.13 and 4.0.10 and an advisory on seven flaws, overnight into November 19, Central European Time. Ruby 3.2 and older no longer receive fixes. [1][8][9][10][53]

  6. Authority

    BSI issues warning, CVE number assigned

    Germany’s Federal Office for Information Security (BSI) lists the flaws in its warning WID-SEC-2026-4668 “Ruby: multiple vulnerabilities” with the risk rating “high”: a remote, anonymous attacker could, among other things, execute code. In the morning, MITRE publishes CVE-2026-132825. [44][5][39]

  7. Vendor

    WAF rules and first packages

    Cloudflare, AWS, Fastly and CrowdSec publish WAF rules against the known attack path. Ubuntu delivers patched packages with USN-9176-1; the official Docker images and Homebrew also offer the new versions. [40][42][41][43][35][22][23]

  8. Vendor

    GitLab, Debian and Amazon Linux

    GitLab publishes the critical patch releases 19.6.1, 19.5.8 and 19.4.10, and the French agency CERT-FR issues a warning about them. Debian delivers DSA-6644-1 and DLA-4926-1, and Amazon delivers patched packages for Amazon Linux 2023. [34][13][14][20][45]

  9. Looking ahead

    Public exploit announced

    Veria Labs plans to publish a proof of concept for code execution against Rails on this day, or later if major vendors have not patched by then. VamiSec assessment: attacks are to be expected from then on. [3]

Affected versions

Which Ruby installations need the update

An application is vulnerable if three conditions coincide. You can check the first here in seconds; the other two apply to many Rails and Sinatra applications.

  • CRuby 2.4.0 up to 3.3.13, 3.4.12 or 4.0.9

    All Ruby versions from 2.4.0 onward without the fix are affected, including the lines up to 3.2 that are no longer maintained and the pre-release version 4.1.0-preview1. JRuby and TruffleRuby are separate implementations.

  • Text in a single-byte encoding

    Affected are ISO-8859-1, -2, -3, -4, -9, -10, -13, -14, -15 and -16 as well as Windows-1250, -1252, -1254 and -1257. Text in UTF-8 is not affected; it becomes dangerous when attackers can determine the encoding themselves.

  • Conversion of externally supplied data

    The application must process such text with upcase, swapcase, downcase(:fold) or casecmp?. In full Rails applications and classic Sinatra, Rack does this for the _method form field, without authentication.

Ruby check

Paste the output of ruby -v, a Docker tag or a version number. The check shows whether your version contains the fix.

Examples:

The check runs only in your browser; nothing is transmitted.

No version entered yet

The result appears as soon as you enter the output of ruby -v, a Docker tag or a version number.

Fixed as of version
Ruby 3.33.3.14
Ruby 3.43.4.13
Ruby 4.04.0.10

Debian, Ubuntu, RHEL and other distributions sometimes include fixes without a new Ruby version number. There, the package version stated in the distributor’s security advisory is what counts.

Vendor status as of November 21, 2026, 10 a.m. CET [1][22][12][35][11][16][17][18][19][20][23][24][25][26][27][28][21][46][36]
PlatformLinesVersion with fixStatus
Ruby (ruby-lang.org)3.33.44.03.3.143.4.134.0.10Fix availableReleases of November 18. Ruby 3.3 will only be maintained until the end of March 2027, and Ruby 3.2 has not received updates since April 2026. [1][8][9][10][52]
Docker Official Images (ruby)3.33.44.03.3.143.4.134.0.10Fix availableAll variants (trixie, bookworm, slim, alpine) since November 19; latest points to 4.0.10. Rebuild your own images. [22]
Debian12 (ruby3.1)13 (ruby3.3)3.1.7-1~deb12u23.3.14-0+deb13u1Fix availableDSA-6644-1 and DLA-4926-1 of November 20. Testing and unstable were still unpatched on November 21. [12][13][14]
Ubuntu22.04 (ruby3.0)24.04 (ruby3.2)26.04 (ruby3.3)26.10 (ruby3.3)3.0.2-7ubuntu2.143.2.3-1ubuntu0.24.04.93.3.8-2ubuntu3.23.3.8-2.2ubuntu4.1Fix availableUSN-9176-1 of November 19; the Ruby version number stays the same, and the package version is what counts. Ubuntu 20.04 and older are not listed. [35][15]
Red Hat Enterprise LinuxRHEL 8RHEL 9RHEL 10–Fix pendingRed Hat rates the flaw as critical. Fixes for ruby, ruby4.0, the ruby:2.5, ruby:3.3 and ruby:4.0 modules as well as for pcs are pending; according to Red Hat, Satellite 6, OpenShift and OpenStack containers are also affected. There is no mitigation that meets Red Hat’s criteria. [11]
SUSE and openSUSESLE 15SLES 16Leap 15.6Leap 16–Fix pendingFor SLE 15 SP7 and LTSS, packages are in quality assurance, and for SLES 16 and Leap the fix is in progress; nothing had been released as of November 21. [16]
Fedora and Arch LinuxFedora 43–45RawhideArch4.0.10-42.fc46PartialOnly Fedora Rawhide is patched. Fedora 43 to 45 and Arch have the new versions in the testing branch; the stable packages are still unpatched. [17][18]
Alpine Linux3.213.22 bis edge3.3.14-r03.4.13-r0Fix availablePackages since November 19. Alpine 3.20 and older without a fix. [19]
Amazon Linux 2023ruby3.2ruby3.4ruby4.03.2.8-184.amzn2023.0.73.4.13-27.amzn2023.0.94.0.10-41.amzn2023.0.1Fix availableALAS2023-2026-3509 to -3511 of November 20, for ruby3.2 as a backport. According to AWS, restarting the application servers is then sufficient. [20][21]
Homebrew (macOS, Linux)rubyruby@3.4ruby@3.34.0.103.4.133.3.14Fix availableSince November 19, including brew’s portable Ruby as of version 7.0.15. ruby@3.2 remains without a fix. [23][60]
ruby-build, mise, ruby-install, RubyInstaller, setup-ruby3.33.44.03.3.143.4.134.0.10PartialNew versions since November 19; with asdf, update the plugin. RVM had not yet added them on November 21. [24][25][26][27]
Heroku3.33.44.03.3.143.4.134.0.10Fix availableAvailable since November 18; the default is 3.4.13. Raise the Ruby version in the Gemfile and redeploy. [28][29]
AWS Lambdaruby3.3ruby3.4ruby4.0–Fix pendingIn progress, according to AWS. Functions in automatic update mode receive the fix automatically; container images must be rebuilt. [21]
JRuby and TruffleRubyJRubyTruffleRubyjcodings 1.0.66Check noteJRuby uses the Java library jcodings, which contained the same faulty check; fix in jcodings 1.0.66 of November 19. According to Semgrep, no memory overflow occurs in JRuby and TruffleRuby. JRuby releases with the fix were still pending on November 21. [46][36][15]

Your vendor’s security advisory is what counts. Distributions often build fixes into older version numbers, container images only receive the fix with the next build, and every Ruby process needs a restart.

Products with their own Ruby

These products ship with their own Ruby. An operating system update does not help here; you need the vendor’s patched version.

  • GitLab

    Critical patch releases 19.6.1, 19.5.8 and 19.4.10 of November 20; GitLab.com and GitLab Dedicated are already patched. Self-compiled installations need Ruby 3.3.14 or 3.4.13. [34]

  • GitHub Enterprise Server

    According to Veria Labs, all versions up to 3.22.5 are vulnerable. The release notes for 3.22.5 of November 17 do not mention the flaw; a fix was still pending on November 21. [3][59]

  • Mastodon

    Versions 4.7.6, 4.6.12, 4.5.22 and 4.4.29 of November 19 mainly update Ruby in the Docker images. Installations without Docker need to provide a patched Ruby themselves. [56][3]

  • Discourse

    Base image 2.0.20261119-0203 ships Ruby 4.0.10. Hosted instances are patched; self-hosted ones must be rebuilt with the new base image. [55]

  • OpenProject, Chatwoot, Forem and Zammad

    OpenProject 17.9.8 and 17.8.3 as well as Chatwoot 4.20.1 ship with a patched Ruby, and Forem has switched its main branch to Ruby 3.3.14. Zammad switched its stable branch to Ruby 3.4.13 on November 19; there was no corresponding release as of November 21. [3][57][63][64]

  • Puppet and OpenVox

    The OpenVox agent is patched in 9.5.0 and 8.34.0 of November 19, with a backport for Ruby 3.2. As of November 21, we were not aware of any announcement of a fix for Perforce’s Puppet agent. [58][67][68]

  • Chef, Fluentd, Metasploit and Vagrant

    According to their current build files, Chef Infra Client ships with Ruby 3.4.10, fluent-package 6.0.5 with Ruby 3.4.11, the Metasploit installers with Ruby 3.4.12 and Vagrant with Ruby 3.3.8; patched packages were still pending on November 21. Such tools are usually only vulnerable if they process external data in an affected encoding. The update still belongs in the plan. [62][61][65][66]

As of November 21, 2026, 10 a.m. CET, according to the vendors and Veria Labs. The commands below show which Ruby version a product ships with.

Not affected

  • Ruby 3.3.14, 3.4.13 and 4.0.10 as well as patched distribution packages, once the processes have been restarted
  • Text in UTF-8, US-ASCII or binary encoding; according to Semgrep, this applies to JSON data, query strings and HTTP headers
  • Ruby before version 2.4.0, which, however, has not received security updates for years
  • Not vulnerable via the known default path: Rails in API mode, modular Sinatra, other frameworks and plain Rack, as long as your own code does not convert such text

Not affected does not mean permanently safe: a new gem, a middleware or your own code can open up the path. Semgrep, for example, found another path via Rodauth’s account creation. Plan the update anyway.

Find Ruby installations (Linux)

Finds all Ruby installations, including those embedded in GitLab, Puppet, Chef or Fluentd, via their rbconfig.rb file and shows the version without executing any of the programs found. The package list shows whether patched distribution packages are installed.

Bash · Linux
# Ruby installations incl. embedded ones (GitLab, Puppet, Chef, Fluentd …),
# read from rbconfig.rb (nothing is executed)
find / \( -path /proc -o -path /sys -o -path /tmp -o -path /var/tmp -o -path /dev/shm \) -prune -o \
  -type f -name rbconfig.rb -print 2>/dev/null |
while read -r f; do
  v=$(grep -oE 'CONFIG\["(MAJOR|MINOR|TEENY)"\] = "[0-9]+"' "$f" | grep -oE '[0-9]+"$' | tr -d '"' | paste -sd.)
  echo "$v  $f"
done | sort -V

# Distribution packages: backported fixes (Ubuntu, Debian 12, AL2023 ruby3.2) keep the old Ruby version number
dpkg -l 'ruby*' 'libruby*' 2>/dev/null | grep '^ii' || rpm -qa 'ruby*' 2>/dev/null

Find Ruby installations (Windows)

The same for Windows servers and developer machines using PowerShell.

PowerShell · Windows
# Ruby installations (RubyInstaller, embedded copies), read from rbconfig.rb
Get-ChildItem -Path C:\ -Filter rbconfig.rb -Recurse -File -ErrorAction SilentlyContinue | ForEach-Object {
  $v = (Select-String -LiteralPath $_.FullName -Pattern 'CONFIG\["(MAJOR|MINOR|TEENY)"\] = "(\d+)"' |
        ForEach-Object { $_.Matches[0].Groups[2].Value }) -join '.'
  "$v  $($_.FullName)"
}

Check running services and containers

For running Ruby services such as Puma, Unicorn or Sidekiq, shows the interpreter in use and its version; for processes in containers or with a replaced binary, it prints a note. In addition, it shows the Ruby version in running Docker containers.

Bash · processes & Docker
# Running Ruby services (Puma, Unicorn, Sidekiq, Passenger …) and their interpreter
for pid in $(pgrep -f 'ruby|puma|unicorn|sidekiq|passenger'); do
  exe=$(readlink /proc/$pid/exe 2>/dev/null) || continue
  case "$exe" in *ruby*) ;; *) continue;; esac
  if [ "$(readlink /proc/$pid/root)" = "/" ] && [ -x "$exe" ]; then
    echo "$pid  $("$exe" -v)  $exe"
  else
    echo "$pid  $exe  (container or replaced binary: check inside the container or restart)"
  fi
done

# Ruby version inside running Docker containers
for c in $(docker ps -q); do
  echo "$(docker inspect -f '{{.Config.Image}}' "$c"): $(docker exec "$c" ruby -v 2>/dev/null || echo 'no ruby')"
done

Check repositories and middleware

Lists the Ruby version that a repository specifies in .ruby-version, Gemfile, Gemfile.lock, Dockerfiles and CI files, and shows whether Rack::MethodOverride is in a Rails application’s middleware stack.

Bash · repositories
# Ruby version pins in a repository (run in its root): .ruby-version, Gemfile(.lock),
# Dockerfiles, CI files
git ls-files | grep -E '(^|/)(\.ruby-version|\.tool-versions|mise\.toml|Gemfile|Gemfile\.lock|Dockerfile[^/]*|[^/]+\.ya?ml)$' |
  xargs -r grep -HnE -A1 '^[0-9]+\.[0-9]+\.[0-9]+$|^ruby-[0-9]|^ruby |^ *ruby [0-9"]|^ *ruby = |RUBY VERSION|FROM .*ruby:|ruby-version' 2>/dev/null

# Rails: is Rack::MethodOverride in the middleware stack? (missing in API-only apps)
bin/rails middleware | grep -i MethodOverride
Self-check

How well prepared are you for Ruby2Shell?

Eight questions, answered honestly. “Yes” is always the safe answer. The evaluation stays in your browser.

  1. Do you have a complete list of all Ruby installations, including those embedded in container images and products such as GitLab, Puppet or Fluentd?
  2. Are all Ruby applications reachable from the internet running 3.3.14, 3.4.13, 4.0.10 or a patched distribution package, and have they been restarted since?
  3. Are container images based on a Ruby base image rebuilt and rolled out after the update?
  4. Have you defined a path to a maintained version or to a package with a backport for applications on Ruby 3.2 or older?
  5. Have you asked the vendors of products with their own Ruby about Ruby2Shell and a date for the update?
  6. Are WAF rules against Ruby2Shell active and set to block for your reachable Ruby applications?
  7. Does your monitoring detect crashes of Ruby processes and shells started by Ruby services?
  8. Is the Ruby interpreter covered in your SBOMs and vulnerability scanning, not just the gems?
Your result

0 of 8 questions answered

The self-check is no substitute for an assessment of your environment.

Action plan

What to do now

Three stages: update reachable applications today, cover the full breadth this week, then improve how you manage runtime environments. Ruby, Red Hat and GitLab do not name a workaround, and AWS emphasizes that none provides complete protection. [1][11][34][21][40][41][42][43][49][54][36]

Today

Close the exposure

  • List Rails and Sinatra applications reachable from the internet, plus GitLab, Mastodon, Discourse and other products with their own Ruby.
  • Update Ruby to 3.3.14, 3.4.13 or 4.0.10 or install the patched distribution package, then restart all Ruby processes.
  • Bring products with their own Ruby up to the vendors’ patched versions.
  • Where this is not possible today: restrict access from the internet and activate WAF rules; with Cloudflare, the rule already blocks, while with AWS, from “Known bad inputs” 1.29 onward, count first, then block.
  • Use the queries below to search for crashes and unusual processes.
This week

Cover the full breadth

  • Rebuild container images with an updated base image without the cache and roll them out.
  • Update internal applications, batch jobs, CI runners and developer machines.
  • Assign applications on Ruby 3.2 and older to an upgrade path or a distribution package with a backport.
  • Know the limits of the WAF: the AWS rules only inspect the first 8 KB of the request body at the Application Load Balancer, and 16 to 64 KB with CloudFront. Keep Rack up to date: version 3.2.9 of November 20 fixes a bug in multipart boundaries that could be used to bypass WAF rules.
  • Contact vendors with embedded Ruby and record their answers.
30 days

Improve the process

  • Keep Ruby interpreters permanently in your inventory and in SBOMs, not just the gems.
  • Set patch deadlines for runtime environments, not just for applications.
  • Phase out old versions without vendor support.
  • Install Rails updates as soon as they include the change merged on November 19 that prevents arbitrary encodings in multipart fields. It hampers the known path but does not replace the Ruby update.
  • Contractually commit vendors with embedded Ruby to update deadlines.
  • Record lessons learned and practice the emergency process for flaws in runtime environments.

For IT operations and the SOC

  • Report the update status daily, internet-facing applications first.
  • Collect and analyze crash reports from Ruby processes and WAF rule hits centrally.
  • Monitor child processes of Ruby services in endpoint monitoring.

For executive management and the information security officer

  • Make internet-facing applications the priority and follow up on progress.
  • Hold suppliers with embedded Ruby accountable, for example for GitHub Enterprise Server.
  • Clarify whether a suspected incident is reportable under NIS2 or DORA and, as a manufacturer, review your obligations under the Cyber Resilience Act.
Suspect exploitation?

Isolate the system, preserve logs and memory dumps, replace all credentials known to the application, such as database passwords, API keys, secret_key_base and tokens, and search for new accounts, cron jobs and web shells. Our CSIRT supports you around the clock.

Report an incident csirt@vamisec.com
Detection

Hunting for traces

No attacks are known, but crash proofs of concept are public and an exploit for code execution has been announced. Search back to at least November 18 and repeat the search after November 25. For your inventory, Tenable detects the Ruby version with plugin 383389; gem scanners such as bundler-audit do not see the interpreter. The queries are examples; test them in your environment before use. [36][4][42][50]

Ruby process crashes

A failed attempt can end the process with a Ruby crash report ([BUG] Segmentation fault) or an abort by glibc’s memory allocator. According to Semgrep, however, the overflow often does not cause a crash, so a clean log proves nothing.

Bash · journald & logs
# Ruby crashes in the last 14 days: [BUG] reports, glibc heap aborts, killed workers
journalctl --since "14 days ago" --no-pager 2>/dev/null |
  grep -E '\[BUG\] (Segmentation fault|Bus Error)|corrupted size|malloc\(\): |free\(\): invalid|double free|SIGSEGV|SIGABRT' |
  tail -n 50

# Same patterns in application logs (Puma, Unicorn, Passenger, Sidekiq)
APP_LOG_DIR=/var/log/myapp   # adjust
grep -hE '\[BUG\] Segmentation fault|corrupted size|malloc\(\): |SIGSEGV|SIGABRT|method_override\.rb' \
  "$APP_LOG_DIR"/*.log log/*.log 2>/dev/null | sort | uniq -c | sort -rn | head -20

Restart missing? Check running processes

An update only takes effect after a restart. The query finds processes that still use a replaced libruby and those that have loaded an affected encoding. The latter only shows that the process has handled such text, not that an attack took place.

Bash · /proc
# Ruby processes still running a replaced libruby (restart needed after the update)
# or with an affected single-byte encoding module loaded (handled such text, no proof of an attack);
# statically linked Ruby builds show neither libruby nor encoding modules here
for pid in $(pgrep -f 'ruby|puma|unicorn|sidekiq|passenger'); do
  m=/proc/$pid/maps
  grep -q 'libruby.*(deleted)' "$m" 2>/dev/null && echo "$pid  libruby replaced on disk: restart"
  grep -qE 'enc/(iso_8859_(1|2|3|4|9|10|13|14|15|16)|windows_125[0247])\.so' "$m" 2>/dev/null &&
    echo "$pid  affected encoding module loaded"
done

WAF rule hits

The AWS rules Ruby2Shell_MULTIPARTMETHOD, Ruby2Shell_MethodOverride_BODY and Ruby2Shell_METHODOVERRIDE_HEADER report matching requests; with Cloudflare, Fastly and CrowdSec, hits appear in the security events. The telltale bytes are in the multipart body, not in the URL.

CloudWatch Logs Insights · AWS WAF
# Hits of the three Ruby2Shell rules (Known bad inputs >= 1.29);
# in Count mode they appear as non-terminating matches
fields @timestamp, httpRequest.clientIp, httpRequest.country, httpRequest.uri, action
| filter @message like /Ruby2Shell_/
| sort @timestamp desc
| limit 200

Ruby starts a shell

After successful code execution, attackers usually start a shell or download additional tools. For deployment tools and background jobs this can be normal, so maintain exceptions there.

KQL · Defender XDR
DeviceProcessEvents
| where Timestamp > ago(14d)
| where InitiatingProcessFileName startswith "ruby"
    or InitiatingProcessCommandLine has_any ("puma", "unicorn", "sidekiq", "passenger")
| where FileName in~ ("sh", "bash", "dash", "zsh", "curl", "wget", "nc", "ncat",
    "python3", "perl", "cmd.exe", "powershell.exe", "pwsh.exe")
| project Timestamp, DeviceName, AccountName, FileName, ProcessCommandLine,
    InitiatingProcessCommandLine

Hits are indications, not proof, and their absence does not prove that nothing has happened. If you find something, treat the system as compromised until proven otherwise.

NIS2, CRA and DORA

What regulation says about it

The flaw itself is not a reportable incident. What attackers do with it can become reportable, and manufacturers have obligations of their own.

  • Handling vulnerabilities is mandatory

    NIS2 requires essential and important entities to have risk management in place that includes vulnerability handling. Anyone who leaves a flaw rated as critical in internet-facing applications open for days may have to justify it.

  • Reporting deadlines in an emergency

    If an attack leads to a significant security incident, the following applies in Germany: early warning to the BSI within 24 hours, notification within 72 hours, final report no later than one month after the notification.

  • Manufacturers: Cyber Resilience Act

    Since September 11, 2026, manufacturers have had to submit an early warning within 24 hours if a vulnerability in one of their own products with digital elements is actively exploited, even if it lies in the bundled Ruby. The obligations to handle vulnerabilities and provide updates apply from December 11, 2027.

  • Financial sector: DORA

    Financial entities assess ICT incidents under DORA and report major ones to their supervisory authority. Ruby applications from service providers are part of ICT third-party risk management.

How VamiSec supports you

Find, secure, prove

From a short-notice exposure check to a lasting overview of your runtime environments.

Acute

CSIRT and Compromise Assessment

If you suspect an incident, we determine whether a Ruby application has been compromised: crash reports, processes, credentials and network traffic, across servers and containers.

Compromise Assessment
Attack surface

Find reachable Ruby applications

Within an authorized scope, VamiRedteam checks from the outside which Rails, Sinatra and GitLab instances are reachable.

VamiRedteam
Cloud

Cloud workloads with Wiz

As a member of the Wiz Partner Alliance, we help Wiz customers find and prioritize affected Ruby versions in VMs and containers.

VamiSec and Wiz
Detect

Managed Detection & Response

We monitor servers and containers for Ruby process crashes, suspicious child processes and attempts to download additional tools, and respond around the clock.

MDR at VamiSec
Supply chain

SBOM and runtime inventory

We make visible which Ruby versions are contained in your products, images and applications, and keep the inventory up to date.

SBOM at VamiSec
Prevent

Zero-day monitoring

We promptly match newly disclosed flaws such as Ruby2Shell against your attack surface, so that you can act before regular patch cycles take effect.

Zero-day monitoring
VamiGRCAgentic GRC platform

VamiGRC: match vulnerabilities against assets, manage deadlines, maintain evidence

VamiGRC matches CISA KEV, NVD and EPSS against your assets, products and SBOMs. When a flaw such as CVE-2026-132825 appears, you see which of your recorded assets are affected and manage actions and deadlines through to evidence.

  • CISA KEV, NVD and EPSS are matched against your assets, products and SBOMs.
  • Evidence from connected systems is updated along with its source rather than at audit time.
  • When an incident is recorded, a deadline timer starts for NIS2; VamiAI drafts notifications, and your team reviews and submits them.
  • One control, multiple frameworks: implemented once, mapped to NIS2, ISO 27001 and other standards.
  • AI agents handle the routine work according to your approval rules; your team decides.
Valeri Milke, founder and managing director of VamiSec GmbH
Schedule a call

Let’s talk about your Ruby landscape

Whether it is an exposure check, an update rollout or evidence for NIS2 and the CRA, Valeri Milke and the VamiSec team help you derive concrete next steps from this briefing.

“IT security and compliance without AI is a vulnerability.”

Valeri MilkeFounder & Managing Director · VamiSec GmbHISO/IEC 27001 & ISO/IEC 42001 Lead Auditor
20Years of GRC experience of the founder
ISO 27001VamiSec is itself certified
T Cloud PublicOperation in German data centers
24/7CSIRT for security incidents
FAQ

Frequently asked questions about Ruby2Shell

What is Ruby2Shell?

Ruby2Shell is the name Veria Labs has given to CVE-2026-132825, a one-byte heap overflow in the Ruby interpreter CRuby. When Ruby converts the character “ß” to uppercase in one of 14 older single-byte encodings such as ISO-8859-1 or Windows-1252, it becomes “SS”, but Ruby only checks for room for one byte. The Ruby project closed the flaw on November 18, 2026 with versions 3.3.14, 3.4.13 and 4.0.10.

Am I affected?

All CRuby versions from 2.4.0 onward without the fix are affected, that is, up to 3.3.13, 3.4.12 and 4.0.9 as well as all versions from 2.4 to 3.2. According to Veria Labs, those open to attack from the outside are primarily Rails and classic Sinatra applications in their default configuration as well as products with their own Ruby, such as GitLab or GitHub Enterprise Server. You can check your version with the Ruby check on this page.

Which versions contain the fix?

Ruby 3.3.14, 3.4.13 and 4.0.10 of November 18, 2026. Debian 13 raises ruby3.3 to 3.3.14-0+deb13u1, and Amazon Linux 2023 delivers ruby3.4 3.4.13 and ruby4.0 4.0.10. Ubuntu (for example 3.2.3-1ubuntu0.24.04.9 in 24.04), Debian 12 (3.1.7-1~deb12u2) and Amazon Linux 2023 for ruby3.2 (3.2.8-184.amzn2023.0.7) backport the fix without changing the Ruby version number. Red Hat and SUSE had not yet released updates as of November 21.

What does the “ß” have to do with it?

The affected encodings have no capital “ẞ”. When converting to uppercase, “ß” therefore becomes “SS”: one byte turns into two. For the result, Ruby reserves the input length plus 20 bytes, so 21 “ß” characters are enough for a one-byte overflow. That is why Veria Labs writes the name as “ruby2ßhell”.

Is RubyShell (rubyshell.org) affected?

No, that is a mix-up. RubyShell is an independent open-source gem that lets you write shell commands as Ruby methods; no flaw is known for the gem itself. Like any Ruby software, however, it runs on an interpreter, and that should be 3.3.14, 3.4.13, 4.0.10 or a patched distribution package.

Why are Rails and Sinatra particularly at risk?

Both use Rack and its MethodOverride middleware. For form requests, it reads the _method field and converts it to uppercase with upcase so that browsers can send PATCH or DELETE requests. The sender may set the field’s encoding via charset. This allows an attacker to reach the faulty function with a single request, even before routing and authentication. In Sinatra, this is only active by default in the classic style.

Are Rails API applications affected?

Not via the known default path: Rails does not include Rack::MethodOverride in API mode (config.api_only). According to Semgrep, however, text fields in multipart requests keep the encoding specified by the sender there too; if your own code converts such parameters to uppercase, the flaw is reachable. You should therefore update API applications as well.

Is Ruby2Shell already being exploited?

As of November 21, no attacks are known, the flaw is not in CISA’s KEV catalog, and the EPSS score was 0.19% on November 20. So far, the publicly available proofs of concept trigger the bug and cause a crash but do not execute code. Several teams have built working exploits, and Veria Labs plans to publish a proof of concept against Rails on November 25. Expect attacks by then at the latest.

Is there a workaround?

Not officially: Ruby, Red Hat and GitLab do not name one, and AWS emphasizes that no workaround provides complete protection. As a stopgap, WAF rules from Cloudflare, AWS, Fastly or CrowdSec and restricted access help. Semgrep also describes removing Rack::MethodOverride, which breaks forms that use _method for PATCH and DELETE, or rejecting multipart parts with an encoding other than UTF-8 at the very front of the stack. None of this replaces the update.

What about Ruby 3.2 and older?

These versions are affected from 2.4.0 onward but no longer receive fixes from the Ruby project; Ruby 3.2 has been without support since April 2026. Some distributions backport the fix, such as Debian 12 for ruby3.1, Ubuntu 22.04 for ruby3.0 and Amazon Linux 2023 for ruby3.2. Otherwise, the only option is to upgrade to 3.3 or later.

Does bundler-audit detect the flaw?

No. bundler-audit only checks the gems in Gemfile.lock, not the interpreter, even though the ruby-advisory-db database has an entry for the CVE. Tenable detects the flaw with plugin 383389, and Semgrep provides open-source, read-only check scripts. Also check the Ruby version with the Ruby check or the commands on this page.

Are Docker images and cloud services affected?

Yes, if they contain an affected Ruby version. The official Docker images have been available in patched versions since November 19; you need to rebuild your own images. Heroku has offered the new versions since November 18. For the managed Lambda runtimes, the update from AWS was still pending on November 21.

How does VamiSec support you?

At short notice, we check which Ruby applications are reachable and affected, roll out updates and image rebuilds with you, build detection rules and investigate suspected cases with a compromise assessment and our CSIRT. With VamiGRC, you manage vulnerabilities, deadlines and evidence for NIS2 and the CRA.

Sources

Sources and further information

The information is based on publications by the Ruby project, the discoverers, distributions, platforms, vendors, security companies and authorities up to November 21, 2026, 10 a.m. CET. Assessments by VamiSec are identified as such.

  1. [1]Ruby: Security advisories: multiple vulnerabilities in Regexp and String case conversion,
  2. [2]Ruby (GitHub): GHSA-34m4-m9fh-gqp5: Heap buffer overflow in case conversion of strings,
  3. [3]Veria Labs: Ruby2Shell (CVE-2026-132825),
  4. [4]Durendal (Moritz Sanft): Yet another ẞug,
  5. [5]CVE Program: CVE Record CVE-2026-132825,
  6. [6]NIST National Vulnerability Database: CVE-2026-132825 Detail,
  7. [7]Ruby (GitHub): Commit d582f8f: Fix a heap buffer overflow in case mapping of the sharp s,
  8. [8]Ruby: Ruby 4.0.10 Released,
  9. [9]Ruby: Ruby 3.4.13 Released,
  10. [10]Ruby: Ruby 3.3.14 Released,
  11. [11]Red Hat: CVE-2026-132825,
  12. [12]Debian: Security Tracker: CVE-2026-132825,
  13. [13]Debian: DSA-6644-1 ruby3.3 – security update,
  14. [14]Debian LTS: DLA-4926-1 ruby3.1 – security update,
  15. [15]Ubuntu: CVE-2026-132825,
  16. [16]SUSE: CVE-2026-132825,
  17. [17]Fedora: Package ruby,
  18. [18]Arch Linux: ruby (extra-testing),
  19. [19]Alpine Linux: Package index: ruby,
  20. [20]Amazon Linux Security Center: CVE-2026-132825,
  21. [21]Amazon Web Services: Security Bulletin 2026-193-AWS,
  22. [22]Docker Hub: ruby – Docker Official Image,
  23. [23]Homebrew: ruby (Formula),
  24. [24]rbenv (GitHub): ruby-build v20261119,
  25. [25]RubyInstaller (GitHub): RubyInstaller2 Releases,
  26. [26]ruby/setup-ruby (GitHub): setup-ruby Releases,
  27. [27]RVM (GitHub): Pull Request 5682: Add Ruby 3.3.14, 3.4.13, 4.0.10,
  28. [28]Heroku Dev Center: Changelog: Ruby version 3.4.13 is now available,
  29. [29]Heroku Dev Center: Heroku Ruby Support Reference,
  30. [30]Rack (GitHub): lib/rack/method_override.rb
  31. [31]FIRST: Exploit Prediction Scoring System (EPSS): CVE-2026-132825,
  32. [32]CISA: Known Exploited Vulnerabilities Catalog,
  33. [33]Ruby: Ruby 2.4.0 Released,
  34. [34]GitLab: GitLab Critical Patch Release: 19.6.1, 19.5.8, 19.4.10,
  35. [35]Ubuntu: USN-9176-1: Ruby vulnerabilities,
  36. [36]Semgrep: Ruby2Shell (CVE-2026-132825): Heap Overflow in Ruby,
  37. [37]Semgrep (GitHub): detection-scripts: CVE-2026-132825,
  38. [38]heise online: ruby2ßhell: Remote Code Execution durch 21 ß,
  39. [39]Openwall oss-security: Re: Ruby: multiple vulnerabilities in Regexp and String case conversion,
  40. [40]Cloudflare: WAF Emergency Release – 2026-11-19,
  41. [41]Fastly: Added virtual patch for CVE-2026-132825 (Ruby2Shell),
  42. [42]Amazon Web Services: AWS Managed Rules changelog (Known bad inputs 1.29),
  43. [43]CrowdSec: Ruby2Shell Virtual Patch: Free WAF Rule for CVE-2026-132825,
  44. [44]BSI / CERT-Bund: WID-SEC-2026-4668: Ruby: Mehrere Schwachstellen,
  45. [45]CERT-FR: CERTFR-2026-AVI-1591: Vulnérabilité dans GitLab,
  46. [46]jcodings (GitHub): Commit 8425e1f: Guard case mapping and multibyte case folding,
  47. [47]Rails (GitHub): railties: default_middleware_stack.rb
  48. [48]Sinatra (GitHub): lib/sinatra/base.rb
  49. [49]Rack (GitHub): CHANGELOG (Rack 3.2.9),
  50. [50]Tenable: Nessus Plugin 383389: Ruby < 3.3.14 / 3.4.x < 3.4.13 / 4.0.x < 4.0.10 Multiple Vulnerabilities,
  51. [51]RubySec (GitHub): ruby-advisory-db: rubies/ruby/CVE-2026-132825.yml,
  52. [52]Ruby: Ruby Maintenance Branches
  53. [53]Openwall oss-security: Ruby: multiple vulnerabilities in Regexp and String case conversion,
  54. [54]Rails (GitHub): Pull Request 59872: Patch Rack::Multipart::Parser to not allow arbitrary encoding,
  55. [55]Discourse Meta: Ruby2Shell and Nginx2Root response,
  56. [56]Mastodon (GitHub): Release v4.7.6,
  57. [57]Chatwoot (GitHub): Release v4.20.1,
  58. [58]OpenVox Project: OpenVox release notes,
  59. [59]GitHub Docs: GitHub Enterprise Server 3.22 release notes,
  60. [60]Homebrew (GitHub): brew 7.0.15,
  61. [61]Fluentd (GitHub): fluent-package-builder: Pull Request 1160 (Release v6.0.6),
  62. [62]Chef (GitHub): habitat/x86_64-linux/plan.sh
  63. [63]Forem (GitHub): Pull Request 24858: Patch Ruby Regexp and String vulnerabilities with 3.3.14,
  64. [64]Zammad (GitHub): Commit 92a82e6: Maintenance: switch to Ruby 3.4.13,
  65. [65]Rapid7 (GitHub): metasploit-omnibus: config/software/ruby.rb
  66. [66]HashiCorp (GitHub): vagrant-installers: substrate/deps.sh
  67. [67]OpenVox Project: OpenVox 8.x release notes,
  68. [68]OpenVox Project (GitHub): puppet-runtime: Pull Request 357 (Ruby 3.2 security patches),

This briefing is no substitute for legal advice or an assessment of your environment.

Act now

Updating comes first.
Knowing your runtime environments makes you faster next time.

Arrange a no-obligation initial consultation: together, we will clarify your exposure, update plan and evidence.