-1

I am having an issue with connecting to an SFTP server.

On the same computer when I access SFTP via application A, I am given access, but when I use application B, I have no access.

In my server logs I can see that when I connect via application B I receive following error:

Did not receive identification string from...

Port 22 is open and works fine.

I was able to connect to FTP via port 21 on both applications and both applications support port 22.

2
  • 2
    It would be helpful to know the applications you're using, both for the server and the clients.
    – zymhan
    Jan 20, 2015 at 19:14
  • 2
    It is not clear from your question which protocol you are trying to use: ftp, sftp, or ftps.
    – kasperd
    Jan 20, 2015 at 19:40

1 Answer 1

1

From the server log record ("Did not receive identification string from..."), I assume you are connecting to an SSH/SFTP port (22) using an FTP protocol.

Make sure the application B really supports SSH/SFTP and that you selected that protocol in its configuration (as opposite to entering port 22, but using FTP protocol).

Make sure you did not confuse SFTP with FTPS (FTP over TLS/SSL).


When opening an SSH/SFTP connection, the server sends its identification string (like "SSH-2.0-OpenSSH_5.3") to what the SSH/SFTP client responds with its identification string (like "SSH-2.0-WinSCP_release_5.6.5").

If you connect to an SSH/SFTP server with an FTP client, the FTP client expects an FTP welcome message and keeps waiting for its ending line before sending any commands. It gets the SSH identification string instead. Depending on the FTP client implementation, it either aborts upon recognizing that the SSH identification string is not valid FTP message; or timeouts waiting for the ending line of the FTP welcome message. Of course, unless the SSH/SFTP server happens to timeout first, waiting for client's SSH identification string. What probably happened in your case.


I was able to reproduce your problem by connecting to port 22 of OpenSSH SFTP server using WinSCP client configured to use FTP protocol (but SFTP port 22).


It's confusing that you tagged your question with , while the log record ("Did not receive identification string from...") is produced by OpenSSH server.

1
  • yes, i should have explained initial question better, proftpd is a server side application that i used to handle FTP Jan 20, 2015 at 22:35

Not the answer you're looking for? Browse other questions tagged .