SSH authenticates by using the SSH protocol.
-vv option when connecting to another server using SSH will show you more detailed information on the key exchange, protocol negotiation, etc.
Event Sequence of an SSH Connection
The following series of events help protect the integrity of SSH communication between two hosts.
- A cryptographic handshake is made so that the client can verify that
it is communicating with the correct server.
- The transport layer of
the connection between the client and remote host is encrypted using
a symmetric cipher.
- The client authenticates itself to the server.
- The client interacts with the remote host over the encrypted
SSH servers and clients can be configured to allow different types of authentication, which gives each side the optimal amount of control. The server can decide which encryption methods it supports based on its security model, and the client can choose the order of authentication methods to attempt from the available options.
You can read more about the specifics on Red Hat's website: