Hello, I am developing a software as a part of my academic project, which will allow multiple peers to communicate with each other, at the same time. This communication needs to be encrypted over network. I am using RSA for the same.
For random generation of keys it will work fine. But now the requirement is such that , I need to pre-generate the file and store it into one file. Once that is done use that public - private key pair to transfer data. For EX: If peer3 wants to send some data to peer1, he'll use public key of peer1, i.e. stored in one file. Peer1 will use the same file to get the private key of itself and will decrypt the message. I am able to store keys in one file. But while I am fetching it from file, I am not able to encrypt / decrypt it. Could you please help me out , about how should I go ahead for the same and how to store keys in the file and retrieve the keys for encryption/decryption. Thanks for any help. Thanks, Mitul Thakkar.