Presentation is loading. Please wait.

Presentation is loading. Please wait.

Diffie-Hellman Key Exchange

Similar presentations


Presentation on theme: "Diffie-Hellman Key Exchange"— Presentation transcript:

1 Diffie-Hellman Key Exchange
MATH 3396 Instructor: Alex Karassev

2 Discrete logarithm problem (DLP)
Тема №1 Серверное оборудование a, b from Fp* The smallest non-negative integer x such that ax = b is called the discrete logarithm of b to the base a Notation: x = Log a b числа b по основанию а Example: 42 = 5 in F11 and therefore 2 = log4 5 Knowing a and b it is hard to find x Exhaustive search: O(p) Improvement: O(p1/2) УЦ Сетевая Академия ЛАНИТ, 2008

3 Sophie Germain primes A prime q such that 2q+1 is also prime
In this case p = 2q+1 is called safe prime First few Sophie Germain primes: 2, 3, 5, 11, 23, 29, 41, 53 First few safe primes: 5,11,23,47,59 Largest known (as of 2016) Sophie Germain prime has digits Conjecture: there are infinitely many Sophie Germain prime

4 Diffie-Hellman key exchange
Choose large prime p (preferably, a safe prime) Choose g in Fp* such that ord g is a large prime (if p = 2 q +1, ord g = q) p and g are NOT secret (in fact, usually g = 2 or 3)

5 Diffie-Hellman Key exchange
Тема №1 Серверное оборудование p, g non-secure channel A Secret а A = ga Secret b B = gb B Alice computes K=Ba Shared secret key: K = Ba = (gb)a = gab = (ga)b = Ab Bob computes K=Ab A possible way to find K = gab : knowing p, g, А, find а, such that ga = A mod p which is the Discrete Logarithm Problem УЦ Сетевая Академия ЛАНИТ, 2008

6 Тема №1 Серверное оборудование
Example p = 11, g = 2 A = 8 a = 3 A = 23 = 8 B = 6 b = 9 B = 29 =512 = 46*11+6 = 6 Alice computes K = Ba = 63 = 216 = 19* = 7 Bob computes K = Ab = 89 = = = = *11+ 7 = 7 Shared secret key K = 7 УЦ Сетевая Академия ЛАНИТ, 2008

7 Man-in-the-middle attack
Diffie-Hellman key exchange protocol is not protected against man-in-the middle attack: An authenticated version of Diffie-Hellman protocol can be obtained with the use of digital signature

8 Digital signature – brief overview
Bob needs to send Alice a document m Alice needs to make sure that document has been sent by Bob and not by somebody else Bob send c=e(m), and encrypted E(f(m)), where s=f(m) is a function of m (digital signature), and E is the encryption function using Bob’s private key for digital signature Alice receives c and s, and computes m=d(c) and s=D(E(f(m))), using Bob’s public key for digital signature Verification: if f(m) = s, then the document has been sent by Bob


Download ppt "Diffie-Hellman Key Exchange"

Similar presentations


Ads by Google