I have been wasting more then an hour on this now and I think this should be really simple…
I have an azure website that allows me to connect and deploy to it using sftp. I can connect to it fine using FileZilla with the following settings:
- Host: The host given by azure portal
- Port: Empty
- Protocol: FTP – File Transfer Protocol
- Encryption: Require implicit FTP over TLS
- Logon Type: Normal
- User: The username given by Azure portal
- Password: The password given by Azure portal.
I don't want to connect to it using FileZilla though. I want to move files over using the command line. I have been trying to use sftp
, ftp
and scp
all without success. In the end they all fail with the following:
$ sftp -v -oPort=990 user@xxxxx.ftp.azurewebsites.windows.net
OpenSSH_7.9p1, OpenSSL 1.0.2r 26 Feb 2019
debug1: Reading configuration data /home/rg/.ssh/config
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 17: Applying options for *
debug1: Connecting to xxxxxxx.azurewebsites.windows.net [xxx.xxx.xxx.xxx] port 990.
debug1: Connection established.
debug1: identity file /home/rg/.ssh/id_rsa type 0
debug1: identity file /home/rg/.ssh/id_rsa-cert type -1
debug1: identity file /home/rg/.ssh/id_dsa type -1
debug1: identity file /home/rg/.ssh/id_dsa-cert type -1
debug1: identity file /home/rg/.ssh/id_ecdsa type -1
debug1: identity file /home/rg/.ssh/id_ecdsa-cert type -1
debug1: identity file /home/rg/.ssh/id_ed25519 type -1
debug1: identity file /home/rg/.ssh/id_ed25519-cert type -1
debug1: identity file /home/rg/.ssh/id_xmss type -1
debug1: identity file /home/rg/.ssh/id_xmss-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.9
ssh_exchange_identification: Connection closed by remote host
Connection closed.
Connection closed
I have tested that the OpenSSL version in use supports TLS 1.2. Neither is the host in the known hosts with another fingerprint.
I hope somebody can help me here.
Best Answer
FTP (over TLS) is not SFTP.
If you can connect using FTP with FileZilla, you have to use a command-line FTP client. Not SFTP client. Though not all command-line FTP clients support TLS encryption.