Hi all, 

         I tried JSch to scp a file to a VMware ESX 3.0 host and the session 
could not be established because of  

 

Algorithm negotiation fail 

        at com.jcraft.jsch.Session.receive_kexinit(Unknown Source) 

        at com.jcraft.jsch.Session.connect(Unknown Source) 

        at com.jcraft.jsch.Session.connect(Unknown Source) 

 

Here is the output of ssh -v <host> 

 

 

OpenSSH_3.5p1, SSH protocols 1.5/2.0, OpenSSL 0x009060df 

debug1: Reading configuration data /etc/ssh/ssh_config 

debug1: Applying options for * 

debug1: Rhosts Authentication disabled, originating port will not be trusted. 

debug1: ssh_connect: needpriv 0 

debug1: Connecting to vmmdev1.ind.hp.com [15.154.69.89] port 22. 

debug1: Connection established. 

debug1: identity file /root/.ssh/identity type -1 

debug1: identity file /root/.ssh/id_rsa type -1 

debug1: identity file /root/.ssh/id_dsa type -1 

debug1: Remote protocol version 2.0, remote software version OpenSSH_3.6.1p2 

debug1: match: OpenSSH_3.6.1p2 pat OpenSSH* 

debug1: Enabling compatibility mode for protocol 2.0 

debug1: Local version string SSH-2.0-OpenSSH_3.5p1 

debug1: SSH2_MSG_KEXINIT sent 

debug1: SSH2_MSG_KEXINIT received 

debug1: kex: server->client aes128-cbc hmac-md5 none 

debug1: kex: client->server aes128-cbc hmac-md5 none 

debug1: SSH2_MSG_KEX_DH_GEX_REQUEST sent 

debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP 

debug1: dh_gen_key: priv key bits set: 132/256 

debug1: bits set: 1632/3191 

debug1: SSH2_MSG_KEX_DH_GEX_INIT sent 

debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY 

debug1: Host 'vmmdev1.ind.hp.com' is known and matches the RSA host key. 

debug1: Found key in /root/.ssh/known_hosts:4 

debug1: bits set: 1592/3191 

debug1: ssh_rsa_verify: signature correct 

debug1: kex_derive_keys 

debug1: newkeys: mode 1 

debug1: SSH2_MSG_NEWKEYS sent 

debug1: waiting for SSH2_MSG_NEWKEYS 

debug1: newkeys: mode 0 

debug1: SSH2_MSG_NEWKEYS received 

debug1: done: ssh_kex2. 

debug1: send SSH2_MSG_SERVICE_REQUEST 

debug1: service_accept: ssh-userauth 

debug1: got SSH2_MSG_SERVICE_ACCEPT 

debug1: authentications that can continue: 
publickey,password,keyboard-interacti 

ve,hostbased 

debug1: next auth method to try is publickey 

debug1: try privkey: /root/.ssh/identity 

debug1: try privkey: /root/.ssh/id_rsa 

debug1: try privkey: /root/.ssh/id_dsa 

debug1: next auth method to try is keyboard-interactive 

debug1: authentications that can continue: 
publickey,password,keyboard-interacti 

ve,hostbased 

debug1: next auth method to try is password 

 

 

 

Also the sshd_config file on the ESX 3.0 host is : 

 

#       $OpenBSD: sshd_config,v 1.59 2002/09/25 11:17:16 markus Exp $ 

 

# This is the sshd server system-wide configuration file.  See 

# sshd_config(5) for more information. 

 

# This sshd was compiled with PATH=/usr/local/bin:/bin:/usr/bin 

 

# The strategy used for options in the default sshd_config shipped with 

# OpenSSH is to specify options with their default value where 

# possible, but leave them commented.  Uncommented options change a 

# default value. 

 

#Port 22 

Protocol 2 

#ListenAddress 0.0.0.0 

#ListenAddress :: 

 

# HostKey for protocol version 1 

