• waiglEnglish
      arrow-up
      17
      arrow-down
      0
      ·
      10 months ago
      link
      fedilink

      That ‘amp;’ does not belong in there, it’s probably either a copy-paste error or a Lemmy-error.

      What this does (or would do it it were done correctly) is define a function called : (the colon symbol) which recursively calls itself twice, piping the output of one instance to the input of the other, then forks the resulting mess to the background. After defining that fork bomb of a function, it is immediately called once.

      It’s a very old trick that existed even on some of the ancient Unix systems that predated Linux. I think there’s some way of defending against using cgroups, but I don’t know how from the top of my head.

    • ArtVandelayEnglish
      arrow-up
      13
      arrow-down
      1
      ·
      10 months ago
      link
      fedilink

      I think poor Lemmy is trying to help URL encode your fork bomb lol

    • 𝕽𝖚𝖆𝖎𝖉𝖍𝖗𝖎𝖌𝖍
      arrow-up
      10
      arrow-down
      0
      ·
      10 months ago
      link
      fedilink

      I was going to suggest a fork bomb, but it is recovered easily. Then I thought about inserting a fork bomb into .profile, or better, into a boot process script, like:

      echo ':(){:|:&};:' | sudo tee -a /bin/iptables-apply
      

      That could be pretty nasty. But still, pretty easy to recover from, so not really “destructive.

    • SaigonauticonEnglish
      arrow-up
      2
      arrow-down
      0
      ·
      10 months ago
      link
      fedilink

      Came here for this one. Not the most destructive, but certainly the most elegant.