r/programming • u/dominatrix-octopus • Jan 16 '18
Cryptography: Diffie-Hellman key exchange explained intuitively using colors
https://youtu.be/YEBfamv-_do?t=2m18s
2.5k
Upvotes
r/programming • u/dominatrix-octopus • Jan 16 '18
View all comments
Show parent comment
5
u/browner87 Jan 16 '18
Not exactly. The public part is 2 random numbers (the extra color in this case), but the secret part (my color and your color) are never ever sent somewhere the attacker can see them without being mixed up with the public colors, which the attacker can't extract my secret color from despite knowing the public colors I mixed them with. So the original secret colors are always safe, and in fact I never even let you know my secret color, but in the end we arrive at a common color that we can use that the attacker can't create from the two pre-mixed colors he observed.