3 ms·
The technique here keeps a large set of objects from escaping the sandbox. Those objects are accessed both by C++ and JIT code. You are right that using Rust in
by azakai 3y ago
The technique here keeps a large set of objects from escaping the sandbox. Those objects are accessed both by C++ and JIT code. You are right that using Rust instead of C++ would help on the C++ side, but it would not help at all on the JIT code side, and that is by far the major source of exploits.
In other words, even if you write a JS engine in Rust you could benefit greatly from this technique.
- vlovich123 3y agoI have no issue with the sandbox technique. My critique is that the sandbox escapes just have to find an assumption violation in C++ that leads to a memory violation, meaning that sandbox escapes are easier in V8 due to being written in C++. Having the sandbox & security-relevant runtime pieces written in Rust would do a lot to prevent huge swathes of sandbox escapes more robustly than trying to ensure that all C++ today & that will be written remains hardened.