Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 28 Jan 2001 15:13:54 +0100 (CET)
From:      Alban Hertroys <dalroi@solfertje.student.utwente.nl>
To:        Jason Watkins <jwatkins@firstplan.com>
Cc:        Freebsd-Stable <freebsd-stable@FreeBSD.ORG>
Subject:   Re: ftp logins
Message-ID:  <20010128141356.99CCA1F5D@solfertje.student.utwente.nl>
In-Reply-To: <JBEOKPCEMKJLMJAKBECCKECPCFAA.jwatkins@firstplan.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 22 Jan, Jason Watkins wrote:
> Since rebuilding from 4.1 release to -stable, I've had a curious problem
> with ftp logins. Users which should be allowed to log into ftp will get a
> denial message immedately after entrying the login name, the password prompt
> is never given.

I had a similar problem and it turned out to be related to vim
(sounds ridiculous, right?)

Here's the story (some anecdotal value):

I had replaced all instances of '/usr/local/bin/tcsh' to '/bin/tcsh'
in /etc/shells, and in the master.passwd using vipw.
But I had vim set as my EDITOR, and set vim to save a backup of the
original (extension '.orig').

As it turned out, vipw found a copy of the master.passwd file and
told me this:
'the pw.xxx.orig' file did not change. Do you want to edit it?[y]'.

If you enter 'n', it doesn't update your passwd database, and I had
totally overlooked the messages that said such, as the question didn't
seem important.

This way you end up with a perfectly correct /etc/shells,
/etc/master.passwd and /etc/ftpusers, but users using tcsh can't ftp,
as the passwd_db says otherwise! Even the entries in /etc/pam.conf were
correct.

I have been trying to track this problem for about a week, before
finding out what was wrong.

A couple of nice hints:
- are users with other shells allowed ftp access?
- what do you get if you telnet to the ftp port and try to log in by
hand? (great command: 'HELP')
- if you use vim as your default EDITOR, add this to your autocmds:
	autocmd Bufread /etc/pw.* set patchmode
  This stops making a backup in the current directory (if you use the
  patchmode method; there are other ways to create backups!)



-- 

Alban Hertroys                              http://solfertje.student.utwente.nl
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                       The world is filled with fools,
                       and I enjoy every one of them.



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010128141356.99CCA1F5D>