Square and Multiply

11^37 = ?

37 = 100101 in binary

  • 1 -> first “One” lists number = 11

  • 0 -> square = (11)^2

  • 0 -> square = ((11)^2)^2

  • 1 -> square + multiply = (((11)^2)^2)^2*11

  • 0 -> square = ((((11)^2)^2)^2*11)^2

  • 1 -> square + multiply = (((((11)^2)^2)^2*11)^2)^2*11

Read More

Diffie Hellman MITM Attack

p = prime number (public)
g = modulus (public)

a = Alice private key (private)
b = Bob private key (private)

A = Alice public key (public)
B = Bob public ket = (public)

Sx = Shared key (public)

eA = Eve private key for Alice (private)
eB = Eve private key for Bob (private)
Ea = Spoofed Alice public key will sent to Bob (public)
Eb = Spoofed Bob public key will sent to Alice (public)

Read More