6

I was reading the following document:
https://www.digitalocean.com/community/tutorials/understanding-the-ssh-encryption-and-connection-process

In the asymmetric encryption it looks like the shared secret key (symmetric key) is always used to encrypt/decrypt the messages between the client and server. I was confused why it's called asymmetric encryption when the private and public key is used only in authentication? Is asymmetric encryption (public and private key) used in encrypting messages after authentication? Or is the shared secret key only used in both (symmetric and asymmetric), private and public key in both should be used for authentication only right?

0

1 Answer 1

6

In the asymmetric encryption it looks like the shared secret key (symmetric key) is always used to encrypt/decrypt the messages between the client and server.

In SSH (not in asymmetric encryption), shared secret key (symmetric key) is always used to encrypt/decrypt the messages between the client and server.

I was confused why it's called asymmetric encryption when the private and public key is used only in authentication?

It's not called an asymmetric encryption, it's a symmetric encryption when a shared key is used. The asymmetric encryption is used to exchange the shared key and optionally for an authentication. Though in both cases, different keys are used.

Is asymmetric encryption (public and private key) used in encrypting messages after authentication?

No.

Or is the shared secret key only used in both (symmetric and asymmetric), private and public key in both should be used for authentication only right?

There's no "both". It looks like you understood from the document that there's some choice between "symmetric" and "asymmetric" in SSH. There's not. Both symmetric and asymmetric encryption is used in SSH, but for specific tasks. And you cannot choose, when is which of them used.

Private and public keys (the ones you know of) are used only for an authentication. There are other temporary asymmetric keys used for shared (symmetric) key exchange. But you are not involved in any way with those keys.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .