Page 1 of 1

Setting up Proftpd in debian

Posted: Thu Mar 30, 2006 12:36 pm
by a94060
Would anyone know a good guide that would show me how to set up an FTP server on Debian? I would also like to know if any1 knows how i could read and/or write to an NTFS partition to my linux computer?

Posted: Thu Mar 30, 2006 1:14 pm
by timvw
Where have you already looked?

I find http://www.debian.org/doc/ an excellent starting point.[/img]

Posted: Tue Apr 04, 2006 7:23 pm
by a94060
i have looked at http://www.castaglia.org/proftpd/doc/co ... O-SQL.html and a guide at howtoforge.net

i wil lcheck out the debian docs. basically i want to set up proftpd with authentication comnig from a mysql DB

Posted: Thu Apr 06, 2006 7:24 pm
by a94060
i checked the docs and stuff,i tried multiple guides. What i want to do is install proftpd and i want it get the list of users and passwords from the mysql database. the database name is ftp, the username is proftpd pass is proftpd.

Proftpd.conf

Code: Select all

#
# /etc/proftpd.conf -- This is a basic ProFTPD configuration file.
# To really apply changes reload proftpd after modifications.
# 

ServerName			"Debian"
ServerType			standalone
DeferWelcome			off

MultilineRFC2228		on
DefaultServer			on
ShowSymlinks			on

TimeoutNoTransfer		600
TimeoutStalled			600
TimeoutIdle			1200

DisplayLogin                    welcome.msg
DisplayFirstChdir               .message
ListOptions                	"-l"

DenyFilter			\*.*/
DefaultRoot			/ftp

<Limit LOGIN>
   Order deny,allow
   AllowGroup ftpusers
</Limit>

# Uncomment this if you are using NIS or LDAP to retrieve passwords:
#PersistentPasswd		off

# Uncomment this if you would use TLS module:
#TLSEngine 			on

# Uncomment this if you would use quota module:
#Quotas				on

# Uncomment this if you would use ratio module:
#Ratios				on

# Port 21 is the standard FTP port.
Port				21

# To prevent DoS attacks, set the maximum number of child processes
# to 30.  If you need to allow more than 30 concurrent connections
# at once, simply increase this value.  Note that this ONLY works
# in standalone mode, in inetd mode you should use an inetd server
# that allows you to limit maximum number of processes per service
# (such as xinetd)
MaxInstances			30

# Set the user and group that the server normally runs at.
User				nobody
Group				nogroup

# Umask 022 is a good standard umask to prevent new files and dirs
# (second parm) from being group and world writable.
Umask				022  022
# Normally, we want files to be overwriteable.
AllowOverwrite			on

# Delay engine reduces impact of the so-called Timing Attack described in
# http://security.lss.hr/index.php?page=details&ID=LSS-2004-10-02
# It is on by default. 
#DelayEngine 			off

AuthPam			off
RequireValidShell 	off


SQLAuthTypes          	Crypt Backend
SQLAuthenticate       	on
SQLConnectInfo        	proftpd@localhost proftpd proftpd
SQLUserInfo           	users userid passwd uid gid homedir shell
SQLGroupInfo          	groups groupid gid members
SQLDefaultHomedir     	~
SQLDefaultGID		998
SQLDefaultUID		998
SQLHomedirOnDemand	on
SQLLogFile		/var/log/proftpd.sql_log

# Count number of logins for each user
SQLLog                PASS logincount
SQLNamedQuery         logincount UPDATE "login_count=login_count+1 WHERE userid='%u'" users
# Save last login
SQLLog                PASS lastlogin
SQLNamedQuery         lastlogin UPDATE "last_login=now() WHERE userid='%u'" users
# Count number of bytes/files downloaded and uploaded
SQLLog RETR           dlbytescount
SQLNamedQuery         dlbytescount UPDATE "dl_bytes=dl_bytes+%b WHERE userid='%u'" users
SQLLog RETR           dlcount
SQLNamedQuery         dlcount UPDATE "dl_count=dl_count+1 WHERE userid='%u'" users
SQLLog STOR           ulbytescount
SQLNamedQuery         ulbytescount UPDATE "ul_bytes=ul_bytes+%b WHERE userid='%u'" users   
SQLLog STOR           ulcount
SQLNamedQuery         ulcount UPDATE "ul_count=ul_count+1 WHERE userid='%u'" users

# Do not let disabled or expired users to login
SQLUserWhereClause    "disabled!=1 and (NOW()<=expires or expires=-1 or expires='0000-00-00 00:00:00')"

# Log file/dir access
ExtendedLog         		/var/log/proftpd.access_log    WRITE,READ write

# Record all logins
ExtendedLog          		/var/log/proftpd.auth_log      AUTH auth

# Paranoia logging level....
ExtendedLog          		/var/log/proftpd.paranoid_log  ALL default
if somebody could,can they tell me whats wrong or what i should do? i have searched many times and im getting really irritated with this.