We have moved to a new Sailfish OS Forum. Please start new discussions there.
7

[BUG] SSH Protocol error with latest SDK (Qt-Creator 3.1.2) for Linux

asked 2015-03-19 17:31:48 +0300

flywheel gravatar image

I was earlier notified by the Qt-Creator of the SDK, that an update was available, and as usual it ended up with having to uninstall the whole and reinstall - a pain n the * but I'll live.

But when trying to pair the Jolla with the SDK (New Mer ARM Device Setup->Public Key Deployment->Connection) - when trying to test the connection, I get the following status:

"SSH Protocol error: Server and client capabilities don't match. Client list was: aes128-cbc,3des-cbc. Server list was aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com,chacha20-poly1305@openssh.com."

The IP, port, username, password should be fine and the Generate new SSH keys has been enabled (default). It works perfectly fine with the emulator.

Anyone able to figure this one out ?

edit retag flag offensive close delete

Comments

Indeed I had similar issues when connecting to the emulator (bizarre) via ssh after the update. I know use

ssh -p 2223 -i ~/SailfishOS/vmshare/ssh/private_keys/SailfishOS_Emulator/nemo nemo@localhost

instead of ssh -p 2223 nemo@localhost.

Which seems to work but obviously there has been some changes. Last time I connected Jolla via ssh it needed to agree to add a new ssh key. I don't know what went wrong with that last SDK update, but there is something...

MikErk ( 2015-03-19 18:31:09 +0300 )edit

The ssh library used in SailfishOS IDE offers two ciphers: aes128-cbc and 3des-cbc. Those match to your client list as expected. By a quick look there haven't been configuration changes on the device side, so on 1.1.2.16 the server list should be: "aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se". The list of ciphers offered by the Openssh server can be changed for example by modifying the "Ciphers" line in "/etc/ssh/sshd_config", so first check that for changes. Normal installation uses the default cipher list and doesn't specify any ciphers in that config file.

Jare ( 2015-03-27 19:15:38 +0300 )edit

I have the same problem with actual sdk Beta-1506. Any solutions or workarounds that work? I recognized that after updating my Jolla to 1.1.6.27, Warehouse updated my openssh stuff. Could this the problem?

Black Sheep ( 2015-06-20 18:25:36 +0300 )edit

It is now august, I just installed the SDK afresh today. I get the message:

SSH Protocol error: Server and client capabilities don't match. Client list was: aes128-cbc,3des-cbc. Server list was aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com,chacha20-poly1305@openssh.com.

My PC's output for ssh -Vv is OpenSSH_6.6.1p1 Ubuntu-2ubuntu2, OpenSSL 1.0.1f 6 Jan 2014

My phone's output for ssh -Vv is OpenSSH_6.8p1, OpenSSL 1.0.2 22 Jan 2015

My phone is too new? I have Aaslakkajärvi (1.1.6.27)

Bokkie ( 2015-08-10 02:12:13 +0300 )edit
2

@Bokkie: In 1.1.6.27 the official Openssh package version is 5.6p1+git9. Your version on the phone is much newer than this, which means that you've probably gotten it from e.g. Openrepos. The newer version has a different default cipher list, which causes the issue. Please reinstall the Openssh package from the official repository.

Jare ( 2015-08-10 12:02:30 +0300 )edit

4 Answers

Sort by » oldest newest most voted
1

answered 2015-07-06 13:18:21 +0300

inte gravatar image

