PureFTP

Configuration

On décrit ici la configuration du serveur FTP "pure-ftpd".

# cat /etc/pure-ftp/pure-ftpd.conf
PAMAuthentication yes
PureDB /etc/pure-ftpd/pureftpd.pdb
# /usr/sbin/useradd -g ftp -d /dev/null -s /bin/false xxx
# pure-pw useradd xxx -u xxx -g ftp -d /home/xxx -N 100
Password:
Enter it again:
# pure-pw show xxx
# pure-pw mkdb
# pure-config.pl /etc/pure-ftpd/pure-ftpd.conf
Running: /usr/sbin/pure-ftpd -A -c50 -B -C8 -D -fftp -H -I15 -lpuredb:/etc/pure-ftpd/pureftpd.pdb -lpam -L7500:8 -m4 -s -U133:022 -u500 -i -Oclf:/var/log/pureftpd.log -k99 -Z
# service pure-ftpd restart

Ne pas oublier d'ouvrir le port pour FTP...

# /sbin/iptables --list
Chain INPUT (policy ACCEPT)
target prot opt source destination
RH-Firewall-1-INPUT all -- anywhere anywhere

Chain FORWARD (policy ACCEPT)
target prot opt source destination
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

Chain RH-Firewall-1-INPUT (1 references)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT icmp -- anywhere anywhere icmp any
ACCEPT esp -- anywhere anywhere
ACCEPT ah -- anywhere anywhere
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:domain
ACCEPT udp -- anywhere anywhere state NEW udp dpt:domain
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ftp
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT udp -- anywhere anywhere state NEW udp dpt:ntp
ACCEPT udp -- anywhere anywhere state NEW udp dpt:time
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited

mis à jour le 20/07/2009

Raccourcis