cancel
Showing results for 
Search instead for 
Did you mean: 

ssh-keygen error

 
sen_ux
Valued Contributor

ssh-keygen error

I am getting below error while generating ssh key.

$ ssh-keygen -t rsa1 -b 2048 -f testkey -N
Bits has bad value 2048 (too small)
$

It is getting generated with out -b option.
Tried with different values, but fails.

$ ssh -V
OpenSSH_4.2p1, OpenSSL 0.9.7g 11 Apr 2005
$
ia64 hp server BL860c
HP-UX B.11.23
OpenSSL A.00.09.07m.042

Thanks
sen
6 REPLIES
Steven Schweda
Honored Contributor

Re: ssh-keygen error

I know nothing, but a quick Google search
suggests that you're not the first one to see
this problem.

http://www.mail-archive.com/openpkg-users@openpkg.org/msg02482.html

> $ ssh -V
> OpenSSH_4.2p1, OpenSSL 0.9.7g 11 Apr 2005

Have you considered installing something a
little less obsolete?

https://h20392.www2.hp.com/portal/swdepot/displayProductInfo.do?productNumber=T1471AA
sen_ux
Valued Contributor

Re: ssh-keygen error

Thanks.

What is the impact of not specifying the number of bits.?

sen
Steven Schweda
Honored Contributor

Re: ssh-keygen error

> What is the impact of not specifying the
> number of bits.?

I don't know. "man ssh-keygen"? I assume
that you'll get _some_ number of bits.

> Tried with different values, but fails.

If my psychic powers were stronger, then I
might be better able to guess exactly what
you tried. But they're too weak.

Again, I know nothing, but have you
considered the possibility that 2048 is too
large, and the message is wrong?

What's the problem with installing something
up-to-date?
sen_ux
Valued Contributor

Re: ssh-keygen error

Yes.. Installing a new version is not a problem. But would like to know the reason behind it, before blindly going for an upgradation.

Anyway thanks.
Steven Schweda
Honored Contributor

Re: ssh-keygen error

On my most out-of-date system:

dy # uname -a
HP-UX dy B.11.11 U 9000/785 2012616114 unlimited-user license

dy # ssh -V
OpenSSH_4.3p2-hpn, OpenSSL 0.9.7i 14 Oct 2005
HP-UX Secure Shell-A.04.30.006, HP-UX Secure Shell version

dy # ssh-keygen -t rsa1 -b 2048 -f testkey -N
ssh-keygen: option requires an argument -- N
Usage: ssh-keygen [options]
Options:
-a trials Number of trials for screening DH-GEX moduli.
[...]

but, done properly:

dy # ssh-keygen -t rsa1 -b 2048 -f testkey -N 'sword fish'
Generating public/private rsa1 key pair.
Your identification has been saved in testkey.
Your public key has been saved in testkey.pub.
The key fingerprint is:
b0:02:11:97:ea:be:94:30:9d:d0:96:98:4c:88:3b:59 root@dy

You may draw your own conclusions.
Steven Schweda
Honored Contributor

Re: ssh-keygen error

Seems to work after an update, too:

dy # ssh -V
OpenSSH_5.3p1+sftpfilecontrol-v1.3-hpn13v5, OpenSSL 0.9.8l 5 Nov 2009
HP-UX Secure Shell-A.05.30.007, HP-UX Secure Shell version

dy # ssh-keygen -t rsa1 -b 2048 -f testkey2 -N 'sword fish'
Generating public/private rsa1 key pair.
Your identification has been saved in testkey2.
Your public key has been saved in testkey2.pub.
The key fingerprint is:
9b:74:3d:ba:fa:99:c8:c8:26:97:2a:69:ea:65:f5:34 root@dy
The key's randomart image is:
+--[RSA1 2048]----+
| |
| |
| |
| . |
| . ES . o |
| . o..+ . . |
| + oo . |
| * ..+o . + |
|o+ ..=o +o= |
+-----------------+

(And it has flashier art.)

But I wouldn't try to tell you what to do.