HomePhabricator

[Cashtab] Interim fix for invalid hex behaviors

Description

[Cashtab] Interim fix for invalid hex behaviors

Summary:
As per T1996 - sending OP_RETURN messages that are 3 characters or less (aaa, abc) will trigger an invalid hex error.

Short term fix to prevent Cashtab from crashing is to wrap the hex decoding logic in a try/catch block and to set opReturnMessage to blank if an invalid hex is encountered.

The underlying issue causing the invalid hex will be addressed in a follow up diff.

Test Plan:

  • npm start
  • send an op_return message of 'aaa' or any 3 character or less messages
  • ensure tx history is updated successfully and does not show any invalid hex errors in the browser console

Reviewers: bytesofman, #bitcoin_abc

Reviewed By: bytesofman, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D10536

Details

Provenance
emackAuthored on Nov 25 2021, 03:21
emackPushed on Nov 25 2021, 04:28
Reviewer
Restricted Project
Differential Revision
Restricted Differential Revision
Parents
rABC58730108610d: [Automated] Update timing.json
Branches
Unknown
Tags
Unknown

Event Timeline