client: Override IP used in PASV connect
|Reported by:||puddle||Owned by:||Alexander Schuch|
|Keywords:||Cc:||puddle, Alexander Schuch|
|Component version:||Operating system type:|
|Operating system version:|
Servers behind NAT may give the wrong IP when they give
the host/port info in their response to the client PASV.
I just experimented, and I can simply substitute the
original server IP instead of using the one the server
passed in the response.
I think this would make a nice option.
I'm seeing this matter when the server's NAT gateway
can fix the outbound info in unencrypted channel (so I
have no problem there), but the server's NAT gateway
can't fix it in encrypted channel, so I can't connect
unless I hack the code in CFtpControlSocket::List to
I think it would be nifty to have an Advanced option
"Use original Server IP in PASV connection"
for this case, to avoid having to hack in the cpp code
I might be able to submit a code patch for it, if I can
(a) figure out the original server IP (which shouldn't
be hard, but when I was hacking, I knew the server IP
and just put in a hardcoded one, so I didn't solve this
part), and (b) figure out the GUI stuff (probably much
the harder part).
circa lines 1306-1309
pData->host = "220.127.116.11"; hack, should fetch
original server IP
if PASV create the socket & initiate outbound
data channel connection