{"id":"MAL-2026-6025","summary":"Malicious code in @mastra/koa (npm)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (c0e8ae2c317dbb57c6a85b0bea50cddd76d109cd8ec802bc646df6c514d91bcd)\nThe bundled output at dist/index.cjs:212 and dist/index.js:210 contains a Buffer.from(..., 'base64').toString('utf-8') pattern. Base64 decoding into a UTF-8 string is a routine primitive used by many libraries (decoding JWT segments, parsing data URIs, handling HTTP basic-auth headers, decoding SDK tokens, etc.) and on its own is not evidence of malicious behavior. No environmental scraping, attacker-controlled network destinations, lifecycle hooks, or eval/exec of decoded content was observed. Routing to human review so a reviewer can confirm the decoded value is used as data rather than passed to an interpreter.\n\n## Source: ghsa-malware (8dd39253d95966dbc6f4cdf9ad6f910e67502b6df405fa824848e6e95d2b4b7f)\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","aliases":["GHSA-w9wg-f3pj-cf4v"],"modified":"2026-07-09T22:17:05.373797587Z","published":"2026-06-17T04:56:21Z","database_specific":{"malicious-packages-origins":[{"sha256":"8dd39253d95966dbc6f4cdf9ad6f910e67502b6df405fa824848e6e95d2b4b7f","import_time":"2026-06-17T05:56:08.467800841Z","id":"GHSA-w9wg-f3pj-cf4v","modified_time":"2026-06-17T04:56:21Z","versions":["1.5.14"],"source":"ghsa-malware"},{"import_time":"2026-07-09T22:02:32.241346846Z","id":"IN-MAL-2026-009443","modified_time":"2026-07-09T21:56:35Z","versions":["1.5.14"],"source":"amazon-inspector","sha256":"c0e8ae2c317dbb57c6a85b0bea50cddd76d109cd8ec802bc646df6c514d91bcd"}]},"references":[{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-w9wg-f3pj-cf4v"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/@mastra/koa/v/1.5.14"}],"affected":[{"package":{"name":"@mastra/koa","ecosystem":"npm","purl":"pkg:npm/%40mastra/koa"},"versions":["1.5.14"],"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":{"evidence_files":[{"path":"dist/index.cjs","sha256":"72c9a264386332c90948a748d43875663e664e1043abef3d19ba999aac54f4c8","tlsh":"96d2405a0af71227497366bd8b0b54553336e0033069ed697f9cd2992fc947c89b2bcc"},{"sha256":"6162d8853eb3f14f029be7f93ec5863d60d334d0adfbbc4b39c56a051cc0597c","tlsh":"cdd24f5a0af71227496366bd8b0b54553336e0033059ed697f9cd2a52fc897cc9b2bcc","path":"dist/index.js"}]},"source":"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/@mastra/koa/MAL-2026-6025.json"}}],"schema_version":"1.7.5","credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"}]}