lkml.org 
[lkml]   [1999]   [May]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: access to proc filesystem from chrooted process
Hi all.

>> Are you referring to some means of mounting /proc so it
>> appears visible to ALL processes no matter where they're
>> chroot'd to? If so, I'd love to know how.

>> Sure, I know that the proc file system does not have to
>> be mounted over /proc (although it usually is), but I'd
>> love to know how to mount it so that it's visible to two
>> processes that are respectively chroot'd as follows:

>> 1. /home/ftp (aka ~ftp)
>> 2. /usr/mirrors (aka ~mirrors)

>> As you can see, there are no common subdirectories between
>> those two processes...

> don't need any. proc can be mounted any number of times.

This basically summarises the view expressed in some 70 different
emails I've received in response to that posting, but in my opinion,
they all skirt round the question being asked. I have therefore chosen
to rephrase the question as follows:

Q> Given a system with the proc filesystem mounted ONCE on the
Q> /proc directory, and an account chroot'd to /home/ftp (say),
Q> with no /etc/fstab visible below that chroot point, and also
Q> no means for a non-root user to create one there, how does a
Q> non-root user in that chroot trap access files in the /proc
Q> filesystem?

The original posting that I responded to IMPLIED that a non-root user
in that situation COULD access files in the /proc filesystem, and I
have yet to see a single response that answers that question.

My analysis states that without the /etc/fstab file, no further
filesystems can be mounted, so even if the mount command is present,
the user will not be able to mount any further copies of the proc
filesystem (or any other filesystem) inside the chroot trap, and thus
that such a non-root user has no means to access anything in the proc
filesystem.

Best wishes from Riley.

+----------------------------------------------------------------------+
| There is something frustrating about the quality and speed of Linux |
| development, ie., the quality is too high and the speed is too high, |
| in other words, I can implement this XXXX feature, but I bet someone |
| else has already done so and is just about to release their patch. |
+----------------------------------------------------------------------+
* ftp://ftp.MemAlpha.cx/pub/rhw/Linux
* http://www.MemAlpha.cx/kernel.versions.html


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:51    [W:0.274 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site