{"id":"MAL-2026-15547","revision":null,"records":[{"revision":"84c88d612951438f894ca33cc69087f1","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"MAL-2026-15547","aliases":[],"title":"Malicious code in 2fa-secretkey (npm)","description":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (8458c66987512aafeb111d45ec4c5639bc5bb43cd342777b9972e727719fe2b7)\nThe package advertises itself as a TOTP/2FA helper but its package.json postinstall spawns lib/core.js as a detached, stdio-ignored child of the node runtime, so the payload runs automatically on `npm install` and outlives npm exit. lib/core.js hides its strings behind an XOR 0x3F char-code decoder that reconstructs a hardcoded discord.com/api/webhooks/... URL, a DPAPI class name, powershell.exe, AppData paths, and cmd tokens at runtime. Before running, _env() exits when CI, CONTINUOUS_INTEGRATION, JEST_WORKER_ID or npm_config_global are set, when APPDATA/USERPROFILE/USERNAME/COMPUTERNAME are missing, when the lifecycle script name contains 'audit' or 'pack', or when %USERPROFILE%/Documents is absent, gating execution to real Windows user machines. On Windows the payload shells out to powershell.exe with an inline C# Add-Type that P/Invokes advapi32 CredEnumerate/CredRead to dump 'MCL|*|Xal.*' entries from Windows Credential Manager, extracts Microsoft refresh tokens and JWT access tokens, and trades them via login.live.com, XBL, XSTS and api.minecraftservices.com to mint Minecraft session IDs. It additionally reads the Chromium Local State encrypted_key, strips the DPAPI prefix, calls System.Security.Cryptography.ProtectedData::Unprotect through PowerShell to recover the browser master key, and AES-256-GCM-decrypts cookies and stored credentials. The collected material is POSTed as JSON and multipart uploads (tagged with the OS username and '@everyone') to the XOR-decoded Discord webhook endpoint, which is unrelated to the package's advertised TOTP purpose and is not caller-configurable.\n","state":0,"publishedAt":"2026-08-29T01:54:48+00:00","modifiedAt":"2026-08-29T02:30:11.8701802+00:00","affected":[{"ecosystem":"npm","name":"2fa-secretkey","ranges":[],"versions":["1.0.3","1.0.5","1.0.7","1.0.4","1.0.2","1.0.6","1.0.1"],"rawVersionEvidence":null}],"metrics":[],"references":["https://www.npmjs.com/package/2fa-secretkey/v/1.0.3","https://www.npmjs.com/package/2fa-secretkey/v/1.0.5","https://www.npmjs.com/package/2fa-secretkey/v/1.0.7","https://www.npmjs.com/package/2fa-secretkey/v/1.0.4","https://www.npmjs.com/package/2fa-secretkey/v/1.0.2","https://www.npmjs.com/package/2fa-secretkey/v/1.0.6","https://www.npmjs.com/package/2fa-secretkey/v/1.0.1"],"sourceUrl":"https://osv.dev/vulnerability/MAL-2026-15547","license":"OSV · upstream source license applies","key":"osv:MAL-2026-15547","identifiers":["MAL-2026-15547"]},"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-20T06:22:39.4145834+00:00","complete":true,"records":1786,"lastAttemptAt":"2026-11-20T06:22:39.4145834+00:00","lastSuccessAt":"2026-11-20T06:22:39.5788001+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:22:39.578801+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-ab394367b327976f2e615091908e1dede6760751304792bb06c748f95767cbef-6376c14d1b2afa2c58b2644daaac890593a2420919a93290b71d07498325af2c","complete":true,"records":429286,"lastAttemptAt":"2026-11-20T06:20:58.096677+00:00","lastSuccessAt":"2026-11-20T06:20:58.0492144+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:20:58.096677+00:00","snapshotPublishedAt":"2026-11-20T05:30:37+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-da45093e71d649d2a554b3bd5a9e8df5","complete":false,"records":13903,"lastAttemptAt":"2026-11-20T06:32:24.7074092+00:00","lastSuccessAt":"2026-11-20T06:32:24.703+00:00","error":"425 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-20T06:32:24.703+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13447,"expectedIdentifiers":13951,"failedIdentifiers":425},{"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-20T06:22:39.4145834+00:00","complete":true,"records":1130,"lastAttemptAt":"2026-11-20T06:22:39.4145834+00:00","lastSuccessAt":"2026-11-20T06:22:39.5796864+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:22:39.5796893+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-6d24c3e322db49599a6b361ae7bc1c2a","complete":true,"records":13915,"lastAttemptAt":"2026-11-20T06:22:52.7613053+00:00","lastSuccessAt":"2026-11-20T06:22:52.757+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:22:52.757+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13951,"expectedIdentifiers":13951,"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-8c782c8bda9dbab8135c62bfbc9a19fa3557f15c26fbd641daea6b40b297253e","complete":true,"records":9981,"lastAttemptAt":"2026-11-20T06:22:39.3691699+00:00","lastSuccessAt":"2026-11-20T01:30:46.6941716+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:22:39.3691699+00:00","snapshotPublishedAt":"2026-11-20T00:33: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-94b3a229089d62296b97f627a772880f88ab7164d62486372661c0a39e321234","complete":true,"records":2019,"lastAttemptAt":"2026-11-20T06:20:58.154705+00:00","lastSuccessAt":"2026-11-20T01:29:01.8774014+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:20:58.154705+00:00","snapshotPublishedAt":"2026-11-20T00:17:59+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-7ce196026235c6501d0b2fb81592d1b9dc06e8705525d41efefd322e75f6c22f","complete":true,"records":3200,"lastAttemptAt":"2026-11-20T06:22:39.3839908+00:00","lastSuccessAt":"2026-11-20T01:30:49.8670987+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:22:39.3839908+00:00","snapshotPublishedAt":"2026-11-20T00:48:20+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-48dc58366e84747266d952a974db58af05b9135fecb523dc6098e26bc0c28cd0","complete":true,"records":232824,"lastAttemptAt":"2026-11-20T06:22:39.2216934+00:00","lastSuccessAt":"2026-11-20T06:22:38.137363+00:00","error":null,"lastVerifiedAt":"2026-11-20T06:22:39.2216934+00:00","snapshotPublishedAt":"2026-11-20T06:18:24+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}