Sziasztok!

Készítettem egy proftpd + pgsql ftp szervert Ubuntura, sajnos nem 
működik úgy, ahogy szeretném.
Azt akarom hogy ftp-n csak a virtual userek kapcsolódhassanak, más 
felhasználók nem.
Egyenlőre fordított a helyzet, a postgres authentikáció nem sikerül.

A /var/log/proftpd/postgres.log:

Sep 22 07:56:54 mod_sql/4.2.2[3048]: query "SELECT userid, passwd, uid, 
gid, homedir, shell FROM ftpuser WHERE (userid='tomi') LIMIT 1"
Sep 22 07:56:54 mod_sql/4.2.2[3048]: entering   postgres cmd_close
Sep 22 07:56:54 mod_sql/4.2.2[3048]: connection 'default' count is now 2
Sep 22 07:56:54 mod_sql/4.2.2[3048]: exiting    postgres cmd_close
Sep 22 07:56:54 mod_sql/4.2.2[3048]: exiting    postgres cmd_select
Sep 22 07:56:54 mod_sql/4.2.2[3048]: cache miss for user 'tomi'
Sep 22 07:56:54 mod_sql/4.2.2[3048]: user 'tomi' cached
Sep 22 07:56:54 mod_sql/4.2.2[3048]: + pwd.pw_name  : tomi
Sep 22 07:56:54 mod_sql/4.2.2[3048]: + pwd.pw_uid   : 33
Sep 22 07:56:54 mod_sql/4.2.2[3048]: + pwd.pw_gid   : 3001
Sep 22 07:56:54 mod_sql/4.2.2[3048]: + pwd.pw_dir   : /var/www/webtar/
Sep 22 07:56:54 mod_sql/4.2.2[3048]: + pwd.pw_shell : /bin/false
Sep 22 07:56:54 mod_sql/4.2.2[3048]: <<< cmd_getpwnam
Sep 22 07:56:56 mod_sql/4.2.2[3048]: >>> cmd_auth
Sep 22 07:56:56 mod_sql/4.2.2[3048]: entering   postgres cmd_escapestring
Sep 22 07:56:56 mod_sql/4.2.2[3048]: entering   postgres cmd_open
Sep 22 07:56:56 mod_sql/4.2.2[3048]: connection 'default' count is now 3
Sep 22 07:56:56 mod_sql/4.2.2[3048]: exiting    postgres cmd_open
Sep 22 07:56:56 mod_sql/4.2.2[3048]: exiting    postgres cmd_escapestring
Sep 22 07:56:56 mod_sql/4.2.2[3048]: cache hit for user 'tomi'
Sep 22 07:56:56 mod_sql/4.2.2[3048]: >>> cmd_check
Sep 22 07:56:56 mod_sql/4.2.2[3048]: checking SQLAuthType 'Backend'
Sep 22 07:56:56 mod_sql/4.2.2[3048]: entering   postgres cmd_checkauth
Sep 22 07:56:56 mod_sql/4.2.2[3048]: exiting    postgres cmd_checkauth
Sep 22 07:56:56 mod_sql/4.2.2[3048]: 'Backend' auth handler reports failure
Sep 22 07:56:56 mod_sql/4.2.2[3048]: <<< cmd_check
Sep 22 07:56:56 mod_sql/4.2.2[3048]: <<< cmd_auth
Sep 22 07:56:58 mod_sql/4.2.2[3048]: entering   postgres cmd_exit
Sep 22 07:56:58 mod_sql/4.2.2[3048]: entering   postgres cmd_close
Sep 22 07:56:58 mod_sql/4.2.2[3048]: connection 'default' closed
Sep 22 07:56:58 mod_sql/4.2.2[3048]: connection 'default' count is now 0
Sep 22 07:56:58 mod_sql/4.2.2[3048]: exiting    postgres cmd_close
Sep 22 07:56:58 mod_sql/4.2.2[3048]: exiting    postgres cmd_exit


Én úgy látom, hogy megtalálja a felhasználó adatait, de mégsem enged be.
Mi lehet a baja?

sql.conf:

DefaultRoot ~


# Force the use of mysql backend
SQLBackend                      postgres

# The passwords in MySQL are using its own PASSWORD function
SQLAuthTypes                    Backend
#SQLAuthenticate                 users* groups*
SQLAuthenticate                 users
SQLAuthTypes                    Plaintext



# details to connect to mysql db
# dbn...@host dbuser dbpass
SQLConnectInfo                  pro...@localhost proftp pass

# Let proFTPd know the name of the columns in the user table
# Mind that this need to match the name in you table
SQLUserInfo                     ftpuser userid passwd uid gid homedir shell

# Let proFTPd know the name of the columns in the group table
# we want it to interact with. Again the names match with those in the db
SQLGroupInfo                    ftpgroup groupname gid members

SQLMinID        33


# proftpd will dynamicaly create if the homedir does not yet exist
#SQLHomedirOnDemand              on

# update counter when a user logs in
SQLLog                          PASS updatecount
SQLNamedQuery                   updatecount UPDATE "count=count+1, 
accessed=now() WHERE userid='%u'" ftpuser

# change modified time anytime a user delete a file or upload one
SQLLog                          STOR,DELE modified
SQLNamedQuery                   modified UPDATE "modified=now() WHERE 
userid='%u'" ftpuser

SQLLogFile /var/log/proftpd/pgsql.log



_________________________________________________
linux lista      -      [email protected]
http://mlf2.linux.rulez.org/mailman/listinfo/linux

válasz