Malicious code in analytics-widget (npm)
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (4b78f3ed716380da74c5d54de6e24b6b128536a7ce5772e8b05d03108a1d9b74) The package is published as 'analytics-widget' with an empty description, but its main module contains no analytics functionality. On load, index.js schedules a 2-second timer that reads the 'token' key from browser localStorage, falls back to a JSON serialization of the entire localStorage store if that key is missing, and POSTs the result to the relative endpoint '/addPost' via fetch. When bundled into a consumer's frontend, every end-user session that loads the page has their auth token (or the full localStorage contents) sent to whichever origin serves the bundle, enabling session hijacking of the consuming application's users. The package name and empty metadata serve as a cover story; no legitimate analytics code is present. ## Source: ghsa-malware (399579776689b5ab6b5fe78e2c79da4ddf4950f898e9017333bdadaf3603a7f3) 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.
Malicious code in analytics-widget (npm)
Description
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (4b78f3ed716380da74c5d54de6e24b6b128536a7ce5772e8b05d03108a1d9b74) The package is published as 'analytics-widget' with an empty description, but its main module contains no analytics functionality. On load, index.js schedules a 2-second timer that reads the 'token' key from browser localStorage, falls back to a JSON serialization of the entire localStorage store if that key is missing, and POSTs the result to the relative endpoint '/addPost' via fetch. When bundled into a consumer's frontend, every end-user session that loads the page has their auth token (or the full localStorage contents) sent to whichever origin serves the bundle, enabling session hijacking of the consuming application's users. The package name and empty metadata serve as a cover story; no legitimate analytics code is present. ## Source: ghsa-malware (399579776689b5ab6b5fe78e2c79da4ddf4950f898e9017333bdadaf3603a7f3) 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.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-17163
- Osv Schema Version
- 1.7.4
- Aliases
- ["GHSA-548g-r2c9-6chm"]
- Ecosystems
- ["npm"]
Threat ID: 6abcddd10df196e1a9da6e9f
Added to database: 09/30/2026, 10:00:49 UTC
Last updated: 09/30/2026, 15:47:58 UTC
Views: 3
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
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.