Diffie-Hellman
- Two parties can jointly agree a shared secret over an insecure channel
- Mathematically, both calculating the same value mod a prime p
- 600+ decimal digits
- The parties separately compute the same key, rather than share it
Groups
- Operation is closed
- Operation is associative
- Neutral element
- Each called a neutral element such that ...
- A group is abelian (commutative)
consists of the integers 1,2,..,n-1 for which . This set forms an abelian group under multiplicative n
Group Cardinality
- The cardinality of a group is the number of elements in that group
Cyclic Groups
...
- A group that contains an element of maximum order is called a cyclic group
- Any element of maximum order is called a primitive root, or generator
Subgroups
- For all primes, ..., is an abelian finite cyclic group
- Will always be a size of 1,2,5 or 10
Order of an element
Cracking
- Brute force:
- Shanks Baby-Step Gian-Step: and ~
- Pollards Rho:
- Pohlig-Hellman: Prime factorisation of
- Discrete log problem is solved mod each prime factor and the results combined using the Chinese remainder theorem
- Index Calculus directly attacks .. and is the reason EC is so much more efficient
Which prime?
- To avoid unexpected small subgroup attacks, DH primes are safe primes
- A safe prime is a prime where is also prime