string crash found while fuzzing WebGL shaders
Originally disclosed on Mozilla
- Fixed in 16 days
- Paid in 2.1 years
- Disclosed after 16 days
Created attachment 540783
PoC zipped
Michael Jordon of Context IS submitted this Javascript string crash he found while testing WebGL in Firefox 4.0.1 on WinXP. He cannot reproduce the bug in a nightly build, but doesn't know if that means we've fixed it or the crash is just moved a bit. From Michael:
This, might be related to WebGL but I don't think it actually is. It was just exposed when doing fuzzing against the shader compiler. It isn't clear if this has a security implication, although it looks possibly like some memory is getting overwritten causing the issues to occur.
The bug seems to manifest in two different ways, both of them when calling into nsPromiseFlatString::nsPromiseFlatString. The first manifestation ends up with a call to memcpy where the source pointer is too small for the number of bytes it is supposed to be copying so crashes on a read AV. This is string crash 1. The second is a stack overflow, where the code calls into the function xul!nsAString_internal::Assign which seems to think it can optimise the string operation by calling back into itself, which causes an infinite loop and eventually the stack runs out. This is string crash 2. Which one occurs seems to depend on what has already been loaded at the time.
The PoC minimal_crash.html exhibits the bug on 4.0.1 on XP SP3. It doesn't seem to crash the latest nightly build, however slight changes to the Javascript (which doesn't change function, just form) seems to also stop the crash so it might just be the nightly build is rebuilt in such a way that memory layout is sufficiently different to stop the underlying bug, or it could be fixed.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
What is known
A doS bug in Graphics: CanvasWebGL. Mozilla made it public on 8 July 2011 as CVE-2011-2988.
About DoS
A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
What is DoS?
A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.