rsa and fermat
play

RSA and Fermat. RSA: Key Generation: (Alice) Primes: p , q . N = pq - PowerPoint PPT Presentation

RSA and Fermat. RSA: Key Generation: (Alice) Primes: p , q . N = pq . Encryption Key: e , where gcd ( e , ( p 1 )( q 1 ))) = 1 Decryption Key: d = e 1 ( mod ( p 1 )( q 1 )) Message: m Encryption (Bob): y = E ( m ) = m e ( mod


  1. RSA and Fermat. RSA: Key Generation: (Alice) Primes: p , q . N = pq . Encryption Key: e , where gcd ( e , ( p − 1 )( q − 1 ))) = 1 Decryption Key: d = e − 1 ( mod ( p − 1 )( q − 1 )) Message: m Encryption (Bob): y = E ( m ) = m e ( mod N ) . Decryption (Alice): D ( y ) = y d ( mod N ) . Result: m ed ( mod N )

  2. RSA and Fermat. RSA: Key Generation: (Alice) Primes: p , q . N = pq . Encryption Key: e , where gcd ( e , ( p − 1 )( q − 1 ))) = 1 Decryption Key: d = e − 1 ( mod ( p − 1 )( q − 1 )) Message: m Encryption (Bob): y = E ( m ) = m e ( mod N ) . Decryption (Alice): D ( y ) = y d ( mod N ) . Result: m ed ( mod N ) Want D ( E ( x )) = x

  3. RSA and Fermat. RSA: Key Generation: (Alice) Primes: p , q . N = pq . Encryption Key: e , where gcd ( e , ( p − 1 )( q − 1 ))) = 1 Decryption Key: d = e − 1 ( mod ( p − 1 )( q − 1 )) Message: m Encryption (Bob): y = E ( m ) = m e ( mod N ) . Decryption (Alice): D ( y ) = y d ( mod N ) . Result: m ed ( mod N ) Want D ( E ( x )) = x Thm: x ed = x ( mod N )

  4. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 ))

  5. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic!

  6. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) ,

  7. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) .

  8. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ?

  9. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1.

  10. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ?

  11. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3.

  12. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ?

  13. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ?

  14. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ?

  15. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3.

  16. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p )

  17. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back

  18. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) .

  19. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) .

  20. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) . Proof of Corollary. If a = 0, a k ( p − 1 )+ 1 = 0 ( mod m ) .

  21. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) . Proof of Corollary. If a = 0, a k ( p − 1 )+ 1 = 0 ( mod m ) . Otherwise

  22. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) . Proof of Corollary. If a = 0, a k ( p − 1 )+ 1 = 0 ( mod m ) . Otherwise a 1 + k ( p − 1 ) ≡

  23. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) . Proof of Corollary. If a = 0, a k ( p − 1 )+ 1 = 0 ( mod m ) . Otherwise a 1 + k ( p − 1 ) ≡ a 1 ∗ ( a p − 1 ) k

  24. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) . Proof of Corollary. If a = 0, a k ( p − 1 )+ 1 = 0 ( mod m ) . Otherwise a 1 + k ( p − 1 ) ≡ a 1 ∗ ( a p − 1 ) k ≡ a ∗ ( 1 ) b ≡ a ( mod p )

  25. RSA and Fermat: mathematical connection Thm: m ed = m ( mod pq ) if ed = 1 ( mod ( p − 1 )( q − 1 )) Seems like magic! Fermat’s Little Theorem: For prime p , and a �≡ 0 ( mod p ) , a p − 1 ≡ 1 ( mod p ) . 3 6 ( mod 7 ) ? 1. 3 7 ( mod 7 ) ? 3. 3 19 ( mod 7 ) ? 3 3 ∗ 6 + 1 ( mod 7 ) ? ( 3 3 ∗ 6 ∗ 3 ) ( mod 7 ) ? 3. Corollary: a k ( p − 1 )+ 1 = a ( mod p ) Get a back when exponent is 1 ( mod p − 1 ) . A little like RSA: a ed ( mod ( p − 1 )( q − 1 )) is a when exponent is 1 ( mod ( p − 1 )( q − 1 )) . Proof of Corollary. If a = 0, a k ( p − 1 )+ 1 = 0 ( mod m ) . Otherwise a 1 + k ( p − 1 ) ≡ a 1 ∗ ( a p − 1 ) k ≡ a ∗ ( 1 ) b ≡ a ( mod p )

Recommend


More recommend