Usb2shell: Root on Linux from a USB Plug-In

(usb2shell.com)

63 points | by matanyall 1 hour ago

9 comments

  • jcul 0 minutes ago
    Hmm... people seem to be dismissing this in the comments.

    It's more than a normal rubber duck attack, like pretending to be a mouse and keyboard, it is a proper exploit of the SCSI driver IIUC.

    Someone with access to a physical device for one or two minutes can get root pretty much undetected.

    It works even if locked or if the device is booted with no one logged in. That's pretty cool IMO.

    Not as worrying as a remote exploit of course.

  • rpdillon 25 minutes ago
    Was fixed in 7.2.8, my machines are updated on occasion by me, and are running 7.2.15, which came out on 01 Nov.

    Looks like 7.2.8 was cut on 25 Sep: https://lwn.net/Articles/1096820/

    So if you're on a maintained distro and update more often than every couple of months, you probably already have the fix for this.

  • gadtfly 34 minutes ago
    I just always assumed this was the case
    • mrob 26 minutes ago
      Unless you changed the USB authorization policy to default deny [0] with some userspace filter for whitelisting specific devices, e.g. USBGuard [1], any USB device can pretend to be any other USB device.

      There's no need to exploit the mass storage device driver when you can just pretend to be a keyboard and open a terminal. It's likely also possible to detect when the system is idle and do this when nobody is watching.

      [0] https://www.kernel.org/doc/Documentation/usb/authorization.t...

      [1] https://usbguard.github.io/

      • turbert 10 minutes ago
        i believe this works on a locked machine, a keyboard shouldn't be able to get you past the lock screen.
        • mnahkies 0 minutes ago
          Odd I never get past my lock screen without a keyboard.
  • mort96 36 minutes ago
    AFAIU, Linux considers physically connected devices to be "trusted", and doesn't place a ton of importance on securing drivers against hardware acting maliciously. I myself think that this policy is pretty bad, but I see how it could be the only reasonable policy for a monolithic kernel written in C where all drivers run in ring 0..

    ..I'm surprised though that there's an ACE which can be triggered from the generic USB Mass Storage Device driver without even mounting the filesystem I guess. This is gonna affect even many systems which disable all USB drivers they don't need for security reasons. I expected it to be from a driver for some ancient piece of hardware nobody has maintained for 15 years.

  • kortzeus 50 minutes ago
    Finally something my server can't be reached by!
  • dvh 1 hour ago
    >curl -fsSLO https://usb2shell.com/tools/usb2shell-check.sh

    >less usb2shell-check.sh

    >sh usb2shell-check.sh

    I LOLed. Use "less -nU" to prevent black text on black background attack vector. Maybe.

  • cyberax 15 minutes ago
    Hm, it looks like it can be used to jailbreak the Tesla Model 3. I wonder if I can use it to add AndroidAuto.
  • kamk3 34 minutes ago
    Clickbait2shell, a new exploit where you blindly add "2shell" at the end of a random word. Sequel to Clickbleed.
    • ByteOfWood 29 minutes ago
      At least the "2shell" names make sense. It clearly states the weak point (usb, php...) and what the result is (full on shell, rather than just reading from RAM or an out of bounds write)
      • malfist 17 minutes ago
        I can open the terminal with my mouse. Should I call it cursor2shell?
        • ssl-3 13 minutes ago
          2shell1mouse
    • temp0826 12 minutes ago
      baitgate imo
      • mahboi 8 minutes ago
        It's never going to stop being funny how scandals are still called "gate" just because of that one hotel's name
  • ALSOPSS 14 minutes ago
    [dead]