Score:0

How does knowing the factors of the key help me decrypt?

cn flag

I recently started learning about cryptography and its Quantum aspect and I came across Shor's Algorithm (which solves the following problem: "Given an integer N, find its prime factors").

I also came across this video called "How Quantum Computers Break Encryption | Shor's Algorithm Explained"

I am still confused about how knowing the factors of the key is going to help me solve the problem.

kelalaka avatar
in flag
[This answer might be helpful](https://crypto.stackexchange.com/a/70215/18298)
Score:1
my flag

I came across Shor's Algorithm (which solves the following problem: "Given an integer N, find its prime factors").

Actually, Shor's algorithm solves the problem "given a periodic function $f$, that is, if $\underbrace{f(f(... f(a))...)}_{k\text{ times}} = a$, what's $k$?"

By specifying $f$ cleverly, we can use this to solve the factorization problem. I note this because it can be used to solve other interesting problems as well.

In any case, what are you really asking is "if we can factor the key, how does that help us break RSA"? Note that relying on the difficulty of factorization what RSA depends on; other methods (such as Diffie-Hellman) are equally vulnerable to Shor's algorithm, but they use a different $f$ function.

Well, with RSA, the public exponent $e$ and the private exponent $d$ are related by $e \cdot d \equiv 1 \pmod{\text{lcm}(p-1, q-1)}$. It turns out that if we know the prime factors $p, q$ and we know the public exponent $e$ (which is given in the public key), it is easy to compute the private exponent $d$; that immediately gives us a way to decrypt via $P = C^d \bmod n$.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.