Chapter 8 Notes
Public Key cryptography: The basic idea is to do away with the necessity of a secure key
exchange, which is necessary for all private key encryption schemes. The idea is as
follows:
1) Bob creates two keys, a public key, E and a private key D.
2) Bob posts the public key in a location that anyone can access.
The important thing here is that the knowledge of E does not compromise the value of D
in any way shape or form.
3) Now, anyone who wants to send a message to Bob encrypts it using the public key E.
4) Bob can now read the message using his private key D. However, since the value of E
gives no information as to the value to D, all others can not read the message.
The idea seems easy enough, but the difficulty is in finding some mathematical function
to use in this scheme such that the knowledge of E does not compromise the secrecy of
D. Clearly in all the other schemes we have seen, knowledge of the encrypting key all but
completely gives away the decrypting key.
One thing to note however is that if you use a system outlined above with nothing extra,
although Bob can decipher a message sent to him, he can not be sure of who the sender
is, because the whole public has the ability to encipher a message, so someone could
easily indicate in their message that they were someone else and Bob would not have any
way of knowing. But, the person sending the message can be confident that no one read
can read the plaintext except for Bob, the only person with the private key.
Number Theory Background for RSA.
First, we need to go over some mathematics before we look at RSA:
Euler Phi Function
First, let’s define the Euler
φ
(phi) function:
φ
(n) = the number of integers in the set {1, 2, .
.., n-1} that are relatively prime to n.
φ
(p) = p –1 , for all prime numbers
φ
(pq) = (p-1)(q-1), where p and q are distinct primes. Here is a derivation of that result:
We want to count all values in the set {1, 2, 3, .
.., pq –1} that are relatively prime to pq.
Instead, we could count all value in the set NOT relatively prime to pq. We can list these
values: