{"id":3748,"date":"2026-10-23T18:49:22","date_gmt":"2026-10-23T18:49:22","guid":{"rendered":"https:\/\/thedigitalfortress.us\/?p=3748"},"modified":"2026-10-23T18:49:22","modified_gmt":"2026-10-23T18:49:22","slug":"ruby-fixes-three-regex-engine-bugs-responsible-for-four-critical-gitlab-rce-flaws","status":"publish","type":"post","link":"https:\/\/thedigitalfortress.us\/?p=3748","title":{"rendered":"Ruby Fixes Three Regex Engine Bugs Responsible for Four Critical GitLab RCE Flaws"},"content":{"rendered":"<div>\n<p><span class=\"p-author\"><i class=\"icon-font icon-user\">\ue804<\/i><span class=\"author\">Swati Khandelwal<\/span><i class=\"icon-font icon-calendar\">\ue802<\/i><span class=\"author\">Oct 23, 2026<\/span><\/span><span class=\"p-tags\">Vulnerability \/ Software Security<\/span><\/p>\n<\/div>\n<div id=\"articlebody\">\n<div class=\"separator\" style=\"clear: both;\"><a href=\"https:\/\/blogger.googleusercontent.com\/img\/b\/R29vZ2xl\/AVvXsEjA5n8ST_yuElQgTwbfq1oFnVAoiTvZCW_Ct1b8lT_OQ9dnyeXfocrqzTUJJ1t920YaEa-7Sonxl9KlthV4x7lXI3dmJxc9_S11NjWRJ6dcgfsX4UGhv0KFWZsZrzXKpjh92JPyDdHPlCPQh1AHd0YKM44sVcc9d-57r8_BdrIb3V06MWfk8bRAy4kDU6I\/s1700-nu-rw-lo-l85-e365\/ruby-rce.jpg\" style=\"display: block;  text-align: center; clear: left; float: left;\"><\/a><\/div>\n<p>Ruby has released versions 4.0.9, 3.4.12, and 3.3.13 to fix three bugs in Onigmo, the regular expression engine built into the language. The bugs lie behind four critical security flaws that GitLab patched over the past month.<\/p>\n<p>GitLab found that a specially crafted pattern could corrupt memory while Ruby compiles it, potentially leading to code execution on its own servers.<\/p>\n<p>Ruby says any application that builds a regular expression from text an attacker controls is affected, not just GitLab.<\/p>\n<h3>Which Applications Are Affected<\/h3>\n<p>In <a href=\"https:\/\/www.ruby-lang.org\/en\/news\/2026\/10\/23\/regexp-fixes-for-gitlab-cves\/\" target=\"_blank\">its advisory<\/a>, Ruby said an application is affected only if it compiles a regular expression from a string an attacker controls. That happens when a program passes such a string to Regexp.new, Regexp.union or Regexp.compile, or places it inside a pattern through interpolation, as in \/#{input}\/.<\/p>\n<p>Applications that only use regular expressions written by their own developers are not affected.<\/p>\n<div class=\"dog_two clear\">\n<div class=\"cf\"><a href=\"https:\/\/thehackernews.uk\/ai-governance-platform-d\" rel=\"nofollow noopener sponsored\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"lazyload\" alt=\"Cybersecurity\" src=\"https:\/\/blogger.googleusercontent.com\/img\/b\/R29vZ2xl\/AVvXsEhyu3ExJi2vbls3Z9aCvSrcqvhtsSOqXMOIxESfkx7uurTZb7rN3a2eQxwzgZ-j1ioplnCvQFTCYr8w3IUlYx0FrQzDaqQsBsUi885UYvHF3MjAObvO6ptvKBeX6zhQvzAi_KjmVno6a8bYI3Wozti5mHavNFGrekT_gC6JDVY8G3N-aV44-OZJGX9rlLng\/s728-nu-rw-lo-l85-e365\/nudge-1-d.png\" width=\"729\" height=\"91\"\/><\/a><\/div>\n<\/div>\n<p>Ruby fixed the bugs in 4.0.9, 3.4.12, and 3.3.13. The 3.4.12 and 3.3.13 releases are the first in their series to carry any of the three fixes.<\/p>\n<p>An earlier release from the same week, 4.0.8, does not include the fix for one of the flaws, <a href=\"https:\/\/www.cve.org\/CVERecord?id=CVE-2026-110264\" target=\"_blank\">CVE-2026-110264<\/a>, so 4.0 users should install 4.0.9.<\/p>\n<p><a name=\"more\"\/><\/p>\n<p>Ruby 3.2 and earlier will not get a fix. Ruby 3.2 <a href=\"https:\/\/www.ruby-lang.org\/en\/downloads\/branches\/\" target=\"_blank\">reached end of life<\/a> on April 1, 2026, and 3.2.11 was its final release. Ruby recommends moving to 3.4 or 4.0.<\/p>\n<p>If you cannot upgrade yet, the advisory says to stop compiling regular expressions from untrusted input.<\/p>\n<p>Two defenses that look like they would help do not. Setting Regexp.timeout does not stop these bugs. Capping the length of a pattern is also unreliable because short patterns can trigger bugs.<\/p>\n<h3>How the Bugs Reached GitLab<\/h3>\n<p>GitLab compiles regular expressions supplied by its users, such as the patterns in a CI\/CD configuration. It found that crafted patterns could corrupt memory as Ruby compiled them, and it issued four CVEs between <a href=\"https:\/\/docs.gitlab.com\/releases\/patches\/patch-release-gitlab-19-4-1-released\/\" target=\"_blank\">September 23<\/a> and October 21, fixing each by shipping a patched Ruby.<\/p>\n<p>The first two, disclosed on September 23, each need a logged-in account and were rated 9.9 out of 10. The two from October, <a href=\"https:\/\/www.cve.org\/CVERecord?id=CVE-2026-97229\" target=\"_blank\">CVE-2026-97229<\/a> on the 12th and CVE-2026-110264 on the 21st, need no account and were rated 10.0, the maximum. CVE-2026-110264 reaches every GitLab version from 7.0 onward.<\/p>\n<p>A researcher using the handle joaxcar reported all four through GitLab&#8217;s bug bounty program. As of October 23, none of the four was listed in CISA&#8217;s Known Exploited Vulnerabilities catalog.<\/p>\n<h3>No Ruby CVE, for Now<\/h3>\n<p>Ruby has not requested CVE identifiers of its own for these fixes, \u00abat least for now,\u00bb it said, and told users to track the issues by GitLab&#8217;s four CVE numbers instead.<\/p>\n<p>That leaves a gap for anyone who scans by CVE. GitLab&#8217;s CVE records name only GitLab as the affected product, so a scanner that checks those records against installed Ruby versions has nothing to match.<\/p>\n<div class=\"dog_two clear\">\n<div class=\"cf\"><a href=\"https:\/\/thehackernews.uk\/network-defense-d\" rel=\"nofollow noopener sponsored\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"lazyload\" alt=\"Cybersecurity\" src=\"https:\/\/blogger.googleusercontent.com\/img\/b\/R29vZ2xl\/AVvXsEjVV2rRkX8tRMF6gCzemvQNpwFwGxRWxY1cJEYfoLLSj1EZYJOlj5WTR77t0i6kELXujYcaHTpRDqTjCbVHH5Pnh7wzxUiKP5j4dsDkWIMlp2bmpZsL0jeAsA_19pHH5UPtyBvNkZdyGEULOAsXPcraMP5CYjQRFefhXRSdEjYkrdcpUnc4ILcvcdEfAauE\/s728-nu-rw-lo-l85-e365\/tl-d.jpg\" width=\"729\" height=\"91\"\/><\/a><\/div>\n<\/div>\n<p>Ruby has treated this kind of bug as a vulnerability before, assigning CVE numbers to fixes in <a href=\"https:\/\/www.ruby-lang.org\/en\/news\/2022\/04\/12\/double-free-in-regexp-compilation-cve-2022-28738\/\" target=\"_blank\">2022<\/a> and <a href=\"https:\/\/www.ruby-lang.org\/en\/news\/2024\/04\/23\/arbitrary-memory-address-read-regexp-cve-2024-27282\/\" target=\"_blank\">2024<\/a>, even though it has long been unsafe to build a regular expression from untrusted input.<\/p>\n<p>Its <a href=\"https:\/\/docs.ruby-lang.org\/en\/master\/Regexp.html#class-regexp-timeouts\" target=\"_blank\">documentation<\/a> still describes untrusted patterns only as a denial-of-service risk. Ruby said it will update its advisory if it requests any CVE identifiers.<\/p>\n<h3>For GitLab Administrators<\/h3>\n<p>Self-managed GitLab instances need the release that fixes CVE-2026-110264. GitLab <a href=\"https:\/\/docs.gitlab.com\/releases\/patches\/patch-release-gitlab-19-5-1-released\/\" target=\"_blank\">shipped it<\/a> on October 21 and backported it as far as version 18.11.13.<\/p>\n<ul>\n<li>19.5.1<\/li>\n<li>19.4.3<\/li>\n<li>19.3.6<\/li>\n<li>19.2.9<\/li>\n<li>19.1.9<\/li>\n<li>19.0.10<\/li>\n<li>18.11.13<\/li>\n<\/ul>\n<p>GitLab.com already runs the patched version, and GitLab Dedicated tenants on recent internal releases need no action, GitLab said. Because GitLab bundles its own copy of Ruby and patched it there, installing one of these fixed versions applies the fix.<\/p>\n<p>GitLab also published <a href=\"https:\/\/gitlab.com\/gitlab-security-oss\/tldr\/-\/blob\/main\/Detections\/platforms\/GitLab\/Vulnerability%20Detections\/onigmo_native_worker_crash.md\" target=\"_blank\">detection rules<\/a> that self-managed administrators can use to look for signs of exploitation attempts.<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\ue804Swati Khandelwal\ue802Oct 23, 2026Vulnerability \/ Software Security Ruby has released versions 4.0.9, 3.4.12, and 3.3.13 to fix three bugs in Onigmo, the regular expression engine built into the language. The&hellip;<\/p>\n","protected":false},"author":1,"featured_media":3749,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[809,58,1398,655,11,2717,316,3917,3918,1489],"class_list":["post-3748","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","tag-bugs","tag-critical","tag-engine","tag-fixes","tag-flaws","tag-gitlab","tag-rce","tag-regex","tag-responsible","tag-ruby"],"_links":{"self":[{"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=\/wp\/v2\/posts\/3748","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3748"}],"version-history":[{"count":0,"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=\/wp\/v2\/posts\/3748\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=\/wp\/v2\/media\/3749"}],"wp:attachment":[{"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3748"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3748"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/thedigitalfortress.us\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3748"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}