Location: Hong Kong
Posted: 2012-09-19 08:53
My vendor has created an account for me to access their SFTP server. I had created an script but could not pass the password authentication.
Below are the information provided by the vendor:
1. account name
2. SFTP server IP address and port number
3. private key(ppk)(no Encryption)
What I have done were:
1. Use PuTTY Key Generator to generate the Key Fingerprint:
- open PuTTY Key Generator
- Load the private key file
- select key type = SSH-2 RSA (1024 bits)
- NOTE: I have not enter a Key passphrase
- copy the generated Key fingerprint and copy as -hostkey as shown
2. Create a script to connect to the SFTP server:
- open sftp://firstname.lastname@example.org:22 -hostkey="ssh-rsa 1024
3. Received an authentication error as shown in the log file attached.
My questions are:
a. do I need the vendor to create the account password and embed it
in the open statement?
b. if not, how can I resolve the authentication problem.
Thanks in advance.
Location: Prague, Czechia
1) You need to use -privatekey to specify a path to your private key.
2) In -hostkey you specify fingerprint of server's public key, not your private key.
No need to your step 1.
You can post new topics in this forum
And it's free!