This project has moved. For the latest updates, please go here.

Error using certificate on sendport

Aug 21, 2008 at 6:00 PM

Hello, i recently installed this adapter on BizTalk 2006 R2 and im getting this error trying to send a file using a certificate.
I already logged in using psftp + pageant with my key and i had no problem so is not a connection problem.

Event Type: Error
Event Source: Blogical
Event Category: None
Event ID: 0
Date:  21/08/2008
Time:  02:39:46 p.m.
User:  N/A
Computer: D095SRTEC204
Description:
Method: Blogical.Shared.Adapters.Sftp.SftpTransmitterEndpoint.ProcessMessage
Error: Unable to transmit file /home/CSUD/OUT/PRUEBA.TXT.
Inner Exception:
Unable write file to /home/CSUD/OUT/PRUEBA.TXT
Unable to connect to Sftp host [xxx.xxx.x.xxx]

------------------------------
Information:
Type: Blogical.Shared.Adapters.Sftp.SftpException
Target: Microsoft.BizTalk.Message.Interop.IBaseMessage ProcessMessageInternal(Microsoft.BizTalk.Message.Interop.IBaseMessage, Blogical.Shared.Adapters.Sftp.ISftp)
Message: Unable to transmit file /home/CSUD/OUT/PRUEBA.TXT.
Inner Exception:
Unable write file to /home/CSUD/OUT/PRUEBA.TXT
Unable to connect to Sftp host [xxx.xxx.x.xxx]
Stacktrace:
   at Blogical.Shared.Adapters.Sftp.SftpTransmitterEndpoint.ProcessMessageInternal(IBaseMessage message, ISftp sftp)
   at Blogical.Shared.Adapters.Sftp.SftpTransmitterEndpoint.ProcessMessage(IBaseMessage message)

------------------------------
Type: Blogical.Shared.Adapters.Sftp.SftpException
Target: Void Put(System.IO.Stream, System.String)
Message: Unable write file to /home/CSUD/OUT/PRUEBA.TXT
Stacktrace:
   at Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.Put(Stream memStream, String destination)
   at Blogical.Shared.Adapters.Sftp.SftpTransmitterEndpoint.ProcessMessageInternal(IBaseMessage message, ISftp sftp)

------------------------------
Type: System.Exception
Target: Void connect(Boolean)
Message: Unable to connect to Sftp host [xxx.xxx.x.xxx]
Stacktrace:
   at Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.connect(Boolean force)
   at Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.reConnect()
   at Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.Put(Stream memStream, String destination)

------------------------------
Type: Tamir.SharpSsh.jsch.JSchException
Target: Void .ctor(System.String, Tamir.SharpSsh.jsch.JSch)
Message: invaid privatekey: c:\Test.ppk
Stacktrace:
   at Tamir.SharpSsh.jsch.IdentityFile..ctor(String identity, JSch jsch)
   at Tamir.SharpSsh.SshBase.AddIdentityFile(String privateKeyFile)
   at Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.connect(Boolean force)

 
For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Thanks

Coordinator
Aug 21, 2008 at 7:53 PM
Seems to be a connection problem, are you able to connect using username / password (temporarly)?
//Mikael
Aug 21, 2008 at 8:27 PM
Edited Aug 21, 2008 at 8:39 PM
I can try that, but sftp server only allows username / certificate. I can connect without problem when i dont use biztalk. 
I get this error with username / password (without certificate)

Event Type: Error
Event Source: SFTPAdapter
Event Category: None
Event ID: 1001
Date:  21/08/2008
Time:  05:28:04 p.m.
User:  N/A
Computer: D095SRTEC204
Description:
Method: Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.connect
Error: Unable to connect to Sftp host [xxx.xxx.x.xxx]

------------------------------
Information:
Type: System.Exception
Target:
Message: Unable to connect to Sftp host [xxx.xxx.x.xxx]
Stacktrace:

------------------------------
Type: Tamir.SharpSsh.jsch.JSchException
Target: Void connect(Int32)
Message: System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond
   at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress)
   at System.Net.Sockets.Socket.Connect(EndPoint remoteEP)
   at Tamir.SharpSsh.java.net.Socket..ctor(String host, Int32 port)
   at Tamir.SharpSsh.jsch.Util.createSocket(String host, Int32 port, Int32 timeout)
Stacktrace:
   at Tamir.SharpSsh.jsch.Session.connect(Int32 connectTimeout)
   at Tamir.SharpSsh.SshBase.ConnectSession(Int32 tcpPort)
   at Tamir.SharpSsh.SshBase.Connect(Int32 tcpPort)
   at Blogical.Shared.Adapters.Sftp.SharpSsh.Sftp.connect(Boolean force)

 

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Coordinator
Aug 22, 2008 at 7:14 AM
Edited Aug 22, 2008 at 7:20 AM
First exception:
"invaid privatekey: c:\Test.ppk"
I have seen this before, try generate a new key, preferbly in open ssh format.

Secon message:
"Message: System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond"
This looks like it can't find the host. Could you try using servername, rather than ip-address?

It might be easier to solve this using msn messenger...wmmihaa at hotmail dot com


Here is a test station you might find usefull, http://blogical.se/blogs/mikael/blogical.sftpteststation.zip. You'll get the same exception, since it uses the same library, but it's easier for testing...


//Mikael
Aug 22, 2008 at 3:56 PM
You were right about connection problem, i already fix that, and u also right about private key, i generated a new one with another aplication and now looks like sftpteststation recognize that format, thank you very much!.
Coordinator
Aug 24, 2008 at 7:15 PM
Glad to help