Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Sep 1997 10:57:14 +0930
From:      Greg Lehey <grog@lemis.com>
To:        David Langford <langfod@dihelix.com>
Cc:        questions@FreeBSD.ORG
Subject:   Re: Hiding user directories without breaking ftp?
Message-ID:  <19970913105714.09863@lemis.com>
In-Reply-To: <199709122324.NAA07029@caliban.dihelix.com>; from David Langford on Fri, Sep 12, 1997 at 01:24:12PM -1000
References:  <199709122324.NAA07029@caliban.dihelix.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Sep 12, 1997 at 01:24:12PM -1000, David Langford wrote:
>
> I am trying to get a system so that users can't "ls" other peoples
> home directories.

I've taken -isp off the list, since this doesn't have anything to do
with ISPs.

> The current problem is that this really breaks ftpd.
>
> It doesn't affect uploading to the directory, but when a user moves to a
>  subdirectory and then tries to back out, it goes all the way to the
> server root directory.
>
> I set the dirs up like:
>
>  drwxr-x--x   33 root  nolist	/u1
>  drwxr-x--x   33 root  nolist	/u1/u
>  drwx--x--x    3 user  user     /u1/u/user
>
> PWD works like this.
>
>  -r-xr-sr-x  1 bin  nolist /bin/pwd
>
> Since ftpd setuid's the the incoming user then the getcwd() command doesnt
> work.
>
> I would like to figure out a way for getpwd() to work but break "ls".

I don't understand why you're doing things this way.  It would suffice
to set the permissions on the user directories, and this way you're
making it impossible for anybody except root to find the directories.

If you add read permission to /u1 and /u1/u, things should work OK.

Greg




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19970913105714.09863>