Wednesday, January 16, 2008

Master boot record rootkits

Security mavens have uncovered a new class of attacks that attach malware to the bowels of a hard drive, making it extremely hard to detect and even harder to remove.

The rootkit modifies a PC's master boot record (MBR), which is the first sector of a storage device and is used to help a PC locate an operating system to boot after it is turned on. The result: the rootkit is running even before Windows loads. There have been more than 5,000 infections in less than a month, researchers say.

"Master boot record rootkits are able to subvert the Windows kernel before it loads, which gives it a distinct stealth advantage over rootkits that load while Windows is running," said Matthew Richard, director of the rapid response team for iDefense, a security provider owned by VeriSign. "It gives it a great stealth mechanism that allows it to persist even after removal." Such rootkits can even survive reinstallation of the operating system, he said.

Because the rootkit lurks deep within the hard drive, well below the operating system, most antivirus programs don't detect the malware. Symantec's antivirus program is an exception, however. It labels the pest Trojan.Mebroot, according to Javier Santoyo, a senior manager for emerging technologies at Symantec.

The new rootkit is part of the arms race between security vendors and malware writers, he said. "We're definitely making it harder and harder for the bad guys to do stuff to the operating system," he said. They respond by attacking new parts of a PC.

Every version of Windows, including Vista, is vulnerable to the rootkit.

About 30,000 websites, mostly located in Europe, are actively trying to install the rootkit by exploiting users who have failed to install Windows updates, Richard says. There were 5,000 infections from December 12 to January 7. The rootkit is being spread by the same group responsible for distributing the Torpig banking Trojans, which are used to steal online banking credentials.

While the number of infections is relatively low, the number could rise quickly if the group expanded the number of exploits it used.

MBR-based attacks date back to the days of MS-DOS, when viruses such as Brain, Stoned, Tequila caused mischief by hiding themselves in a hard drive's primary partition. In 2005, researchers from eEye Digital Security demonstrated a proof of concept that showed how the technique could be extended to the Windows NT domain.

The rootkit comes as a wake-up call, demonstrating that new measures are needed to protect PC security. Many motherboard makers still don't provide functionality that prevents the overwriting of an MBR. But even when such capabilities do exist, the average user has no idea how to enable them. And even when they're enabled, malware writers are likely to target even deeper recesses within a PC.

"We will never win the battle with malware, especially rootkits, without a help from hardware and changes in the *design* of the OSes," Joanna Rutkowska, a researcher specializing in rootkits, wrote in an email.

Source:
Dan Goodin
The Register

1 comment:

Rafa Minu said...

GMER, author of one of the most famous free antirootkit software, has published a fully detailed article of what looks like the new trend of infections: sadly, that proof of concept called BootRoot is now in the wild:

n 2005 Derek Soeder and Ryan Permeh, researchers from eEye Digital Security, presented eEye BootRoot. The technique used in their project wasn't new and had been popular in DOS times, but they first successfully used it in Windows NT Environment. The eEye Digital Security researchers skipped one part - BootRoot didn't hide the real content of affected sectors like old DOS Stealth MBR viruses, but it had only been created to show the possible way to compromise Windows NT OS.

Unfortunately, all the Windows NT family (including VISTA) still have the same security flaw - MBR can be modified from usermode. Nevertheless, MS blocked write-access to disk sectors from userland code on VISTA after the pagefile attack, however, the first sectors of disk are still unprotected !
Rootkit in the wild

At the end of 2007 stealth MBR rootkit was discovered by MR Team members (thanks to Tammy & MJ) and it looks like this way of affecting NT systems could be more common in near future if MBR stays unprotected.

"Good points" of being MBR rootkit:
# full control of machine boot process-code is executed before the OS starts
# rootkit does not need a file - code could exists in some sectors of the disk and it cannot be deleted as a usual file
# rootkit does not need any registry entry because it is loaded by MBR code
# to hide itself, rootkit needs to control only a few sectors of the disk

How MBR rootkit works :
# Installer
# MBR loader
# Kernel patcher
# Kernel driver loader
# Sectors hider/protector
# Kernel driver
# Detection
# Rootkit removal

Source:
http://www2.gmer.net/mbr/