NFS2ROOT: A Decade Old Linux Vulnerability CVE-2026-99362 · 14h CISA KEV Weekly Briefing – Week 48 · 1d Suspected Vietnam-Linked Hackers Target Southeast Asia in South China Sea Espionage Campaign · 2d Vulnerability in GNU m4 software · 2d Vulnerability in SMSEagle RCDevs OpenOTP SMS integration connector software · 2d Fragnesia: When a Firewall Becomes the Target · 3d Vulnerability in Chainlit software · 3d Vulnerabilities in GNU Screen software · 3d Drupal Warns of New Highly Critical Site Takeover Vulnerability Under Active Exploitation · 3d Hackers Exploit 10 Vulnerabilities Across Mitel, Juniper, Vates, and Danfoss Products · 3d NFS2ROOT: A Decade Old Linux Vulnerability CVE-2026-99362 · 14h CISA KEV Weekly Briefing – Week 48 · 1d Suspected Vietnam-Linked Hackers Target Southeast Asia in South China Sea Espionage Campaign · 2d Vulnerability in GNU m4 software · 2d Vulnerability in SMSEagle RCDevs OpenOTP SMS integration connector software · 2d Fragnesia: When a Firewall Becomes the Target · 3d Vulnerability in Chainlit software · 3d Vulnerabilities in GNU Screen software · 3d Drupal Warns of New Highly Critical Site Takeover Vulnerability Under Active Exploitation · 3d Hackers Exploit 10 Vulnerabilities Across Mitel, Juniper, Vates, and Danfoss Products · 3d
🛡️
ACyber Sentinel 安全评估团队
← 返回
⚡ 情报报告

Ruby 修复了三个正则表达式引擎漏洞,导致四个关键的 GitLab RCE 漏洞

Ruby 发布了 4.0.9、3.4.12 和 3.3.13 版本,以修复内置于该语言中的正则表达式引擎 Onigmo 的三个漏洞。这些漏洞是导致 GitLab 在过去一个月内修补的四个关键安全缺陷的根源。

GitLab 发现,特制的模式可能会在 Ruby 编译时损坏内存,从而可能导致在其服务器上执行代码。

Ruby 表示,任何从攻击者控制的文本构建正则表达式的应用程序都受到影响,而不仅仅是 GitLab。

受影响的应用程序

在其公告中,Ruby 表示,只有当应用程序从攻击者控制的字符串编译正则表达式时,才会受到影响。这种情况发生在程序将这样的字符串传递给 Regexp.new、Regexp.union 或 Regexp.compile,或通过插值将其放入模式中,例如 /#{input}/。

仅使用自己开发的正则表达式的应用程序不受影响。

Ruby 在 4.0.9、3.4.12 和 3.3.13 中修复了这些漏洞。3.4.12 和 3.3.13 版本是其系列中首次包含这三项修复的版本。

Ruby 4.0:升级到 4.0.9

Ruby 3.4:升级到 3.4.12

Ruby 3.3:升级到 3.3.13

同一周早些时候发布的 4.0.8 不包含修复其中一个缺陷 CVE-2026-110264,因此 4.0 用户应安装 4.0.9。

Ruby 3.2 及更早版本将不会获得修复。Ruby 3.2 于 2026 年 4 月 1 日达到生命周期结束,3.2.11 是其最后一个版本。Ruby 建议迁移到 3.4 或 4.0。

如果您尚无法升级,公告建议停止从不受信任的输入编译正则表达式。

看似有帮助的两种防御措施实际上并没有效果。设置 Regexp.timeout 并不能阻止这些漏洞。限制模式的长度也不可靠,因为短模式可能会触发漏洞。

漏洞如何影响 GitLab

GitLab 编译用户提供的正则表达式,例如 CI/CD 配置中的模式。它发现,特制的模式可能会在 Ruby 编译时损坏内存,并在 9 月 23 日至 10 月 21 日之间发布了四个 CVE,通过发布修补版 Ruby 来修复每个漏洞。

