From owner-freebsd-questions Sat Mar 9 13:15: 1 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mailsrv.otenet.gr (mailsrv.otenet.gr [195.170.0.5]) by hub.freebsd.org (Postfix) with ESMTP id 823B737B417 for ; Sat, 9 Mar 2002 13:14:51 -0800 (PST) Received: from hades.hell.gr (patr530-a076.otenet.gr [212.205.215.76]) by mailsrv.otenet.gr (8.12.2/8.12.2) with ESMTP id g29LEdft010020; Sat, 9 Mar 2002 23:14:40 +0200 (EET) Received: from hades.hell.gr (hades [127.0.0.1]) by hades.hell.gr (8.12.2/8.12.2) with ESMTP id g29LET1t054156; Sat, 9 Mar 2002 23:14:38 +0200 (EET) (envelope-from keramida@freebsd.org) Received: (from charon@localhost) by hades.hell.gr (8.12.2/8.12.2/Submit) id g29HRqfM015753; Sat, 9 Mar 2002 19:27:52 +0200 (EET) (envelope-from keramida@freebsd.org) X-Authentication-Warning: hades.hell.gr: charon set sender to keramida@freebsd.org using -f Date: Sat, 9 Mar 2002 19:27:52 +0200 From: Giorgos Keramidas To: Steve Tremblett Cc: Steven Lake , freebsd-questions@freebsd.org Subject: Re: Selectively forbidding login Message-ID: <20020309172752.GI15318@hades.hell.gr> References: <20020308181812.A8403@sjt-u10.cisco.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020308181812.A8403@sjt-u10.cisco.com> User-Agent: Mutt/1.3.27i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 2002-03-08 18:18, Steve Tremblett wrote: > I believe a user will be allowed FTP login if their shell is in > /etc/shells. I'm not %100 sure on what nologin does (not on a FreeBSD > box right now), but I'm guessing that if it is a shell that is made up > of something like "int main() { return 0; }" it should be safe to put > in /etc/shells. It's very easy to find out: hades:~$ file /sbin/nologin /sbin/nologin: Bourne shell script text executable hades:~$ grep -v '^#' /sbin/nologin echo 'This account is currently not available.' exit 1 But even if it wasn't a shell script, you can read the source at /usr/src/sbin/nologin. The wonders of Open Source :))) Giorgos Keramidas FreeBSD Documentation Project keramida@{freebsd.org,ceid.upatras.gr} http://www.FreeBSD.org/docproj/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message