Using Python 3.3.0 and this script:
from ftplib import FTP_TLS
ftps = FTP_TLS('xxx.xx.xxx.xx')
ftps.sendcmd('USER myuname')
ftps.sendcmd('PASS mypwd')
ftps.prot_p()
ftps.retrlines('LIST')
ftps.quit()
I get a connection failure due to timeout
>>> ================================ RESTART ================================
>>>
Traceback (most recent call last):
File "C:\Python33\fixFTP.py", line 2, in <module>
ftps = FTP_TLS('xxx.xx.xxx.xx')
File "C:\Python33\lib\ftplib.py", line 685, in __init__
FTP.__init__(self, host, user, passwd, acct, timeout, source_address)
File "C:\Python33\lib\ftplib.py", line 114, in __init__
self.connect(host)
File "C:\Python33\lib\ftplib.py", line 148, in connect
source_address=self.source_address)
File "C:\Python33\lib\socket.py", line 424, in create_connection
raise err
File "C:\Python33\lib\socket.py", line 415, in create_connection
sock.connect(sa)
TimeoutError: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond
But I can connect using a FileZilla client using these credentials. Any clue as to why it times out using a script, but not using Filezilla client?