freebsd-src/sys
Poul-Henning Kamp 75c1354190 This Implements the mumbled about "Jail" feature.
This is a seriously beefed up chroot kind of thing.  The process
is jailed along the same lines as a chroot does it, but with
additional tough restrictions imposed on what the superuser can do.

For all I know, it is safe to hand over the root bit inside a
prison to the customer living in that prison, this is what
it was developed for in fact:  "real virtual servers".

Each prison has an ip number associated with it, which all IP
communications will be coerced to use and each prison has its own
hostname.

Needless to say, you need more RAM this way, but the advantage is
that each customer can run their own particular version of apache
and not stomp on the toes of their neighbors.

It generally does what one would expect, but setting up a jail
still takes a little knowledge.

A few notes:

   I have no scripts for setting up a jail, don't ask me for them.

   The IP number should be an alias on one of the interfaces.

   mount a /proc in each jail, it will make ps more useable.

   /proc/<pid>/status tells the hostname of the prison for
   jailed processes.

   Quotas are only sensible if you have a mountpoint per prison.

   There are no privisions for stopping resource-hogging.

   Some "#ifdef INET" and similar may be missing (send patches!)

If somebody wants to take it from here and develop it into
more of a "virtual machine" they should be most welcome!

Tools, comments, patches & documentation most welcome.

Have fun...

Sponsored by:   http://www.rndassociates.com/
Run for almost a year by:       http://www.servetheweb.com/
1999-04-28 11:38:52 +00:00
..
alpha Enable vmspace sharing on SMP. Major changes are, 1999-04-28 01:04:33 +00:00
amd64 Enable vmspace sharing on SMP. Major changes are, 1999-04-28 01:04:33 +00:00
boot Make man page reflect reality on parsing rules. Now I know Jordan 1999-04-25 21:41:09 +00:00
cam Release bus entries in the EDT when a path is released. 1999-04-23 23:25:48 +00:00
coda Removed a bogus cast to c_caddr_t. This is part of terminating 1999-01-29 07:23:53 +00:00
compat Enable vmspace sharing on SMP. Major changes are, 1999-04-28 01:04:33 +00:00
compile
conf This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
contrib Use COMPAT_PCI_DRIVER() for registration if it exists. This shouldn't 1999-04-24 20:24:02 +00:00
ddb Fixed -Wcast-qual warnings. 1999-02-12 12:44:19 +00:00
dev s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/. 1999-04-28 10:54:24 +00:00
fs This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
geom Fixed variable overflow problem. 1999-03-11 18:50:39 +00:00
gnu This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
i4b Suser() simplification: 1999-04-27 11:18:52 +00:00
i386 s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/. 1999-04-28 10:54:24 +00:00
isa s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/. 1999-04-28 10:54:24 +00:00
isofs/cd9660 Suser() simplification: 1999-04-27 11:18:52 +00:00
kern This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
libkern Fix warnings in preparation for adding -Wall -Wcast-qual to the 1999-01-28 02:26:20 +00:00
miscfs This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
modules Allow loadable interface drivers with BPF support to be loaded into a kernel 1999-04-28 01:18:13 +00:00
msdosfs This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
net This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
netatalk Change suser_xxx() to suser() where it applies. 1999-04-27 12:21:16 +00:00
netatm Suser() simplification: 1999-04-27 11:18:52 +00:00
netinet This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
netipx Suser() simplification: 1999-04-27 11:18:52 +00:00
netkey #ifdef out unused function key_freetables. 1999-01-12 12:38:31 +00:00
netnatm Examine all occurrences of sprintf(), strcat(), and str[n]cpy() 1998-12-04 22:54:57 +00:00
netns
nfs This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
nfsclient Suser() simplification: 1999-04-27 11:18:52 +00:00
nfsserver This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
ntfs Removed annoying messaged during boot,added some check 1999-04-20 21:06:44 +00:00
pc98 s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/. 1999-04-28 10:54:24 +00:00
pccard Eliminate compiler warning about missing type in declaration. 1999-04-27 18:47:39 +00:00
pci s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/. 1999-04-28 10:54:24 +00:00
posix4 Well folks, this is it - The second stage of the removal for build support 1999-04-17 08:36:07 +00:00
powerpc Fixed several (not all) warnings. 1999-04-23 19:53:38 +00:00
rpc
svr4 Suser() simplification: 1999-04-27 11:18:52 +00:00
sys This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
tools Declare static __inline functions as __inline in their forward 1999-02-28 11:30:00 +00:00
ufs This Implements the mumbled about "Jail" feature. 1999-04-28 11:38:52 +00:00
vm s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/. 1999-04-28 10:54:24 +00:00
Makefile Use ${.CURDIR} in `exists()' constructs. 1999-04-21 11:09:40 +00:00