0 Replies Latest reply on Mar 30, 2016 2:00 AM by sharma_arun_se

    JSCH-0.1.44 Vs OpenSSH_6.6.1 issue : com.jcraft.jsch.JSchException: Session.connect: java.io.IOException: End of IO Stream Read

    sharma_arun_se

      We are facing below mentioned error once our client applied latest changes for SSH.

       

      • Is this problem with camel-ftp component?
      • Do we need to update camel-ftp component from our current 2.6 to latest?
      • Do Fuse/servicemix version (apache-servicemix-4.3.1-fuse-03-01) support latest camel-ftp component (say 2.16)?

       

      Current software version that we deployed are:

      1. apache-servicemix-4.3.1-fuse-01-09

      2. camel-ftp - 2.6.0

      3. jdk -1.6.0

       

      Connection String

      -------------------

      2016-03-21 12:27:01 | DEBUG | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | Using private keyfile: C:/TEST/Fuse/client/SFTP/client_ppk.openssh

      2016-03-21 12:27:01 | DEBUG | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | Using StrickHostKeyChecking: no

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> Connecting to xxx.xx.xx.xxx port 22

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> Connection established

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> Remote version string: SSH-2.0-OpenSSH_6.6.1

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> Local version string: SSH-2.0-JSCH-0.1.44

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr,arcfour,arcfour128,arcfour256

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> aes256-ctr is not available.

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> aes192-ctr is not available.

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> aes256-cbc is not available.

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> aes192-cbc is not available.

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> arcfour256 is not available.

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> SSH_MSG_KEXINIT sent

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> SSH_MSG_KEXINIT received

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> kex: server->client aes128-ctr hmac-sha1 none

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> kex: client->server aes128-ctr hmac-sha1 none

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> SSH_MSG_KEX_DH_GEX_REQUEST(1024<1024<1024) sent

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> expecting SSH_MSG_KEX_DH_GEX_GROUP

      2016-03-21 12:27:01 | INFO  | tenerContainer-1 | SftpOperations                   | 207 - org.apache.camel.camel-ftp - 2.6.0.fuse-01-09 | JSCH -> Disconnecting from xxx.xx.xx.xxx port 22

       

      Error Stack trace:

      2016-03-21 12:27:02 | ERROR | tenerContainer-1 | EndpointMessageListener          | 68 - org.apache.camel.camel-core - 2.6.0.fuse-01-09 | Caused by: [org.apache.camel.component.file.GenericFileOperationFailedException - Cannot connect to sftp://abc@xxx.xx.xx.xxx:22//abc@xxx.xx.xx.xxx:22

      org.apache.camel.component.file.GenericFileOperationFailedException: Cannot connect to sftp://abc@xxx.xx.xx.xxx:22//abc@xxx.xx.xx.xxx:22

              at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:113)[207:org.apache.camel.camel-ftp:2.6.0.fuse-01-09]

              at org.apache.camel.component.file.remote.RemoteFileProducer.connectIfNecessary(RemoteFileProducer.java:199)[207:org.apache.camel.camel-ftp:2.6.0.fuse-01-09]

              at org.apache.camel.component.file.remote.RemoteFileProducer.recoverableConnectIfNecessary(RemoteFileProducer.java:189)[207:org.apache.camel.camel-ftp:2.6.0.fuse-01-09]

              at org.apache.camel.component.file.remote.RemoteFileProducer.preWriteCheck(RemoteFileProducer.java:117)[207:org.apache.camel.camel-ftp:2.6.0.fuse-01-09]

              at org.apache.camel.component.file.GenericFileProducer.processExchange(GenericFileProducer.java:113)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.component.file.remote.RemoteFileProducer.process(RemoteFileProducer.java:50)[207:org.apache.camel.camel-ftp:2.6.0.fuse-01-09]

              at org.apache.camel.impl.converter.AsyncProcessorTypeConverter$ProcessorToAsyncProcessorBridge.process(AsyncProcessorTypeConverter.java:50)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:70)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.SendProcessor$2.doInAsyncProducer(SendProcessor.java:104)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.impl.ProducerCache.doInAsyncProducer(ProducerCache.java:272)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.SendProcessor.process(SendProcessor.java:98)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:70)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.processNext(DelegateAsyncProcessor.java:98)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:89)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:68)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:70)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.processNext(DelegateAsyncProcessor.java:98)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:89)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.interceptor.TraceInterceptor.process(TraceInterceptor.java:99)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:70)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.RedeliveryErrorHandler.processErrorHandler(RedeliveryErrorHandler.java:299)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:208)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DefaultChannel.process(DefaultChannel.java:269)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:70)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.Pipeline.process(Pipeline.java:125)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.UnitOfWorkProcessor.process(UnitOfWorkProcessor.java:102)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:70)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.processNext(DelegateAsyncProcessor.java:98)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:89)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:68)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:91)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:85)[68:org.apache.camel.camel-core:2.6.0.fuse-01-09]

              at org.apache.camel.component.jms.EndpointMessageListener.onMessage(EndpointMessageListener.java:92)[208:org.apache.camel.camel-jms:2.6.0.fuse-01-09]

              at org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:560)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:498)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:467)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:325)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:263)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1058)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:1050)[95:org.springframework.jms:3.0.5.RELEASE]

              at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:947)[95:org.springframework.jms:3.0.5.RELEASE]

              at java.lang.Thread.run(Unknown Source)[:1.6.0_23]

      Caused by: com.jcraft.jsch.JSchException: Session.connect: java.io.IOException: End of IO Stream Read

              at com.jcraft.jsch.Session.connect(Session.java:504)[206:org.apache.servicemix.bundles.jsch:0.1.44.1]

              at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:85)[207:org.apache.camel.camel-ftp:2.6.0.fuse-01-09]

              ... 42 more

       

       

      -----

       

      It seems client applied this:

      kexalgorithms diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1

      macs umac-64@openssh.com,hmac-sha2-256,hmac-ripemd160,hmac-sha1

      ciphers aes256-ctr,aes128-ctr "