PT-2024-2479 · Ruby+7 · Rdoc+7

Oooooo_Q

·

Published

2024-03-19

·

Updated

2025-09-29

·

CVE-2024-27281

CVSS v3.1

4.5

Medium

VectorAV:L/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:L
Name of the Vulnerable Software and Affected Versions RDoc versions 6.3.3 through 6.6.2
Description The issue is related to the restoration of untrusted data in memory by the RDoc documentation generator for the Ruby programming language. This can be exploited to execute arbitrary code using specially crafted files with the .rdoc options extension. When parsing .rdoc options as a YAML file, object injection and resultant remote code execution are possible due to the lack of restrictions on the classes that can be restored. Additionally, when loading the documentation cache, object injection and resultant remote code execution are also possible if a crafted cache exists.
Recommendations For Ruby 3.0 users, update to rdoc 6.3.4.1. For Ruby 3.1 users, update to rdoc 6.4.1.1. For Ruby 3.2 users, update to rdoc 6.5.1.1. For other users, update the RDoc gem to version 6.6.3.1 or later. You can use gem update rdoc to update it. If you are using bundler, please add gem "rdoc", ">= 6.6.3.1" to your Gemfile. As a temporary workaround, consider restricting access to the .rdoc options file to minimize the risk of exploitation.

Exploit

Fix

RCE

Deserialization of Untrusted Data

Special Elements Injection

Weakness Enumeration

Related Identifiers

ALSA-2024:3500
ALSA-2024:3546
ALSA-2024:3668
ALSA-2024:3670
ALSA-2024:3671
ALSA-2024:3838
ALSA-2024:4499
ALSA-2025_16880
AZL-40523
AZL-40675
BDU:2024-02457
CESA-2024_3500
CESA-2024_3546
CESA-2024_3670
CESA-2024_4499
CVE-2024-27281
DLA-3858-1
DSA-5677-1
GHSA-592J-995H-P23J
INFSA-2024_3500
INFSA-2024_3546
INFSA-2024_3668
INFSA-2024_3670
INFSA-2024_3671
INFSA-2024_3838
INFSA-2024_4499
MGASA-2024-0160
OESA-2024-1433
RHSA-2024:3500
RHSA-2024:3546
RHSA-2024:3668
RHSA-2024:3670
RHSA-2024:3671
RHSA-2024:3838
RHSA-2024:4499
RHSA-2024_3500
RHSA-2024_3546
RHSA-2024_3668
RHSA-2024_3670
RHSA-2024_3671
RHSA-2024_3838
RHSA-2024_4499
RLSA-2024:3546
RLSA-2024:3668
RLSA-2024:3670
RLSA-2024:3671
RLSA-2024:4499
USN-6838-1
USN-6838-2

Affected Products

Almalinux
Astra Linux
Centos
Linuxmint
Rdoc
Red Hat
Rocky Linux
Ubuntu