The next talk to be announced is of particularly interest to me. I remember when I first heard about sysjail a couple years ago, and enjoyed Kristaps Džonsons’ talk about it at NYCBSDCon 2006. Unfortunately for fans of sysjail, systrace (the mechanism it is based on) was found to have vulnerabilities that neutralized much of its usefulness.
Kristaps is obviously a dedicated individual that doesn’t give up easy. He’s been busy working on a new process isolation mechanism called mult.
In NetBSD and OpenBSD, user-land process and process-context isolation is limited to credential cross-checks, file-system chroot and explicit systrace/kauth applications. I’ll demonstrate a working mechanism of isolated process trees in branched OpenBSD-4.4 and NetBSD-5.0-beta kernels where an isolated process is started by a system call similar to fork; following that, the child process and its descendants execute in a context isolated from the caller. This system is the continued work of “mult” — first prototyped in a branched NetBSD-3.1 kernel and isolating all system resources — pared down to a lightweight, auditable patch of process-only separation for both OpenBSD and NetBSD. I specifically address solutions to performance issues and mechanism design with an eye toward more resources being isolated in the future.
This sounds pretty cool, but most of it went over my head. I went back to Kristaps, asking him to pretend I’m a Linux user.
mult allows the creation of isolated instances, similar to jails on FreeBSD, but considerably more robust, feature-rich, safe and scalable.
An instance contains a process and all of its descendant processes. Once started, an instance’s processes are invisible to the caller; similarly, the caller is invisible to the instance.
Ok, that makes more sense. How far along are you with mult? Is it usable today for the average BSD administrator?
In the current version of mult, which is a lightweight re-write of the NetBSD-3.1 prototype, only pids, pgids and file descriptors are isolated. Thus, a process can’t stat other instances’ processes, even if of the same pid. However, users are still unisolated, so using setpriority on a user will affect all instances. New stuff can be easily appropriated, but my intent is to (re-)start small and clean.
% instproc — /usr/sbin/sshd -df /var/jail/etc/ssh/sshd_config
This starts a process, sshd, where a connecting user will only “see” (e.g., via ps ax) the sshd process and its descendants. Similarly, the caller will not see the started sshd.
Good stuff. I’m really anxious to hear Kristaps talk about this project and how useful it will be in the near future. If I had a crystal ball, I bet I’d see quite a few ShmooCon attendees sneaking into this talk. Don’t let them steal your seat… register now and get your barcode!
News
kernel, Kristaps Džonsons, mult, NetBSD, OpenBSD, process, security, sysjail, systrace