3 ms·
Question: How much overlap is there between using ASLR and writing code in Rust? In other words, do the safety mechanics of Rust also prevent the kind of vulner
by phkahler 10y ago
Question: How much overlap is there between using ASLR and writing code in Rust? In other words, do the safety mechanics of Rust also prevent the kind of vulnerabilities that ASLR protects against? If so, does it do so to the extent that ASLR would be redundant for code written in rust?
- eugeneionesco 10y agoRust does not protect against attacks on ASLR.
- deleted 10y ago[deleted]
- Gankro 10y agoASLR is only relevant if you're exploiting a memory-safety bug. It is therefore "useless" in a safe Rust program (just as it's "useless" in Python, Java, JS, etc), but this is assuming: * all the underlying unsafe routines are correctly implemented (unlikely in theory, false in practice) * the compiler is correctly implemented (objectively false) * the OS doesn't have a weird bug/hole that pwns safe programs (not very informed here, would be interested to hear examples of this) * C libraries the Rust code FFI's into are correct (libc, openssl, gtk, etc...) All safe languages gain defense-in-depth benefits from ASLR (insofar as anything benefits from ASLR), because our whole software stack is riddled with bugs.