ruby/rdoc · Security
Arbitrary Code Execution in Rdoc
- GHSA ID
- GHSA-ggxm-pgc9-g7fp
- CVE ID
- CVE-2021-31799
- Severity
- high
- Published
- Updated
- CVSS
- 7 · CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
- CVSS v3
- 7 · CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
Description
In RDoc 3.11 through 6.x before 6.3.1, as distributed with Ruby through 3.0.1, it is possible to execute arbitrary code via | and tags in a filename.
CWEs
- CWE-74 · Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')
- CWE-77 · Improper Neutralization of Special Elements used in a Command ('Command Injection')
- CWE-78 · Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
References
- https://nvd.nist.gov/vuln/detail/CVE-2021-31799 ↗
- https://github.com/ruby/rdoc/commit/a7f5d6ab88632b3b482fe10611382ff73d14eed7 ↗
- https://security-tracker.debian.org/tracker/CVE-2021-31799 ↗
- https://lists.debian.org/debian-lts-announce/2021/10/msg00009.html ↗
- https://www.oracle.com/security-alerts/cpuapr2022.html ↗
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rdoc/CVE-2021-31799.yml ↗
- https://security.gentoo.org/glsa/202401-05 ↗
- https://security.netapp.com/advisory/ntap-20210902-0004 ↗
- https://www.ruby-lang.org/en/news/2021/05/02/os-command-injection-in-rdoc ↗
- https://github.com/advisories/GHSA-ggxm-pgc9-g7fp ↗