• Railcar8095@lemmy.world
    link
    fedilink
    arrow-up
    11
    arrow-down
    2
    ·
    edit-2
    1 day ago

    Linux users tend not to download random software off of sketchy websites;

    Search for “sudo curl … | sh” and let me know how many hits you get.

    • Possibly linux@lemmy.zip
      link
      fedilink
      English
      arrow-up
      2
      ·
      7 hours ago

      Every time I see this a part of be dies inside. It is always a cursed install script that makes problematic changes to the system.

      • Flipper@feddit.org
        link
        fedilink
        arrow-up
        1
        ·
        7 hours ago

        It’s even worse. The server can detect if you are piping it straight into a shell or just downloading the file. It can then send different scripts based on that.

        • Railcar8095@lemmy.world
          link
          fedilink
          arrow-up
          1
          ·
          6 hours ago

          How can it see that? If possible, isn’t that a flaw of curl? I don’t see a good reason for the sever to know what you’re doing with the file

          • Flipper@feddit.org
            link
            fedilink
            arrow-up
            2
            ·
            4 hours ago

            Curl has a limited buffer and bash reads a line and then executes it, before reading the next line.

            So first you need a command that takes time if executed. So a delay, downloading a big file, user input work. Next you fill up the buffer. Just your normal script. Maybe some comments etc.

            Now the server can detect if after the first kB the stream stops.

    • 1984@lemmy.today
      link
      fedilink
      arrow-up
      7
      arrow-down
      2
      ·
      edit-2
      1 day ago

      Thats not random sketchy websites though.

      I would say Linux users who install software from the web knows what sites to trust. The beginners use the app store.