Net::FTP : Passive mode does not work as documented.



A few of our servers reject connection via Net::FTP with the error

"PASV is disabled"

From the wording I guessed that this means that our client program
tries to establish the connection via passive mode, but the server
only supports active mode.

From the perldoc documentation of Net::FTP I concluded that active
mode is the default when creating a Net::FTP object (unless one
explicitly sets Passive=>0 in the constructor, which we don't). So
it seems that the documentation for Net::FTP does not match the
implementation.

(Additional note:

To double-check this, I ran the client again, but now with setting
the environment variable FTP_PASSIVE to zero. The transfer
now works.

Similarily, if I set FTP_PASSIVE to 1 makes the error message
reappear, as does an explicit call to the pasv method).

Ronald

.



Relevant Pages

  • Re: Net::FTP : Passive mode does not work as documented.
    ... "PASV is disabled" ... explicitly sets Passive=>0 in the constructor, ... # Passive default for internal hosts ...
    (comp.lang.perl.modules)
  • Re: No Ftp uploads with new computer
    ... Mode (PASV)" to "Active Mode " ... I have a new Windows Xp Home ed computer and can no longer ftp. ...
    (microsoft.public.windowsxp.general)
  • FTP PASV returns internal IP address of server
    ... I am using Windows Server 2003, with IIS 6.0 enabled for FTP. ... It works fine in Active mode (non-pasv). ... Actually, PASV works fine when ...
    (microsoft.public.windows.server.networking)
  • Newbie help
    ... i am using ftp commands to transfer files between local machine and ... I am sending 'PASV' and 'PORT' commands to set passive or active ... providing passive mode or active mode or not. ...
    (microsoft.public.dotnet.general)