Описание
GitLab has remediated an issue in GitLab CE/EE affecting all versions from 19.2 before 19.2.7, 19.3 before 19.3.3, and 19.4 before 19.4.1 that under certain conditions could have allowed an authenticated user to execute arbitrary code on the GitLab server due to a double free issue when parsing a specially crafted regular expression in a CI/CD configuration.
A flaw was found in Ruby. When compiling a specially crafted regular expression with the methods Regexp.new, Regexp.union, Regexp.compile, or via a string interpolation such as /#{input}/, a double free can occur when parsing a pattern that fails after an alternation. This double free causes memory corruption, potentially resulting in arbitrary code execution.
Отчет
Red Hat has rated the impact of these flaws as Moderate for the Ruby packages shipped in Red Hat Enterprise Linux. The Ruby packages provide a language interpreter and standard library and do not accept external input on their own; these flaws are reachable only when an application compiles a regular expression constructed from attacker-controlled input. Upstream Ruby has published a security advisory for these issues and scopes the flaws narrowly, stating that they "are reached only when an application compiles a regular expression from a string that an attacker controls, for example by passing it to Regexp.new, Regexp.union or Regexp.compile", and that "applications that only use regular expressions written by their own developers are not affected". Upstream further notes that Ruby "has generally considered it unsafe to compile and use a regular expression created from untrusted input". The CVE identifiers for these flaws were assigned by GitLab, where the issues were originally reported and where remote code execution was demonstrated against GitLab's own application. Ruby did not request separate identifiers and has asked downstream distributors to track these issues under GitLab's CVE IDs.
Меры по смягчению последствий
To mitigate this vulnerability, do not compile regular expressions from untrusted sources. Standard safeguards such as Regexp.timeout or limiting the length of the input pattern do not protect against this issue.
Затронутые пакеты
| Платформа | Пакет | Состояние | Рекомендация | Релиз |
|---|---|---|---|---|
| Red Hat Enterprise Linux 10 | ruby4.0 | Not affected | ||
| Red Hat Enterprise Linux 6 | ruby | Affected | ||
| Red Hat Enterprise Linux 7 | ruby | Affected | ||
| Red Hat Enterprise Linux 8 | ruby:2.5/ruby | Affected | ||
| Red Hat Enterprise Linux 8 | ruby:3.3/ruby | Affected | ||
| Red Hat Enterprise Linux 9 | ruby:4.0/ruby | Not affected | ||
| Red Hat Hardened Images | hi/ruby | Not affected | ||
| Red Hat OpenShift Container Platform 4 | openshift/ose-rhel-coreos-9 | Not affected | ||
| Red Hat OpenShift Container Platform 5 | openshift/ose-rhel-coreos-9 | Not affected | ||
| Red Hat Enterprise Linux 10 | ruby | Fixed | RHSA-2026:96235 | 09.11.2026 |
Показывать по
Ссылки на источники
Дополнительная информация
Статус:
EPSS
9.8 Critical
CVSS3
Связанные уязвимости
GitLab has remediated an issue in GitLab CE/EE affecting all versions from 19.2 before 19.2.7, 19.3 before 19.3.3, and 19.4 before 19.4.1 that under certain conditions could have allowed an authenticated user to execute arbitrary code on the GitLab server due to a double free issue when parsing a specially crafted regular expression in a CI/CD configuration.
GitLab has remediated an issue in GitLab CE/EE affecting all versions ...
GitLab has remediated an issue in GitLab CE/EE affecting all versions from 19.2 before 19.2.7, 19.3 before 19.3.3, and 19.4 before 19.4.1 that under certain conditions could have allowed an authenticated user to execute arbitrary code on the GitLab server due to a double free issue when parsing a specially crafted regular expression in a CI/CD configuration.
Уязвимость программной платформы на базе git для совместной работы над кодом GitLab, связанная с ошибкой повторного освобождения памяти, позволяющая нарушителю выполнить произвольный код
EPSS
9.8 Critical
CVSS3