CVE-2025-64726
Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.
NVD · uneditedSocket Firewall is an HTTP/HTTPS proxy server that intercepts package manager requests and enforces security policies by blocking dangerous packages. Socket Firewall binary versions (separate from installers) prior to 0.15.5 are vulnerable to arbitrary code execution when run in untrusted project directories. The vulnerability allows an attacker to execute arbitrary code by placing a malicious `.sfw.config` file in a project directory. When a developer runs Socket Firewall commands (e.g., `sfw npm install`) in that directory, the tool loads the `.sfw.config` file and populates environment variables directly into the Node.js process. An attacker can exploit this by setting `NODE_OPTIONS` with a `--require` directive to execute malicious JavaScript code before Socket Firewall's security controls are initialized, effectively bypassing the tool's malicious package detection. The attack vector is indirect and requires a developer to install dependencies for an untrusted project and execute a command within the context of the untrusted project. The vulnerability has been patched in Socket Firewall version 0.15.5. Users should upgrade to version 0.15.5 or later. The fix isolates configuration file values from subprocess environments. Look at `sfw --version` for version information. If users rely on the recommended installation mechanism (e.g. global installation via `npm install -g sfw`) then no workaround is necessary. This wrapper package automatically ensures that users are running the latest version of Socket Firewall. Users who have manually installed the binary and cannot immediately upgrade should avoid running Socket Firewall in untrusted project directories. Before running Socket Firewall in any new project, inspect `.sfw.config` and `.env.local` files for suspicious `NODE_OPTIONS` or other environment variable definitions that reference local files.
Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.
dbcve analysis · high confidenceSocket Firewall versions before 0.15.5 load configuration from `.sfw.config` files and directly populate environment variables into the Node.js subprocess without sanitization. An attacker placing a malicious `.sfw.config` with `NODE_OPTIONS='--require /path/to/malicious.js'` in a project directory allows arbitrary code execution when developers run `sfw npm install` in that directory, bypassing the tool's security controls.
Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.
CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.
From the vector- Attack vector
- Local
- Complexity
- Low
- Privileges
- Low
- Authentication
- X
- User interaction
- P
- Scope
- X
CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.
dbcve checksWork through these to decide whether this CVE applies to you.
-
Check installed Socket Firewall versionRun `sfw --version` or `npm list sfw -g` to determine the installed versionAffected if Version is lower than 0.15.5 (e.g., 0.15.4, 0.15.0, etc.)
-
Locate .sfw.config files in project directoriesRun `find . -name .sfw.config` in project directories or check common locations like the current working directory and user home directoryAffected if Any .sfw.config file exists in directories where you run `sfw npm install`
-
Inspect .sfw.config for unsafe environment variablesOpen each found .sfw.config file and examine its contents for lines starting with `NODE_OPTIONS=`, `NODE_PATH=`, or other environment variable assignmentsAffected if The file contains `NODE_OPTIONS=` or similar environment variable definitions pointing to external paths or unexpected values
-
Verify config loading behaviorRun `sfw npm install` with debug output or strace/dtrace to observe if .sfw.config values are passed to the npm subprocess environmentAffected if The subprocess environment includes values directly from the .sfw.config file without isolation or sanitization
You are affected if Socket Firewall version is below 0.15.5 AND a .sfw.config file containing NODE_OPTIONS or similar environment variables exists in or near your project directory where you run sfw commands.
Generated from the published advisory. Verify against your own configuration.
Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.
dbcve · scopedUpgrade to Socket Firewall version 0.15.5 or later, which isolates configuration file values from subprocess environments. Alternatively, ensure Socket Firewall is installed via the recommended `npm install -g sfw` method which auto-updates, or avoid running in untrusted project directories and inspect `.sfw.config` files for suspicious content.
version 0.15.5
- Check current Socket Firewall version by running `sfw --version`
- If version is earlier than 0.15.5, upgrade to version 0.15.5 or later
- For npm-based installations, run `npm install -g sfw` to get the latest version
- As a temporary mitigation if immediate upgrade is not possible, avoid running Socket Firewall in untrusted or unverified project directories
- Before running sfw in any new project, manually inspect the `.sfw.config` and `.env.local` files for suspicious `NODE_OPTIONS` or environment variable definitions that reference local files
Generated from the published advisory — verify against the referenced sources before acting.
- Consultation2.0 h
- Implementation1.0 h
- Testing2.0 h
- Review / QA1.0 h
An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $1,696.
Scan for this in your stack
Free · runs locallyCheck whether your project pulls in CVE-2025-64726 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.
References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.
Primary sourcesPractitioner notes
ContributedPeer-ranked notes from engineers who’ve handled CVE-2025-64726 in production — separate from our analysis above.
The advisory tells you what broke. It rarely tells you what actually worked. If you’ve dealt with this one, that detail is what the next engineer is searching for.
- The version that genuinely resolved it — not the one the vendor claimed
- A config change or rule that shut the vector down
- A gotcha in the upgrade path that cost you an afternoon
No notes yet
Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.
A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.
- Verified mitigations, workarounds, and config changes
- Version or environment caveats, and links to real fixes
- No weaponised exploit code, or anything meant to cause harm
- No spam, self-promotion, credentials, or personal data