Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
5.2k views
in Java FTP by
Once a FTPClient establishes a connection, is there a way for it to check if the server supports PASV and fall back to PORT otherwise. I've had an issue where one FTP server (MS) when establishing a PASV PUT, just ends up disconnecting me everytime because it does not support PASV.

Thanks!

1 Answer

0 votes
by (162k points)
Does it throw an exception during the put?

If so, you could catch the exception and attempt to retry the put, first setting the mode to PORT.

Once a FTPClient establishes a connection, is there a way for it to check if the server supports PASV and fall back to PORT otherwise. I've had an issue where one FTP server (MS) when establishing a PASV PUT, just ends up disconnecting me everytime because it does not support PASV.

Thanks!

Categories

...