Ticket #4819 enhancement new
Add FTP support for REST and APPE
|Reported by:||eternicode||Owned by:|
Currently, the FTP server doesn't support the FTP REST command. Each incoming command is read, and pauseProducing is called before the command is processed. No other commands are read until the current command is finished.
Clients (I tested with filezilla) send a REST command after a PASV command and then wait for a response before making the DTP connection. FTP.ftp_PASV, however, waits for a DTP connection before resumeProducing is called (effectively). This would result in a deadlock between the two, if the current implementation didn't return "Not Implemented" for REST.
I've posted my workaround for this on StackOverflow: Implementing REST in tiwsted.protocols.ftp.FTP?. This sets the reactor to call resumeProducing in the near future with callLater, canceling that call if the DTP connection is made in the interim. This allows a REST command to come in and be processed if necessary, or normal processing to go on if not.