#HostKey /etc/ssh/ssh_host_key 

# HostKeys for protocol version 2 

#HostKey /etc/ssh/ssh_host_rsa_key 

#HostKey /etc/ssh/ssh_host_dsa_key 

 

# Lifetime and size of ephemeral version 1 server key 

#KeyRegenerationInterval 3600 

#ServerKeyBits 768 

 

# Logging 

#obsoletes QuietMode and FascistLogging 

SyslogFacility AUTH 

LogLevel VERBOSE 

 

# Authentication: 

 

#LoginGraceTime 120 

PermitRootLogin yes 

#StrictModes yes 

 

#RSAAuthentication yes 

#PubkeyAuthentication yes 

#AuthorizedKeysFile     .ssh/authorized_keys 

 

# possible, but leave them commented.  Uncommented options change a 

# default value. 

 

#Port 22 

Protocol 2 

#ListenAddress 0.0.0.0 

#ListenAddress :: 

 

# HostKey for protocol version 1 

#HostKey /etc/ssh/ssh_host_key 

# HostKeys for protocol version 2 

#HostKey /etc/ssh/ssh_host_rsa_key 

#HostKey /etc/ssh/ssh_host_dsa_key 

 

# Lifetime and size of ephemeral version 1 server key 

#KeyRegenerationInterval 3600 

#ServerKeyBits 768 

 

# Logging 

#obsoletes QuietMode and FascistLogging 

SyslogFacility AUTH 

LogLevel VERBOSE 

 

# Authentication: 

 

#LoginGraceTime 120 

PermitRootLogin yes 

#StrictModes yes 

 

#RSAAuthentication yes 

#PubkeyAuthentication yes 

#AuthorizedKeysFile     .ssh/authorized_keys 

 

# rhosts authentication should not be used 

#RhostsAuthentication no 

# Don't read the user's ~/.rhosts and ~/.shosts files 

#IgnoreRhosts yes 

# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts 

#RhostsRSAAuthentication no 

# similar for protocol version 2 

HostbasedAuthentication yes 

 

# Change to yes if you don't trust ~/.ssh/known_hosts for 

HostbasedAuthentication yes 

#IgnoreUserKnownHosts no 

 

# To disable tunneled clear text passwords, change to no here! 

#PasswordAuthentication yes 

#PermitEmptyPasswords no 

 

# Change to no to disable s/key passwords 

#ChallengeResponseAuthentication yes 

 

# Kerberos options 

#KerberosAuthentication no 

#KerberosOrLocalPasswd yes 

#KerberosTicketCleanup yes 

 

#AFSTokenPassing no 

 

# Kerberos TGT Passing only works with the AFS kaserver 

#KerberosTgtPassing no 

 

# Set this to 'yes' to enable PAM keyboard-interactive authentication 

# Warning: enabling this may bypass the setting of 'PasswordAuthentication' 

#PAMAuthenticationViaKbdInt no 

 

#X11Forwarding no 

#X11DisplayOffset 10 

#X11UseLocalhost yes 

#PrintMotd yes 

#PrintLastLog yes 

#KeepAlive yes 

#UseLogin no 

#UsePrivilegeSeparation yes 

#PermitUserEnvironment no 

#Compression yes 

 

#MaxStartups 10 

# no default banner path 

#Banner /some/path 

#VerifyReverseMapping no 

#ShowPatchLevel no 

 

# override default of no subsystems 

Subsystem       sftp    /usr/libexec/openssh/sftp-server 

Ciphers aes256-cbc,aes128-cbc 

 

 

I am guessing that some tweaking to the config file should solve the issue. 

Can you please throw some light on this??? Or is this configuration not 
supported??? 

 

Thanks, 

Pal
                        



      ___________________________________________________________
Yahoo! Answers - Got a question? Someone out there knows the answer. Try it
now.
http://uk.answers.yahoo.com/ 
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
JSch-users mailing list
JSch-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jsch-users

Reply via email to