by CyberRabbi · 5y ago · 0 comments
There are OSes that use the language for safety and have a single process but having to use memory safe languages is a pretty big limitation! Plus I would imagine it is easier to prove process security than language security.
https://en.wikipedia.org/wiki/Singularity_(operating_system)
https://github.com/lastweek/source-singularity/tree/master/b...
Microsoft and Oracle have removed CAS and JAAS from CLR/JVM respectively as they have failed to provided the software isolated model that was expected from them.
The point is that drivers and apps are managed code and can be software isolated, obviously some of the kernel is unsafe.
CAS was fined grain runtime model that added significant overhead and was never close to being verified, software isolation was coarse grained just like a hardware process and had much less overhead with the goal of verification, more here:
https://www.microsoft.com/en-us/research/wp-content/uploads/...
Rust is only memory-safe and only as long as you stay away from unsafe code. It is not magic pixie dust.
1. https://github.com/paulbartrum/jurassic
2. https://en.wikipedia.org/wiki/Singularity_(operating_system)
V8 basically does this internally with its bytecode, if your whole system was built on that bytecode then you can do software isolation rather than hardware.
> Ideally everything would just be in a single process.
Processes are an amazing boundary, probably the most powerful abstraction in existence.
> Why are new systems exposing the ability to dereference raw pointers to user programs?
This shouldn't be possible today - SMAP/SMEP are standard now.
> obsoleting the need for hardware isolation
I think if the last 3 years (sidechannel frenzy) has taught us anything, it's that software-isolation is extremely difficult. Even hardare isolation is difficult.
Any real example where this makes sense on an internet-connected device?
Rust programmers use unsafe escape hatches all the time BTW.