|Subject:||Re: FTP passive connection between client and server running in different local networks|
|Posted by:||Remy Lebeau \(Indy Team\) (email@example.com)|
|Date:||Wed, 16 Sep 2009|
"Tomasz B" <t.berg.REMO…@slican.pl> wrote in message
> Is it possible to force idFtp to alter ip address sending by server as a
> respond on PASV command when returning address is a private ip and
> idFtp.Host contains public ip?
If you are using Indy 10, you can set the TIdFTP.PassiveUseControlHost
property to True.
> My situation looks like:
> client (local ip) -- gateway* -- internet -- gateway2* -- server (local
It is the server's responsibility to provide the public IP of gateway2 in
its PASV reply. If the server is not doing that, then it is not configured
> FTP communication between IdFTp and IdFtpServer works if command
> port is in use (so it's possible to list directories).
TIdFTPServer has an OnPASVReply event available that allows your code to
control which IP is reported to the client.
Remy Lebeau (Indy Team)
FTP passive connection between client and server running in different local networks posted by Tomasz B on Wed, 16 Sep 2009