Must be adapted to general SFTP transfer