1819684 Members
3435 Online
109605 Solutions
New Discussion юеВ

Passive mode FTP

 
Raynald Boucher
Super Advisor

Passive mode FTP

Good day all,

We just upgraded a server from Linux Red Hat to Mandrake and FTP no longer performs the same.

Originally, a connection was established and the you had to issue the PASSIVE command to continue.
Now, we receive message "passive mode off" after the PASSIVE command is issued.

Am I missing a configuration file or something? If so, I'd appreciate to know which one and the syntax to set it.
I couln't find anything in the man pages.

Thanks
5 REPLIES 5
Goran Koruga
Honored Contributor

Re: Passive mode FTP

Check config file for FTP daemon, it's probably not allowing passive connectionts.

Details would depend on the FTP daemon that you're using.

G.
Jerome Henry
Honored Contributor

Re: Passive mode FTP

Can you precise also which ftp server you are using (depends on which Mandrake distro, the recent distros even have 4 different ftp servers, default is wu-ftpd server) ?
If wu-ftpd, your /etc/ftpaccess should contain sth like
passive address 10.0.0.1 0.0.0.0/0 # this *IS* required for passive
passive ports 0.0.0.0/0 1024 65535 # to see if it made a difference
pasv-allow all *.mybox.com
port-allow all *.mybox.com

But best would be to let active mode on... depends on your version !
You can lean only on what resists you...
U.SivaKumar_2
Honored Contributor

Re: Passive mode FTP

Hi,

"Originally, a connection was established and the you had to issue the PASSIVE command to continue.
Now, we receive message "passive mode off" after the PASSIVE command is issued"

That means your FTP server is running in PASSIVE mode by default . So if you giva PASV command it toggles the passive mode to off state.

So instruct the users not to give the pasv command. and use ftp server just like that.

regards,
U.SivaKumar

Innovations are made when conventions are broken
Raynald Boucher
Super Advisor

Re: Passive mode FTP

Thanks pals,
I finally opted to remove passive commands from my command files due to time restrictions but found the following:

The /etc files for ftp
# find . -name '*ftp*' -exec ls -l {} \;
./xinetd.d/wu-ftpd
./pam.d/ftp
./ftpaccess
./ftpconversions
./ftpgroups
./ftphosts
./ftpusers
./lftp.conf

./xinetd.d/wu-ftpd contains
server = /usr/sbin/in.ftp server_args = -l -a

/etc/ftpaccess has no "passive" related command bu /etc/lftp.conf contains
set ftp:passive-mode on

NOW I'm encountering another problem / difference.
When I ftp TO the server everything is (looks) OK.
When I ftp FROM the server I keep getting the following in my logs:
'AUTH GSSAPI': command not understood
'AUTH KERBEROS_V4': command not understood
KERBEROS_V4 rejected as an authentication type

Some applications look for empty logs (ie no error) to proceed.
How can I configure FTP to eliminate those messages?

Thanks again and sorry for the delay in answering
Bill Douglass
Esteemed Contributor

Re: Passive mode FTP

It sounds like the remote server's ftpd is trying to negotiate the type of authentication to be used (e.g. kerberos or GSS, generic security service).

Check in /etc/pam.d/ftp for something like:

auth optional /lib/security/pam_krb5.so

and comment it out.