Event-stream npm hijacking (2018)
September-November 2018What Happened
A developer using the handle right9ctrl gained the trust of event-stream's original maintainer through legitimate code contributions, then took over the package and injected a dependency that targeted the Copay Bitcoin wallet. The backdoor harvested private keys from accounts holding more than 100 Bitcoin. It went undetected for two months until a university student flagged suspicious code on GitHub.
Outcome
npm removed the malicious code, but the incident exposed how easily maintainership of critical packages could be transferred through social engineering.
The attack became the defining example of open-source supply chain risk and directly motivated npm's later security reforms, including mandatory two-factor authentication for high-impact package maintainers.
Why It's Relevant Today
The Axios attack follows the same fundamental pattern — compromising a single maintainer account to poison a widely-used package — but at dramatically larger scale. Event-stream had 2 million weekly downloads; Axios has 100 million.
