Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
1.1k views
in General by (450 points)
We have a partner who we are trying to send files to via SSH (public key authentication). The partner is saying that EDTPro is trying to send the file to their root folder (where we don't have permission to send to), even though the code is set to change directories on the remote server. What is odd is that the change directory code is working with our other clients, so not sure why it wouldn't here.

I just added logging, so here are the debug logs. I have only included the logs after connection, since we aren't having trouble connecting. Also, I redacted the IP address of our client.
DEBUG [BaseSocket] 5 Nov 2014 08:58:47.652 :  Successfully connected to xxxxxxxxxxxx
DEBUG [SSHSCPClient] 5 Nov 2014 08:58:47.652 :  Connected successfully to SFTP server xxxxxxxxxxxx
DEBUG [SSHConnection] 5 Nov 2014 08:58:47.652 :  Beginning protocol negotiation
DEBUG [PlainSocket] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 RepeatCallback received 41 bytes
DEBUG [ProtocolNegotiationHandler] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 offset=0,length=41
DEBUG [ProtocolNegotiationHandler] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 Read: 'SSH-2.0-OpenSSH_6.6.1p1 Ubuntu-2ubuntu2'
INFO [ProtocolNegotiationHandler] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 Server version = 'SSH-2.0-OpenSSH_6.6.1p1 Ubuntu-2ubuntu2'
DEBUG [SSHUtil] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 Major string = '2'
DEBUG [SSHUtil] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 Minor string = '0'
DEBUG [SSHUtil] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 Version 2.0
DEBUG [SSHUtil] 5 Nov 2014 08:58:47.730 : SSHSCPClient.1 Protocol compatible
DEBUG [SSHConnection] 5 Nov 2014 08:58:47.730 :  Server version=SSH-2.0-OpenSSH_6.6.1p1 Ubuntu-2ubuntu2
DEBUG [SSH2Connection] 5 Nov 2014 08:58:47.730 :  Timeout=120000
DEBUG [SSHConnection] 5 Nov 2014 08:58:47.730 :  Sending client version=SSH-2.0-edtFTPnet/PRO-8.6.0.20
DEBUG [SSH2Connection] 5 Nov 2014 08:58:47.730 :  Starting key exchange
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  Sending SSH_MSG_KEXINIT
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  key exchange method=diffie-hellman-group1-sha1,diffie-hellman-group14-sha1
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  hostkey algorithms=ssh-dss,ssh-rsa
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  ciphers=blowfish-cbc,3des-cbc,aes128-cbc,aes192-cbc,aes256-cbc
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  ciphers=blowfish-cbc,3des-cbc,aes128-cbc,aes192-cbc,aes256-cbc
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  MACs=hmac-md5,hmac-sha1
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  MACs=hmac-md5,hmac-sha1
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  compression algorithms=none,zlib
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  compression algorithms=none,zlib
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.746 :  Sent SSH_MSG_KEXINIT
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.746 :  Reading SSH_MSG_KEXINIT reply
DEBUG [SSH2Connection] 5 Nov 2014 08:58:47.746 :  Waiting for packet
DEBUG [PlainSocket] 5 Nov 2014 08:58:47.808 : SSHSCPClient.1 RepeatCallback received 1608 bytes
DEBUG [SSH2Connection] 5 Nov 2014 08:58:47.808 :  Packet arrived
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  Processing SSH_MSG_KEXINIT reply
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote kex alg=curve25519-sha256@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided kex alg= DiffieHellmanGroup1Sha1
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote hostkey alg=ssh-rsa
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided hostkey alg= RSA
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote Cipher CS=aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-gcm@openssh.com,aes256-gcm@openssh.com,chacha20-poly1305@openssh.com,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided Cipher C->S= Blowfish
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote Cipher SC=aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-gcm@openssh.com,aes256-gcm@openssh.com,chacha20-poly1305@openssh.com,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided Cipher S->C= Blowfish
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote MAC CS=hmac-md5-etm@openssh.com,hmac-sha1-etm@openssh.com,umac-64-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-ripemd160-etm@openssh.com,hmac-sha1-96-etm@openssh.com,hmac-md5-96-etm@openssh.com,hmac-md5,hmac-sha1,umac-64@openssh.com,umac-128@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided MAC C->S= HMACMD5
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote MAC SC=hmac-md5-etm@openssh.com,hmac-sha1-etm@openssh.com,umac-64-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-ripemd160-etm@openssh.com,hmac-sha1-96-etm@openssh.com,hmac-md5-96-etm@openssh.com,hmac-md5,hmac-sha1,umac-64@openssh.com,umac-128@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided MAC S->C= HMACMD5
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote Comp CS=none,zlib@openssh.com
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided Comp C->S=None
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Remote Comp SC=none,zlib@openssh.com
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Decided Comp S->C=None
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  first_kex_packet_follows=False
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  Processed SSH_MSG_KEXINIT reply
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.808 :  Sending SSH_MSG_KEXDH_INIT
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.808 :  DH_PRIME_GROUP1
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.824 :  DH_PRIME_GROUP1
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.839 :  Sent SSH_MSG_KEXDH_INIT
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.839 :  Reading SSH_MSG_KEXDH_INIT reply
DEBUG [SSH2Connection] 5 Nov 2014 08:58:47.839 :  Waiting for packet
DEBUG [PlainSocket] 5 Nov 2014 08:58:47.917 : SSHSCPClient.1 RepeatCallback received 720 bytes
DEBUG [SSH2Connection] 5 Nov 2014 08:58:47.917 :  Packet arrived
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.917 :  Processing SSH_MSG_KEXDH_INIT reply
DEBUG [AbstractKeyExchanger] 5 Nov 2014 08:58:47.917 :  DH_PRIME_GROUP1
INFO [ClientKeyExchanger] 5 Nov 2014 08:58:47.917 :  Verifying host key
DEBUG [ClientKeyExchanger] 5 Nov 2014 08:58:47.933 :  Processed SSH_MSG_KEXDH_INIT reply successfully
DEBUG [ClientKey

2 Answers

0 votes
by (161k points)
What are you using for the parameters of the upload method?
0 votes
by (450 points)
I see the issue now. I didn't set the destination file name properly in the code. Thanks for your help.

Categories

...