Hi Bjoern, On Thu, May 30, 2002 at 04:58:18AM +0200, Bjoern Fischer wrote: > OpenBSD has a new interesting feature: systrace. It is a system call > policy generator for "sandboxing" untrusted or semi-trusted binaries.
The idea of sandboxing binaries is nice ofcourse but there is a conceptual drawback. I think you can divide the programs you run in two groups: the group of extra privileged programs which need that for changing passwords or for allowing users to log into their shell (ssh etc). the group of normal programs ran by a user interacting with the outside world like a browser. The problem is, a program needs privileges in order to perform its function. if this function is to change passwords, it needs privileges to actually change those passwords. The same thing goes for capabilities: you can finetune exactly what is allowed, but the main thing a program is supposed to do will still be allowed. If that program was ment to do something which requires root, and you disable everything else so the program can only do that little thing like changing passwords, an attacker gaining control of the process will still be able to do enough to hack the box. You can make it harder for him, but if the binary had to run with root privileges, and you disable all other privileges, an exploiter can still hack the box. If you could drop all privileges, the binary shouldn't be ran as root in the first place. This all goes for the first group of programs i just mentioned. The second group is more for trying to keep hackers from gaining local access. The examples provided by systrace are for this group of programs. But, the same concept applies: the binary needs to run local and access local files and even write to files. A webbrowser still needs to execute xpdf, the user still needs to be able to specify what program to run for pdf's. You can limit the possibilities, but, the minimal capabilities a program needs to function is always enough for a hacker. > The whole idea looks interesting. The implementation details look > relatively simple (read: not too complicated). Anyone interested in > having a closer look and maybe porting it? I have coded similar things for linux, the main problem is the performance hit. For every system call, you will need to check against the policy and systrace even provides regular expression filters etc. This is a major performance hit for most daemons. > Or I will try to port it myself if at least one core member says: > "Interesting technology, send a patch..." I'm not sure if the performance hit will be worth the limiting of possibilities for hackers. They will still get in, it will only take a more specialized shellcode. Looking forward for others' views, Frank van Vliet [EMAIL PROTECTED] To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message