From nobody@FreeBSD.ORG  Thu Aug 17 02:53:08 2000
Return-Path: <nobody@FreeBSD.ORG>
Received: by hub.freebsd.org (Postfix, from userid 32767)
	id 3504C37B423; Thu, 17 Aug 2000 02:53:08 -0700 (PDT)
Message-Id: <20000817095308.3504C37B423@hub.freebsd.org>
Date: Thu, 17 Aug 2000 02:53:08 -0700 (PDT)
From: vova@express.ru
Sender: nobody@FreeBSD.ORG
To: freebsd-gnats-submit@FreeBSD.org
Subject: ftpd can't correct handle usernames more than 9 charactes long
X-Send-Pr-Version: www-1.0

>Number:         20675
>Category:       bin
>Synopsis:       ftpd can't correct handle usernames more than 9 charactes long
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    sheldonh
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Aug 17 03:00:01 PDT 2000
>Closed-Date:    Thu Aug 17 05:32:14 PDT 2000
>Last-Modified:  Thu Aug 17 05:33:44 PDT 2000
>Originator:     Vladimir B Grebenschikov
>Release:        5.0-CURRENT
>Organization:
TSB "Russian Express"
>Environment:
FreeBSD lanturn.kmost.express.ru 5.0-CURRENT FreeBSD 5.0-CURRENT #4: Wed Jun  7 18:40:26 MSD 2000     root@lanturn.kmost.express.ru:/ext/src/sys/compile/LANTURN  i386

>Description:
looking into ftpd code:


static int login_attempts;	/* number of failed login attempts */
static int askpasswd;		/* had user command, ask for passwd */
static char curname[10];	/* current USER name */

/*
 * USER command.
 * Sets global passwd pointer pw if named account exists and is acceptable;

>How-To-Repeat:
add user with long username (> 9 characters)
try to login with this user by ftp
>Fix:
--- ftpd.c.orig Thu Aug 17 13:48:14 2000
+++ ftpd.c      Thu Aug 17 13:47:55 2000
@@ -871,7 +871,7 @@
 
 static int login_attempts;     /* number of failed login attempts */
 static int askpasswd;          /* had user command, ask for passwd */
-static char curname[10];       /* current USER name */
+static char curname[MAXLOGNAME];       /* current USER name */


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->sheldonh 
Responsible-Changed-By: sheldonh 
Responsible-Changed-When: Thu Aug 17 05:24:55 PDT 2000 
Responsible-Changed-Why:  
I'll take this one, since I've been suing this patch for a  
little over a year, now. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=20675 
State-Changed-From-To: open->closed 
State-Changed-By: sheldonh 
State-Changed-When: Thu Aug 17 05:32:14 PDT 2000 
State-Changed-Why:  
Committed, thanks! 

ftpd.c rev 1.67 (HEAD) 
ftpd.c rev 1.62.2.4 (RELENG_4) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=20675 
>Unformatted:
