From 6808486e7efb55dd7867ff158c25cf66e95cfe53 Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Thu, 1 May 1997 14:45:38 +0000 Subject: change -A to let in anon | chroot accounts --- libexec/ftpd/ftpd.8 | 5 +++-- libexec/ftpd/ftpd.c | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/libexec/ftpd/ftpd.8 b/libexec/ftpd/ftpd.8 index 9f40a6bb785..c4a39ef11f6 100644 --- a/libexec/ftpd/ftpd.8 +++ b/libexec/ftpd/ftpd.8 @@ -1,4 +1,4 @@ -.\" $OpenBSD: ftpd.8,v 1.11 1997/04/14 00:55:03 millert Exp $ +.\" $OpenBSD: ftpd.8,v 1.12 1997/05/01 14:45:36 deraadt Exp $ .\" $NetBSD: ftpd.8,v 1.8 1996/01/14 20:55:23 thorpej Exp $ .\" .\" Copyright (c) 1985, 1988, 1991, 1993 @@ -62,7 +62,8 @@ service specification; see Available options: .Bl -tag -width Ds .It Fl A -Permit only anonymous ftp connections. +Permit only anonymous ftp connections or accounts listed in +.Pa /etc/ftpchroot. Other connection attempts are refused. .It Fl d Debugging information is written to the syslog using LOG_FTP. diff --git a/libexec/ftpd/ftpd.c b/libexec/ftpd/ftpd.c index d2eaeffafdf..81545067776 100644 --- a/libexec/ftpd/ftpd.c +++ b/libexec/ftpd/ftpd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ftpd.c,v 1.34 1997/04/25 11:06:28 deraadt Exp $ */ +/* $OpenBSD: ftpd.c,v 1.35 1997/05/01 14:45:37 deraadt Exp $ */ /* $NetBSD: ftpd.c,v 1.15 1995/06/03 22:46:47 mycroft Exp $ */ /* @@ -598,7 +598,7 @@ user(name) "ANONYMOUS FTP LOGIN REFUSED FROM %s", remotehost); return; } - if (anon_only != 0) { + if (anon_only && !checkuser(_PATH_FTPCHROOT, name)) { reply(530, "Sorry, only anonymous ftp allowed."); return; } -- cgit v1.2.3