前两个漏洞在 9 月 23 日披露,每个漏洞都需要一个登录账户,评分为 9.9 分(满分 10 分)。10 月的两个漏洞,CVE-2026-97229 在 12 日和 CVE-2026-110264 在 21 日,不需要账户,评分为 10.0,最高分。CVE-2026-110264 影响从 7.0 开始的所有 GitLab 版本。

一位使用昵称 joaxcar 的研究人员通过 GitLab 的漏洞奖励计划报告了所有四个漏洞。截至 10 月 23 日,四个漏洞均未列入 CISA 的已知利用漏洞目录。

目前没有 Ruby CVE

Ruby 尚未为这些修复请求自己的 CVE 标识符,“至少目前没有,”它表示,并告知用户根据 GitLab 的四个 CVE 编号跟踪这些问题。

这给任何通过 CVE 扫描的人留下了空白。GitLab 的 CVE 记录仅将 GitLab 命名为受影响的产品,因此检查这些记录与已安装 Ruby 版本的扫描器没有匹配项。

Ruby 曾将这种类型的漏洞视为安全漏洞,在 2022 年和 2024 年为修复分配了 CVE 编号,尽管从不受信任的输入构建正则表达式一直是不安全的。

其文档仍然仅将不受信任的模式描述为拒绝服务风险。Ruby 表示,如果请求任何 CVE 标识符,将更新其公告。

针对 GitLab 管理员

自托管的 GitLab 实例需要修复 CVE-2026-110264 的版本。GitLab 于 10 月 21 日发布了该版本,并向后移植至 18.11.13 版本。

19.5.1

19.4.3

19.3.6

19.2.9

19.1.9

19.0.10

18.11.13

GitLab.com 已经运行了修补版本,GitLab Dedicated 租户在最近的内部版本中无需采取任何行动,GitLab 表示。由于 GitLab 打包了自己的 Ruby 副本并在其中进行了修补,因此安装这些修复版本之一将应用修复。

GitLab 还发布了检测规则,自托管的管理员可以使用这些规则查找利用尝试的迹象。

觉得这篇文章有趣吗?请在 Google News、Twitter 和 LinkedIn 上关注我们,阅读更多我们发布的独家内容。

相关漏洞

CVE-2026-110264 CVSS 10 CRITICAL Undergoing Analysis
CVE-2026-110264 - Integer Overflow or Wraparound in GitLab
An issue has been discovered in GitLab CE/EE affecting all versions from 7.0 before 18.11.13, 19.0 before 19.0.10, 19.1 before 19.1.9, 19.2 before 19.2.9, 19.3 before 19.3.6, 19.4 before 19.4.3, and 19.5 before 19.5.1 that, under certain conditions, could have allowed an unauthenticated user to execute arbitrary code on the GitLab server due to integer overflow when compiling a specially crafted regular expression.
CVE-2026-97229 CVSS 10 CRITICAL Analyzed
CVE-2026-97229 - Integer Overflow or Wraparound in GitLab
GitLab has remediated an issue in GitLab CE/EE affecting all versions from 19.2 before 19.2.8, 19.3 before 19.3.5, and 19.4 before 19.4.2 that, under certain conditions, could have allowed an unauthenticated user to execute arbitrary code on the GitLab server via a specially crafted regular expression in a CI/CD configuration, due to insufficient regular expression validation.
CVE-2024-27282 CVSS 6.6 MEDIUM Deferred
CVE-2024-27282 - Apache Ruby Heap Information Disclosure Vulnerability
An issue was discovered in Ruby 3.x through 3.3.0. If attacker-supplied data is provided to the Ruby regex compiler, it is possible to extract arbitrary heap data relative to the start of the text, including pointers and sensitive strings. The fixed versions are 3.0.7, 3.1.5, 3.2.4, and 3.3.1.
CVE-2022-28738 CVSS 9.8 CRITICAL Modified
CVE-2022-28738 - Ruby Regxp Double Freeяет
A double free was found in the Regexp compiler in Ruby 3.x before 3.0.4 and 3.1.x before 3.1.2. If a victim attempts to create a Regexp from untrusted user input, an attacker may be able to write to unexpected memory locations.