oauth-connect (npm) · Malicious Code
Affects oauth-connectSource GCVE Database
Malicious package : remove oauth-connect and rotate any secrets on hosts that installed it.
Data as of 8 Sep 2026, 11:37 UTC
Malicious package
Published to npm · OSV MAL-2024-2779
What to do
Remove oauth-connect from every project, lockfile and image that pulls it in. Treat any host that installed it as compromised: rotate the credentials, tokens and keys it could read, from a clean machine.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
npmoauth-connectpkg:npm/oauth-connectOther threats | Affected
| Fixed in– |
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
Description
The npm package 'oauth-connect' versions 0.1.1 and 2.0.1 contain malicious code that executes automatically during installation. This code collects sensitive system information including hostname, user info, home directory, DNS configuration, and contents of /etc/passwd and /etc/hosts, as well as the consumer's package.json. The collected data is exfiltrated via HTTPS POST to an attacker-controlled domain. The package's stated function as an OAuth helper is unrelated to this behavior, indicating a dependency confusion or supply chain attack vector.