Date: Fri, 23 Mar 2007 13:15:54 +0300 (MSK) From: Dmitri Alenitchev <dmitri@dworlds.ru> To: FreeBSD-gnats-submit@FreeBSD.org Subject: bin/110701: [patch] ftpd(8): don't advertise version Message-ID: <20070323101554.C17771EA58E@opay.ru> Resent-Message-ID: <200703231010.l2NAA19r016374@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 110701
>Category: bin
>Synopsis: [patch] ftpd(8): don't advertise version
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Fri Mar 23 10:10:01 GMT 2007
>Closed-Date:
>Last-Modified:
>Originator: Dmitri Alenitchev
>Release: FreeBSD 6.2-STABLE i386
>Organization:
Digital Worlds J.S.C.
>Environment:
>Description:
do not advertise version in the ftp banner, because there is no reason to
>How-To-Repeat:
>Fix:
--- ftpd.diff begins here ---
Index: ftpd.c
===================================================================
RCS file: /home/ncvs/src/libexec/ftpd/ftpd.c,v
retrieving revision 1.211
diff -u -r1.211 ftpd.c
--- ftpd.c 9 Feb 2007 17:18:39 -0000 1.211
+++ ftpd.c 23 Mar 2007 09:11:46 -0000
@@ -102,7 +102,6 @@
#include <stdarg.h>
-static char version[] = "Version 6.00LS";
#undef main
extern off_t restart_point;
@@ -641,7 +640,7 @@
hostname[MAXHOSTNAMELEN - 1] = '\0';
#endif
if (hostinfo)
- reply(220, "%s FTP server (%s) ready.", hostname, version);
+ reply(220, "%s FTP server ready.", hostname);
else
reply(220, "FTP server ready.");
for (;;)
@@ -2370,7 +2369,6 @@
if (hostinfo) {
lreply(211, "%s FTP server status:", hostname);
- printf(" %s\r\n", version);
} else
lreply(211, "FTP server status:");
printf(" Connected to %s", remotehost);
--- ftpd.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070323101554.C17771EA58E>
