The SSL protocol involves several processing steps known as a handshake protocol to establish the secure communication channel. Should any of these steps fail, the channel will not be established and the connection will fail. These steps are as follows:
Determine the cipher suite to use.
Optionally authenticate the server.
Agree on an encryption mechanism.
If necessary, exchange secret keys using a public key.
Begin encrypted communication.
The ability for the client and server to negotiate to determine the cipher suite to use is one of the flexibility features of SSL. A number of cipher suites are available, and this handshake protocol allows the client and server to mutually determine the best protocol to use.