Understanding the TLS Handshake: The Journey to Getting that Secure Padlock π
In todayβs digital landscape, ensuring secure communication between you and the websites you visit is paramount. This security is primarily achieved through a process known as the TLS (Transport Layer Security) handshake. In this blog post, we will explore what transpires between your browser and the web server to secure your connection and get that reassuring padlock icon.
For a visual reference of the handshake process, I recommend opening the infographic linked below in a new tab as we discuss each step.
Introduction: The Purpose of TLS
Before delving into the intricacies of the TLS handshake, let’s clarify its primary objectives:
- β To authenticate the server’s identity
- β To establish session keys for secure data transfer
Understanding these goals will help contextualize the handshake process.
A Quick Note on Records and Packets
As we analyze the infographic, itβs essential to distinguish between “records” and “packets.” Each line in the illustration represents a βrecordβ exchanged during the TLS handshake, which is not equivalent to a packet. Depending on the situation, a single packet can carry multiple records, and conversely, multiple packets may be necessary for one record.
Cryptographic Terms to Know
While we wonβt explore cryptography in depth here, familiarity with the following concepts is beneficial for grasping the TLS handshake:
- Hashing
- MACs (Message Authentication Codes) and HMACs (Hashed Message Authentication Codes)
- Encryption
If youβre unfamiliar with these terms, consider checking some introductory videos that cover these topics.
Step 1: Client Hello
The handshake commences when the client, your web browser, sends a Client Hello message. This message contains five critical components:
- SSL Version
- Random Number
- Session ID
- Cipher Suites
- Extensions
Each of these elements plays a vital role in establishing the secure connection.
SSL Version
The client indicates the highest SSL version it supports, such as SSL 3.0, TLS 1.0, and so forth. The server will respond with its highest supported version, and they will settle on the most secure option available. As of now, TLS 1.2 and TLS
Share this content: