Answer the question
In order to leave comments, you need to log in
What is the best way to encrypt on the client and decrypt on the server?
Good day, dear gentlemen! I wondered if it is possible to encrypt a file / photo on the client using JS , send it to the server and decrypt it using PHP and save it? What are the options? Maybe there are ready-made packages / practices? Until this moment, I had absolutely no experience with cryptography...
Thank you all for any help!
Answer the question
In order to leave comments, you need to log in
Create public/private keys on the server. public you send to the client, with its help you encrypt everything. public was invented for that, that it could be given to anyone so that they could encrypt, but someone who only has a private key can decrypt. Actually, that’s all, take RSA as an algorithm, it’s the easiest with it, there’s a lot of information, there are a lot of libraries. But you can show off and come up with something of your own.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question