Hi Alex The FTPClient library isn't capable of FTP transactions thru a proxy at present (unless there is some external trickery that I'm not aware of that would facilitate this). This wouldn't require a huge amount of extra effort - I've looked at how Sun have implemented it for their internal JDK FTP client, but unfortunately it's not something that's there now.
Rory "Jakarta Commons Developers List" <[email protected]> wrote: > > hi all, > i am developing a ftpclient.java using commons-net-1.4.1.jar library. > > it works fine if not via proxy server. it can login the ftp account > and list files. But my target is to connect the ftp server via proxy > server. > > by following the Paul Buchana > here: > http://marc.theaimsgroup.com/?l=jakarta-commons-user&m=107877944806547&w=2 > i add the following two lines before the connect line > System.getProperties().put( "socksProxyPort", "7200"); > System.getProperties().put( "socksProxyHost" ,"25.10.22.11"); // > 25.10.22.11 is proxy server with port 7200 > > prv_cls_ftpclient.connect("25.10.22.13",21); <-- target ftp server to > connect, it can connect to ftp server if comment the above > System.getProperties lines > reply = prv_cls_ftpclient.getReplyCode(); > System.out.print("Print log reply code"+reply); > if(!FTPReply.isPositiveCompletion(reply)) { > prv_cls_ftpclient.disconnect(); > System.err.println("FTP server refused connection."); > System.exit(1); > } > System.out.print("Print log Connection"); > prv_cls_ftpclient.login("user", "pass"); > > but it stop at the .connect line without further proceed, what's wrong > with my code. any miss setting i should did?? or is it possible to a > ftp server via a proxy server? > > I am using a lite proxy server called Binary Proxy Server BPSLite.exe on > windows > -- > Regards, > Alex > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > ----------------------------------------------------------------- Find the home of your dreams with eircom net property Sign up for email alerts now http://www.eircom.net/propertyalerts --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
