User: Password:
|
|
Subscribe / Log in / New account

Xorg flaw

Xorg flaw

Posted Aug 19, 2010 1:40 UTC (Thu) by avik (guest, #704)
In reply to: Xorg flaw by xtifr
Parent article: An ancient kernel hole is closed

From what I've read it appears the recursion flaw was unrelated to MIT-SHM:

"3. Allocate windows arranged so that when X processes them, some function
F is called recursively. Trigger F recursion."

Looks like any X client can crash the server, with or without a patched kernel.


(Log in to post comments)

Xorg flaw

Posted Aug 19, 2010 3:21 UTC (Thu) by xtifr (subscriber, #143) [Link]

Fair enough, but it still says that Xorg tried and failed to find an adequate fix. If the kernel fix prevents privilege escalation, then what we're left with is merely a potentially annoying bug. Sure, it would be nice to have the bug fixed, but until someone comes up with a fix that works, it's going to be hard to fix it! (The first rule of Tautology Club is the first rule of Tautology Club.)

In any case, runaway memory use already puts your processes in the whimsical hands of the OOM-killer.

Xorg flaw

Posted Aug 19, 2010 17:32 UTC (Thu) by iabervon (subscriber, #722) [Link]

I think that there are actually three things the client has to do: get the server to allocate enough server-side, non-shared resources to use up most of the address space and force the remainder somewhere useful; get a shared memory segment so that the client will be able to change an area of the server's address space; and get the server to overflow the stack into the shared memory segment.

The shared memory aspect is not really a flaw to avoid; the flaws to be fixed on the userspace side are really that the server will go overboard allocating resources for clients, rather than applying some limits to protect itself, and that the server's stack can grow into the heap. At some point, the server should refuse to do what the clients are asking in order to protect itself from overloading (which is hard); the kernel should do better at preventing overloading from leading to unexpected aliasing (which they did). The MIT-SHM aspect just makes the exploit comprehensible.

I don't doubt that a sufficiently clever request could get the server to overflow the stack into the area where the response to the request will be written and write a chosen response into a spot that aliases a return address on the stack, causing the server to return to effectively calling system() on a chunk of an image provided by the client.

Xorg flaw

Posted Aug 19, 2010 14:33 UTC (Thu) by NAR (subscriber, #1313) [Link]

Looks like any X client can crash the server, with or without a patched kernel.

If I understood correctly the problem (which is far from certain) the client can ask the server to allocate memory in the server's address space. Consequently the X server can run out of memory and the OOM killer can kill it. This seems to a be a feature, not a bug (i.e. the whole X server was designed this way). By the way, the X server uses the most memory on my system currently (according to top) and as far as I know, most of the memory is allocated on behalf of clients.

Anyway, nowadays most X clients run locally and if a malicious attacker already controls a client locally, even if it doesn't find any local root holes (which I'm sure there are plenty of), he can delete all of the user's files, send e-mails in the user's name, etc.

Xorg flaw

Posted Aug 21, 2010 9:12 UTC (Sat) by niner (subscriber, #26151) [Link]

"send e-mails in the user's name, etc."

Just because this is one of my favourite misconceptions floating around: nothing at all prevents anyone from sending e-mails in any user's name. Same as you can write any name as sender on an envelope of bad old snail mail. The only thing proving the identity of the sender is in both cases a signature. The electronic version even more so than your easy to fake hand writing. And of course, such a signature should not lie around on your computer unprotected...

Xorg flaw

Posted Aug 23, 2010 23:42 UTC (Mon) by mgedmin (subscriber, #34497) [Link]

The bad thing that malicious programs can do is send emails using the user's bandwidth (and their IP, to avoid spam blacklists).


Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds