CVE-2024-41921
7.8Open Source Robotics Foundation · Robot Operating System (ROS)
A code injection vulnerability in the ROS rostopic tool allows local attackers to execute arbitrary code via the --filter option by passing unsanitized input to the Python eval function.
Executive summary
The ROS 1 rostopic command-line tool contains a critical code injection vulnerability that allows local attackers to execute arbitrary commands, requiring an immediate migration to ROS 2.
Vulnerability
The vulnerability exists within the echo verb of the rostopic tool, which improperly handles user-provided input via the --filter flag. This input is passed directly to the Python eval function without sanitization, allowing an attacker with local access to perform code injection.
Business impact
This vulnerability poses a severe risk to any environment utilizing ROS 1, as it allows for full code execution under the privileges of the user running the rostopic tool. A successful exploit could lead to complete system compromise, unauthorized data access, or the manipulation of robotic hardware controlled by the ROS environment. Given the high CVSS score of 7.8, organizations must treat this as a significant security deficiency.
Remediation
Immediate Action: Since all affected ROS 1 distributions are end-of-life, the only effective remediation is to migrate all affected systems to a supported ROS 2 distribution.
Proactive Monitoring: Security teams should audit system access logs for suspicious rostopic command executions and monitor for unauthorized Python processes spawned by the ROS environment.
Compensating Controls: Restrict local user access to the systems running ROS and implement strict file system permissions to minimize the impact of a potential code injection.
Exploitation status
Public Exploit Available: Unknown
Analyst recommendation
The reliance on end-of-life software components creates an unpatchable security gap that cannot be fully mitigated through configuration alone. Organizations should prioritize the transition to ROS 2 immediately to eliminate this code injection vector and ensure long-term support and security updates are available for their robotic systems.
More Open Source Robotics Foundation CVEs
Sources
Originally found and disclosed by Florencia Cabral Berenfus, Ubuntu Robotics Team, per the CVE Program record.