Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Feb 2016 15:50:46 +0100
From:      Marko =?UTF-8?B?Q3VwYcSH?= <marko.cupac@mimar.rs>
To:        freebsd-ports@freebsd.org
Subject:   ftp/pure-ftpd mysql auth from jail not working?
Message-ID:  <20160213155046.020932af@efreet>

next in thread | raw e-mail | index | archive | help
Hi,

I have working pure-ftpd server on vmware-based 9.3-RELEASE-p33. It
authenticates virtual users from mysql server over tcp, and chroots them
to their directories.

I'd like to move pure-ftpd to jail-based 10.2-RELEASE-p10. I copied
pure-ftpd.conf and pureftpd-mysql.conf to new server, but I get:

331 User someuser OK. Password required
Password:
530 Login authentication failed
Login failed.

pure-ftpd.conf:
ChrootEveryone              yes
BrokenClientsCompatibility  no
MaxClientsNumber            50
Daemonize                   yes
MaxClientsPerIP             32
VerboseLog                  no
DisplayDotFiles             no
AnonymousOnly               no
NoAnonymous                 yes
SyslogFacility              ftp
DontResolve                 yes
MaxIdleTime                 15
MySQLConfigFile             /usr/local/etc/pureftpd-mysql.conf
LimitRecursion              10000 8
MaxLoad                     4
PassivePortRange            30000 31000
Umask                       133:022
MinUID                      2001
AllowUserFXP                no
ProhibitDotFilesWrite       yes
ProhibitDotFilesRead        yes
AltLog                      stats:/var/log/pureftpd.log
NoChmod                     yes
CreateHomeDir               yes
MaxDiskUsage                99
CustomerProof               yes
IPV4Only                    yes
Bind                        IP.ADD.RE.SS,21

pureftpd-mysql.conf:
MYSQLServer		mysql.example.org
MYSQLPort       	3306
MYSQLUser       	user
MYSQLPassword   	pass
MYSQLDatabase   	pureftpd
MYSQLCrypt      	any
MYSQLGetPW      	SELECT Password FROM users WHERE User=3D'\L'
MYSQLGetUID     	SELECT Uid FROM users WHERE User=3D'\L'
MYSQLGetGID     	SELECT Gid FROM users WHERE User=3D'\L'
MYSQLGetDir     	SELECT Dir FROM users WHERE User=3D'\L'
MySQLGetBandwidthUL     SELECT ulBwidth FROM users WHERE User=3D'\L'
MySQLGetBandwidthDL     SELECT dlBwidth FROM users WHERE User=3D'\L'
MySQLGetQTASZ           SELECT sizeQuota FROM users WHERE User=3D'\L'
MySQLGetQTAFS		SELECT fileQuota FROM users WHERE User=3D'\L'

Any idea why the same configuration does not work in jail-based host?
--=20
Before enlightenment - chop wood, draw water.
After  enlightenment - chop wood, draw water.

Marko Cupa=C4=87
https://www.mimar.rs/



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