i have a question about vsftp
please !
if i use active mode for my ftp server , should i see that my vsftp server is listening on 21 and 20 port when i use netstat ??
when i test
sudo netstat -lnp | grep vsftp
i get only port 21
tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN 47/vsftpd
Port 20 is used as the local port number for the outgoing connection, so the service never listens on it, but still needs permission to bind to low port numbers.
Normally, outgoing connections are made from sockets that are not bound to a specific local address and port number, and initiating the connection then assigns a random port number and the local address of the interface that the connection will go out to.
FTP explicitly says that outgoing connections should use port 20, and the FTP client can then verify the remote port number on the incoming connection to make sure it originates from a process running as root, so that is an archaic security feature.