Rsa 1
Rsa 1
Objectives
q To distinguish between two cryptosystems:
symmetric-key and asymmetric-key
q To introduce trapdoor one-way functions and their
use in asymmetric-key cryptosystems
q To discuss the RSA cryptosystem
q To discuss the Rabin cryptosystem
q To discuss the ElGamal cryptosystem
q To discuss the elliptic curve cryptosystem
10.2
10-1 INTRODUCTION
10.3
10-1 INTRODUCTION
Note
Symmetric-key cryptography is based on sharing secrecy;
asymmetric-key cryptography is based on personal secrecy.
10.4
10.1.1 Keys
10.5
10.1.2 General Idea
10.6
10.1.2 Continued
Plaintext/Ciphertext
Unlike in symmetric-key cryptography, plaintext and
ciphertext are treated as integers in asymmetric-key
cryptography.
Encryption/Decryption
C = e(Kpublic , P) P = d(Kprivate , C)
10.7
10.1.3 Need for Both
10.8
10.1.4 Trapdoor One-Way Function
Functions
10.9
10.1.4 Continued
One-Way Function (OWF)
1. f is easy to compute.
2. f −1 is difficult to compute.
10.10
10.1.4 Continued
Example 10. 1
When n is large, n = p × q is a one-way function.
Easy Given p and q à calculate n
Difficult Given n à calculate p and q
This is the factorization problem.
Example 10. 2
When n is large, the function y = xk mod n is a trapdoor
one-way function.
Easy Given x, k, and n à calculate y
Difficult Given y, k, and n à calculate x
This is the discrete logarithm problem.
However, if we know the trapdoor, k′ such that k × k ′ = 1
mod f(n), we can use x = yk′ mod n to find x.
10.11
10-2 RSA CRYPTOSYSTEM
10.12
10.2.1 Introduction
10.13
10.2.2 Procedure
10.14
Public key encryption algorithms
Requirements:
1
+ . .
need KB ( ) and K - ( ) such that
B
- +
K (K (m)) = m
B B
+
2 given public key KB , it should be
impossible to compute private
-
key K B
Magic d
m = (m e mod n) mod n
happens!
x
letter m me c = me mod n
encrypt:
l 12 1524832 17
d
decrypt:
c c m = cd mod n letter
17 481968572106750915091411825223071697 12 l
e
(m mod n) d mod n = medmod n
ed mod (p-1)(q-1)
= m mod n
(using number theory result above)
1
= m mod n
(since we chose ed to be divisible by
(p-1)(q-1) with remainder 1 )
= m
8: Network Security 8-19
RSA: another important property
The following property will be very useful later:
- + + -
K (K (m)) = m = K (K (m))
B B B B
10.21
n http://www-fs.informatik.uni-
tuebingen.de/~reinhard/krypto/Engl
ish/4.1.e.html
10.22