Skip to content
supplychainattack.orgSupply chain attack incident catalog
resolvedcritical

Malicious code in simple-date-formatter-new-10 (npm)

simple-date-formatter-new-10@1.0.0 on npm contained malicious postinstall scripts that established a reverse shell and exfiltrated SSH keys from affected systems. The package masqueraded as a date-formatting utility while executing two attack payloads upon installation.

ShareXLinkedInHacker News
Disclosed
Last updated
Blast radius
Any developer or system that installed simple-date-formatter-new-10@1.0.0 during the package's availability on npm.
Ecosystems
Attack vectors
Affected entities
  • simple-date-formatter-new-10 · 1.0.0

simple-date-formatter-new-10@1.0.0 was published to npm as a seemingly benign date-formatting library but contained two malicious payloads executed during package installation via postinstall scripts.\n\nThe first payload, triggered by a postinstall script in package.json, opens an interactive bash reverse shell to 124.221.154.135:4444 over /dev/tcp, granting the attacker remote command execution on the installer's host. The second payload, bundled in postinstall.js, reads the contents of the installer's ~/.ssh directory and exfiltrates it via HTTP POST to https://124.221.154.135/post, the same C2 endpoint, along with the username and platform information.\n\nThe advertised date-formatting API (index.js exporting formatDate) served as cover for the actual malicious functionality. The incident was identified and credited to the OpenSSF's malicious-packages repository.

Indicators of compromise

Packages
  • simple-date-formatter-new-10
Domains
  • 124.221.154.135
IPs
  • 124.221.154.135

Remediation

  • Immediately uninstall simple-date-formatter-new-10 from all systems where it was installed
  • Rotate all SSH keys that may have been present in ~/.ssh directories on affected systems
  • Review command execution logs on systems where the package was installed for signs of unauthorized access
  • Audit npm package.json postinstall scripts in your dependency tree for suspicious behavior
  • Use npm audit to identify and remove other potentially malicious packages
  • Consider implementing npm package verification and sandboxing practices in your development workflow

Sources

  1. GitHub Advisory GHSA-wgv9-74pq-hwh9 · GitHub Advisory Database

Cite this entry

"Malicious code in simple-date-formatter-new-10 (npm)." supplychainattack.org, Supply Chain Attack Incident Catalog. Disclosed August 10, 2026; last updated August 10, 2026. https://supplychainattack.org/incident/malicious-code-in-simple-date-formatter-new-10-npm-5priws

Suggest a correction

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

  1. resolvedcritical

    Malicious code in autbank-core (npm)

    The npm package autbank-core contained malicious preinstall and postinstall lifecycle hooks that exfiltrated environment variables, credentials, and system information to a hardcoded webhook.site endpoint during installation.

    npmCompromised package
  2. resolvedcritical

    Malicious code in adxaa (npm)

    The npm package adxaa contained obfuscated malicious JavaScript designed to target users of a specific WordPress site. The payload exfiltrates session data, deletes accounts, and hijacks credentials via email overwrite and password reset.

    npmCompromised package
  3. resolvedcritical

    Malicious code in upload-to-gcp (npm)

    upload-to-gcp@3.2.1 (npm) contains malicious code in its postinstall script that exfiltrates host identifiers to an attacker-controlled endpoint. The package masquerades as a Google Cloud Platform utility but performs unauthorized telemetry collection at install time.

    npmCompromised package
  4. resolvedcritical

    Malicious code in akamai-sensor (npm)

    A malicious npm package named akamai-sensor impersonated Akamai's legitimate sensor_data anti-bot SDK. The package contained hidden JavaScript code concealed using invisible Unicode characters and implemented a dynamic command-and-control channel via a Google Calendar dead-drop, enabling arbitrary code execution on installation.

    npmCompromised packageTyposquatting