.

What is the difference between sshd-generate and ssh-keygen?

<<

morpheus063

User avatar

Sr. Member
Sr. Member

Posts: 393

Joined: Sun Jun 25, 2006 10:08 am

Location: Cochin - India

Post Fri Feb 01, 2008 9:58 pm

What is the difference between sshd-generate and ssh-keygen?

Hi,

I was just refreshing and digging on ssh and came across these two commands - sshd-generate and ssh-keygen. Can anybody explain me what is the difference between these two?

The output is almost similar except the location where it is saved.

  Code:
bt ssh # sshd-generate
Generating public/private rsa1 key pair.
Your identification has been saved in /etc/ssh/ssh_host_key.
Your public key has been saved in /etc/ssh/ssh_host_key.pub.
The key fingerprint is:
xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx root@bt
Generating public/private rsa key pair.
Your identification has been saved in /etc/ssh/ssh_host_rsa_key.
Your public key has been saved in /etc/ssh/ssh_host_rsa_key.pub.
The key fingerprint is:
xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx root@bt
Generating public/private dsa key pair.
Your identification has been saved in /etc/ssh/ssh_host_dsa_key.
Your public key has been saved in /etc/ssh/ssh_host_dsa_key.pub.
The key fingerprint is:
xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx root@bt



  Code:
bt ssh # ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa): n
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in n.
Your public key has been saved in n.pub.
The key fingerprint is:
xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx root@bt
bt ssh #


Thanks in advance.
Manu Zacharia
MVP (Enterprise Security), ISLA-2010 (ISC)², C|EH, C|HFI, CCNA, MCP,
Certified ISO 27001:2005 Lead Auditor

[b]There are 3 roads to spoil; women, gambling & hacking. The most pleasant with women, the quickest with gambling, but the surest is hacking - c0c0n
<<

LSOChris

Post Sat Feb 02, 2008 12:10 am

Re: What is the difference between sshd-generate and ssh-keygen?

i've had some beers but...

i think sshd keygen is for the server side so you generate the key you will present to clients and for whatever reason you may want to update that key, sshd keygen will generate that first key and any other keys after that.

likewise, you can just do ssh key logon where you dont have to present a password, only username and your ssh key you created with ssh-keygen.  refer to the passwordless ssh article over at lso.

Return to Other

Who is online

Users browsing this forum: No registered users and 0 guests

.
Powered by phpBB® Forum Software © phpBB Group.
Designed by ST Software