News for hackers. Stuff that matters.
Re:Curl to shell isn't so bad by tastroder on Saturday November 09, 2019 @05:02AM (#21490628)
An unmodified curl invocation does not require weird timing based attacks, it sends an appropriate user-agent header the server can use (and which the article already adresses).
Re:Curl to shell isn't so bad by y4mi on Saturday November 09, 2019 @05:05AM (#21490634)
different attack vector.

by detecting the usage of `curl | bash` you can serve a different script only when someone does it, so someone doing `curl -O /tmp/some_script.sh` to audit the script wont see the harmful code.

It opens you up to a literally undetectable attack.

nonetheless, the point of the article author does have some truth. there is always a degree of trust involved when you're installing binaries from a third party. by using curl|bash you're just increasing the required trust a bit.

Re:Curl to shell isn't so bad by zshev on Saturday November 09, 2019 @05:34AM (#21490716)
> It opens you up to a literally undetectable attack.

This is the crux of it for me. This is why it is dangerous. The author appears to have overlooked this attack vector entirely.

Re:Curl to shell isn't so bad by vbezhenar on Saturday November 09, 2019 @02:04PM (#21493538)
Is it undetectable? `curl | tee file | bash` should detect IMO.
Re:Curl to shell isn't so bad by tln on Saturday November 09, 2019 @03:42PM (#21494220)
True, you can detect it without a way to stop the damage! Or easier and more thorough,

    curl | bash -x
Re:Curl to shell isn't so bad by y4mi on Sunday November 10, 2019 @12:10PM (#21498885)
Piping through tee doesn't trigger the sever side detection (it doesn't stop to read every few ms) and using the x flag isn't inherited, so it's gone as soon as subshells are invoked, which is pretty normal for an installation script.

This has all been mentioned in the linked comment thread

Re:Curl to shell isn't so bad by tln on Sunday November 10, 2019 @04:08PM (#21500219)
Actually the server side detection in [0] isn't really affected by putting tee in the middle... and neither does -x, of course.

Good point about -x being fallible to an adversarial script, even a simple set +x would be enough!

Where's the link where this has been mentioned? I missed it.

0: https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-b...

Re:Curl to shell isn't so bad by tulunsutao on Saturday November 09, 2019 @04:23PM (#21494459)
Use disposable virtual machine to isolate the damage, while dumping the script, this way we can detect attack without compromising ourself.