4 ms·
> Running untrusted unbounded code in the kernel is not smart. Well currently we run code (e.g. drivers) as trusted full-permission code. Surely, web-assembly
by nicoburns 7y ago
> Running untrusted unbounded code in the kernel is not smart.
Well currently we run code (e.g. drivers) as trusted full-permission code. Surely, web-assembly would be better than this from a security perspective.
- manyworlds 7y agoGenerally kernel code is also written to specific constraints. Out-of-tree drivers are usually bad at conforming and hypothetical out-of-tree webassembly drivers would be bad for similar reasons. Memory safety isn’t enough, using kernel interfaces safely requires conformance that webassembly can’t statically guarantee like BPF can Basic examples: code that takes a lock and never releases it, code that loops forever, code that leaks kernel resources.
- boomlinde 7y agoWhat use case do you envision?
- mkup 7y agoOut-of-tree drivers, support for closed-source drivers in Linux (assuming kernel API for wasm drivers is stable).
- boomlinde 7y agoWhile I see how out-of-tree drivers using a stable API might be a desirable goal, I don't understand what WASM adds to the table. Maybe some degree of cross-arch portability, but that's already afforded by C and the kernel.