|       LAB 7      |       Fall 2001      |       Michael Siff       |
Lab Report due Tuesday, November 13
Introduction
The goal of this lab is to demonstrate Diffie-Hellman Key Exchange. Along the way, participants should hopefully learn about the relative efficiencies of computing modular exponents and discrete logarithms.
Computing modular exponents
Experiment with this modular-exponentiation servlet.
For each of the three algorithms, if possible, try and find values of g, e and m that cause the servlet to fail to give a result. (Either by responding something like:
Fatal error: Maximum execution time of 5 seconds exceededor producing some other message. If it's another message, indicate what that message is.)
Indicate the answer and which algorithm you used to arrive at that answer. Pick one of the algorithms you did not use and estimate (roughly!) how long it would have taken to compute the answer using that algorithm. Finally, indicate how you might have arrived at the answer quite rapidly without using any of these three algorithms.
Diffie-Hellman exchange
Use the modular-exponentiation tool to compute shared keys following the Diffie-Hellman protocol. That is, choose two different values for private keys, a for a fictional Alice, b for a fictional Bob. Use the tool to compute:
x = ga mod mand
y = gb mod mThen use the tool and those values to find a shared key. Make sure and check that
xb mod m = ya mod m.
Cracking Diffie-Hellman via discrete log
Experiment with using this discrete-log tool.
Fatal error: Maximum execution time of 15 seconds exceeded
The best known method for foiling Diffie Hellman is to compute the discrete log of either
ga mod por
gb mod pin order to recover one of the private keys so you can form the shared key.
Suppose you have intercepted the following string of bits sent from Alice to Bob:
11010101101111011011010100110111The bits have known to have been encrypted using a shared key generated via Diffie Hellman with g=103 and p=57143. While Alice and Bob were setting up their key, you eavesdropped that: Alice sent 33600 to Bob and Bob sent 28988 to Alice.
DHeKE
Meet DHeKE (pronounced "deek"), the Diffie-Hellman-Key-Exchange computer. To interact with DHeKE, you need a login (your regular Sarah Lawrence username) and a password (see me).
Look at the public record: all the messages that DHeKE has exchanged with the class to date.
Extra credit (due any time before end of the semester): Use DHeKE's public record and all your cryptanalytic skills to intercept and decrypt as many of the messages in the record as you can. If you decrypt all the messages, you will uncover a clue...
| crypto home | assignments | labs | notes | tools | contact instructor |