Closed jdm closed 5 years ago
(I was just writing this in https://github.com/servo/servo/issues/11625 … :D)
Gaol is designed around a syscall filtering model like seccomp/pledge, not an object-capability model like Capsicum. (I made a little crate that's better suited for Capsicum — including the awesome openat
trick.)
I can add a Capsicum backend for Gaol that disallows everything :) but Servo would have to pass all the descriptors from a privileged process or open them beforehand.
Looks like the content process sandbox only needs /dev/urandom
and a resources directory! So it should be possible to open these things before starting the sandbox, and use the openat crate to open the resources under the directory.
Actually /dev/urandom
might not even be necessary. If Servo uses the rand
crate (I haven't checked), it uses sysctl kern.arandom :)