CVE-2019-1010023
glibc: running ldd on malicious ELF leads to code execution because of wrong size computation
Severity
LowRed Hat Product Security
CVSS 3.0
Review impact separately from score.
Published · July 15, 2019
Updated · November 22, 2025
Description
It was discovered that when executing ldd on a malicious file, it is possible to execute code because of the way libraries are loaded into the process memory. An attacker may trick a victim user into running ldd on malicious files, thus executing code with their privileges.
Statement
ldd is not intended to be executed on untrusted binaries, so a user should be very careful on what he runs ldd on.
CVSS score applicability
The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.
Mitigation
Use objdump -p /path/to/program | grep NEEDED instead of ldd when you want to get the library dependencies of an untrusted executable. However this just returns the direct dependencies of the program, so it should be manually run against all the needed libraries to get the entire dependency tree as ldd does.
CVSS / CWE
CVSS 3.0 · 7.8CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
CWE-20 · Improper Input Validation