The FTP classes uses passive mode when listing files on the server.
Passive mode means a port other than the default FTP port is used to
exchange data. Is it possible the second port is not open through the
firewall? I had some confidence that this was it until I realized put also
uses passive mode. Why would put work when list doesn't? Could be the ftp
server is set up to handle get/put via passive mode, but not list?
David Wall
AS/400 Toolbox for Java
"Bennion, Dick" <Dick_Bennion@AFCC.com>@midrange.com on 01/09/2001 11:52:33
AM
Please respond to JAVA400-L@midrange.com
Sent by: owner-java400-l@midrange.com
To: "'JAVA400-L@midrange.com'" <JAVA400-L@midrange.com>
cc:
Subject: JTOPEN FTP Through a Firewall question
I am using the jtopen version of the toolkit and I am attempting to
communicate with a number of sites that are outside our firewall. I am
able
to get and put files, but I am having a problem getting a listing of the
files in the current working directory. I am using the FTP class.
If I am accessing the server directory without going through the firewall
everything goes perfectly.
When I attempt ls through the firewall the list of files returned is always
empty. The message returned is "226 Listing completed."
I found some documentation that talks about using Rbind() from the client
to
establish an inbound connection.
What should I do to be able to get a list of the files in a directory on
the
server? All help would be much appreciated.
> Dick Bennion
+---
| This is the JAVA/400 Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner: joe@zappie.net
+---
+---
| This is the JAVA/400 Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner: joe@zappie.net
+---