commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "E. Dominguez" <e.doming...@ticino.com>
Subject Re: [NET] ftp requires 2 passwords (a proxy password)
Date Fri, 03 Feb 2006 19:24:42 GMT
now i have a doubt...
should i use the sendCommand( "password" ) or the pass( "password" ) to 
pass the second requested password?

e.dominguez wrote:

>Is it correct an approach like:
>[CODE]
>//(...)
>FtpClient myc = new FtpClient( ); //init ftpclient
>myc.connect( "proxy.acme.ch", 21 ); //connect to server
>myc.login( "far-username@ftp.far-server.ch proxy_tech_userename", "far_password" ); //login
>if( myc.getReplyCode() == FtpReply.CODE_332 ){ //check if reply is 332
>	myc.sendCommand( "proxy_tech_password" );
>}
>//(...)
>[/CODE]
>Can this be a possible solution? Sorry that I ask but I actually can't test... ;-)
>- - - - - - - - - - - - - - - - -
>On Fri, 3 Feb 2006 08:58:44 +0100
>"e.dominguez" <e.dominguez@ticino.com> wrote:
>  
>
>>Hi.
>>I trying to connect to an ftp server through a proxy by a customer.
>>the enterprise has a proxy server, so for the connection I have received this 'connection
example' (it's in german but i think is understandable):
>>
>>Sobald Sie die UserID und das Passwort für den Technical Account erhaltet haben,
müssen Sie folgende Syntax anwenden:
>>(Beispiel basiert auf W32 FTP-Client).
>> 
>>c:\>ftp proxy.acme.ch
>>Verbindung mit proxy.acme.ch wurde hergestellt.
>>220 Blue Coat FTP Service
>>Benutzer (proxy.acme.ch:(none)): far-username@ftp.far-server.ch proxy_tech_userename
>>331 Enter password.
>>Kennwort: far_password
>>332 Enter proxy password.
>>Kennwort: proxy_tech_password
>>Hier nochmal die technische Syntax, die angewendet werden soll:
>>Usage: USER username@hostname proxyusername
>>       PASS password
>>       ACCT proxypassword
>>
>>How can i pass the second password (332/ACCT) as connection property for my pgm?
>>
>>Thanx. Best regards. e.dominguez
>>    
>>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>
>  
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message