-
Notifications
You must be signed in to change notification settings - Fork 57
Description
1. Expected behavior and actual behavior.
Expected to decrypt encrypted message but returns empty string.
2. Steps to reproduce the problem.
-
pass
recipient.publicAccountinstead ofaccount.publicAccount(sender's public account)
https://github.com/nemtech/nem2-sdk-typescript-javascript/blob/3ef71309ab05ccb603c00ada86f2008faf2e50b0/test/model/transaction/EncryptedMessage.spec.ts#L35-L39What confuses is me is line 37 of above test code: I don't understand why would the
accountthat encrypts message used again to decrypt the encrypted message, while passing the public account of that sameaccount(symmetric).Shouldn't it be the
senderAccountthat does the.encryptMessage()(repro code line 39-41) and followed byrecipientAccountthat decrypts the message subsequently (repro code line 44-46)?repro code: https://repl.it/@wzulfikar/repro-codenem2-sdk-encrypted-message
3. Specifications like the version of the project, operating system, or hardware.
- TypeScript v3.3.3 (via repl.it)
- nem2-sdk v0.11.5
P.S:
I'm not sure if encrypted message is still under development, but since i saw the test and the EncryptedMessage is exported in v0.11.5, I wanted to test and see if I understand it correctly.
