Cloudanix VulnDB

CVE-2021-42200

Medium · 5.5

CVSS

5.5

EPSS

0.7%

Published

Jun 2, 2022

CISA due date

—

Cloudanix analysis

Schedule a fix SSVC: Track

A bug in a file-processing tool can make it crash when it receives certain bad files, briefly stopping whatever work depends on that tool.

Exploit Available
Exploitation
Requires User Interaction
Attacker needs
User Interaction
Complexity
Low
Impact
Denial Of Service
Component
Application
Class
Memory Corruption
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

NULL pointer dereference in main() within swfdump.c causes the process to crash when handling specially crafted input, resulting in denial of service.

Why it matters to the business

Unexpected crashes interrupt processing workflows that rely on the affected library or tool, leading to operational delays and potential loss of availability for dependent services.

How an attack unfolds

An attacker supplies a malformed input file to the swfdump utility; the code path reaches the vulnerable main function without proper null checks, dereferencing a null pointer and terminating the process.

How to fix it

Upgrade libp2p/js-libp2p to the fixed commit cfc26ee21516a411971af5e4aec446c7c3eab6c0; rebuild and redeploy any packages that embed the vulnerable swftools code.

How to confirm the fix worked

Confirm the installed version or commit hash matches the fixed revision; re-run the crashing input against the updated binary to verify it no longer terminates unexpectedly.

Typical attack path

  1. Identify an application or script that invokes the vulnerable swfdump functionality
  2. Craft or obtain a file that triggers the null dereference
  3. Deliver the file to the target process or command
  4. Observe process termination and service disruption

How to detect it

Review system and application logs for abrupt terminations of swfdump or processes linked to the affected library; correlate with file-processing events around the time of the crash.

What your security team should do

  • Apply the referenced commit immediately given the public exploit availability
  • Scan build pipelines and dependency manifests for the vulnerable swftools code
  • Add crash-monitoring alerts for swfdump processes in production environments

The record

An issue was discovered in swftools through 20201222. A NULL pointer dereference exists in the function main() located in swfdump.c. It allows an attacker to cause Denial of Service.

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