Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
troygoode
· 10y ago · 0 comments
they'd notice as soon as they tried to run their program as "import * from 'lodash'" would fail (unless they were consistent with their typos...)
Comments
[–]
jtuchsen
10y ago
You can inject a version of whatever you want into the node_modules folder in the post install script though can't you? So you just copy your own malicious lodash into node_modules. I haven't tried it but I think it'd work.
[–]
goldbeck
10y ago
what if it ran "npm install -g lodash"?