Skip to content
Heist/ feed
Unrated

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

Type: advisorySource: OSV1 source record

--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (5e57e9eff2fae987a2a23e3107d64c818e020b03380e31d6a3ae9cf8d4eb14ec) package.json declares a postinstall lifecycle script that pipes a string-reversed shell one-liner through `rev | bash`, decoding to a bash reverse shell that opens /dev/tcp/124.221.154.135/4444 and attaches an interactive shell to it. This gives the publisher remote code execution on the installer's host at `npm install` time. The tarball also ships postinstall.js, which enumerates the installer's ~/.ssh directory, collects the filenames along with username and platform, and POSTs the JSON to https://124.221.154.135/post — direct exfiltration of SSH key material to the same hardcoded IP that receives the reverse shell. The obfuscation of the postinstall payload via string reversal and the mismatch between the package's advertised purpose (a date formatter) and its actual install-time behavior confirm malicious intent.

Announced Group revision 1
Original source ↗

MAL-2026-17162

Primary source · Revision 1

Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.

Security context

Source reference: osv:MAL-2026-17162

simple-date-formatter-new-16

Source reference: /affected/0/package/name

Affected versions
1.0.0

Source reference: /affected/0/versions

Fixed versions
Not stated in this record
Prerequisites
Not stated in this record

Structured affected-version data

Original package identities and version rules from this source.

[
  {
    "package": {
      "name": "simple-date-formatter-new-16",
      "purl": "pkg:npm/simple-date-formatter-new-16",
      "ecosystem": "npm"
    },
    "versions": [
      "1.0.0"
    ],
    "database_specific": {
      "cwes": [
        {
          "name": "Embedded Malicious Code",
          "cweId": "CWE-506",
          "description": "The product contains code that appears to be malicious in nature."
        }
      ],
      "source": "https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/simple-date-formatter-new-16/MAL-2026-17162.json",
      "indicators": {
        "evidence_files": [
          {
            "path": "package.json",
            "tlsh": "68e02684ce2098731ac682b948564557bb58ae4b45153c19324b141c839fbb39dfc34e",
            "sha256": "d5d79da80e4c6575e9c290ba125e1c016efa14db3b18d42967285a827c2b987f"
          },
          {
            "path": "postinstall.js",
            "tlsh": "273165d558f9cd3007778685639b91263102fe13650ee940f3c807a51fe9a5449f2dee",
            "sha256": "f2be6940c08d36a7f1ce83d5fe16fefd8c14edda5d124e0f6406725beb5020ef"
          }
        ],
        "package_integrity": [
          {
            "hashes": {
              "sha1": "9af16e301c7e58bd5de7d12ee95ede4fe0788fb6",
              "sha512_sri": "sha512-3kal5oEDxCbnumlU6PZbdvxNCdOBrWgGluQe7U19mADfmpsyGSWJ8bM/4IOeudrrwdKIwLmPDoSRwd3CCMsAFg=="
            },
            "filename": "simple-date-formatter-new-16-1.0.0.tgz"
          }
        ]
      }
    }
  }
]

Publisher severity

No explicit severity was provided.

Event
#13789 · Revision 1
Added to Heist Feed
Publisher date
Read the original announcement