3 ms·
Techniques like this could make curl|bash more prone to malicious activity: https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/ https:/
by dementiapatien 4y ago
Techniques like this could make curl|bash more prone to malicious activity: https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/ https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-b...
- vore 4y agoYou're running untrusted binaries anyway in the end, so I don't think this is anything more than a neat party trick.
- dementiapatien 4y agoBut this technique lets you serve malicious code to a small number of people using curl|bash, rather than hosting obviously-bad binaries that anyone can inspect and call you out on. It also lets you target the attack to specific users or IP blocks. The previous HN discussion said it better than I can: https://news.ycombinator.com/item?id=17636032 https://news.ycombinator.com/item?id=17636032
- efreak 4y agoMoreutils has two programs that would trivially defeat this: `sponge` reads the full input before passing it on `vipe` inserts your editor inline, so you can view/modify the input before passing it on to bash (change an install directory, etc)