New BIOS Exploiting Rootkit Discovered
First time accepted submitter mtemar writes with a Symantec analysis of an interesting new trojan/virus. From the article:"There are more and more known viruses that infect the MBR. Symantec Security Response has published a blog to demonstrate this trend last month. However, we seldom confront with one that infects the BIOS. One of them, the notorious CIH, appeared in 1999, which infected the computer BIOS and thus harmed a huge number of computers at that time. Recently, we met a new threat named Trojan.Mebromi that can add malicious components into Award BIOS which allows the threat to take control of the system even before MBR."
Is it really a total surprise that it was discovered initially by a Chinese security firm? Their reaction should have been, " look at this virus we just found that we just made!"
I got here through a series of tubes
Seems I need to drink my coffee a little faster as to write an anti-Trojan.Medromi fix to prevent it from getting in our systems. Lol
When flash BIOS first appeared you had to move a hardware jumper to enable writing it. Then we had systems where you could fix it so that once POST finished the possibility to write the BIOS was physically removed. But people wanted simple Windows based utilities to reflash the BIOS instead of booting from a special floppy or even using the flashers many BIOSes themselves offered, and nobody wanted end users to have to open the case and move a jumper. So the vital security functions were removed. Hilarity ensues.
Democrat delenda est
Name one reason why it is a good idea that application programs or the kernel or ANYTHING ELSE should even be ABLE to screw with the BIOS. There should be a big red PHYSICAL switch which makes the BIOS read-only, and it should only be temporarily turned off to allow updating with the manufacturer's files and NOTHING ELSE.
The only real reason a computer needs a BIOS is to run a bootloader, and if that functionality works, then it's probably going to continue to work. All other hardware drivers belong in the OS, where they can be updated without the risk of bricking your goddamn motherboard.
BIOS malware is not new. TFA even mentions malware from 2007 that did the same thing. Some motherboards have actually shipped with rootkits accidentally installed. Proprietary BIOSes can have rootkits in them, and can't be detected.
If you can compile the binary yourself, you can mitigate BIOS viruses. That's why we need Coreboot support on motherboards.
Not bios exploting rootkit, which implies the bios is doing the exploiting, sort of like that french guy and his chambermaid !!
It tried to overwrite it with garbage, thus corrupting it. Kind of like blowing up your car with dynamite isn't the same thing as stealing it.
Most of the time all CIH succeeded at was trashing the BIOS settings stored in CMOS. Clean the infector, reset the BIOS, save the changes and you were done.
It's amazing how low the understanding of what malware is and does has fallen. By the way, the antivirus industry has been aware that it would be possible to write a bios infector the moment software the update-able bios became available. Fortunately most writers of malware are pretty incompetent as far as programming goes, though this did take about 6 years longer than I expected.
I for one welcome our new Chinese metal oxide semiconductor (CMOS) overlord.
Motherboard vendors (think ASUS in particular) _always_ provide tools to update the BIOS firmware from Windows. I kind of understand this, because they want to be able to ship something dummy-proof so it's not a support nightmare. Of course, as long as this feature exists, it will be exploitable. The only solution is to have a more complex BIOS updating procedure, as several posters have mentioned. I suspect motherboard vendors would be rather resistant to this.
Well some points why the kernel may need to write area of the BIOS off the top of my head:
So if you use full disk encryption such as truecrypt do you just get a trashed drive?
The only real reason a computer needs a BIOS is to run a bootloader, and if that functionality works, then it's probably going to continue to work.
You're obviously nostalgic for the days when software was debugged as thoroughly as possible before shipping because it couldn't be upgraded later, rather than released with known major bugs because 'we can always fix it with a flash upgrade'.
> The only real reason a computer needs a BIOS is to run a bootloader...
Oh how I wish that were still true. Got one word for ya, ACPI.
Democrat delenda est
since many wlan and asdl routers are actually small linux boxes with http flashing and known default root passwords, i'd be surprised if there wasn't some worms infectim them as well..
Oh, this is ba-
>Windows PE
Ahahahahahahahahahahahahahahahahaha.
Ahahahahaha.
The real question is why are BIOSes not verified for a digital signature by a hardware component.
Yes, you want to be able to upgrade a BIOS by sending a file to a client. That's an important feature. I just don't get why the file should not, as a requirement, be digitally signed.
Shachar
posting anonymously to not revert moderation
Preface: I know a thing or two about BIOS hacking.
Given the very limited space available in the average PC Flash BIOS chip, how fancy can this possibly be, ? Many of them only have 2MB, already close to capacity with just the stock BIOS. This doesn't leave a whole lot of space for adding an attack module, and it would have to do some fancy footwork to survive past the protected-mode switch. Modern operating systems don't use the BIOS at all past the bootloader, once the native device drivers take over. It might be possible to punt out some other chunk of the BIOS to make room, but that's playing with fire. If the machine becomes unbootable, the rootkit won't get very far.
CIH was a very trivial virus. All it did was blindly clobber things with zeroes. It had no way of "rooting" a box. It would simply toast your OS, and if your BIOS chip supported the one flash command CIH knew, it would blank that out as well, rendering your machine unbootable. That's what we get for outsourcing even our virus writing ot China :P
-Billco, Fnarg.com
Can we really trust sky-falling advisories from companies such as Symantec? #ProfitMotive
And DDR2/3/4
And PCIe/16 Graphics
All timings & lane skews handled by BIOS
-nB
whois gawk date unzip strip find touch finger mount join nice man top fsck grep eject more yes exit umount sleep dump
And how do you propose the units in the field get fixed?
Put the BIOS image on a microSD mask ROM. Then open the case, snap out the old BIOS card, insert new BIOS card, close the case.
And HT/QPI. Hell, you have to get the PCIe buses walked enough to even see the BIOS boot ROM on the south bridge. Not a full initialization but enough to read the contents of the boot ROM into cache and/or RAM.
ACPI is a cluster fuck, but do you have any ready reason why it could not all be done in the OS, perhaps a unique module particular to the individual motherboard, rather than the BIOS?
... in other words, ACPI?
For large sets, this will be our guide even unto death, for the LORD will work for each type of data it is applied to...
Expect more of this. a full command environment with access to all the hardware on the system before the os boots? it's almost as if it was written 'for' virus and malware makers.
no, DMI training (AFAIK that is not part of ACPI)
whois gawk date unzip strip find touch finger mount join nice man top fsck grep eject more yes exit umount sleep dump
I just looked at the supported boards page. Everything on there is a least a decade old. Oh great someone hacked together a bios that lets my Celeron 533 box boot up 3 seconds faster.
So what about UEFI, will it make this type of threat more difficult or (much) easier? Also, it seems all my servers are safe from this even if they'd be running MS-Windows, because they use a cheap RAID card to detect the hard drives and then boots from one of them. Another mitigation is an encrypted root filesystem because hook.com won't be able to find a login program. Until they modify it to infect the encryption software, of course. Best way to defend against this would be to use TPM with a signed kernel, which is virtually non-existent today.
BIOS contains lots of free/unused space for the skilled programmer.
The BIOS Logo, which most BIOS have provision for is 640x480x16 colors. Now thats 19,200 Bytes! One can fit a LOT of malware in 18.75k IF they are skilled in C/ASM.
Another way, is to make an add-on "OPTION ROM". BIOS have provision for these too [ RAID, Video, Ethernet]. Option ROMS can hook various bios functions, interrupts, etc and override them.
The average BIOS now has ballooned to over 2Mbytes. Probably leaving 200k or so free. That is a LOT of space for code.
When the OS requests the BIOS to flash itself, the old bios should check that the new one has a correct public key signature from the manufacturer. Three could be a physical switch on the mobo for (the tiny minority of) people who wanted to use an unsigned bios.
But wouldn't the use of a BIOS password pretty much put a quick end to this? Ignoring backdoor/default passwords, of course.
But wouldn't using a BIOS password pretty much put a quick end to this? Ignoring backdoor/default passwords, of course.
Superstition IS a virus!
No modern man runs that code or respects the ideas behind it.
"This post is an artistic work of fiction and falsehood. Only a fool would take anything posted here as fact."
My house mate and I caught a virus back in 1997 that infected executables, MBR, and lodged itself in his BIOS. He had to run McAfee 7 times before it finally cleared out. A BIOS infecter isn't new.
Flash BIOS is a convenience to manufacturers, normal end users usually couldn't give a shit. They have no idea what it is, what it does, or why they should care. If it doesn't make their system play games or run Office faster, they don't care.
When you want something built, come see me. If you want correct grammar and spelling, get a F*ing liberal arts student.
Would it be possible to put an appliance at the router (or add functionality to the router) to flag probable infections based on network activity? I'm thinking something a person with only moderate net admin skills could use in addition to virus scans.
If your bootstrap code and code that allows for an "emergency BIOS reload from CD" early in the boot process is read-only, there will be a way to recover from any BIOS infection.
Knowledge is how to play a game, intelligence is how to win, wisdom is knowing what game to play.
Headline should be "New BIOS-Exploiting Rootkit Discovered," otherwise it means a new BIOS was discovered that is exploiting rootkits.
C'mon, editors - finish your GEDs and do your jobs.
Real old school, and I am very surprised we even allow this to happen even today after all this time.
Should have never got rid of that jumper that required a little bit of human protection.
---- Booth was a patriot ----
It seems like the trivial fix here is to sign the code and only allow flashing of signed images after boot. It would be nice to be able to flash anything during boot for hacking/testing/whatever, but anyone using the windows-based flash software is likely to be okay with just signed code from the manufacturer.
Isn't this what those TPM chips were designed for in the first place before they hijacked into being tools for draconian DRM?
Didn't he get gunned down in LA, after that Vibe magazine party?
Hey! I'm a west-coast, DU / Tupac kind of guy!
"Flyin' in just a sweet place,
Never been known to fail..."
It used to be IBM would reset these for you if you could prove you owned the machine. I think you had to send them into to IBM or have an onsite visit, but it was possible.
It's not quite the same as back then they were EPROM's and not EEPROM's or flash. So you'd have to actually pull the chips out, erase them with a UV Lamp and then programming then in a Burner.
It's a long story but after I left high school in New Jersey I had entrusted a friend Mark to ship my possession to California where I had moved to. Instead it stole it all.
After moving I started a large collection of BIOS for XT, AT 80286 motherboards. I had written code that was floating around the BBS's that would harvest the BIOS and dump out ROM images that you could burn on to EPROM and install in to another Motherboard.
So I had made several sets of the latest AMI bios for some friends back home. Well Mark asked a mutual friend to get a copy of the BIOS from me, but not tell me who it was really for.
Well I found out and prepared a special BIOS just for him.
Mark was a big warez guy. He was sharing floppies with everyone.
So I took a copy of the Friday the 13th virus. Also know as Jerusalem B that would slow your PC down to a crawl and every time you ran a program it's file size would grow. It was very easy to detect and clean and mostly harmless. I removed the malicious payload , but made sure it still propagated normally.
The virus was only around 2000 bytes, and ran as a TSR.
I found some empty space in the ROM image, and xor encrypted it and placed it in and added hooks so when you format a floppy (Int 13) it would install the virus TSR.
From there it would then attach itself to any exe file that get's ran.
So I burned the EPROM's and sent them over. I was hearing story's from friends how he was loosing his mind. He'd clean all his disks. Then go to make someone a copy and it would be infected. No one would trade disk with him.
He never did figure out how he kept getting infected.
Revenge is sweet.
I am always doing that which I can not do, in order that I may learn how to do it. - Pablo Picasso
some boards have dual bios and now update from bios as well.
Like those floppy disks or something. Enable/Disable physical write option for CMOS/BIOS.
Ant(Dude) @ Quality Foraged Links (AQFL.net) & The Ant Farm (antfarm.ma.cx / antfarm.home.dhs.org).
If one has a read-only bios, then the virus has to be with the disk or software loaded at boot. SDK That software should more easily be examined for scanners, etc.
The problem with signed BIOSes is that the verifying process could fail due to a current BIOS defect resulting from, at your choice, obsolescence, incompabilities from motherboards/CPUs's, previous failed BIOS update, etc..
In that case, the BIOS update becomes impossible, even for many dual-BIOS motherboards.