If private and public keys are performing the same task (although asymmetrically), but I mean each one can encrypt something that only the other one can decrypt, can I create a paper wallet and share my "private key" and just keep my "public key" private?
-
5Some public key cryptosystems have this kind of symmetry (RSA does), but it's not a general property of digital signature algorithms. Signing and verifying are not symmetric at all for ECDSA.– Nate EldredgeCommented Feb 3, 2016 at 4:55
-
1@NateEldredge That's short, but it's an answer. Please rather post it as such. :)– Murch ♦Commented Feb 3, 2016 at 8:09
2 Answers
The ECDSA signature algorithm used by Bitcoin doesn't have symmetry between its private and public keys. If you read about how the algorithm works, they aren't even the same type of mathematical object: a private key is an integer, while a public key is a point on an elliptic curve. They do not, in your words, "perform the same task." So you can't do that. (It's not at all clear why you would want to, in the first place.)
In fact, ECDSA is an algorithm for digital signatures, not encryption; ECDSA can't be used to encrypt or decrypt secret data at all.
The property that "each one can encrypt something the other can decrypt" is a special feature of the RSA algorithm. In this particular cryptosystem, signing and verifying (and encryption/decryption) use the same process; people sometimes say that signing in RSA consists of "encrypting using the private key". One could interchange the roles of the private and public keys, and the algorithm would still work mathematically. But this isn't a general feature of all asymmetric cryptosystems.
(Even for RSA, although mathematically you could switch the private and public keys, this would totally blow its security: as typically implemented, the public exponent is an arbitrary integer that doesn't have to be secret, and people usually just use 65537. But the private exponent is hard to compute without knowing the primes used to generate the key. So if you released what was intended to be the "private" key as your public key, people would have no trouble guessing the other key as well, and then you have no security.)
-
1Your answer is correct. I'd like to add that in RSA, mathematically speaking the public key and private key behave the same way, but in practice we tweak them. The public exponent is one of those tweaks. Another tweak is that the private key contains the factorization of n, which allows faster arithmetic via the Chinese remainder theorem.– NayukiCommented Feb 4, 2016 at 22:06
No.
Your private key can be decoded/reversed to reveal your public key. Public keys can not be reversed to reveal the private key. If you share your private key they have EVERYTHING.