Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Nov 1996 10:03:50 +0100 (MET)
From:      Greg Lehey <grog@lemis.de>
To:        marc@crwbin.demon.co.uk (Marc Hawkins)
Cc:        questions@FreeBSD.org (FreeBSD Questions)
Subject:   Re: FTP Software
Message-ID:  <199611170903.KAA25355@freebie.lemis.de>
In-Reply-To: <AB5vQBAQOQjyEwpA@crwbin.demon.co.uk> from Marc Hawkins at "Nov 15, 96 11:58:08 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Marc Hawkins writes:
> Hi,
>    Please could you tell me where i can get some FTP software for BSDI
> so i can make my own FTP server. I have looked everywhere but can't find
> any.

I'm not sure what exactly you want, but both BSD/OS and FreeBSD
support anonymous FTP, and they both come with the wuftp daemon.

> freeBSD should be compatible with BSDI so it doesn't matter if it is for
> freeBSD.

You don't make it clear whether you want to run it on FreeBSD or
BSD/OS.  The operating systems are *not* compatible, well, at least
not completely.  In particular, you'll run into problems with
different shared libraries.  In any case, there's no need, since both
systems provide the facility.  Loook on page 126 of the BSD/OS 2.1
handbook if you're using BSD/OS; if you're using FreeBSD, currently
you're limited to the man pages.

To set up anonymous ftp, you need to add a user 'ftp' and create a
home directory for it.  In these examples, I'll assume that it's
/var/spool/ftp (a good name to choose), and I'll refer to it as ~ftp,
which many shells understand.

Your need copies of programs the users want to run in ~ftp/bin, and it
should have a directory ~ftp/pub, writable only by user ftp, and
incoming, writable by anybody, assuming you want to allow people to
upload files.  It may also include a directory ~ftp/hidden, which is
not readable by anybody.  This makes it possible to put files there
which people can access only if they know the names.  In addition,
BSD/OS will give you directories ~ftp/shlib with a copy of the shared
C library, and etc with a modified password file.  These directories
do not appear to be necessary under FreeBSD.

For example (BSD/OS):

+ === grog@allegro (/dev/ttyp3) ~ 688 -> ls -lR ~ftp
+ total 6
+ drwxr-xr-x   2 root     wheel         512 Oct 24 14:02 bin
+ drwxr-xr-x   2 root     wheel         512 Oct 24 14:02 etc
+ d--x--x--x   2 root     wheel         512 Dec 19  1995 hidden
+ drwxrwxrwx   2 root     wheel         512 Oct 24 14:03 incoming
+ drwxr-xr-x   4 root     wheel         512 Nov 17 09:56 pub
+ drwxr-xr-x   2 root     wheel         512 Oct 24 14:02 shlib
+ 
+ /var/spool/ftp/bin:
+ total 396
+ -r-xr-xr-x   1 bin      bin         49152 Feb  3  1994 compress
+ -rwxr-xr-x   1 grog     wheel       77824 Nov  5  1993 gzip
+ -r-xr-xr-x   1 bin      bin         98304 Feb  3  1994 ls
+ -r-xr-xr-x   1 bin      bin        172032 Feb  3  1994 pax

These are the programs that the anonymous ftp user can start.  pax is
a kind of substitute tar/cpio program.

+ /var/spool/ftp/etc:

(not under FreeBSD)

+ total 42
+ -r--r--r--   1 root     wheel         374 Oct 13  1995 group
+ -r--r--r--   1 root     wheel         837 Oct 13  1995 localtime
+ -r--r--r--   1 root     wheel       40960 Oct 13  1995 pwd.db
+ 
+ ls: /var/spool/ftp/hidden: Permission denied

Not even local users can access ~ftp/hidden.

+ /var/spool/ftp/incoming:
+ total 906
+ -rw-r--r--   1 ftp      wheel      416100 Jul  5 15:48 mrouted3.8.2-src.tar.gz
+ -rw-r--r--   1 ftp      wheel        7029 Jul  5 15:48 ucd-snmp-3.1.README
+ -rw-r--r--   1 ftp      wheel       19300 Jul  5 15:43 ucd-snmp-3.1.diffs.gz
+ -rw-r--r--   1 ftp      wheel      466944 Jul  5 15:47 ucd-snmp-3.1.tar.gz
+ 
+ /var/spool/ftp/pub:
+ total 2
+ drwxrwxrwx   2 root     wheel         512 Oct 24 14:02 2.1.0-RELEASE
+ drwxrwxrwx   2 root     wheel         512 Oct 24 14:02 FreeBSD-2.1.0
+ 
+ /var/spool/ftp/pub/2.1.0-RELEASE:
+ total 0
+ 
+ /var/spool/ftp/pub/FreeBSD-2.1.0:
+ total 0

pub is effectively empty on this system.
 
+ /var/spool/ftp/shlib:
+ total 304
+ -r-xr-xr-x   1 root     wheel      298407 Oct 13  1995 libc_s.2.0

FreeBSD will look pretty much the same, except that the directories
shlib and etc are missing.

Greg



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