Your RSA-2048 keys break in 2030. Find every one of them before attackers do.
📦
📦 npm
Not in CISA KEV
CRITICAL severity

GHSA-gjx4-2c7g-fm94

CRITICALFix: bencevans/screenshot-desktop@59c87b0

GHSA-gjx4-2c7g-fm94 is a critical-severity (CVSS 9.8) CWE-77 vulnerability in screenshot-desktop. O3 Security confirms whether GHSA-gjx4-2c7g-fm94 is actually reachable in your code before you act, and blocks exploitation at runtime until you patch.

screenshot-desktop vulnerable to command Injection via `format` option

Also known asCVE-2025-55294
Published
Aug 19, 2025
Updated
Aug 19, 2025
Affected
1 pkg
Patched
1 / 1
Exploits
None indexed
Exploitation data as of Aug 19, 2025 · OSV.dev, NVD, FIRST.org (EPSS)

Real-World Exposure

1 pkg affected

How broadly this vulnerability is actually deployed: weekly install volume shows current usage, a proxy for how much of the ecosystem is exposed.

screenshot-desktopnpm
54Kdownloads / week

Description

Impact

This vulnerability is a command injection issue.
When user-controlled input is passed into the format option of the screenshot function, it is interpolated into a shell command without sanitization.
An attacker can craft malicious input such as:

{ format: "; echo vulnerable > /tmp/hello;" }

This results in arbitrary command execution with the privileges of the calling process.

Who is impacted:
Any application that accepts untrusted input and forwards it directly (or indirectly) into the format option is affected. If the library is used in a server-side context (e.g., API endpoints, web services), attackers may be able to exploit this remotely and without authentication, leading to full compromise of confidentiality, integrity, and availability.

CVSS v3.1 Base Score: 9.8 (Critical)
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Patches

The issue has been patched in version 1.15.2.
All users are strongly recommended to upgrade to 1.15.2 or later.
All earlier versions are vulnerable.

Workarounds

If upgrading is not immediately possible, developers should:

  • Strictly validate or whitelist acceptable format values (e.g., "jpeg", "png", "webp").
  • Reject or sanitize any unexpected input before passing it to the library.
  • Avoid allowing user-controlled data to reach the format option.

References

Affected Packages

1 total 1 fixed
EcosystemPackageVulnerable rangeFix
📦npmscreenshot-desktopall versions1.15.2

Detection & mitigation playbook

Open-source dependency
  1. Detect

    Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for screenshot-desktop. O3's reachability analysis confirms whether the vulnerable code path is actually invoked in your application, so you act on real exposure instead of every transitive match.

  2. Fix

    Update screenshot-desktop to 1.15.2 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-gjx4-2c7g-fm94 is resolved across your whole dependency graph.

  3. Workarounds

    If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.

  4. How O3 protects you

    O3 pinpoints whether GHSA-gjx4-2c7g-fm94 is reachable in your code and exactly where to fix it, then blocks exploitation in production at runtime until the patched version is deployed.

Tailored to GHSA-gjx4-2c7g-fm94. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.

Frequently Asked Questions

## Impact This vulnerability is a **command injection** issue. When user-controlled input is passed into the `format` option of the screenshot function, it is interpolated into a shell command without sanitization. An attacker can craft malicious input such as: { format: "; echo vulnerable > /tmp/hello;" } This results in arbitrary command execution with the privileges of the calling process. **Who is impacted:** Any application that accepts untrusted input and forwards it directly (or indirectly) into the `format` option is affected. If the library is used in a server-side contex
O3 Security · Impact-Aware SCA

Is GHSA-gjx4-2c7g-fm94 in your dependencies?

O3 detects GHSA-gjx4-2c7g-fm94 across npm dependencies and uses function-level reachability to confirm whether the vulnerable code path is actually reachable — not just present. No false positives.

GHSA-gjx4-2c7g-fm94: screenshot-desktop… | O3 Security