cURL / Mailing Lists / curl-library / Single Mail


[PATCH] FTP EPSV handling on IPv6

From: Vojtěch Král <>
Date: Wed, 07 Jan 2015 22:08:10 +0100

   I'm sending a patch that fixes this bug:

TL;DR: when an EPVS reply comes from an FTP server on a link-local IPv6
address, curl won't pass the scope ID necessary for a link-local IPv6
connection to the new connection info.

For more information see my bugreport: (Note that I initially
incorrectly blamed PASV handling, see later comment.)

Someone also seems to have ran into the same problem a while back here:

The attached patch fixes the problem in a very simple way: In EPSV
handling, the original hostname is simply copied and resolved again when
the data connection is being established. It is the same code as if
there was a proxy so I simply merged the two branches. I'm not sure it's
okay to have the hostname resolved again - let me know if not.

(Also, it might be a good idea not to fallback to PASV on IPv6 since
PASV is technically illegal on IPv6.)

Best Regards,
Vojtech Kral

List admin:

Received on 2015-01-07