Diffie–Hellman Key Exchange

Traditional secret/single key cryptography uses one key that is shared by both sender and the receiver. But if this key is disclosed, all the communications are compromised. One of the solution to this problem is Diffie-Hellman key exchange.The Diffie-Hellman Key Exchange Protocol is a key agreement protocol that allows authenticated parties to exchange keying material over an unsecured connection.This protocol is widely used in protocols like IPSec and SSL/TLS. Using this protocol, sending and receiving devices in a network derive a secret shared key using which data can be encrypted.


To implement Diffie-Hellman, the two end users A and B, while communicating over a channel they know to be private, mutually agree on positive whole numbers p and q, such that p is a prime number and q is a generator of p.The generator q is a number that, when raised to positive whole-number powers less than p, never produces the same result for any two such whole numbers. The value of p may be large but the value of q is usually small. Once Alice and Bob have agreed on p and q in private, they choose positive whole-number personal keys a and b, both less than the prime-number modulus p.

Next user A will compute his public key(KA) , 
                                                    KA = qa mod p
and user B also compute his public key(KB) , 
                                                    KB qa mod p

The two users can share their public keys KA and KB over a communications medium assumed to be insecure. Then users can calculate key X using these public keys.

User A -: X = (KA)a mod p
User B -: X = (KB)b mod p

User A and B both have derived X without directly sending X to each other. So, even if an attacker eavesdrops the communication between A and B and gets the value of KA KB, q and p, it will be computationally infeasible for the attacker to derive the value of X. Now, Alice and Bob are free to encrypt the data with the secret key X and transfer the data between them securely. 

This was a brief overview of the Diffie-Hellman Key Exchange Method. If you who want to know more about this here are some good references links.
https://www.youtube.com/watch?v=cM4mNVUBtHk
https://www.youtube.com/watch?v=zLKT4-uRGw4


Comments

Popular posts from this blog

What is Fringe Science?

What is Quantum Computing?

Cyber Security