Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have installed proftpd on my debian 4.0 server. I have modified the proftpd.conf file so that there is a statement for AuthUserFile, which points to a valid file. The file is configured per the proftpd specs, however the user that I have placed in this file is not able to log-in to the server. What could I be doing wrong?

AuthUserFile is of the format: username:passwd:999:1002:www:/var/www:/bin/bash

share|improve this question
    
Does that user actually have permissions to access the folder /var/www? –  wolfgangsz Aug 17 '10 at 8:51
    
So the user in the Auth file, even though they don't have a system profile, needs access to the directory? The group they are assigned to, which is a system group, does have access to this directory. –  dirknibleck Aug 18 '10 at 0:13
    
Does the GID you have listed in the question match the GID for the system group? If it does not match, the FTP user will be attempting to access /var/www using whatever permissions the proftpd user has. –  avggeek Aug 18 '10 at 2:27
    
Yes, it matches. I think this is not the problem though, because the user is not being authenticated. It's not a folder access problem. –  dirknibleck Aug 18 '10 at 3:00
add comment

2 Answers

The entry looks okay to me. Are there any errors in /var/log/proftpd/auth.log?

I found it easier to debug proftpd by stopping the proftpd service and running in the foreground using

proftpd -d 10

(Perhaps not 10, 5 should be ample, see man proftpd for options)

Then try connecting and see what errors you get.

share|improve this answer
    
I checked var/log/proftpd/auth.log and it has the following errors: Aug 17 19:25:54 domain proftpd[13964] domain (IP[IP]): FTP session opened. Aug 17 19:26:10 domain proftpd[13964] domain (IP[IP]): PAM(myuser): User not known to the underlying authentication module. Aug 17 19:26:10 domain proftpd[13964] domain (IP[IP]): USER myuser (Login failed): Incorrect password. –  dirknibleck Aug 18 '10 at 0:53
    
I had entered the correct password. Here is what I think is pertinent from the log... dispatching auth request "getpwnam" to module mod_auth_file mod_auth_file/0.8.3: using passwd file '/etc/proftpd/authfiles/passwd' stashed module 'mod_auth_file.c' for user 'myuser' in the authcache retrieved UID 999 for user 'myuser' dispatching auth request "gid2name" to module mod_radius dispatching auth request "gid2name" to module mod_ldap dispatching auth request "gid2name" to module mod_sql dispatching auth request "gid2name" to module mod_auth_file –  dirknibleck Aug 18 '10 at 0:59
    
dispatching auth request "gid2name" to module mod_auth_unix using module 'mod_auth_pam.c' to authenticate user 'myuser' dispatching auth request "auth" to module mod_auth_pam ROOT PRIVS at mod_auth_pam.c:264 PAM(myuser): User not known to the underlying authentication module. RELINQUISH PRIVS at mod_auth_pam.c:423 using module 'mod_auth_file.c' from authcache to authenticate user 'myuser' dispatching auth request "auth" to module mod_auth_file mod_auth_file/0.8.3: using passwd file '/etc/proftpd/authfiles/passwd' –  dirknibleck Aug 18 '10 at 1:00
    
using module 'mod_auth_pam.c' to authenticate user 'myuser' using module 'mod_auth_file.c' from authcache to authenticate user 'myuser' dispatching auth request "check" to module mod_auth_file USER myuser (Login failed): Incorrect password. –  dirknibleck Aug 18 '10 at 1:00
    
Can you post back the AuthOrder from your proftpd.conf file? Also do any authentication methods work? For example can you login using your normal Linux account? Can you rule out firewall problems (for example turn of firewall and try again)? –  Richard Holloway Aug 18 '10 at 15:20
show 1 more comment

It might be helpful to turn off checking of the legacy ftpusers file using the following Directive:

UseFtpUsers off

By default, the UseFtpUsers directive is On

share|improve this answer
    
I put this in place - no go. I noticed a line in proftpd.conf: Include /etc/proftpd/modules.conf It does not have mod_auth_file.c listed in the file, nor does mod_auth_file.c exist in /usr/lib/proftpd It is supposed to be compiled by default, according to the documentation - proftpd.org/docs/modules/mod_auth_file.html Should I be reinstalling? –  dirknibleck Aug 18 '10 at 3:23
    
Can you execute the command "proftpd -vv" and post the output here? I believe that modules listed as "compiled by default" are statically loaded in the main executable, rather than as a DSO. –  avggeek Aug 19 '10 at 1:50
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.