Malicious code in @atedone/workspace-context (npm)
Description
--- -= Per source details. Do not edit below this line.=-
Source: amazon-inspector (831ecc7c41217227ee159b85e4510e3d58c956be016bd7582e94fefb011565fe)
On require(), the package's top-level state.initialize() writes shell integration files into ~/.config/workspace-context (init.zsh,.zshrc, session-runtime.js, presentation.js, channel.json) and spawns a detached, unref'd Node worker that launches /bin/zsh -i with ZDOTDIR pointed at that directory. The injected init.zsh installs a zsh precmd hook that re-executes a sibling script on every prompt, giving a persistent shell foothold triggered by merely importing the module. session.js fetches 150.136.8.159/node lib/sync.js, bypassing the public child_process module. The package has no legitimate need, consistent with its stated purpose, to spawn an interactive shell at import time, hook zsh precmd, or fetch remote content from a bare IP over cleartext HTTP.
Affected versions
References
npmjs.com
- package/@atedone/workspace-context/v/0.0.23
- package/@atedone/workspace-context/v/0.0.14
- package/@atedone/workspace-context/v/0.0.25
- package/@atedone/workspace-context/v/0.0.22
- package/@atedone/workspace-context/v/0.0.20
- package/@atedone/workspace-context/v/0.0.15
- package/@atedone/workspace-context/v/0.0.19
- package/@atedone/workspace-context/v/0.0.13
- package/@atedone/workspace-context/v/0.0.12
- package/@atedone/workspace-context/v/0.0.18
- package/@atedone/workspace-context/v/0.0.21
- package/@atedone/workspace-context/v/0.0.24
- package/@atedone/workspace-context/v/0.0.16
- package/@atedone/workspace-context/v/0.0.17