Re:Glibc getaddrinfo stack-based buffer overflow
by fpoling on Wednesday February 17, 2016 @01:41PM
(#11120146)
Both asm.js and NaCl guarantee execution stack integrity and allow jumps only at predefined targets in code making exploiting bugs like this highly problematic. Data-only exploits are hard and in asm.js case they are father limited as access outside of the memory leads to program termination.
On the other hand memory safety does not prevent bugs like Heartbleed or resent OpenSSH key leak. As the underling issue is related to broken reuse of a cached buffer, such code can be written in Java or even Rust just as well.
Re:Glibc getaddrinfo stack-based buffer overflow
by gpderetta on Thursday February 18, 2016 @03:18AM
(#11124411)
Sure, but these are (very effective) mitigation techniques, but still do not guarantee memory safety.
You are right that Heartbleed is not a memory safety issue, I should have been more careful. I just wanted an example of an exploit that doesn't need to escape the process boundary to cause damage.
This is different from, for example, java bytecode which is verified and guaranteed to be memory safe.
This is not a mere technicality: an heartbleed vulnerable version of openssl compiled on top of asm.js or NaCl would still leak secret information.
edit: typo