Skip to main content

Malicious code in pfa-errors (npm)

0
Critical
Published: 08/05/2026 (08/05/2026, 12:51:05 UTC)
Source: GCVE Database
Product: pfa-errors

Description

The pfa-errors npm package version 20.4.9 contains malicious code that downloads and executes a platform-specific binary from hardcoded Cloudflare workers.dev endpoints. The binary is saved with a decoy filename and executed detached from the main process. If HTTPS is unavailable, the binary is reconstructed via a DNS-TXT covert channel. The code uses obfuscation techniques to evade detection. A second similar dropper exists in the package but is not invoked from the main entry point.

Affected software

npmghsa
pfa-errors
Affected versions
=20.4.9

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 08/05/2026, 17:23:12 UTC

Technical Analysis

The pfa-errors package version 20.4.9 includes malicious functionality in its index.js file that unconditionally loads a runtime.js script. This script fetches an opaque binary payload from one of three hardcoded Cloudflare workers.dev URLs, writes it to a temporary file with a decoy name, sets executable permissions, and spawns it detached using system shell commands. When HTTPS is unavailable, the binary is reconstructed through a DNS-TXT covert channel from base64-encoded chunks. The code fragments sensitive API names and hostnames into arrays and reassembles them at runtime to evade static analysis. Additionally, a second dropper with identical behavior is embedded in lib/telemetry.js but is not reachable from the main index.js entry point.

Potential Impact

This malicious code enables remote code execution on any system that installs and runs the affected pfa-errors package version 20.4.9. The attacker can execute arbitrary platform-specific binaries fetched from attacker-controlled endpoints, potentially leading to full system compromise. The use of covert DNS channels and obfuscation techniques complicates detection and analysis.

Mitigation Recommendations

Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix or removal of the malicious package is confirmed, avoid using pfa-errors version 20.4.9. Consider removing the package from your environment and replacing it with a trusted alternative. Monitor for updates from the package maintainers or npm security advisories regarding remediation.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
MAL-2026-12406
Osv Schema Version
1.7.4
Ecosystems
["npm"]

Threat ID: 6a735745bf8831d539159ee8

Added to database: 08/05/2026, 15:31:17 UTC

Last enriched: 08/05/2026, 17:23:12 UTC

Last updated: 09/09/2026, 12:45:04 UTC

Views: 18

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses