From owner-freebsd-questions Fri Jul 2 21:21:57 1999 Delivered-To: freebsd-questions@freebsd.org Received: from ucsu.Colorado.EDU (ucsu.Colorado.EDU [128.138.129.83]) by hub.freebsd.org (Postfix) with ESMTP id 21B7B14D52 for ; Fri, 2 Jul 1999 21:21:54 -0700 (PDT) (envelope-from doranj@ucsu.Colorado.EDU) Received: (from doranj@localhost) by ucsu.Colorado.EDU (8.9.3/8.9.3/ITS-5.0/standard) id WAA26287; Fri, 2 Jul 1999 22:21:49 -0600 (MDT) From: Jonathon Doran Message-Id: <199907030421.WAA26287@ucsu.Colorado.EDU> Subject: Re: I am new... To: peter@sweda.com.hk (Peter Kok) Date: Fri, 2 Jul 1999 22:21:48 -0600 (MDT) Cc: doranj@Colorado.EDU, freebsd-questions@FreeBSD.ORG In-Reply-To: <377D727E.1829636F@sweda.com.hk> from "Peter Kok" at Jul 3, 99 10:16:30 am X-Mailer: ELM [version 2.4 PL25] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > how to set up ftp server. it allows login in as "anonymous" and the password as > 'email address' The ftp daemon (ftpd) which ships with FreeBSD is capable of doing this fairly easily. I like wu_ftpd (from Washington University) better for a number of reasons. If you'd like to use wu_ftpd, it is in the ports collection. However, to get you started, I'll discuss ftpd. All of this info is available in the man page, which you can read by typing "man ftpd". However, you'll need the man pages installed before this will work. And since my earlier directions were for installing just bin, I'll assume that these aren't available. If you have the time, I suggest pulling down some additional directories before doing your install. The compat2*, and manpages directories are very useful. Back to ftpd... FreeBSD will already have this installed, and minimally configured when you perform the install. To allow anonymous ftp access you'll need to create a user named "ftp". The "adduser" script will walk you through this process (prompting you for information). I'd create the account with /sbin/nologin as the shell. This is what adduser will look like whe you add the ftp account: Enter username [a-z0-9_-]: ftp Enter full name []: FTP User Enter shell csh date no nologin sh [sh]: nologin Enter home directory (full path) [/home/ftp]: Uid [1003]: Enter login class: default []: Login group ftp [ftp]: Login group is ``ftp''. Invite ftp into other groups: guest no [no]: Enter password []: (The Uid will probably be different) As an additional (optional) step, I'd remove the password for the ftp account. This further prevents unauthorized access to the ftp account. Use "vipw" and change the ftp line to look like this: ftp:*:1003:1003::0:0:FTP User:/home/ftp:/sbin/nologin All I changed was the password field (between the first and second ':'), making it '*'. This character can never occur in a Unix password, so this guarantees that nobody can su to this account. (As opposed to being able to login) When someone anonymously ftps into your machine, ftpd will place them in /home/ftp (or whatever directory you specified as ftp's home). They will be unable to leave this subtree, since it appears as '/' to their ftp client. Jon Doran To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message