This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Albert-Jan Nijburg
Recipients Albert-Jan Nijburg, georg.brandl, giampaolo.rodola, pitrou
Date 2017-10-06.13:53:48
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1507298029.37.0.213398074469.issue7167@psf.upfronthosting.co.za>
In-reply-to
Content
I understand the standpoint that the server is configured incorrectly, and I see why this might not be the best solution to the problem. 

But not everyone owns the ftp server they're connecting to. And the `EPSV` command often doesn't include the ipaddress, so many ftp clients are now using `EPSV` to circumvent the problem of the ip address and the dns address not matching up.

Would it not be sensible to give users the option to use just `EPSV` so people can connect to incorrectly configured ftp servers. Although this can't be a massive issue for people, because I'd expect this bug to be a bit more active. 

Curl for example defaults to EPSV and then falls back to PASV when it's not supported by the server. The ftp client in macos also defaults to EPSV. I'm not sugesting we do that, but it would be nice if we could tell the ftplib to use EPSV without it being a ipv6 address. 

In our specific situation, we have an ftp server that has a public and a private endpoint on different ip addresses, and the ftp server is configured to use the public ip address, but if we want to access in internally we need to use the internal host and ip address. This causes `ftplib` not to work, because the ips don't line up. 

We currently monkey patch ftplib to use `EPSV`, but it does state that you need to use EPSV when you connect with ipv6 it doesn't say you can't use it when you use ipv4.
History
Date User Action Args
2017-10-06 13:53:49Albert-Jan Nijburgsetrecipients: + Albert-Jan Nijburg, georg.brandl, pitrou, giampaolo.rodola
2017-10-06 13:53:49Albert-Jan Nijburgsetmessageid: <1507298029.37.0.213398074469.issue7167@psf.upfronthosting.co.za>
2017-10-06 13:53:49Albert-Jan Nijburglinkissue7167 messages
2017-10-06 13:53:48Albert-Jan Nijburgcreate