CVE-2024-42851
NoneCVSS
—
EPSS
0.3%
Published
Aug 27, 2024
CISA due date
—
Cloudanix analysis
A flaw in an old open-source tool for reading camera photo details lets someone who already has access to a computer run their own programs if they feed it a specially made picture file.
- Exploitation
- Local Privilege
- Attacker needs
- Local User
- Complexity
- Moderate
- Impact
- Full Compromise
- Component
- Library
- Class
- Buffer Overflow
- Remediation
- Patch
- Effort
- Medium
- Patch risk
- Low
What it actually does
Buffer overflow in the paresetag function of exiftags allows local arbitrary code execution by writing beyond allocated memory bounds during tag parsing.
Why it matters to the business
Attackers who can run code locally may gain control of the process or system, potentially leading to data theft or further compromise on machines that process untrusted image metadata with this library.
How an attack unfolds
An attacker supplies a specially crafted image file containing malformed EXIF tags to the vulnerable paresetag function, triggering the overflow and injecting shellcode that executes with the privileges of the calling process.
How to fix it
Upgrade to a patched release of exiftags if available, or replace the library with a maintained alternative such as exiftool or libexif. If source is used, apply bounds checking to the paresetag function and recompile. Disable or sandbox any workflows that process untrusted images with this version.
How to confirm the fix worked
Confirm the installed exiftags binary or library version is newer than 1.01 and test parsing of known-malformed samples to ensure no crash or overflow occurs. Review build logs or dependency manifests for the vulnerable version string.
Typical attack path
- Identify a system or workflow that invokes exiftags 1.01 on attacker-controlled files
- Craft a malicious image with oversized or malformed EXIF data targeting the paresetag function
- Trigger parsing via local execution of the tool or an application that embeds it
- Achieve arbitrary code execution and establish persistence or escalate privileges
How to detect it
Search process execution logs and file access records for invocations of exiftags against files originating from untrusted sources. Monitor for segmentation faults or crashes during EXIF parsing and inspect core dumps for signs of stack or heap manipulation.
What your security team should do
- Inventory all systems and containers using exiftags 1.01 and prioritize removal or replacement
- Block untrusted image uploads from reaching any code paths that call this library
- Add static analysis rules to flag use of the paresetag function in future code reviews
The record
Buffer Overflow vulnerability in open source exiftags v.1.01 allows a local attacker to execute arbitrary code via the paresetag function.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Debian:11 | exiftags | 0 | No fix |
| Debian:12 | exiftags | 0 | No fix |
| Debian:13 | exiftags | 0 | No fix |
| Ubuntu:16.04:LTS | exiftags | 0 | No fix |
| Ubuntu:18.04:LTS | exiftags | 0 | No fix |
| Ubuntu:20.04:LTS | exiftags | 0 | No fix |
| Ubuntu:22.04:LTS | exiftags | 0 | No fix |
| Ubuntu:24.04:LTS | exiftags | 0 | No fix |
| Ubuntu:24.10 | exiftags | 0 | No fix |
| Ubuntu:25.04 | exiftags | 0 | No fix |
| Ubuntu:25.10 | exiftags | 0 | No fix |
| Ubuntu:Pro:16.04:LTS | exiftags | 0 | No fix |
| Ubuntu:Pro:18.04:LTS | exiftags | 0 | No fix |
| Ubuntu:Pro:20.04:LTS | exiftags | 0 | No fix |