Zscaler 블로그

Zscaler 블로그의 최신 업데이트를 이메일로 받아보세요

Products & Solutions

Demystifying Key Exchange: From Classical ECDHE to a Post-Quantum Future

image
>Demystifying Key Exchange: From Classical ECDHE to a Post-Quantum Future

In the digital world, the secure exchange of cryptographic keys is the foundation upon which all private communication is built. It’s the initial, critical handshake that allows two parties, like a user’s browser and a web server, to establish a shared secret and communicate securely over the untrusted expanse of the internet.

As the quantum computing era approaches, the very mathematics underpinning our traditional key exchange mechanisms are facing an existential threat. This spurred the development of new, quantum-resistant algorithms. This blog post provides a deep dive into how modern key exchange works, from the trusted classical methods to the emerging post-quantum standards, and explores how Zscaler leverages hybrid key exchange to bridge the gap.

The Components of Modern Key Exchange

At a high level, a secure key exchange protocol must achieve the following:

  • Confidentiality:  The established key must be a secret shared only between the two communicating parties. An eavesdropper should not be able to determine the key.
  • Authentication: In many cases (like with TLS), the parties must be able to verify each other's identity to prevent man-in-the-middle attacks. This is typically handled by digital certificates and is complementary to the key exchange itself.
  • Forward Secrecy: The compromise of a long-term secret (like a server's private key) should not compromise the security of past session keys. This ensures that previously recorded encrypted traffic cannot be decrypted.

Classical Key Exchange: The Reign of ECDHE

For the better part of a decade, the gold standard for key exchange on the web has been  Elliptic Curve Diffie-Hellman Ephemeral (ECDHE). It is a cornerstone of Transport Layer Security (TLS) and is responsible for securing trillions of connections daily.

How Key Exchange Works:

  1. The Foundation: Elliptic Curve Cryptography (ECC): Instead of using very large prime numbers like traditional Diffie-Hellman, ECDHE uses the mathematical properties of elliptic curves. ECC offers the same level of security as older methods but with significantly smaller key sizes, making it faster and more efficient—a crucial advantage for mobile and IoT devices.
  2. The Handshake: Both the client and the server agree on a common elliptic curve and a starting point on that curve (the "generator").
  3. The "Ephemeral" Nature: This is where forward secrecy comes from. For each new session, both the client and server generate a new, temporary (ephemeral) key pair consisting of a private key (a random number) and a public key (a point on the curve).
  4. The Exchange: The client and server exchange their public keys.
  5. The Shared Secret: Each party then uses its *own* private key and the *other* party's public key to perform a calculation. Due to the magic of elliptic curve mathematics, both the client and the server independently arrive at the exact same point on the curve—this becomes their shared secret.
  6. Session Encryption: This shared secret is then used to derive the symmetric encryption keys that will encrypt all data for the remainder of the session.

Even if an attacker were to steal the server's long-term private key years later, they could not use it to derive the ephemeral session keys from past traffic.

The Quantum Threat and Post-Quantum Key Exchange: ML-KEM

The security of ECDHE relies on the difficulty of the "elliptic curve discrete logarithm problem." For a classical computer, this is an incredibly hard problem to solve. But for a sufficiently powerful quantum computer, Shor's algorithm  makes it trivial because it can factor large integers into prime numbers with extreme efficiency.

This has led to a new field of cryptography: Post-Quantum Cryptography (PQC). The goal is to create algorithms that are secure against attacks from both classical and quantum computers.

After a multi-year competition, the U.S. National Institute of Standards and Technology (NIST) selected a suite of algorithms for standardization. For key exchange, the primary choice is the Module-Lattice-based Key-Encapsulation Mechanism (ML-KEM), formerly known as CRYSTALS Kyber.

How Key Encapsulation Mechanism (KEM) Works:

Unlike the interactive exchange in Diffie-Hellman, a KEM works slightly differently:

  1. The server generates a public and private key pair based on the mathematical difficulty of problems in crystal-like structures called lattices.
  2. The server sends its public key to the client.
  3. The client uses the server's public key to generate two things: a shared secret and a "ciphertext" that encapsulates (or wraps) that secret.
  4. The client sends this encapsulating ciphertext back to the server.
  5. The server uses its private key to "decapsulate" the ciphertext, revealing the exact same shared secret that the client generated.

Now both parties have the secret, and an eavesdropper, even one with a quantum computer, cannot solve the underlying lattice math to discover it.

The Real World: Hybrid Key Exchange (ECDHE + ML-KEM)

We are in a transitional period. While powerful quantum computers are not yet widely available, the threat of "harvest now, decrypt later" is very real: adversaries can record sensitive encrypted data today and store it, waiting for the day they have access to a quantum computer to break it.

To counter this, the industry is moving towards a hybrid approach. Zscaler has implemented this by combining the battle-tested classical algorithm with a next-generation post-quantum one.

How Zscaler's Hybrid Implementation Works:

Zscaler’s Zero Trust Exchange acts as an intelligent switchboard for connections. When a client initiates a TLS connection, it sends a "ClientHello" message advertising its capabilities.

  1. Dual Key Generation: In a hybrid key exchange, the client and server perform both an ECDHE key exchange and an ML-KEM key encapsulation simultaneously.
  2. Two Secrets are Better Than One: This process results in two independent shared secrets: one from ECDHE and one from ML-KEM.
  3. Concatenation for a Single Master Key: These two secrets are then concatenated (combined end-to-end) to create the final master secret for the session.
  4. Deriving Session Keys: This robust, hybrid master secret is then used to derive the encryption keys for the session traffic.

The security of this approach is immense. To break the encryption and read the data, an attacker would have to break both the classical ECDHE algorithm and the post-quantum ML-KEM algorithm. This "belt and suspenders" model provides a powerful guarantee: the connection is at least as secure as the classical cryptography we trust today, and it is also protected against the quantum threats of tomorrow. This allows organizations to safely transition to a post-quantum world without compromising on current security.

Conclusion: Two Worlds, One Goal

Classical key exchange is the workhorse of today, securing trillions of connections with proven, efficient software. But the road ahead will be a hybrid one. We can expect to see Post-Quantum Cryptography (PQC)—new algorithms resistant to quantum attacks—securing our communications and critical software-dependent transactions. For security and networking practitioners, understanding the new paradigm is no longer optional—it's essential for securing today’s data against future quantum-based attacks.

Learn how Zscaler can help your organization prepare for the quantum future with our quantum resources or  watch our on-demand webinar where our product experts walk you through how Zscaler uses hybrid key exchange in service of decrypting and inspecting quantum-encrypted traffic with ML-KEM. 

form submtited
읽어주셔서 감사합니다

면책 조항: 이 블로그 게시물은 정보 제공만을 목적으로 Zscaler에서 작성하였으며, 정확성, 완전성 또는 신뢰성에 대한 어떠한 보증도 없이 "있는 그대로" 제공됩니다. Zscaler는 제공된 정보를 기반으로 수행된 조치나 오류 또는 누락에 대해 어떠한 책임도 지지 않습니다. 이 블로그 게시물에 링크된 제3자 웹사이트나 리소스는 편의를 위해서만 제공되며, Zscaler는 해당 웹사이트의 콘텐츠나 관행에 대해 책임을 지지 않습니다. 모든 콘텐츠는 예고 없이 변경될 수 있습니다. 이 블로그에 접속함으로써 귀하는 본 약관에 동의하며 귀하의 필요에 따라 정보를 확인하고 사용할 전적인 책임이 귀하에게 있음을 인정합니다.

Zscaler 블로그의 최신 업데이트를 이메일로 받아보세요

양식을 제출함으로써 귀하는 당사의 개인정보 보호정책에 동의하는 것입니다.