CVE-2022-35104
Medium · 5.5CVSS
5.5
EPSS
0.3%
Published
Aug 16, 2022
CISA due date
—
Cloudanix analysis
A problem in an older set of Flash-file tools can make those programs crash when they try to read certain files on a user's computer.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Denial Of Service
- Component
- Application
- Class
- Memory Corruption
- Remediation
- Patch
- Effort
- Medium
- Patch risk
- Low
What it actually does
Heap buffer overflow in DCTStream::reset() at Stream.cc allows out-of-bounds memory access when parsing malformed DCT streams inside SWF files, resulting in process crash or potential memory corruption.
Why it matters to the business
Local users or automated workflows that process untrusted SWF files with the affected tools may experience application crashes and service interruptions; the project shows no official fixed releases, increasing long-term exposure for organizations still relying on it.
How an attack unfolds
An attacker creates a specially crafted SWF containing a malformed DCT stream, then convinces a victim to open the file locally with an affected swftools binary; the overflow occurs during stream reset and may be leveraged for denial of service or further memory corruption.
How to fix it
Replace swftools with a maintained alternative such as pdf2svg, mutool, or Ghostscript. If continued use is required, compile from a post-772e55a2 codebase once upstream fixes are merged, or isolate the tools inside containers with no access to sensitive data.
How to confirm the fix worked
Run the affected utilities against a corpus of known-good and known-bad SWF files; confirm absence of crashes or sanitizer reports (ASAN/UBSAN) on test cases that previously triggered the overflow. Monitor project commits for any future DCTStream changes.
Typical attack path
- Craft malicious SWF embedding oversized or malformed DCT data
- Deliver file via email, download link, or shared storage
- Victim executes swftools utility (pdf2swf, swfextract, etc.) on the file
- DCTStream::reset triggers heap overflow leading to crash or corruption
How to detect it
Review process execution logs and crash dumps for swftools binaries encountering unexpected termination while processing SWF inputs; correlate with file-access timestamps on potentially malicious SWF artifacts.
What your security team should do
- Inventory all systems and CI pipelines that invoke swftools binaries and prioritize removal or replacement
- Block execution of swftools on endpoints that handle untrusted files until replacement is complete
- Add SWF file-type restrictions or sandboxing for any remaining legacy workflows
The record
SWFTools commit 772e55a2 was discovered to contain a heap-buffer overflow via DCTStream::reset() at /xpdf/Stream.cc.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Ubuntu:16.04:LTS | swftools | 0 | No fix |
| Ubuntu:18.04:LTS | swftools | 0 | No fix |
| Ubuntu:Pro:16.04:LTS | swftools | 0 | No fix |
| Ubuntu:Pro:18.04:LTS | swftools | 0 | No fix |
Related vulnerabilities
- CVE-2024-28458 Null Pointer Dereference vulnerability in swfdump in swftools 0.9.2 allows attackers to… Also affects swftools
- CVE-2024-26334 swftools v0.9.2 was discovered to contain a segmentation violation via the function… Also affects swftools
- CVE-2024-26337 swftools v0.9.2 was discovered to contain a segmentation violation via the function… Also affects swftools
- CVE-2024-26335 swftools v0.9.2 was discovered to contain a segmentation violation via the function… Also affects swftools
- CVE-2024-26339 swftools v0.9.2 was discovered to contain a strcpy parameter overlap via… Also affects swftools
- CVE-2024-26333 swftools v0.9.2 was discovered to contain a segmentation violation via the function… Also affects swftools
- CVE-2024-25165 A global-buffer-overflow vulnerability was found in SWFTools v0.9.2, in the function… Also affects swftools
- CVE-2024-22956 swftools 0.9.2 was discovered to contain a heap-use-after-free vulnerability via the… Also affects swftools