Malicious code in @mastra/agent-browser (npm)
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (49ba6a41e7e43733a8334968ce740af8771208c66c7529d9f4319bd62e39601d) @mastra/[email protected] declares a dependency on 'easy-day-js@^1.11.21' in package.json, but the package's own compiled code in dist/index.js never imports or references easy-day-js (only @mastra/core, agent-browser, and zod are used). The dependency name resembles the popular 'dayjs' library and pulling it in at install time means every installer of @mastra/agent-browser also fetches and executes whatever easy-day-js contains. The wrapper package's own code shows no install hooks, no obfuscation, and no exfiltration behavior, so the installer-side risk depends entirely on the contents of easy-day-js. Routing to human review so the transitive can be evaluated and, if malicious, both packages handled together. ## Source: ghsa-malware (f47e1be40751417e2e8e62b23068d7f74df247fc0c2b47cdf0b7ddb9733ca2f4) 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.
AI Analysis
Technical Summary
@mastra/[email protected] declares a dependency on 'easy-day-js@^1.11.21' which is not referenced in its own compiled code, suggesting the dependency is included solely to execute its contents. The 'easy-day-js' package name resembles the legitimate 'dayjs' library, potentially tricking users into installing malicious code. The wrapper package shows no install hooks or obfuscation, so the risk depends entirely on the transitive dependency's contents. Security advisories indicate that installation of this package compromises the host system, necessitating secret/key rotation and removal of the package, though full remediation cannot be guaranteed due to possible persistent compromise.
Potential Impact
Systems with @mastra/[email protected] installed may be fully compromised by the malicious code in the transitive dependency 'easy-day-js'. Attackers may gain full control over the affected computer, risking exposure of all stored secrets and keys. Removal of the package alone may not eliminate all malicious artifacts, implying potential persistent compromise.
Mitigation Recommendations
No official patch or fix is currently available. Immediate removal of @mastra/[email protected] and its dependencies is recommended. All secrets and keys stored on the affected system should be rotated from a separate, trusted device. Due to the risk of persistent compromise, consider rebuilding or thoroughly cleaning the affected system. Monitor vendor advisories for updates or fixes.
Malicious code in @mastra/agent-browser (npm)
Description
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (49ba6a41e7e43733a8334968ce740af8771208c66c7529d9f4319bd62e39601d) @mastra/[email protected] declares a dependency on 'easy-day-js@^1.11.21' in package.json, but the package's own compiled code in dist/index.js never imports or references easy-day-js (only @mastra/core, agent-browser, and zod are used). The dependency name resembles the popular 'dayjs' library and pulling it in at install time means every installer of @mastra/agent-browser also fetches and executes whatever easy-day-js contains. The wrapper package's own code shows no install hooks, no obfuscation, and no exfiltration behavior, so the installer-side risk depends entirely on the contents of easy-day-js. Routing to human review so the transitive can be evaluated and, if malicious, both packages handled together. ## Source: ghsa-malware (f47e1be40751417e2e8e62b23068d7f74df247fc0c2b47cdf0b7ddb9733ca2f4) 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.
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
@mastra/[email protected] declares a dependency on 'easy-day-js@^1.11.21' which is not referenced in its own compiled code, suggesting the dependency is included solely to execute its contents. The 'easy-day-js' package name resembles the legitimate 'dayjs' library, potentially tricking users into installing malicious code. The wrapper package shows no install hooks or obfuscation, so the risk depends entirely on the transitive dependency's contents. Security advisories indicate that installation of this package compromises the host system, necessitating secret/key rotation and removal of the package, though full remediation cannot be guaranteed due to possible persistent compromise.
Potential Impact
Systems with @mastra/[email protected] installed may be fully compromised by the malicious code in the transitive dependency 'easy-day-js'. Attackers may gain full control over the affected computer, risking exposure of all stored secrets and keys. Removal of the package alone may not eliminate all malicious artifacts, implying potential persistent compromise.
Mitigation Recommendations
No official patch or fix is currently available. Immediate removal of @mastra/[email protected] and its dependencies is recommended. All secrets and keys stored on the affected system should be rotated from a separate, trusted device. Due to the risk of persistent compromise, consider rebuilding or thoroughly cleaning the affected system. Monitor vendor advisories for updates or fixes.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-5996
- Osv Schema Version
- 1.7.4
- Aliases
- ["GHSA-ph9v-3f5h-hg6p"]
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a50ba6168715ace4357f0f9
Added to database: 07/10/2026, 09:24:49 UTC
Last enriched: 07/10/2026, 09:46:14 UTC
Last updated: 07/29/2026, 17:56:26 UTC
Views: 27
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.