{"id":"GHSA-f2r7-23p9-8jff","revision":null,"records":[{"revision":"a35135241e124ec4b65e4bc8cd273bdb","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"MAL-2026-5682","aliases":["GHSA-f2r7-23p9-8jff"],"title":"Malicious code in coral-wraith (npm)","description":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (cf0e5e4aa66ffeb1481fd587c96f596a227c9388b86b3a3443749b5ec9eb09f1)\nThe package's postinstall.js runs at install time and performs a credential-harvest + host-tampering chain against the installer. It enumerates npm credentials by calling `npm config get` for keys including `_authToken`, `_auth`, `registry`, `//registry.spectral-corsair.htb:1337/:_authToken`, `//registry.spectral-corsair.htb/:_authToken`, and `//154.57.164.64:32271/:_authToken`, dumps the full `npm config list --json`, and reads /usr/lib/node_modules/npm/.npmrc, /etc/hosts, /app/.bowerrc, /root/.bowerrc, and source files under /app (Cargo.toml, main.rs) plus filesystem-wide flag/secret greps. The collected output is base64-encoded and HTTP PUT to a hardcoded bare IP `http://154.57.164.64:32271/api/modules/...`. Separately, postinstall.js appends `154.57.164.64 registry.spectral-corsair.htb` to /etc/hosts when not already present, then queries the spoofed registry via curl and `npm view` — install-time host-file tampering that redirects a registry hostname to an attacker-controlled IP and enables later package substitution / MITM. Execution is gated by an anti-analysis `shouldRun()` that bypasses CI environments (GITHUB_ACTIONS, RUNNER_OS, CI), Chinese registry mirrors (npmmirror, tencent, cnpm, taobao), and /tmp working dirs, and only fires when the hostname matches a 12-hex Docker short-id pattern and cwd contains `/app` — narrow targeting that confirms intent while shipping the malicious code unconditionally.\n\n## Source: ghsa-malware (38185d2c242e73e720a6be3f2b234a23119ec986c4b7ca57ca789e24616c1029)\nAny 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.\n\n## Source: ossf-package-analysis (f10fa9dc8c51419efaef960da0e4bed5e80346be9279a40d610d695a8571f6b7)\nThe OpenSSF Package Analysis project identified 'coral-wraith' @ 6.0.0 (npm) as malicious.\n\nIt is considered malicious because:\n\n- The package executes one or more commands associated with malicious behavior.\n","state":0,"publishedAt":"2026-06-12T01:41:21+00:00","modifiedAt":"2026-07-09T23:01:59.6062337+00:00","affected":[{"ecosystem":"npm","name":"coral-wraith","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"}]}],"versions":["6.0.0","19.0.0","7.0.0","11.0.0","1.0.4","1.0.9","1.0.5","7.0.1","5.0.3","15.0.0","1.0.2","4.0.0","1.0.8","1.0.0","1.0.7","1.0.6","14.0.0","1.0.12","1.0.14","9.0.0","12.0.1","13.0.0","5.0.2","1.0.11","12.0.0","2.0.1","2.0.4","7.0.2","2.0.2","5.0.1","17.0.0","2.0.3","1.0.10","22.0.0","21.0.0","10.0.0","20.0.0","1.0.3","8.0.0","1.0.1","3.0.0","16.0.0","19.0.1","7.0.3","1.0.13","2.0.0","18.0.0"],"rawVersionEvidence":null}],"metrics":[],"references":["https://github.com/advisories/GHSA-f2r7-23p9-8jff","https://www.npmjs.com/package/coral-wraith/v/19.0.0","https://www.npmjs.com/package/coral-wraith/v/7.0.0","https://www.npmjs.com/package/coral-wraith/v/11.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.4","https://www.npmjs.com/package/coral-wraith/v/1.0.9","https://www.npmjs.com/package/coral-wraith/v/1.0.5","https://www.npmjs.com/package/coral-wraith/v/7.0.1","https://www.npmjs.com/package/coral-wraith/v/5.0.3","https://www.npmjs.com/package/coral-wraith/v/15.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.2","https://www.npmjs.com/package/coral-wraith/v/4.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.8","https://www.npmjs.com/package/coral-wraith/v/1.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.7","https://www.npmjs.com/package/coral-wraith/v/1.0.6","https://www.npmjs.com/package/coral-wraith/v/14.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.12","https://www.npmjs.com/package/coral-wraith/v/1.0.14","https://www.npmjs.com/package/coral-wraith/v/9.0.0","https://www.npmjs.com/package/coral-wraith/v/12.0.1","https://www.npmjs.com/package/coral-wraith/v/13.0.0","https://www.npmjs.com/package/coral-wraith/v/5.0.2","https://www.npmjs.com/package/coral-wraith/v/1.0.11","https://www.npmjs.com/package/coral-wraith/v/12.0.0","https://www.npmjs.com/package/coral-wraith/v/2.0.1","https://www.npmjs.com/package/coral-wraith/v/2.0.4","https://www.npmjs.com/package/coral-wraith/v/7.0.2","https://www.npmjs.com/package/coral-wraith/v/2.0.2","https://www.npmjs.com/package/coral-wraith/v/5.0.1","https://www.npmjs.com/package/coral-wraith/v/17.0.0","https://www.npmjs.com/package/coral-wraith/v/2.0.3","https://www.npmjs.com/package/coral-wraith/v/1.0.10","https://www.npmjs.com/package/coral-wraith/v/22.0.0","https://www.npmjs.com/package/coral-wraith/v/21.0.0","https://www.npmjs.com/package/coral-wraith/v/10.0.0","https://www.npmjs.com/package/coral-wraith/v/20.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.3","https://www.npmjs.com/package/coral-wraith/v/8.0.0","https://www.npmjs.com/package/coral-wraith/v/1.0.1","https://www.npmjs.com/package/coral-wraith/v/3.0.0","https://www.npmjs.com/package/coral-wraith/v/6.0.0","https://www.npmjs.com/package/coral-wraith/v/16.0.0","https://www.npmjs.com/package/coral-wraith/v/19.0.1","https://www.npmjs.com/package/coral-wraith/v/7.0.3","https://www.npmjs.com/package/coral-wraith/v/1.0.13","https://www.npmjs.com/package/coral-wraith/v/2.0.0","https://www.npmjs.com/package/coral-wraith/v/18.0.0"],"sourceUrl":"https://osv.dev/vulnerability/MAL-2026-5682","license":"OSV · upstream source license applies","key":"osv:MAL-2026-5682","identifiers":["MAL-2026-5682","GHSA-f2r7-23p9-8jff"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-25T04:10:19.7866190+00:00","complete":true,"records":1795,"lastAttemptAt":"2026-11-25T04:10:19.786619+00:00","lastSuccessAt":"2026-11-25T04:10:19.9510943+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:10:19.9510973+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-8d356adab43082cb10bb7c033ed58312cf2ad2f0fb10e0afdf27fc89fa361f3b-7533f75ee7b91925a4dafeac0c4377de200cdf76ed1615058d6a57aa67590f9c","complete":true,"records":431865,"lastAttemptAt":"2026-11-25T04:08:08.7892162+00:00","lastSuccessAt":"2026-11-25T04:08:08.6882766+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:08:08.7892162+00:00","snapshotPublishedAt":"2026-11-25T03:23:57+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-575d87b23d00469fb64809a8b6702225","complete":false,"records":13938,"lastAttemptAt":"2026-11-25T04:15:48.7520496+00:00","lastSuccessAt":"2026-11-25T04:15:48.747+00:00","error":"65 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-25T04:15:48.747+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13910,"expectedIdentifiers":13986,"failedIdentifiers":65},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-25T04:10:19.7866190+00:00","complete":true,"records":1131,"lastAttemptAt":"2026-11-25T04:10:19.786619+00:00","lastSuccessAt":"2026-11-25T04:10:19.9522438+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:10:19.9522442+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-21d6521b6366413086544958d18691b3","complete":true,"records":13950,"lastAttemptAt":"2026-11-25T04:11:04.5423766+00:00","lastSuccessAt":"2026-11-25T04:11:04.533+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:11:04.533+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13986,"expectedIdentifiers":13986,"failedIdentifiers":0},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-e743412268199d418c20ac5ea5d5eefbef4a1c78fcbacada525fcf2201b41d4a","complete":true,"records":10077,"lastAttemptAt":"2026-11-25T04:10:19.3441259+00:00","lastSuccessAt":"2026-11-24T23:11:09.9983084+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:10:19.3441259+00:00","snapshotPublishedAt":"2026-11-24T22:48:13+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-6ba2352decd0c95d34a1b50f642582aa34659ce946f552488f0a5cea4e0cc09a","complete":true,"records":2020,"lastAttemptAt":"2026-11-25T04:08:08.9276371+00:00","lastSuccessAt":"2026-11-20T15:46:15.4249619+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:08:08.9276371+00:00","snapshotPublishedAt":"2026-11-20T14:48:20+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-40938cbac3e2265a24e0d129a60138a855ec8a44cbd619ad6c0de0b22c0e253f","complete":true,"records":3221,"lastAttemptAt":"2026-11-25T04:10:19.7302327+00:00","lastSuccessAt":"2026-11-24T22:27:06.1844325+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:10:19.7302327+00:00","snapshotPublishedAt":"2026-11-24T22:03:27+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-6508b5601cebde5636c02aaee9585235b1518b5bed3f57c018753e63ffb99786","complete":true,"records":233075,"lastAttemptAt":"2026-11-25T04:10:19.148089+00:00","lastSuccessAt":"2026-11-25T04:10:17.9306356+00:00","error":null,"lastVerifiedAt":"2026-11-25T04:10:19.148089+00:00","snapshotPublishedAt":"2026-11-25T04:03:45+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}