Skip to content
supplychainattack.orgSupply chain attack incident catalog
containedcritical

Malicious code in @wizloft/harness-context (npm)

The npm package @wizloft/harness-context contained heavily obfuscated malicious code that executes arbitrary code at require time by fetching instructions from an attacker-controlled Ethereum smart contract. The payload uses the EtherHiding loader pattern to maintain persistent, mutable control over code execution.

ShareXLinkedInHacker News
Disclosed
Last updated
Blast radius
Any npm consumer of @wizloft/harness-context; code execution at require time via attacker-controlled Ethereum contract state.
Ecosystems
Attack vectors
Affected entities
  • @wizloft/harness-contextnpm package with malicious code in dist/index.js

The npm package @wizloft/harness-context was found to contain malicious code in its main entry point (dist/index.js). The malicious payload is an obfuscated IIFE appended after legitimate context-service code, using obfuscator.io-style obfuscation with a rotated string decoder array (~303 entries) to hide its true behavior.\n\nOn import, the payload stashes references to require and module in global variables, then makes HTTPS requests to an Ethereum public RPC endpoint (h.drpc.org) and a block-explorer account API. It reads state from a smart contract (0xa322E5f3...) to resolve a next-stage URL, which is then fetched and executed in-process. This implements the EtherHiding loader pattern, allowing the attacker to update malicious code by modifying contract state without republishing the package.\n\nThe obfuscated strings hide indicators including drpc.org, ?module=ac, POST, application/json, Mozilla/5., and the contract address. The package's advertised purpose—a small typed capability contract—does not match its actual behavior.\n\nThe incident was identified by the OpenSSF malicious-packages project and reported via Amazon Inspector.

Indicators of compromise

Packages
  • @wizloft/harness-context
Domains
  • h.drpc.org
  • drpc.org

Remediation

  • Immediately remove @wizloft/harness-context from all dependencies and lock files
  • Audit all projects that installed this package for signs of compromise or data exfiltration
  • Review network logs for outbound HTTPS connections to h.drpc.org or Ethereum block-explorer APIs
  • Regenerate any credentials or secrets that may have been exposed to the compromised process
  • Update to a safe alternative package or implement the required functionality directly

Sources

  1. GitHub Advisory GHSA-4pph-8v8q-67x2 · GitHub Advisory Database

Cite this entry

"Malicious code in @wizloft/harness-context (npm)." supplychainattack.org, Supply Chain Attack Incident Catalog. Disclosed August 19, 2026; last updated August 19, 2026. https://supplychainattack.org/incident/malicious-code-in-wizloft-harness-context-npm-l1mscf

Suggest a correction

Found an error or have a newer source? Corrections to factual errors take priority over new entries.

  1. containedcritical

    Malicious code in 3-buildsight-web (npm)

    The npm package 3-buildsight-web contains malicious code that fetches and executes arbitrary JavaScript from a remote Bitbucket URL on module load, granting full page privileges to an unverified third party.

    npmCompromised package
  2. resolvedcritical

    Malicious code in @usaa-grp-personal-profile/personal-profile-common (npm)

    Malicious package @usaa-grp-personal-profile/personal-profile-common version 999.0.0 published to public npm as a dependency-confusion attack targeting an organization's internal registry. The package contains preinstall and postinstall hooks that exfiltrate hostname, username, and working directory to an attacker-controlled OAST endpoint on every install.

    npmDependency confusionCompromised package
  3. resolvedcritical

    Malicious code in create-coin (npm)

    create-coin@20.1.1 on npm contained malicious postinstall code that collected sensitive environment variables, credentials, and host reconnaissance data. The package impersonated an esbuild platform build and exfiltrated data to a hardcoded endpoint.

    npmCompromised packageTyposquatting
  4. resolvedcritical

    Malicious code in @syncraft-labs/vue (npm)

    The npm package @syncraft-labs/vue version 0.4.1 contained malicious obfuscated code in its ESM build that implements a blockchain-hosted C2 dropper (EtherHiding pattern), enabling remote code execution on any consumer importing the package.

    npmCompromised package