Deserialization Flaw in Ruby Workers
A severe Remote Code Execution (RCE) vulnerability has been identified in RubitMQ job workers, stemming from unsafe JSON deserialization practices.
The issue arises not from memory corruption or complex undefined behavior, but from design-level trust assumptions regarding how data is processed in Ruby background systems.
Security researcher NullSecurityX has demonstrated that this flaw allows attackers to bridge the gap between data and code, turning harmless JSON inputs into executable commands that can compromise the entire infrastructure.
The core of the vulnerability lies in the use of Oj.load for processing job payloads. While developers often view JSON as a safe data-interchange format, the Oj library in Ruby supports object deserialization features that can reconstruct fully functional objects.
When the system encounters specific directives like ^o, it does not just parse data but allocates instances of classes defined in the application.
This behavior becomes critical when the application employs capability-based dynamic dispatch, checking if an object responds to a specific method before executing it.
According to NullSecurityX, in this specific architecture, the system checks for a run_find method capability, assuming that method availability equates to authorization.
| CVE ID | CVSS Score | Severity | Description |
|---|---|---|---|
| CVE-2024-XXXX | 9.8 | Critical | Unsafe deserialization in RubitMQ via Oj.load allows remote code execution through object injection. |
Attackers can exploit this by crafting a JSON payload that instantiates a Node utility class found within the application code.
This class contains a run_find method designed to execute system commands via Open3.capture3.
Affected Products
| Product | Affected Component | Patch Status |
|---|---|---|
| RubitMQ | Job Worker (JSON Processor) | Update Required |
| Ruby Oj Gem | Default Load Configuration | Configuration Change Required |
By injecting arguments that utilize the Unix find command’s -exec flag, an attacker can force the background worker to execute arbitrary shell commands.
The exploitation path is deterministic and allows the attacker to bypass standard security controls, executing commands with the privileges of the background worker.
This can lead to data exfiltration, service disruption, or further lateral movement within the network.
Follow us on Google News, LinkedIn, and X to Get Instant Updates and Set GBH as a Preferred Source in Google.
A December intrusion to Storm-2603, the China-based group Microsoft ties to Warlock ransomware. The attackers…
A decade-old authentication bypass in OpenSSH on musl-based Linux lets attackers log into accounts that…
Bitdefender researchers have revealed a vulnerability called GhostMap that affects Android devices. This vulnerability can…
Microsoft has announced a vulnerability in Windows Paint that could let unauthenticated attackers execute malicious…
An autonomous penetration-testing framework linked to South Korean banking breaches and cloud supply-chain attacks is…
Shopify is making IP allowlisting mandatory for all public apps to limit abuse of stolen…