RSA Public-Key Cryptography
- 48Unfamiliar
- 0Learning
- 0Familiar
- 0Mastered
What makes RSA a public-key cryptosystem?
48 questions
- 1
What makes RSA a public-key cryptosystem?
Model answer
Its public key lets anyone encrypt a message for a designated receiver, while only the receiver can decrypt it using a private key.
Explanation
The sender needs only publicly available information, but decryption depends on secret information held by the receiver.
- 2
Why can RSA allow someone to send a secret message without prior contact with the receiver?
Model answer
The sender can use the receiver’s publicly available key to encrypt the message, so they do not need to establish a secret key together beforehand.
Explanation
The public key is published in advance and can be used by anyone who wants to send the receiver a message.
- 3
Why does public-key encryption seem paradoxical?
Model answer
The encryption method and key can be public, yet the message remains secret because only the receiver has the information needed to decrypt it.
Explanation
It appears surprising that secrecy can be achieved when the sender’s method and transmitted ciphertext are visible to others.
- 4
What is mental chess, and what does it demonstrate about chess grandmasters?
Model answer
Mental chess is playing a game by verbally announcing moves without a board or pieces; it demonstrates that skilled players can track and play chess mentally.
Explanation
The players communicate moves using chess notation and maintain the game in their minds.
- 5
How does the example of mental chess set up the idea of mental poker?
Model answer
Mental chess shows that a game can be played without physical pieces, prompting the question of whether poker could also be played without directly seeing or handling the cards.
Explanation
The comparison introduces a seemingly impossible task that public-key cryptography can make possible.
- 6
What does the mental-poker example show about the possible uses of public-key cryptography?
Model answer
Public-key cryptography can enable people to play poker without trusting one person with direct control of the deal or needing to reveal their cards.
Explanation
The content describes a method for mental poker using public-key cryptography, associated with Rivest and Shamir.
- 7
What is an injective function, and why does injectivity not guarantee an easy way to invert a function?
Model answer
An injective function maps different inputs to different outputs, so each output in its range has a unique input. Finding that input can still be computationally prohibitive.
Explanation
Uniqueness of an inverse is a mathematical property; efficiently computing the inverse is a separate question.
- 8
What is a one-way function?
Model answer
It is a function that is easy to compute but believed to be hard to invert.
Explanation
The difficulty is not that an inverse does not exist, but that finding it may require too much computation.
- 9
How does factoring relate to the one-way-function idea used to motivate RSA?
Model answer
Multiplying two large primes is easy, while factoring their product into the original primes is believed to be difficult.
Explanation
This difference between easy computation and hard inversion motivates the use of RSA.
- 10
What relationship between factoring and the P-versus-NP problem is described in the content?
Model answer
Factoring is presented as a related open problem, though it is weaker than the P-versus-NP question; factoring might be possible even if P does not equal NP.
Explanation
The content also notes that the existence of one-way functions is closely connected to the P-versus-NP question.
- 11
What values does the RSA receiver choose when setting up a key pair?
Model answer
The receiver chooses two large primes, p and q, and multiplies them to obtain n=pq.
Explanation
The primes are generated by the receiver before the public and private keys are formed.
- 12
Why should the primes used in RSA be large and chosen unpredictably?
Model answer
Large, unpredictably chosen primes make it difficult for others to guess the factors of n.
Explanation
The content recommends primes hundreds of digits long and warns that predictable choices could create a vulnerability.
- 13
What is the RSA modulus, and how is it formed?
Model answer
The modulus is n, formed by multiplying the two primes: n=pq.
Explanation
The modulus is part of the public key and is also used for the encryption and decryption calculations.
- 14
How is the public exponent e chosen in the described RSA setup?
Model answer
It is chosen to be relatively prime to (p−1)(q−1).
Explanation
This condition ensures that e has a multiplicative inverse modulo (p−1)(q−1).
- 15
What is the connection between (p−1)(q−1) and Euler’s function of n?
Model answer
For the RSA primes, Euler’s function of n=pq is [0m(p-1)(q-1).
Explanation
The key-generation recipe uses this product as the modulus for finding the inverse of e.
- 16
Which values make up the RSA public key?
Model answer
The public key consists of e and n.
Explanation
The receiver publishes both values so senders can look them up and encrypt messages.
- 17
How does the receiver obtain the private exponent d?
Model answer
The receiver computes d as the multiplicative inverse of e modulo (p−1)(q−1).
Explanation
Because e is relatively prime to this modulus, the inverse exists and can be found using the extended Euclidean algorithm.
- 18
Why can the receiver find the private exponent efficiently?
Model answer
The receiver can use the extended Euclidean algorithm, also called the Pulverizer in the content, to compute the modular inverse.
Explanation
The algorithm finds the inverse of e because key generation ensures the required relative-primality condition.
- 19
Why is d kept secret, and who knows it?
Model answer
The receiver keeps d secret because it is the private key needed for decryption; the receiver knows it after generating the key pair.
Explanation
The receiver’s knowledge of the chosen primes and the computed inverse allows the receiver to obtain d.
- 20
How does a sender prepare a message for RSA encryption?
Model answer
The sender represents the message as a number m in the permitted range and uses the receiver’s public key (e,n).
Explanation
Messages larger than the available range can be divided into smaller blocks.
- 21
What range of numbers is used to represent an RSA message in the described procedure?
Model answer
The message is represented as a number from 1 to n.
Explanation
The content describes a message block that fits within the range determined by the modulus.
- 22
What does the sender do if a message is too large to fit in one RSA message block?
Model answer
The sender breaks it into smaller pieces that fit within the permitted range.
Explanation
The content illustrates this with blocks sized to fit the modulus.
- 23
How does the sender compute the RSA ciphertext?
Model answer
The sender computes me modulo n and sends the result, denoted by [0m\hat{m}.
Explanation
The public exponent e and modulus n are used to transform the message into its encrypted form.
- 24
How does the receiver decrypt the ciphertext?
Model answer
The receiver raises the received ciphertext to the private exponent d modulo n.
Explanation
The receiver computes [0m\hat{m}^d modulo n to recover the original message.
- 25
Why does RSA decryption recover the original message when the message is relatively prime to n?
Model answer
The relation between e and d, together with Euler’s theorem, makes raising the ciphertext to the power d modulo n recover m.
Explanation
The content identifies Euler’s theorem as the reason the decryption calculation works in this case.
- 26
Does the RSA decryption result described in the content apply only when m is relatively prime to n?
Model answer
No. Although the Euler’s theorem argument is given for messages relatively prime to n, the content states that RSA decryption works for all m.
Explanation
The all-messages result is described as a further theoretical fact to be established separately.
- 27
Why does the content say messages that are not relatively prime to n are unlikely to occur?
Model answer
A message sharing a factor with n could enable someone to factor n, and factoring is believed to be difficult.
Explanation
This makes such messages unlikely under the assumptions described, though the RSA method is stated to work for them too.
- 28
What prime-density result does the prime number theorem give?
Model answer
If [0m\pi(n) counts primes less than or equal to n, then for large n it is approximately n divided by the natural logarithm of n.
Explanation
This describes the asymptotic density of primes among positive integers.
- 29
What lower bound on [0m\pi(n) is given by Chebyshev’s bound?
Model answer
Chebyshev’s bound gives [0m\pi(n) [0m\ge n/(4 log n).
Explanation
The content presents this as a weaker but more elementary bound than the prime number theorem.
- 30
How do prime-density results support the practical generation of large RSA primes?
Model answer
They show that primes are sufficiently common that searching through a manageable number of candidates is likely to find one.
Explanation
The content argues that prime density makes random searching feasible if primality can be tested efficiently.
- 31
Why must RSA key generation include an efficient way to test whether a candidate is prime?
Model answer
The receiver needs to recognize prime candidates efficiently for the search for large primes to be practical.
Explanation
Even if primes occur often enough, testing every candidate too slowly would make key generation infeasible.
- 32
How can the receiver efficiently search for a suitable public exponent e?
Model answer
The receiver can try candidate values and test whether each is relatively prime to (p−1)(q−1).
Explanation
The content says that only a few candidates are typically expected to be needed.
- 33
How does the receiver test whether a candidate e is relatively prime to (p−1)(q−1)?
Model answer
The receiver computes the greatest common divisor and checks whether it equals 1.
Explanation
The greatest common divisor can be computed efficiently with Euclid’s algorithm.
- 34
What is the role of the extended Euclidean algorithm in RSA key generation?
Model answer
It computes the private exponent d, the modular inverse of e modulo (p−1)(q−1).
Explanation
The content refers to this extended algorithm as the Pulverizer.
- 35
State Fermat’s primality condition for a prime candidate n.
Model answer
If n is prime, then for every nonzero a modulo n, an−1 is congruent to 1 modulo n.
Explanation
This condition is the special case of Euler’s theorem used by the Fermat test.
- 36
What can be concluded if a candidate n fails the Fermat test for some a?
Model answer
The candidate n is not prime.
Explanation
Every prime satisfies the stated Fermat condition for all nonzero choices of a.
- 37
Does passing one Fermat test prove that n is prime?
Model answer
No. A composite number can still satisfy the Fermat equation for a particular choice of a.
Explanation
A passing test is evidence, but it does not by itself establish primality.
- 38
How does repeating the Fermat test with random values of a improve confidence in a candidate?
Model answer
For the composite numbers covered by the test’s probability guarantee, at least half of the possible values of a reveal compositeness, so repeated random trials reduce the chance of missing it.
Explanation
Each trial checks a new randomly chosen nonzero value; the guarantee does not apply to Carmichael numbers.
- 39
According to the content, what is the chance that a composite candidate passes 50 independent random Fermat tests, under the stated probability guarantee?
Model answer
The chance is at most 1/250.
Explanation
For each trial, the chance of failing to expose compositeness is at most one half, so the chance across 50 independent trials is at most 1/250.
- 40
What are Carmichael numbers, and why are they a complication for the Fermat test?
Model answer
They are composite numbers for which the usual claim that at least half of the test values expose compositeness does not hold.
Explanation
They can pass Fermat tests despite being composite, so the simple probability argument has an exception.
- 41
Why does the content regard the Fermat test as a plausible practical primality test despite its limitation?
Model answer
Carmichael numbers are described as sparse, making the exception unlikely when candidates are chosen at random; repeated tests also make ordinary composite candidates unlikely to pass.
Explanation
The test is presented as a pragmatic way to identify likely primes, not as a perfect proof of primality.
- 42
Why would factoring the RSA modulus n allow an attacker to find the private exponent?
Model answer
Factoring n reveals p and q, which lets the attacker compute (p−1)(q−1) and then find the inverse of public e modulo that value.
Explanation
The attacker can use the same extended Euclidean method as the receiver to calculate d.
- 43
What does the content claim about the relationship between finding d and factoring n?
Model answer
It states that if someone can find the private key d, they can also factor n.
Explanation
Thus, factoring the modulus and recovering the private key are linked in both directions in the described argument.
- 44
What security conclusion follows if factoring large RSA moduli is hard?
Model answer
Finding the private exponent from the public information is also hard, according to the relationship described.
Explanation
The content uses the claim that recovering d would allow factoring n.
- 45
Why does the factoring relationship not prove that every way of breaking RSA is as hard as factoring?
Model answer
An attacker might conceivably decrypt messages by a method that does not first recover the private exponent.
Explanation
The content distinguishes finding the key from decrypting by any possible method.
- 46
What stronger security theorem for RSA would be desirable, and is it known?
Model answer
A desirable theorem would show that breaking RSA by any method is as hard as factoring; the content says this has not been proved.
Explanation
This remains an open problem, so RSA lacks that strongest theoretical security assurance.
- 47
What practical evidence is offered for confidence in RSA’s security?
Model answer
The content points to decades of mathematical attempts to factor efficiently and to sophisticated cryptographers and computing resources failing to crack RSA.
Explanation
This practical history supports confidence but does not constitute a proof of security.
- 48
What kinds of RSA setup problems were discovered over time, and how were they addressed?
Model answer
Various glitches involving the choice of p, q, and e were found, and additional rules for choosing them were identified and applied.
Explanation
The content describes these issues as fixable and says RSA has remained robust against attacks.

Ask anything
We've read this whole study set, so questions about it get the best answers.