The ASCII transfer mode in Rebex SFTP is little bit more complex than in FTP. In FTP, the transformation is done by the server. In SFTP, it is done by the client.
The behavior of Rebex SFTP depends on whether it's possible to determine the OS type of the SFTP server. If there is a Unix-like OS, all CRLF (0D0A) sequences are converted to LF (0A) during upload and all LF (0A) sequences are converted to CRLF (0D0A) during download.
If it's not possible to to determine whether there is a Unix-like OS (this is often the case with SFTP v3), no conversion is done. However, you can still force it by manually setting
ServerType property to
client.ServerType = SftpServerType.Unix
(where "client" is an instance of Sftp)
This needs to be done in addition to setting
TransferType to ASCII.