:> : What I would like to do is make it so people 'feel alone' on the box. What I
:>
:> Interesting idea. You could put each of them in their own chroot jail,
:> and mount a proc file system on each. That'd get you a bit of the way.
:> You'd then have to doctor the proc fs code to only show their own
:> processes. That'd kill top and ps looksees. For w, you need to doctor
:> utmp, in some way that I can't imagine.
: This is an example of 'vdir /proc' on the machine which makes users "feel
: alone".
: dr-xr-x--- 3 user1 root 0 Feb 5 14:41 26641/
: dr-xr-x--- 3 user1 root 0 Feb 5 14:41 26643/
: dr-xr-x--- 3 user2 root 0 Feb 5 14:41 2693/
: As you can see, in this setup the process information is only readable by
: the owner and root.
But you can still see that another process uid is running!
: In my vanilla RH6.0 setup I get the following:
: dr-xr-xr-x 3 ollie ollie 0 Feb 5 13:41 23612
: dr-xr-xr-x 3 ollie ollie 0 Feb 5 13:41 23613
: dr-xr-xr-x 3 root root 0 Feb 5 13:41 23913
: These are, obviously, readable by everyone.
It doesn't matter. top could trivially still read them if it were suid.
: So, the overriding question is... how do I set my system up like that?
Obviously you can simply change the mask in the proc_fs code. I regret I
can't see where straight off. It might be in array.c by the look. I don't
know if newer kernels have a configure option to do it. Check the uname -r
output on the machine you are looking at.
Peter