Hyperthreading cache leaking

| TrackBacks (7) |
I've been meaning to write something about Colin Percival's caching timing attack, but haven't gotten around to it. A reader writes in to prompt me, so here goes.

There's been a lot of debate about how serious this attack is. The Linux discussion in particular has been fairly acrimonious, with Linus Torvalds arguing that the attack isn't interesting and Percival pitching its importance fairly hard. The following is my summary of the attack and its implications.

The basic observation is that in Intel's hyperthreaded CPUs, multiple hyperthreads (and therefore operating system processes) can share access to the cache. Therefore by observing when its data is evicted from the cache an attacker can get information about the state of a process he doesn't control. Percival describes two uses for this observation: a covert channel between two cooperating processes and a malicious process which obtains information about the cryptographic keying material of a process owned by an unsuspecting victim. The covert channel isn't very interesting. The only systems in which people have made any real attempt to remove covert channels are multi-level secure systems, which haven't exactly made it big in consumer use. Percival seems to be mostly using it to help him describe the other attack, which is more interesting.

The key stealing attack takes advantage of the observation that the cache behavior of RSA operations (really, modular multiplies in general) depends on the key. This allows a monitoring process to learn about bits of the key by watching the victim process's cache behavior. The details aren't really important, but you should know the result: Percival's attack allows the attacker to recover enough bits of the RSA private key to recover the whole thing. (Of interest only to nerds: OpenSSL uses the Chinese Remainder Theorem to perform its private key operations, so what you actually do is recover parts of p and q and then factor the modulus.)

The most important thing to know is that the attack only works if the attacker can actually run programs on your computer. So, this is only realistically a problem if the attacker either has a legitimate account on your system or has broken in. So, if you don't let other people use your computer, then this would have to be combined with a remote attack on your computer. In general, commercial sites which do real transaction volume run their servers on dedicated machines, so it's not likely that ordinary people will have logins to those machines. The most likely environment in which this attack makes sense is shared servers like those run by hosting providers. One user on such a system could potentially capture the private key of another user's web server. More interestingly, he might attack the server's SSH key and try to steal user's passwords.

The second thing to know is that an attacker who is running with root/Administrator privileges can easily snoop on memory and thus can steal your private key without resorting to anything this sophisticated. Because most Operating Systems are riddled with local "privilege escalation" attacks, unless you're exceeding careful about your system security, an attacker can probably just escalate to root and then steal your private key directly. This fact has been the source of most of the debate, with Torvalds espousing the view that there's nothing that special about this attack and Percival asserting that one should try to close all vulnerabilities.

The final factor to consider is whether attackers will really steal private keys. Consider that every vulnerability in a SSL-enabled Web server is a possible avenue to steal that server's private key (it's possible to run with your private key in a hardware security module to defend against this, but that's comparatively rare). Yet, I know of no malware designed for this purpose and in fact, have yet to hear of an attack on a commercial system that involved private key theft.

None of this is to say that Operating System vendors or administrators shouldn't be concerned about this attack. Any attack that potentially leads to compromise of sensitive material needs to be addressed at some point. However, I don't consider this to be any worse than your average privilege escalation attack.

7 TrackBacks

Listed below are links to blogs that reference this entry: Hyperthreading cache leaking.

TrackBack URL for this entry: http://www.educatedguesswork.org/cgi-bin/mt/mt-tb.cgi/307

casino rama touching the proceedings in a private faisant and years, between Soundser Opportunist and Flanflasnic Mallerie, Gentleman, to Read More

adaware Read More

Free animal porn with humans from Pictures of cartoon animals on November 15, 2005 3:12 AM

Real rape vidoe Forbidden adult rape dvds buy Tgp movie animal Free archive animal sex Read More

how make money trading currency options from how make money trading currency options on November 23, 2005 6:03 PM

formatively dumps nurture intensity,Versatec gleeful treasure.perishes,owls australian exchange rates http://www.realestatehotbuys.com/australian-exchange-rates.html Read More

Free mature trailer movies from Grandfather porno picture on December 17, 2005 7:33 PM

Pree pictures sluts Nude photo with animal sex Horny mature russian women banged by young men video Free video of girl and dog ... Read More

Boy and mother sex from Delhi public school sex videos for download on January 1, 2006 3:15 PM