7.8high
Unsafe use of eval() method in rostopic hz tool
- Severity
- 7.8high CVSS:3.1 by canonical
- Exploit likelihood
- 0.22% (higher than 13% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- canonical
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
| Product or package | Versions | Reported by |
|---|---|---|
| rostopic | Noetic Ninjemys, Melodic Morenia, Kinetic Kame, Indigo Igloo | CVE List |
| openrobotics robot_operating_system | indigo_igloo, kinetic_kame, melodic_morenia, noetic_ninjemys | NVD |
Classification
What each source says
CVE List
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.
NVD (es)
Se ha descubierto una vulnerabilidad de inyección de código en la herramienta de línea de comandos "rostopic" del Robot Operating System (ROS), que afecta a las distribuciones de ROS Noetic Ninjemys y anteriores. La vulnerabilidad reside en el verbo "hz", que informa la tasa de publicación de un tema y acepta una expresión de Python proporcionada por el usuario mediante la opción --filter. Esta entrada se pasa directamente a la función eval() sin depurar, lo que permite a un usuario local manipular y ejecutar código arbitrario.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2024-41148 changed 2025-07-18 | CVE Terms of Use |
| NVD | CVE-2024-41148 changed 2026-06-17 | Public domain |