[Cashtab] [Chronik] Upgrade private message decryption error handling
Summary:
As per T2718, I played around with a few different error handling approaches but found the best solution is to simply ensure the output hex is in relation to an incoming msg before attempting to decrypt.
I have seen this error trigger on occasions when you send a few outgoing private message transactions. This is because it is attempting to decrypt the private message when it's sitting in the sender's tx history, but obviously the message has been encrypted with the recipient's pubkey (not the sender's) hence resulting in these errors.
Test Plan:
- receive encrypted message, verify no decryption errors in console and the message is successfully decrypted and rendered correctly
- send encrypted message, verify no decryption errors in console and the message is successfully decrypted in the recipient wallet and rendered correctly
- ensure no regression with sending/receiving unencrypted message
- ensure no regression with sending/receiving oneToMany unencrypted message
Reviewers: bytesofman, #bitcoin_abc
Reviewed By: bytesofman, #bitcoin_abc
Differential Revision: https://reviews.bitcoinabc.org/D12260