-1

I am using RSA asymmetric encryption, encrypting the data using the public key and decrypting the data using the private key.

The public key will be shared in clients machines.

My question is if the user get the public key is there any way to get the private key using the public one?

Maarten Bodewes
  • 90,524
  • 13
  • 150
  • 263
Yasser-Farag
  • 592
  • 4
  • 9
  • 28

3 Answers3

4

The keys are mathematically linked, but it is not possible to get the private key from the public key (at least no one knows or admits to knowing how to do so). However, you can obtain the public key from the private key.

If you don't have a good understanding of Public-key cryptography, you might wonder about things and ask questions. And that's OK, it's confusing when you first think about it. Here's a great book Cryptography Decrypted that I recommend to friends who wish to learn more about cryptography in general. It has a very good section on Public-key cryptography and presents it in such a way that anyone can understand.

2

No. That is the very definition of public key cryptography.

ntoskrnl
  • 5,714
  • 2
  • 27
  • 31
-2

Sure. Some currently-known methods for obtaining a private key, when the public key is already known, include:

1) Brute force. Should take about a million years or so to complete, depending on hardware. Suggestion---expire the public keys once every 500,000 years or so.

2) The user is the NSA, in which case it's entirely possible that they've introduced subtle, top-secret vulnerabilities into the hardware or software you're using to generate the keypair.

3) The user has a quantum computer. They'd have to invent it first, though. Probably worth a Nobel prize right there.

Keith Ripley
  • 1,020
  • 1
  • 10
  • 18
  • Nonsense. It's not possible to derive the private key from the public key even with brute force. Using publicly scrutinized algorithms like RSA rules out any backdoors. While quantum computers *may* be used to attack RSA in the far future, such attacks have nothing to do with getting the private key from the public key. – ntoskrnl Sep 20 '13 at 13:05
  • I guess sarcasm is lost on the population of StackOverflow. RSA is not vulnerable. But if you read the news, you would know that the NSA attack vector isn't to attack cryptographic algorithms themselves, but to ensure that the *implementation* of those algorithms has an issue. Without reviewing it personally, how would you know? – Keith Ripley Nov 12 '13 at 18:31