• Troy
    link
    fedilink
    301 year ago

    That reminds me…

    In circa 1995 I was running a dial upBBS service – as a teenager. So if course, it was full of bootlegged video games and such, and people would dial in, download a game, log off.

    Someone uploaded Descent or something like that. But they had put "deltree /y C:" or similar into a batch file, used a BAT2COM converter program, then a COM2EXE program, then padded the file size to approximately the right size with random crap (probably just using APPEND)… And uploaded it. Well, fortunately for the rest of my users, I say the game and said: oh, that’s neat, I should try it and copied it to another computer over my internal network and launched it. It started deleting files right away and I hit CTRL-C to abort. I lost only a few dozen files.

    Banned the user, deleted the package. Got lucky.

  • @BCsven@lemmy.ca
    link
    fedilink
    231 year ago

    The theme contained rm -rf, but claims it wasn’t malicious intent…I assume rm -rf for cleanup, but seems like it should have a apecific path other than /

    • @carzian@lemmy.ml
      link
      fedilink
      29
      edit-2
      1 year ago

      The command was rm -rf $pathvariable

      Bug in the code caused the path to be root. Wasn’t explicitly malicious

      • Dandroid
        link
        fedilink
        121 year ago

        Don’t most distros have safeguards against this? I tried sudo rm -rf / in an Ubuntu VM that I was about to delete just to see what happened, and it gave me a warning. I had to add some other option to bypass the warning.

    • @GlitterInfection@lemmy.world
      link
      fedilink
      English
      161 year ago

      When I worked at Pixar long ago an intern had a cron job that was intended to clean up his nightly build and ended up deleting everything on the network share for everyone!

      Fortunately there were back-ups and it was fine, but that day was really hilariously annoying while they tracked down things disappearing.

  • @MyNameIsRichard@lemmy.ml
    link
    fedilink
    101 year ago

    A theme is software and software has bugs. While this one had a pretty dramatic effect, you take basically the same risk with every program you run. This, along with hardware and user errors are why backups are so important; they change a disaster to an inconvenience.

    / Preach mode off

    • @ShortN0te@lemmy.ml
      link
      fedilink
      41 year ago

      A windows device just wiped the hardware settings of a periphery device, because it got an update and the new lighting settings wanted to control the LEDs in that device. All gone

  • @fl42v@lemmy.ml
    link
    fedilink
    71 year ago

    The Gray Layout installation script ran the rm -rf command, which normally removes all files from the device

    Translation difficulties, or does the author really think that’s what it’s normally used for?

    • sacredbirdman
      link
      fedilink
      71 year ago

      It’s an accurate translation. Mikrobitti is a generic computer magazine (with a long history) so it could either be that the author is not very familiar with Linux cli or it might also be that they were trying to put it in layman’s terms.

  • @db2@lemmy.world
    link
    fedilink
    31 year ago

    Trust but verify. It was a text file, it doesn’t get much easier to do the second step of that.

    • @aksdb@lemmy.world
      link
      fedilink
      91 year ago

      … in which case you would have seen that they delete a path referenced by an env var being set earlier.

      How likely do you think it would have been to notice, that this env var will turn up empty in your specific case?

      • @zingo@lemmy.ca
        link
        fedilink
        11 year ago

        That’s all you really need to do to break windows. /s

        Edge/Internet Explorer is/were a cornerstone of any Windows install. Uninstall that and you can get all kinds of weird issues on your system.

        • Spectranox
          link
          fedilink
          English
          2
          edit-2
          1 year ago

          Like my auto-installed Copilot doesn’t launch?

          Oh no!

          For some context, I’ve got a Windows install that I primarily keep around for VR gaming which I remove Edge from. That Copilot thing is the only “issue” I’ve noticed.

    • @elvith@feddit.de
      link
      fedilink
      61 year ago

      Windows doesn’t have sudo (not yet, at least) and privileges work a bit different as even as an administrator, you may not have full rights.

      To overcome that obstacle, you’d need to run a shell as an administrator (hold CTRL+Shift, then use the start menu entry or right-click it and select run as administrator).

      Next obstacle: We have a separate drive for each partition, but no root folder.

      If we assume we’re running on a laptop or PC with a single drive and a single partition*, then it’s just

      In cmd.exe:

      del /F /S C:\
      

      In Powershell:

      Remove-Item -Recurse -Force -Path C:\
      

      When you want to delete all (mounted) partitions/drives, you need to iterate over them. (Note that’s from the top of my head, didn’t check the script if it works).

      In cmd.exe:

      REM Not gonna do that, I'm no masochist
      

      In Powershell:

      Get-PSDrive -PSProvider FileSystem | Foreach-Object {
          Remove-Item -Recurse -Force -Path "$($_.Name):\"
      }
      

      Done. Mounting additional partitions before that is left as an exercise for the reader.

      *note that even a standard installation of windows creates 3 partitions. One for the bootloader, one for the recovery system and then the system drive. Only the latter is mounted and will be deleted by this. The other two will still be intact.

  • @HarriPotero@lemmy.world
    link
    fedilink
    21 year ago

    SIDPlay did something similar on the Mac.

    It has the neat built-in feature of rsyncing the high voltage SID collection to your computer.

    However, if you deleted your local copy of it and tried to re-sync it’d update (with deletes) against / instead. Bye bye files.

  • @Certainity45@lemmy.ml
    link
    fedilink
    11 year ago

    Hetken jo ajattelin, että mitä hiivatin noituutta nämä Suomeksi olevat konekääntäjän tekstit ovat olevinaan.

  • ffhein
    link
    fedilink
    11 year ago

    I wonder how much would break, and how much time it would take to update everything, if all shells decided to implement a breaking change to prevent these kind of scenarios. E.g. make “set -u” default or some other solution