Apple Keyboard Firmware Hack Demonstrated
Anonymouse writes with this excerpt from SemiAccurate:
"Apple keyboards are vulnerable to a hack that puts keyloggers and malware directly into the device's firmware. This could be a serious problem, and now that the presentation and code (PDF) is out there, the bad guys will surely be exploiting it. The vulnerability was discovered by K. Chen, and he gave a talk on it at Black Hat this year (PDF). The concept is simple: a modern Apple keyboard has about 8K of flash memory, and 256 bytes of working RAM. For the intelligent, this is more than enough space to have a field day. ... The new firmware can do anything you want it to. Chen demonstrated code which, when you put in a password and hit return, starts playing back the last five characters typed in, LIFO. It is a rudimentary keylogger; a proof of concept more than anything else. Since there is about 1K of flash free in the keyboard itself, you can log quite a few keystrokes totally transparently."
Why does a keyboard even need flash in the first place? Being a keyboard isn't a complex job.
---- Booth was a patriot ----
Pardon my ignorance. I have a lot of it. What is the advantage of having flash memory in a keyboard? I remember that the keyboard (at least at one time, I don't know if that's still the case) used an interrupt call to process input... But the load the keyboard placed on system resources should be so low, that there wouldn't be a need to offload that right? I have to be missing something here. It seems to me that by having something like this, you're just begging for trouble since it opens another attack surface. Anywhere you have processing and memory is a place for malware to reside. This doesn't impress me much Apple.
Laptop charger hack demonstrated?
This is getting quite silly... Perhaps manufacturers should try to keep simple devices actually simple.
...Contiki?
I am TheRaven on Soylent News
A first port for the Mac!
Mandatory 2k long passwords to defeat possible hardware loggers.
Changed monthly, of course.
"There is more worth loving than we have strength to love." - Brian Jay Stanley
Unless you also have some hidden program on the computer to flash the keyboard and later download the data (in which case you could just log the keys by software), you'd need to physically remove the keyboard, flash it with a keylogging BIOS, return the keyboard, then later retrieve the keyboard to get the logged keys.
And, as they say, physical access is root access. There are an unlimited number of ways someone could compromise your computer if they are given access to the hardware and firmware. This hack is just further proof of that.
Oh, and don't let anyone lend you their keyboard.
How can I believe you when you tell me what I don't want to hear?
Microcontrollers in keyboards, BIOS flash, USB-sticks, SD-cards: Please give us hardware write protection. Whether we want our keyboards to be just keyboards, our BIOS unmodified by root kits, USB sticks which we can insert into someone else's system without worrying that our stick gets infected or boot of an SD-card, a simple write protect switch is the easiest and most reliable way.
If I'm not mistaken, doesn't USB have a way for devices to access the host's memory via DMA? If so, does that mean it's possible for a 'hacked' keyboard to use DMA to write an exploit into the host machine's memory?
using namespace slashdot;
troll::post();
RTFA.
Update is completely through software. You'd know this if you even glanced at the article.
...that I don't like the Mac keyboards. I use a Mac Pro at work but the first thing I did was go out and buy a Microsoft ergonomic keyboard. Yeah, I know it's probably blasphemy to many to mix MS & Apple hardware, but I've used MS ergonomic keyboards since they practically first came out, both at home and at work, and would never go back to a regular keyboard, especially one from Apple. I've yet to see one from Apple that doesn't make my hands ache after a few hours of use.
Anyone have any ideas for firmware modifications to add additional functionality?
Is the Apple implementation any different from what other USB HID makers use? I'd be kind of surprised if Apple did anything original with its keyboard design other than making them shiny and thin (and giving them no tactile feedback whatsoever.)
And if so, are other USB keyboards vulnerable to similar hacks?
I'm sure every microwave out there is "hackable" in the sense you can replace its firmware and make it burn users popcorn each time. So what?
Unless you discovered a way to hack someone's keyboard remotely without user intervention, this is not even worth mentioning on a geek site.
As the island of our knowledge grows, so does the shore of our ignorance.
This is a hack on all the new shiny aluminum white keyed keyboards.
I predict a run no eBay sales of old keyboards and USB PC alternatives for the paranoid.
For the rest, well...you get what you pay for eh?
Some days it's just not worth
chewing through my restraints.
The first link says FIFO; the fourth implies LIFO. Which one is it?
Karma fed to this user will be promptly burnt. Be warned; be wary.
That's a red herring. Unless they have changed recently, the internal keyboards on Mac laptops are dumb devices---just a bunch of wires and switches. The controller is on the logic board.
Check out my sci-fi/humor trilogy at PatriotsBooks.
1) A bit of code hacking to put the Keylogger + a simple method to send keystrokes to a 3rd party into a firmware update for the keyboard.
2) Start a "Man in the middle" attack between a Mac user and Mac update servers.
3) User installs update..
4) ???
5) Profit off of all those banking details....
Laters Sol "Have you found the secrets of the universe? Asked Zebade "I'm sure I left them here somewhere"
If someone has sufficient permissions on your machine to update your firmware, aren't you kind of screwed already? I suppose they could swap your (external) keyboard for a compromised one, but that still implies physical access.
That said, given that the ability to update is useful, and that the flash memory size we're talking about is so small, is there a significant downside to having the OS check hashes of the firmware code on initialization?
As the article points out, "For a device as simple as a keyboard, it is hard to imagine why a firmware update mechanism is even required." There's no justification for including an update feature other than as a designed-in security hole. The keyboard CPU should be running off a ROM, or at least an MPU where the security bit has been set to prevent future changes.
This looks like a "feature" put in for development that should have been pulled before release.
RTFA.
Update is completely through software. You'd know this if you even glanced at the article.
New here, I take it?
#DeleteChrome
The problem here isn't really with the end user's keyboard - flashing that is a lot of work for little return, in most cases.
The bigger issue is if/when an enterprising criminal gets access at the plant that makes the keyboards. We've seen CDs/DVDs with malware installed (I'm not even thinking about Sony here); we've seen CompactFlash cards preloaded with viruses... if a batch of keyboards shipped out from manufacturing already installed with a key logger, we're really screwed - who's going to notice?
#DeleteChrome
'physical access unless you have taken over the mac's os'
lol. That's not 'physical access'. That's "You can use physical access, or use remote access".
In the later case you can install a key logger in the OS, so why bother with the keyboard.
..er, because the user can reformat his machine from read-only media, and think he's safe? That's the whole idea.
Not entirely dumb. I have a US keyboard/top case for a late 2006 MB that began registering as a UK keyboard after a Coke spill.
Apple keyboards are pretty standard. You just buy your own and install a keylogger at your leisure. Then you just have to swap your doctored keyboard for theirs. If you have any skill at slight of hand, you could probably do this while someone is watching you.
Hopefully some of the keyboard hackers read slashdot. I would like to request a function added to the keyboard that senses certain "L33T" speak words and automatically backspaces and substitutes REAL words in its place. Some parents might even like to see such a function that senses curse words and substitutes +%$#"!! for matching words... could even be marketable...hrm?
Most hardware should have the flash locked in read-only mode, unlockable only by pressing a specific button on the hardware that's tied to a write-enable wire.
There are obvious exceptions - hardware that needs to be flashed routinely, hardware which is inaccessible by wire and controlled by radio, etc. For those devices, other mechanisms to protect from rogue flashes must be in place.
Knowledge is how to play a game, intelligence is how to win, wisdom is knowing what game to play.
TFA and commenters are talking USB (interesting that it applies to laptops too), but what about the other half of Apple's inventory with Bluetooth. Same? I assume it has the same exploitable flash. But how old a model can it be? I haven't read the PDF, sorry... figured TFA would echo Bluetooth if it was mentioned, since that would be a super easy way to swap out someone's keyboard physically or broadcast a firmware update.
I only need two keystrokes to hack a Mac when I have access to its keyboard: :p Start into single user mode
Cmd - "s"
Voila, root access. documented here
There are fewer illiterates than people who can't read.
Comment removed based on user account deletion
Bet you could infect a keyboard and have it reinfect the computer ever time you try and format / reinstall your OS...
I just bought all cheap PC keyboards to replace the aging mac keyboards. mainly because the mac ones are way too expensive... ~$40. Also because all the Mac keyboards have been a point of irritation- from being bright white with clear housing (sure shows crumbs well) to having non-traditional keys (new ones ala mac book keyboard) they just aren't good for the real work environment.
"Enjoy what you're doing! If it becomes drudgery, you're doing it wrong!" - Jim Butterfield
That *is* a feature. It isn't a hacked battery, it is a battery which is hacked to appear as an authentic internal tool, designed to read a certain area on a memory stick, so sony can quickly restore a problematic psp.
It was designed that way, and obscured. the 'hack' merely makes that information public and usable.
It might run "Pitfall!" though.
The land shall stone them with the bread of his son.
who have infiltrated factories that make digital USB picture frames and inserted viral code in their mass storage?
I use an Apple key/b/ r00lzboard anCredit Card Transaction CompleteddI've never seen aHAHA U BN PWN3Dnything like this happen. More anti-Apple proparickrolledganda!
... at least there's now a chance of someone fixing that bloody Caps Lock delay
Apple has had flash updates for their keyboards before. So they have another one to fix this problem. if it really is a problem. Lots of so called mac hackers have claimed exploits that are not real.
I want to know if OpenBSD thought of this already and blocked it, or if this is their 3rd hole
could be even more interesting!
Ask Me About... The 80's!
Notes
1. If you do not develop software, verbose and single-user modes are only needed when troubleshooting the computer for a startup issue.
2. You cannot enter single user or verbose mode if the computer owner or administrator has enabled Open Firmware Password Protection.*
3. When in single-user mode, the keyboard layout is US English.
* I do on my MacBookPro...
Ask Me About... The 80's!
That doesn't mean there is anything complex going on in the keyboard itself. They could do something as simple as shorting one of the pins on the ribbon cable to ground to tell the controller that it's a UK layout.
So what does /. thinks?
-) Block all unsigned Firmware, locking out the hacker community for the sake of "security"?
-) Allow hacks and custom firmware? (with the possibillity of security issues)
-) think: my Firmware will never have any bugs, i'll put in a ROM (with the risk of recalling the HW when a serious issue is found)
As I see it, this requires Social Engineering to work, and is therefore only possible through the use of a Trojan.
1. If you are using Apple's keyboard updater/bootloader, then THAT has to run on the intended victim's machine. That requires either physical access or the use of a Trojan to dupe users into typing an admin. password. In both cases, that's not as easy as it sounds.
2. If you (as hacker) have reverse-engineered Apple's keyboard bootloader protocol and written your own updater/bootloader (that would be crafted to not require as password), then you STILL need to get the user to run that ON THEIR MACHINE. Again, you need either physical access or a Trojan.
Would the fix be this easy? On boot the OS re-flashes USB devices with the current correct instruction set? On a sophmoric level, it does seem someone is Apple bashing for an issue that is not limited to their products.
> The vulnerability was discovered by K Chen
That guy's a fucking idiot! He couldn't think his way out of a paper bag.
Oh, wait. I thought you said K Fed. n/m
(-1: Post disagrees with my already-settled worldview) is not a valid mod option.
You(r Coke) just hacked a keyboard.
Congratulations!