Subject: RE: Hiding /etc /bin /dev /usr ?

From: Clinton Fisher <[email-masked]>
Date: Wed, 14 May 1997 13:52:59 -0400

Why would you need to hide these?  The files in those directories are
not of much use (should not be anyway).  But secondly, permissions of
111 on the root of ~ftp would make it so that "ls" would respond with no
files found. 

But even with 111 on the parent directory, if you know the pathname and
the file is readable, you can get the file.  See example below.

# chmod 111 /home/ftp_home

ftp `hostname`
<LOGIN STUFF>
ftp> pwd
257 "/pub" is current directory.
ftp> cd /
ftp> ls
200 PORT command successful.
550 No files found.
ftp> cd /etc
ftp> ls
200 PORT command successful.
550 No files found.
ftp> ls passwd
200 PORT command successful.
150 Opening ASCII mode data connection for file list.
passwd
226 Transfer complete.
remote: passwd
8 bytes received in 0.015 seconds (0.52 Kbytes/s)
ftp> get passwd
200 PORT command successful.
150 Opening ASCII mode data connection for passwd (144 bytes).
226 Transfer complete.
local: passwd remote: passwd
147 bytes received in 0.001 seconds (1.4e+02 Kbytes/s)

>----------
>From: 	Gebbie, Bob[SMTP:[email-masked]]
>Sent: 	Wednesday, May 14, 1997 1:03 PM
>To: 	[email-masked]'
>Subject: 	Hiding /etc /bin /dev /usr ?
>
>
>When someone logs in as anonymous or guest, the system directories (ie
>/etc  /usr ... ) are visible.  
>
>At each chrooted directory (ie guest accounts and anonymous), I added
>the system directories (ie /usr  /etc ...) and gave them 111 access
>permissions with owner "root" and group "ftpgroup".
>
>How do you hide these directories?
>
>Thanks in advance, Bob
>
>Bob Gebbie                                                      Phone:
>953-4677
>Applications Analyst                                          Fax:
>356-7831
>Ministry of Environment Lands and Parks
>
>The future ain't what it used to be. 
>Lawrence Peter Yogi Berra 
>
>
>

---

From: [email-masked] (Geoff Terry Systems & Net supt 064 923677)
Date: Thu, 15 May 1997 10:56:29 +1000 (EST)

Not much use hiding them. They need to be there for the chrooted user. You
can protect them so that they cant do any damage which is wise from a
maintenance point of view (you dont want to be restoring/fixing it each day)
but in any case they only impact themselves and noone else (assuming each
user gets chrooted to his/her own space).

Geofft

>Lawrence Peter Yogi Berra 
Geoff Terry    Systems & Network Support
ACR Net        Sapphire Coast NSW 2550
Australia
Ph 064 923677  Mobile 015 668 227 Fax 064 924594