Anyone Can Hack MacOS High Sierra Just by Typing "Root"

A Turkish company found a glaring flaw in Apple's desktop operating system that gives anyone deep access, no password required.
Image may contain Human Person Lamp Table Lamp and Lampshade
Christoph Dernbach/AP

There are hackable security flaws in software. And then there are those that don't even require hacking at all—just a knock on the door, and asking to be let in. Apple's macOS High Sierra has the second kind.

On Tuesday, security researchers disclosed a bug that allows anyone a blindingly easy method of breaking that operating system's security protections. When anyone hits a prompt in High Sierra asking for a username and password before logging into a machine with multiple users, installing an application or changing settings, they can simply type "root" as a username, leave the password field blank, click "unlock" twice, and immediately gain full access.

In other words, the bug allows any rogue user that gets the slightest foothold on a target computer to gain the deepest level of access to a computer, known as "root" privileges. Malware designed to exploit the trick could also fully install itself deep within the computer, no password required.

"We always see malware trying to escalate privileges and get root access," says Patrick Wardle, a security researcher with Synack. "This is best, easiest way ever to get root, and Apple has handed it to them on a silver platter."

As word of the security vulnerability rippled across Twitter and other social media, a few security researchers found they couldn't replicate the issue, but others captured and posted video demonstrations of the attack, like Wardle's GIF below, and another that shows security researcher Amit Serper logging into logged-out account. WIRED also independently confirmed the bug.

X content

This content can also be viewed on the site it originates from.

X content

This content can also be viewed on the site it originates from.

The fact that the attack could be used on a logged-out account raises the possibility that someone with physical access could exploit it just as easily as malware, points out Thomas Reed, an Apple-focused security researcher with MalwareBytes. They could, for instance, use the attack to gain root access to a logged-out machine, set a root password, and then regain access to a machine at any time. "Oooh, boy, this is a doozy," says Reed. "So, if someone did this to a Mac sitting on a desk in an office, they could come back later and do whatever they wanted."

On Wednesday, about 18 hours after the bug was widely publicized, Apple announced a security update to High Sierra designed to fix the "root" flaw. "A logic error existed in the validation of credentials," Apple's update reads. "This was addressed with improved credential validation."

"Security is a top priority for every Apple product, and regrettably we stumbled with this release of macOS," the company said in a statement. "We greatly regret this error and we apologize to all Mac users, both for releasing with this vulnerability and for the concern it has caused. Our customers deserve better. We are auditing our development processes to help prevent this from happening again."

Before Apple made that patch available, MalwareBytes' Reed also noted—and other researchers confirm—that it's possible to block the attack simply by setting a password for the root user. But the safest fix is to install Apple's update. If you've installed High Sierra and haven't yet updated, you should do it now.2

High Sierra's "root" bug was first revealed by Turkish software developer Lemi Orhan Ergin‏, who says security staff at his company stumbled on the issue while trying to help a user get back into their account. "They informed me and tried on my machine too. And I saw the security issue with my eyes. That was scary," Ergin says.

The face-palm worthy bug is only the latest in a disturbing series that have plagued High Sierra. On the day the operating system launched, Wardle found that malicious code running on the operating system could steal the contents of its keychain without a password. And another shocking bug showed the user's password as a password hint when they try to unlock an encrypted partition on their machine known as an APFS container.

Wardle argues that those flaws might have been caught earlier if Apple offered a "bug bounty" for information about security vulnerabilities in its desktop software, just as most other companies do. Apple does have a bug bounty, but only for iOS, not MacOS. "A bug bounty program is a no-brainer. Maybe this is something that will encourage them to go down that path," Wardle says. "It's crazy these kinds of bugs keep blowing up. I don't know if I should laugh or cry."

1Corrected 11/28/2017 11:30pm EST to note that the short term fix for High Sierra's security flaw is to set a root password, not to either set that password or disable root access, as this article had originally stated.2Updated 11/29/2017 11:30am EST to include Apple's software update to fix the problem.