This question already has an answer here:
The idea is to send an encrypted message in such a way that the receiver can verify the sender. Here is the proposal:
I generate an RSA public-private key pair, and I give the private key to Barry.
I keep my public key secret (!) and I use it to encrypt messages.
When I send an encrypted message to Barry, if he can decrypt it using the private key I gave him, then he knows the message came from me.
Is this secure? Without access to my public key, but perhaps an eye on the messages, can anyone else fool Barry? (And does it matter if other people see the private key?)
If not, what kind of approach should we be using to sign encrypted messages, without having to perform a multiple-trip hand-shake? (Preferably still using RSA.)