So, the scenario is: Given I'm Bob, I want to encrypt some message for Alice. The only public key I have is her `ssh-rsa`

id_rsa.pub like this:

ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAyb+qaZLwgC7KAQJzYikf3XtOWuhlMXVv2mbTKa5dp0sHPRd2RaYnH8ZRkt7V8bjqct1IHGCuxI8xyoEp4at3FHe6j9RfWiarc1ldLUCmTtryI0GGpRs6Zpvqdtpcq/1NCIYtUQAvsImyEFCtqmB2suDo1ZSllZQ0x9TCKHdCANYIOeaniuFzR57POgE3vxk/r6PO24oy8BIWqxvi29r0n1LUigVBJ7CmMHuzb4/+i1v6PxV1Lqnj6osPP9GpXpsh8kLUCby/KcmcryWNdSP0esyCdDxkA5hlIuk8qL1vzsyPluUQuc0BEHu6nuw8WQlCF1mFFxcpJL+MhWEr01WIIw== sikachu@Sikachus-Notebook.local

So, is there a way to encrypt a string using this public key so she can use her private key from `id_rsa`

(generated from `ssh-keygen`

) to decrypt the message?

(I know that it's possible right away if you're using `.pem`

key pair file. If you can show me how to convert this to the format that `openssl`

supports, that'd be great as well!)

Thanks!

`ssh-rsa`

public key already, and I don't want to add another layer of complexity (like, asking the recipient to go install gpg, etc.) – sikachu Apr 2 '13 at 0:07