Topic "Need help using WinSCP and SSH2 Keys"

Author Message
Kilbey1

Guest


Hi,

I'm trying to write up documentation so users can remotely connect using SSH2 to our Linux machine, from their PC laptops.

After detailing the installation, I am having them go to PuttyGen to generate a 1024 DSA key, and saviing their public and private keys to their system. So far so good.

Now I'm stuck. How do I tell them to get the key to the server? By default, do they just log in with their current passwords and then then transfer it over?

I've written doc after doc... first using just OpenSSH, then using Cygwin. If one utility can do it, I'd like to make it as simple as possible for the end-user.

So what I need to know is what steps the user must take with WinSCP after generating the keys. Via Cygwin, it's something like:

scp id_dsa.pub username@host:./id_dsa.pub
ssh -2 host
mkdir .ssh
cd .ssh
touch authorized_keys2
chmod 600 authorized_keys2
cat ../id_dsa.pub >> authorized_keys2
rm ../id_dsa.pub

...and then logging in.

Thanks so much,
Eve
eatley@wow-corp.com
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24995
Location: Prague, Czechia
With WinSCP you may upload SSH2 key in similar way. Only instead off appending the uploaded key, use may open the authorized_keys2 file and paste the key at the end.
_________________
Martin Prikryl
Kilbey1
[View user's profile]

Joined: 2004-02-21
Posts: 1
prikryl wrote:
With WinSCP you may upload SSH2 key in similar way. Only instead off appending the uploaded key, use may open the authorized_keys2 file and paste the key at the end.


There doesn't happen to be just 1 authorized_keys2 file, however. It's going into that user's directory. Does this defeat the purpose of keys? Should I be having 1 authorized_keys2 file somewhere?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24995
Location: Prague, Czechia
Kilbey1 wrote:
There doesn't happen to be just 1 authorized_keys2 file, however. It's going into that user's directory. Does this defeat the purpose of keys? Should I be having 1 authorized_keys2 file somewhere?

The key is connected to user, so it is normal to have it in user's directory. You should not have shared key (one common authorized_keys2). IFAIK is it even not possible.

Anyway, you upload authorized_keys2 to user's directory in command-line example in your first post. So I wonder why you mind doing the same with WinSCP?

Maybe I do not understand your problem. In such case, please again Smile
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License