VYPR

npm · Malicious package advisory

Malware

mongoose-json-format

MAL-2026-6499

Malicious code in mongoose-json-format (npm)

Details


---
_-= Per source details. Do not edit below this line.=-_

## Source: amazon-inspector (910cc6eef707ac872daeb3a527e6dd9c75044ebb178f9eb48745f5cfd4123968)
helpers.js defines a createLog() helper that base64-decodes a constant HASH_KEY to https://www.jsonkeeper.com/b/XVHGD (an anonymous JSON-paste host) and fetches the response, then passes data.data to a createLogger() function from the log-format-thread dependency. The destination URL is stored as a base64 literal to avoid plain-text discovery. However, the helper is never invoked from the package's main entry (index.js) in this version, and helpers.js itself contains broken code (an `import { req } from "request"` for an unused symbol, and a top-level `await` inside a non-async function) that would prevent the module from loading cleanly if it were required. The fetched content is also passed only to a logger formatter, not to eval/exec/Function/require — so even on the dead code path, the bytes are not executed as code. The combination of obfuscated URL + anonymous paste host + tampering shape is suspicious and inconsistent with a legitimate JSON-formatting helper, but the harmful path is not reached by a default require() of this package and there is no install-time lifecycle hook driving the fetch.

## Source: ghsa-malware (4b3b4e269246a3979e91e827093cc4161b3f4351957eae0d3f1ba80ae8a07502)
Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.

Compromised versions (2)

  • 3.0.1
  • 3.0.0

Any computer that installed or ran a compromised version should be considered fully compromised. Rotate every secret on that machine from a clean environment.