Skip to content
HomeVideosBooksBlogs
AllTop postsTopics
Podcasts
HistoryListsWatch laterLiked videosFollowing

The videos, books, blogs and podcasts Hacker News keeps recommending, all in one place.

VideosBooksBlogsPodcastsAboutPrivacySettings

Data from Hacker News, HackerTube, HackerBooks, HackerBlogs and Open Library. Credits · Not affiliated with Y Combinator.

HomeVideosBooksBlogsPodcasts
Ctrl K
    I

    I Don't Play Darts

    idontplaydarts.com · Personal blog · on HN since 2011

    An anonymous security researcher writes about web exploits, CSRF, web shells, and data exfiltration techniques.

    Visit blogHN submissions
    Security
    What HN says

    Commenters repeatedly cite its post showing a server can detect when curl output is piped to bash, in debates about curl-to-bash installers.

    Stats for nerds
    81HN people shared it
    13linked in comments
    1.2Kstory points
    Feb 2024last shared
    2020people per year2024

    Top posts on HN

    1. 1
      Detecting the use of "curl | bash" server-side
      70 people · 1.1K points · first shared 2016 · 145 comments on HN
    2. 2
      Exploiting CSRF against search with Lucene
      2 people · 23 points · first shared 2015 · 10 comments on HN
    3. 3
      Popular CAPTCHA broken
      1 person · 10 points · first shared 2011 · 1 comments on HN
    4. 4
      Encoding Web Shells in PNG IDAT chunks
      5 people · 5 points · first shared 2012 · Discussion on HN
    5. 5
      Data exfiltration through the VMware hypervisor
      2 people · 4 points · first shared 2012 · Discussion on HN
    6. 6
      Mongodb is vulnerable to sql injection in php at least
      2 people · first shared 2011
    7. 7
      Scanning the internal network using simplexml
      1 person · first shared 2014
    8. 8
      Google totp two factor authentication for php
      1 person · first shared 2019

    What HN people wrote when they linked it

    • scubboApr 2022

      No, I'm sorry, I seriously don't understand how that applies in this case. How is "trusting the content you get from `apt-get`/`dpkg`/`pacman`" safer than curling-to-bash? In both cases, you are downloading and installing content from a trusted source (assuming you are curling via https to avoid MITMs). In the curl-to-bash case, you have the _ability_ to at least inspect the code first before you install it (though, realistically, how many folks would really have the dedication and the ability to do so?), whereas with package managers you're installing "blind". Doesn't that make curling-to-bash the _safer_ option?

      I clearly must be missing something, here, because everyone decries "curling-to-bash" as a bad security practice, but I haven't seen an explanation of _why_. I tried doing some research for myself - this page[1] suggests that package managers have built-in checksumming and signature verification, but then goes on to propose an attack vector where the load balancer is compromised, so (presumably?) those same checksums/signatures could also be intercepted and faked. This gist[2] has a lot of people speaking against it, but from following those links, the only downside I could see was here[3], pointing out that the shell will keep executing if a connection closes mid-stream - which, yes, is certainly a bad thing and a good argument to use package managers, but not what I would call a security concern (unless you don't trust the entity on the other end of the stream -…

    • jmb99Feb 2024

      There definitely is a difference. See [1] (or [2] since the original site has misconfigured TLS). Long story short, using some fairly trivial heuristics, a malicious server could change its response when it detects its output being piped to a shell rather than saved to a file. Thus, a security-minded person downloading the file (who could inspect it) would be given a clean copy, but someone less security-minded piping it straight to bash would be given the malicious copy. The security-minded person wouldn't be able to warn people not to pipe the script to a shell, since it appears safe.

      [1] https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/

      [2] https://web.archive.org/web/20240228190305/https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/

    • bravetravelerNov 2023

      It's been demonstrated that the server can tell if the client is piping or not

      https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/

      I'm on mobile and this refuses to load due to SSL/HSTS problems. It's an interesting approach if you can get it to load.

      Point being... someone clever could make a bad day for the minority of users who do check first (but don't save/run what they explicitly checked)

      Running curl, saying "yup that looks good", then adding a pipe achieves little with actual malice. The payload can be completely hidden until it's too late

      The phrasing you use is important for any hope at safety - review/run the same downloaded thing.

    • bostikSep 2021

      If you are slightly more paranoid, keep in mind that the file you downloaded for manual inspection may not be the file you download automatically for bash-piping. This article from 2016 was making the rounds on HN about three years ago: https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/

      Of course for a properly, professionally paranoid person, you would download every component manually and store the received artifacts locally (for caching, reproducibility, TOFU principle and general BCP needs). Then build from those only. In fact, in high-trust environments it's common for CI systems to not be able to hit internet at all.

    • anotherhueSep 2021

      binary packages, maybe through github releases. debian packages, potentially upstreamed into the package repos (though that's some effort).

      It's quite presumptive to presume to know how a target system is to be configured.

      no matter which alternative, curl|bash is security risk enough to never use: https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/

      gpg can help (below from zerotier):
      curl -s 'https://raw.githubusercontent.com/zerotier/ZeroTierOne/master/doc/contact%40zerotier.com.gpg' | gpg --import && \
      if z=$(curl -s 'https://install.zerotier.com/' | gpg); then echo "$z" | sudo bash; fi

    • rmetzlerSep 2021

      You didn't even take a look at https://get.docker.io

      It's still downloading and executing a script, just two steps instead of piping the output straight into bash.

      You can't even inspect the code you run when you do curl|bash and the server is able to detect this distinction and hide code when you do a curl and then run bash.

      https://www.idontplaydarts.com/2016/04/detecting-curl-pipe-bash-server-side/

      Your argument is: "we do it and we use GitHub, you can trust us and can trust GitHub, you don't need to verify the code you run."

      And devs learn: "Trust me, you don't need to verify the code you run."

    Related

    Datadog Security Labssecuritylabs.datadoghq.com29 people

    Investigating a backdoored PyPI package targeting FastAPI applications

    Datadog Security Labs
    Company · last shared 2026
    Naked Securitynakedsecurity.sophos.com740 people

    Serious Chrome zero-day

    Naked Security
    Company · last shared 2023
    Neal Poolenealpoole.com20 people

    HTTP Response Splitting Vulnerability on reddit.com

    Neal Poole
    Personal · last shared 2018
    Aqua Security Blogblog.aquasec.com51 people

    Perfctl: Stealthy malware targeting Linux servers

    Aqua Security Blog
    Company · last shared 2026
    Project Zerogoogleprojectzero.blogspot.com550 people

    Reading privileged memory with a side-channel

    Project Zero
    Company · last shared 2025
    Scott Helmescotthelme.co.uk160 people

    Another free CA as an alternative to Let's Encrypt

    Scott Helme
    Personal · last shared 2026
    Daniel Miesslerdanielmiessler.com241 people

    It’s Time to Get Back to RSS

    Daniel Miessler
    Personal · last shared 2026
    Ctrl blogctrl.blog174 people

    TeamViewer installs suspicious font only useful for web fingerprinting

    Ctrl blog
    Personal · last shared 2026