Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between id_rsa.pub and id_dsa.pub?

Is one more secure than the other?

like image 393
Andrew Avatar asked May 12 '10 18:05

Andrew


People also ask

What is a id_rsa pub?

id_rsa. pub contains the public key of your RSA key pair. It may be used to allow you access the machine B over ssh without needing to enter password.

Is id_rsa pub the public key?

pub is your public key. Your identification has been saved in /Users/yourname/. ssh/id_rsa. Your public key has been saved in /Users/yourname/.

Is id_rsa a private key?

The default directory for SSH keys is ~/. ssh with the private key named id_rsa and the public key named id_rsa.

What is the format of id_rsa pub?

This right part of a public key (either "id_rsa. pub" or "id_dsa. pub") is just a comment and is usually filled with the < login>@< hostname> who generated the key. This in a way similar to the comment field from the SSH Public Key File Format (see RFC 4716).


1 Answers

id_rsa.pub and id_dsa.pub are the public keys for id_rsa and id_dsa.

If you are asking in relation to SSH, id_rsa is an RSA key and can be used with the SSH protocol 1 or 2, whereas id_dsa is a DSA key and can only be used with SSH protocol 2. Both are very secure, but DSA does seem to be the standard these days (assuming all your clients/servers support SSH 2).

Update: Since this was written DSA has been shown to be insecure. More information available in the answer below.

like image 56
Mike Pelley Avatar answered Sep 20 '22 11:09

Mike Pelley