Download presentation
Presentation is loading. Please wait.
Published byDwain Powers Modified over 6 years ago
1
Discrete Math for CS CMPSC 360 LECTURE 14 Last time:
Chinese Remainder Theorem Today: Public Key Cryptography: RSA CMPSC 360 2/27/2019
2
Cryptography Secure communications between two parties. Applications:
Military, Intelligence (NSA) E-Commerce 2/27/2019
3
Cryptography Alice encrypts message π to πΈ(π) Alice send πΈ(π) to Bob
Bob decrypts secret message πΈ(π) to π·(πΈ(π)) = π. Eve can intercept πΈ(π) but canβt read m. 2/27/2019
4
Private Key Cryptography
Example: Julius Caesar (shifting 3 letters) Today is Friday. Wrgdb lv Iulgdb. Requires a secret encryption/decryption key between two parties. 2/27/2019
5
Public Key Cryptography
Bob announces a public key π to everyone. Everyone can encrypt a message π to π(π). Only Bob can decrypt π(π) using his private decryption key π for π. 2/27/2019
6
The RSA algorithm Need the following numbers:
Two large primes (i.e., 512 bits) π and π π΅ = ππ A public encryption key π , which is relatively prime to (πβπ)(πβπ). A private decryption key π
, which is πβs inverse modulo (πβπ)(πβπ) 2/27/2019
7
πΈ π₯ = π₯ π mod π π· π₯ = π₯ π mod π ππβ‘1 mod (πβ1)(πβ1) The RSA algorithm
Encrypting a message π₯: πΈ π₯ = π₯ π mod π Decrypting a message π₯: π· π₯ = π₯ π mod π Numbers π, π are prime, and π, π satisfy: ππβ‘1 mod (πβ1)(πβ1) 2/27/2019
8
RSA is correct Fermatβs Little Theorem π·(πΈ(π₯)) = π₯ mod π in RSA
(Blackboard) 2/27/2019
9
Running time of RSA Efficient algorithm (repeated squaring) for exponentiation To create the key pairs, need to find large primes: Primes are relatively densely distributed. Testing if a number is prime is fast. Randomly generate enough large numbers and test which ones are prime. Finding π relatively prime to (πβ1)(πβ1) and its inverse is fast. 2/27/2019
10
RSA is secure Need π and π to find π from π.
Factoring a large number π is hard. 2/27/2019
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.