virtualeconomy / js-v-sdk

[DEPRECATED and please use https://github.com/virtualeconomy/js-vsys instead] Java Script library for V Systems
https://www.npmjs.com/package/@virtualeconomy/js-v-sdk
MIT License
10 stars 5 forks source link

Encrypt attachment #47

Closed vipertechofficial closed 3 years ago

vipertechofficial commented 3 years ago

Hello,

Is there any solution to encrypt the transaction's attachement, I know it is limited to 140 characters so might something such as an algorithm or some functionalities further developed with the current Vsys agenda (possibly zK-SnarkS), could do the trick to send privatenote links encrypted using the receiver's public key?

SheldonYS commented 3 years ago

The attachment is shown with base58 encoding. If you use SDK to input attachment, just input plain text. It will do base58 encoding and then broadcast to blockchain.

vipertechofficial commented 3 years ago

@SheldonYS Thanks.

I am now wondering if one can implement private messaging trough https://privnote.com/ while using the receiver public key to encrypt the url provided by privnote, two factors enter into account, encrypted url length and which algorithms could one use to work with, I mean I guess it is SHA256 but it wouldn't work with https://github.com/cyph/mceliece.js right ?

0x100cc commented 3 years ago

For specific implementation, please refer to How to Encrypt and Decrypt a message in the wiki.