shalki
shalki

Reputation: 908

Extracting a private key from a public key openssl

Is there any way by which i can extract a private key from a public key using openssl?

Upvotes: 0

Views: 689

Answers (3)

Nathan Ridley
Nathan Ridley

Reputation: 34416

The whole point of a public key is to be a token representation of your key, usable only for forward encryption and signature verification. If a public key had any way of decrypting a encrypted set of bytes, or creating a digital signature, there would be no point in having a public/private key system.

Upvotes: 2

dodexahedron
dodexahedron

Reputation: 4657

No. This is not possible, by design.

If a private key could be recovered from a public key, anyone could decrypt data signed with either key, thus defeating the purpose of public key cryptography all together.

If you have lost your private key, unfortunately you will need to generate a new one as well as new public keys to go with it.

Upvotes: 8

Sergii Kudriavtsev
Sergii Kudriavtsev

Reputation: 10532

No, there isn't. Except brute-force.

Asymmetric cryptography was invented to prevent just that - "extracting" private key from the public one.

Upvotes: 0

Related Questions