You are not logged in.
I have some daemons that I have chrooted using jailkit. See here: http://olivier.sessink.nl/jailkit/
I was hoping to further secure these binaries using systrace: http://www.linux.com/archive/feed/51359
there are problems with the 1.6 build and I can't seem to get it compiled; I was wondering if it was even worth the effort?
So my questions for you guys are - is a chroot adequate by itself? the chrooted binaries still make system calls which is a concern for me.
Is there anything I can do to enhance the security here? perhaps apparmor/SELinux? what would you suggest?
Thanks.
Offline
Might I suggest a quick look at the shortcomings with a Google search for chroot security. There are many issues.
Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
The shortest way to ruin a country is to give power to demagogues.— Dionysius of Halicarnassus
---
How to Ask Questions the Smart Way
Offline
Thanks for the suggestion. i have in the past read up on the insecurities of chroot; i was looking for simple alternatives.
Most of the processes i want to sandbox were things like a browser and an irc client; not exactly software that is likely to be circumvented by chroot type exploits. There is only one binary that i was concerned with, that is mldonkey.
I am aware of some of the ways to break out of a chroot, a lot of them require root access, which i make sure chrooted binaries do not have. Others require same basic tools like interpreters or a compiler; usually only the bare essential binaries/libraries are included in my chroot environments.
Hence why i am here seeking advice; like supplementing a chrooted binary by limiting system calls with systrace. I was looking for some advice or lightweight alternatives for some basic protection. i am not running a web server or public services that could be attacked using revised methods, but more binaries that may be victim of automated exploitation such as a worm.
Thanks.
Offline
If you are running a beefy machine, you might consider running certain programs inside an (untrusted) VM. I wouldn't suggest SELinux as it is difficult to learn, debug, and use. I would really only consider it if you are running Fedora or something with SELinux built-in. As you have found out, the chroot jails are not particularly secure.
If you have enough RAM, I would really suggest just running things inside their own VM. If you have a fast enough machine, you should see very little (if any) lag.
Offline
Thanks for the reply. Unfortunately the system i am using is a very old Socket A machine with 256mb ddr1; virtual machine is not really an option. Is AppArmor worth it's weight? Could it suppliment a chroot?
i know jails on BSD are considered pretty secure, why is there no implementation of something similar in Linux?
Last edited by YellowSnowIsBad (2011-08-11 01:03:07)
Offline
I know this post is old, but:
Before you completely drop virtual machines as an option, have a look at the linux-vserver project. This solution lets you run paravirtualized guests with little to no memory hog - Only the daemons inside the pv guest take up significant memory, so if you build yourself a vm template from scratch with only the bare minimal required to run the daemon (init, essential binaries, config, devices etc) the outcome would be a PV guest running under the same kernel as your host, in a very secure isolated enviroment, eating virtually no memory at all.
Offline