SFTP syntax without specifying private key location (no password)
Hi all,
I need to connect using SFTP from Red Hat to Windows. Connection between servers work when I specify location of my private key in the script. However, I want to use syntax without private key location specified. I know this should work, as I found it in older scripts.
Scripts were previously executed from Suse and worked, now they should be run from Red Hat. Working SFTP was against prod server, now we first need to get test working.
working syntax is this (executed from one folder above .ssh):
the syntax that I wish to use (that is in the scripts already) is this:
Right now in terminal it queries me for password and scripts gets permission denied.
In script, it looks like this:
.ssh folder is located in:
/appl/home/user/.ssh/sftp_user_cert
privileges are:
-rw-------. 1 user user 668 Apr 22 15:57 sftp_user_cert
scripts will be executed from (using sh):
On target windows certificate is saved in the correct directory (C\Users\sftp_user\.ssh\authorized_keys\sftp_user_cert.pub)
Please suggest what settings to change so my script would work without certificate specification (and without asking for password).
Thanx for all suggestions.
---------- Post updated at 04:53 PM ---------- Previous update was at 01:57 PM ----------
Solved it ourselves, if anyone else needs to do it, here is the way:
1) check, if you have in ENV text entries for ssh - SSH_AUTH_SOCK, SSH_AGENT_PID
Hi,
we have private and public key, encrypt file using public and want to decrypt using private key. can you please advise below commands are correct or other remedy if unix have?
encrypt -a arcfour -k publickey.asc -i TESTFILE.csv -o TESTFILE00.csv
decrypt -a arcfour -k privatekey.asc... (2 Replies)
Before you get the wrong idea, I am not looking for how to generate one. I have a key from a server admin but I can't figure out how to use it in OS X.
I have the key, the address and everything I should need but there doesn't seem to be a step by step on how to install the key and use it in... (4 Replies)
I've been trying to get out of this, but my manager wont budge.
He wants to sftp files from a server while passing the password in the script. I have said we need to use keys...he said no.
I asked if we had expect capability...no.
He said "use -b batch file command"
I have checked every... (1 Reply)
I have two types of files
pubring.pkr
secring.skr
secring.skr is encrypted and not able to read.
How can i read secring.skr in text format after decrypting ?
is there any way of decrypting this file?
Unix HP - UX Version. (4 Replies)
Hello All,
I am stuck!
I have access to an external server via SFTP. In order to access the external server I was given a specific port, password, and a ppk.
I would to create a script on my server end that can I can setup as a corn job, that will connect to the external server and... (1 Reply)
Hello all,
We have unix environment and we would like to use ssh public and private key to move between server using ssh. I do know how to test this and have it up and running on some sandbox...but my question is how would one secure the PRIVATE KEY....we are not using a passphrase...and i know... (1 Reply)
Hi everyone!
I know you can extract public keys from a keystore using the keytool command.
But what is the process to extract a private key from a jks keystore and import into another jks keystore using keytool?
Any guidance would be greatly appreciated! I can't seem to find anything, I do... (0 Replies)
I would like to ask if you have a procedure on how to upload multiple private key for multiple users in solaris? I was only able to add one but when I tried to add several key, it fails.
example:
a. user1: user1.ppk
b. user2: user2.ppk
Each with different password on the server. Pls advise (6 Replies)
Hi everybody,
I need some help on writing a script that is able to remote copy file to one server. I already created this types of scripts, and works ok as long as this server I want to copy from is access through telnet. Here is how I do it:
ftp -n xxx.xxx.xxx.xxx << _EOF_
user user_name... (6 Replies)
I am trying to SFTP to a couple sites. One has an RSA-KEY that was sent to me. Currently I am running that manually using WinSCP. I would like to set it up as a CRON process on our Linux host (Sun).
Can I use the rsa-key they sent me in any directory or does it need to be placed in a specific... (2 Replies)