Same problem here :(

edit flag offensive delete publish link more

Comments

2

EDIT: It appears this problem was related to installing openssl from Openrepos. At least no problems any more since I reverted back to the genuine version.

inte ( 2015-09-09 16:25:55 +0300 )edit

TuTu APK Android can be updated daily so you can find all the updated versions, you can get modified games like TuTuApp Pokemon Go APK for Android devices.

Jones218 ( 2018-09-06 08:42:16 +0300 )edit
1

answered 2015-09-20 16:57:13 +0300

blacksailer gravatar image

I've same issue. Just deinstalled openssl from NIelDk, And everyting perfect! Windows 7.

edit flag offensive delete publish link more

Comments

Thanks for the pointer, I ran into the exact same situation with my tablet - reverting openssh (and openssh-client, openssh-server) to the official versions made the SDK happy again!

jwalck ( 2016-10-18 11:59:41 +0300 )edit
0

answered 2018-09-05 23:51:30 +0300

jpelfrene gravatar image

I'm getting a similar error message on my newly installed SDK: Error connecting to "Sailfish OS Emulator" virtual machine: Failed to establish SSH conection with virtual machine "Sailfish OS Emulator": 3 SSH Protocol error: Server and client capabilities don't match. Client list was: ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-rsa,ssh-dss. Server list was ssh-ed25519.

I can start the emulator and from the Ubuntu terminal I can connect with it over ssh using following command: ssh -p 2223 -i ~/SailfishOS/vmshare/ssh/private_keys/SailfishOS_Emulator/nemo nemo@localhost

But so far I can't get the SDK program to connect with the emulator. How is this possible? And which settings to check?

edit flag offensive delete publish link more

Comments

@jpelfrene Is this the SDK version 1804? Which version of Ubuntu is it? Anything special in your ~/.ssh/config? Try running Qt Creator with clean configuration if it helps - mv ~/.config/SailfishOS-SDK{,_}. If this does not help, paste the output of awk '{print $6}' "/proc/$(pgrep qtcreator)/maps" |sort -u please.

martyone ( 2018-09-10 08:31:46 +0300 )edit

@martyone Hi, thanks for the help. It is still giving me the same error. To answer your questions:

  1. SDK 1804, Ubuntu 16.04.5 LTS, Virtualbox 5.1.38
  2. I don't have the file ~/.ssh/config and have kept /etc/ssh/ssh_config in its default form
  3. I have executed the command and started the QtCreator with Sailfish SDK up again, but it brought no change; still fails to connect between SDK and the emulator.
  4. The output is quite long, so I put it here: link text Hope it'll help to sort it out; I'd love to get it going.
jpelfrene ( 2018-09-11 14:24:20 +0300 )edit

@jpelfrene The output you provided looks good at first glance. Before I dig deeper into it, did you already tried if the recently released SDK 1807 changed anything in this respect?

martyone ( 2018-09-24 07:38:11 +0300 )edit

@martyone Thanks! I will install the new SDK and see. In the meantime, I just hooked up my Jolla 1 instead of the emulator and already made the first working version of a drum machine app. And it looks and sounds great ;)

jpelfrene ( 2018-09-24 11:31:39 +0300 )edit

@jpelfrene Could you please check if you can reproduce this after upgrading to the latest SDK?

martyone ( 2018-11-20 13:54:33 +0300 )edit
0

answered 2018-10-09 20:02:36 +0300

Alfonso gravatar image

Solved - you may have to fiddle with the /etc/ssh directory of the SailfishOS virtual machines.

I had the same problem with SailfishOS SDK 1807 (qtcreator 4.6.2) and emulator virtual machine running on Ubuntu 18.04:

Error connecting to "Sailfish OS Emulator" virtual machine: Failed to establish SSH conection with virtual machine "Sailfish OS Emulator": 3 SSH Protocol error: Server and client capabilities don't match. Client list was: ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-rsa,ssh-dss.

I entered the virtual machine with the usual command-line:

ssh -p 2223 -i ~/SailfishOS/vmshare/ssh/private_keys/SailfishOS_Emulator/nemo nemo@localhost and looked around.

It appears that at installation time two files under /etc/ssh were truncated to zero lenght: ssh_host_rsa_key and ssh_host_rsa_key.pub

and that was the reason why the ssh server of the virtual machine refused the ssh client from qtcreator - yet it accepted normally the ssh client from Ubuntu command-line: the files ssh_host_ed25519_key and ssh_host_ed25519_key.pub in that same /etc/ssh directory were OK (411 and 99 bytes respectively).

Thus I just had to erase those two zero-length files, and everything ran fine (that is, the emulator ssh server will only rely on ed25519 keys, instead of checking rsa keys first).

Note: I guess uninstalling and reinstalling SFOS SDK could have worked as well.

edit flag offensive delete publish link more

Comments

@Alfonso, could you please check if you can reproduce this after upgrading to the latest SDK?

martyone ( 2018-11-20 13:53:45 +0300 )edit
Login/Signup to Answer

Question tools

Follow
5 followers

Stats

Asked: 2015-03-19 17:31:48 +0300

Seen: 2,647 times

Last updated: Oct 09 '18