chainapsis / keplr-wallet

The most powerful wallet for the Cosmos ecosystem and the Interchain
https://www.keplr.app
Other
774 stars 463 forks source link

Exchanging encrypted data using Keplr #659

Open ThierrySans opened 1 year ago

ThierrySans commented 1 year ago

Is there a way to use Keplr to encrypt/decrypt data using the private/public key pair. Basically, I want Alice to encrypt a small piece of text (like a password) using Bob's public key and have Bob decrypting it using his private key from his Keplr Wallet. Is that possible currently?

BTW, it seems that Metamask has this kind of feature: https://betterprogramming.pub/exchanging-encrypted-data-on-blockchain-using-metamask-a2e65a9a896c

This feature is very useful to encrypt data and exchange it on-chain confidentially.

But I did not find anything like that for Keplr. If not not, can we consider adding such a feature?

Thunnini commented 1 year ago

We would try to consider this, but we do not have plans to integrate this in a near future.

hu55a1n1 commented 1 year ago

Just my two cents on the topic - encrypting using Bob's public key should already be possible but you'd have to use an encryption scheme that works with ECC (see ecies.js). You'd need Bob's private key for decryption though - not sure if Keplr allows you to access it.