From 120d18103d823f3d70f58a4291831400a36d0465 Mon Sep 17 00:00:00 2001 From: Thomas Wolf Date: Wed, 8 Aug 2018 13:43:17 +0200 Subject: Ensure that JSch knows HostKeyAlgorithms ssh-rsa and ssh-dss Without these registrations, JSch's up-front checks which algorithms are available at all fail if the ssh config explicitly sets only these algorithms. Bug: 537790 Change-Id: I1e088447c0ce68aea1bb7bf573d7a1e78713b019 Signed-off-by: Thomas Wolf --- .../src/org/eclipse/egit/core/EclipseSshSessionFactory.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/org.eclipse.egit.core/src/org/eclipse/egit/core/EclipseSshSessionFactory.java b/org.eclipse.egit.core/src/org/eclipse/egit/core/EclipseSshSessionFactory.java index 0150898ae0..0b830ad7f5 100644 --- a/org.eclipse.egit.core/src/org/eclipse/egit/core/EclipseSshSessionFactory.java +++ b/org.eclipse.egit.core/src/org/eclipse/egit/core/EclipseSshSessionFactory.java @@ -35,6 +35,8 @@ class EclipseSshSessionFactory extends JschConfigSessionFactory { @Override protected JSch createDefaultJSch(FS fs) throws JSchException { + JSch.setConfig("ssh-rsa", JSch.getConfig("signature.rsa")); //$NON-NLS-1$ //$NON-NLS-2$ + JSch.setConfig("ssh-dss", JSch.getConfig("signature.dss")); //$NON-NLS-1$ //$NON-NLS-2$ // Forcing a dummy session to be created will cause the known hosts // and configured private keys to be initialized. This is needed by // our parent class in case non-default JSch instances need to be made. -- cgit v1.2.3