Answer the question
In order to leave comments, you need to log in
RSA encryption in PYTHON. How to initially generate a public key, and on another device, having a public key, generate a private one?
It is necessary to generate a public key using it to encrypt information and then send a public key to another device and use the public key to generate a private key and decrypt the text
Answer the question
In order to leave comments, you need to log in
You don't understand the meaning of the keys. If one key could be used to restore the second, then they would not provide any protection.
The correct scheme looks like this:
Device A generates a key pair and shares the public key.
Device B downloads the public key, encrypts the document with it, and sends it to device A.
Device A, using the paired private key, decrypts the document.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question