Vulnerability · Published Jul 17, 2025 · Assigned by canonical

CVE-2024-41148Unsafe use of eval() method in rostopic hz tool

High 7.8

In plain English

A high-severity code injection in Robot Operating System (ROS) from Open Source Robotics Foundation. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 13% of all known vulnerabilities).

Severity (CVSS 3.1)7.8High
Exploit odds (30 days)0.2%top 87.2% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

A code injection vulnerability has been discovered in the Robot Operating System (ROS) 'rostopic' command-line tool, affecting ROS distributions Noetic Ninjemys and earlier. The vulnerability lies in the 'hz' verb, which reports the publishing rate of a topic and accepts a user-provided Python expression via the --filter option. This input is passed directly to the eval() function without sanitization, allowing a local user to craft and execute arbitrary code.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12ros-ros-commno fix listedDEBIAN-CVE-2024-41148
Debian:13ros-ros-commno fix listedDEBIAN-CVE-2024-41148
Debian:14ros-ros-commno fix listedDEBIAN-CVE-2024-41148
Ubuntu:22.04:LTSros-ros-commno fix listedUBUNTU-CVE-2024-41148

Affected products (as reported)

VendorProductVersions
Open Source Robotics Foundation Robot Operating System (ROS) Noetic NinjemysMelodic MoreniaKinetic KameIndigo Igloo

Weakness: CWE-95, CWE-94 · Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

References