SFTP Connection - JschException Algorithm negotiation fail

1
I've had a SFTP connection set up for the last few weeks and everything worked perfectly. However since a few days ago it is not working anymore (no interference from my side, no deployment/settings changing) and I keep receiving the following error: Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (1/56) com.jcraft.jsch.JSchException Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (2/56) Algorithm negotiation fail Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (3/56) com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: JschException occured when opening sftpSession. Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (4/56) at com.mendix.core.component.InternalCore.execute(SourceFile:274) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (5/56) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (6/56) Caused by: Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (7/56) com.mendix.systemwideinterfaces.MendixRuntimeException: JschException occured when opening sftpSession. Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (8/56) at com.mendix.core.actionmanagement.ActionManager.executeSync(SourceFile:210) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (9/56) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (10/56) Caused by: Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (11/56) JschException occured when opening sftpSession. Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (12/56) at sftpconnection.helpers.HandleFileSftp.createSFTPChannel(HandleFileSftp.java:42) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (13/56) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (14/56) Caused by: Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (15/56) Algorithm negotiation fail Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (16/56) at com.jcraft.jsch.Session.receive_kexinit(Session.java:552) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (17/56) at com.jcraft.jsch.Session.connect(Session.java:299) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (18/56) at com.jcraft.jsch.Session.connect(Session.java:162) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (19/56) at sftpconnection.helpers.HandleFileSftp.createSFTPChannel(HandleFileSftp.java:36) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (20/56) at sftpconnection.helpers.HandleFileSftp.getFileListFromSFTP(HandleFileSftp.java:178) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (21/56) at sftpconnection.actions.GetFileListFromSFTPLocation.executeAction(GetFileListFromSFTPLocation.java:41) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (22/56) at sftpconnection.actions.GetFileListFromSFTPLocation.executeAction(GetFileListFromSFTPLocation.java:21) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (23/56) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:53) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (24/56) at com.mendix.core.actionmanagement.CoreAction.doCall(SourceFile:291) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (25/56) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:276) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (26/56) at com.mendix.core.actionmanagement.ActionManager.executeSync(SourceFile:199) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (27/56) at com.mendix.core.component.InternalCore.execute(SourceFile:262) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (28/56) at com.mendix.hI.execute(SourceFile:42) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (29/56) at com.mendix.ir.a(SourceFile:47) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (30/56) at com.mendix.iq.a(SourceFile:193) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (31/56) at com.mendix.iq.executeAction(SourceFile:148) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (32/56) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:53) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (33/56) at com.mendix.core.actionmanagement.CoreAction.doCall(SourceFile:291) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (34/56) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:276) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (35/56) at com.mendix.core.actionmanagement.ActionManager.executeSync(SourceFile:199) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (36/56) at com.mendix.core.component.InternalCore.execute(SourceFile:262) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (37/56) at com.mendix.jd.a(SourceFile:135) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (38/56) at com.mendix.pn$e.apply$mcV$sp(SourceFile:299) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (39/56) at com.mendix.pn$e.apply(SourceFile:290) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (40/56) at com.mendix.pn$e.apply(SourceFile:290) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (41/56) at com.mendix.core.session.Worker$$anonfun$receive$3$$anonfun$2$$anon$1.execute(SourceFile:158) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (42/56) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(SourceFile:36) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (43/56) at com.mendix.core.session.Worker$$anonfun$receive$3$$anonfun$2.apply(SourceFile:160) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (44/56) at scala.util.Try$.apply(Try.scala:191) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (45/56) at com.mendix.core.session.Worker$$anonfun$receive$3.applyOrElse(SourceFile:154) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (46/56) at akka.actor.Actor$class.aroundReceive(Actor.scala:465) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (47/56) at com.mendix.core.session.Worker.aroundReceive(SourceFile:147) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (48/56) at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (49/56) at akka.actor.ActorCell.invoke(ActorCell.scala:487) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (50/56) at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:238) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (51/56) at akka.dispatch.Mailbox.run(Mailbox.scala:220) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (52/56) at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:393) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (53/56) at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (54/56) at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (55/56) at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979) Nov 26 16:29:47 127.0.0.1 tr10000: ERROR - TestLog SFTP: (56/56) at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
asked
5 answers
1

Niels,

Digging some deeper. Found this post: http://stackoverflow.com/questions/6263630/jschexception-algorithm-negotiation-fail

There are a couple of places that SSH clients and servers try and agree on a common implementation. Two I know of are encryption and compression. The server and client produce a list of available options and then the best available option in both lists is chosen.

If there is no acceptable option in the lists then it fails with the error you got.

Not yet a sollution though why they are unable to agree on which encryptiion/compression to use.

Regards,

Ronald

[EDIT1]

Found this link http://blog.millard.org/2014/11/repair-synology-dsm51-for-use-as-linux.html Testing now.

[EDIT2] The link of Edit1 works. We now can SFTP again. I suggest you let your client do the steps. Beware the location where to put the text is crucial. Do it exactly as stated.

answered
0

We have a working connection with our SFTP server on a Synology, but this does include a keypair. To get this to work I can recommend the following tutorial(s):

http://tinyurl.com/lngl8zr

You should SSH into the Synology and change some files (all explained in the tutorials). Only then this SFTP is really S(ecure).

answered
0

Got confirmation from the other party that they have completed all the steps that you have suggested. There is now a Home folder on the Synology server which has both the known_hosts file and a public key (generated by me with puttygen)

The known hosts file consists of a single line:

192.168.xx.xx ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAkgyBI7tBKmQ+XkuFufUTeYJKiXBHZGZ44s8y3233XswD5JS/p/k+pAxM+fNn127s6hnX7oa/EHtnnMMvFof5MzsQSB7zyg3nDPgbX/IZG3gUMy3L7JzZexZagSRGSxn6LSwljclMx7j/ulSEeLL4ANsoIuDAYBlmkloqk/dLmPx8UvdlG3DPw/hMHtjkAa6ayi6sDDz76r23PI5AOEtawXeUiLD8X+sNUoibiMi8NX7TXBGAfh9gwP/E56B1Jxp0o4folHmiCxY2ZCH0epm+kX6P6JOe0F36xRYXfh8vmyZN4nDC9/UVnUgDjaBmMf3eHO1hjWjbv2PqICemTqhS2w==

I've generated my own private key and use the same known_hosts file in the settings. When trying to connect to the SFTP I get the following error. Is there any error you see in these steps or is there still something wrong in the configuration possibly?

com.jcraft.jsch.JSchException

Algorithm negotiation fail com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: JschException occured when opening sftpSession. at com.mendix.core.component.InternalCore.execute(InternalCore.java:274)

Caused by: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: JschException occured when opening sftpSession. at com.mendix.core.actionmanagement.ActionManager.executeSync(ActionManager.java:217)

Caused by: com.mendix.systemwideinterfaces.MendixRuntimeException: JschException occured when opening sftpSession. at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:43)

Caused by: JschException occured when opening sftpSession. at sftpconnection.helpers.HandleFileSftp.createSFTPChannel(HandleFileSftp.java:42)

answered
0

 

jce_policy-8.zip

http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html

 

answered
0

Just overwrite the files with the ones in the ZIP file

Tested already!

answered