Where.src/popup/views/approval.js:369-381 (decodeHexMessage) and 441-447 (the personal_sign message display).
What is wrong.decodeHexMessage slices two characters off the string and
parses the rest as hex byte pairs, so a message that is not 0x-prefixed hex
decodes to NUL/garbage; and a valid hex message that decodes to text containing
bidirectional overrides or zero-width characters is shown verbatim, so what the
user reads can differ from the byte order that signer.signMessage signs. The
raw hex is not shown alongside the decoded text.
Why it matters. A page can make the displayed message read differently from
what is signed.
Reproduction. A personal_sign request whose hex decodes to text containing
U+202E (right-to-left override) around a substituted clause renders reordered; a
non-hex message renders as invisible NUL characters.
Acceptable. Show the raw hex bytes alongside any decoded text; validate that
the input is hex before decoding; strip or visibly mark control and
bidirectional characters in the decoded view.
Definition of done.
The personal_sign screen shows the raw hex bytes as well as any decoded
text.
Control and bidirectional characters are escaped or visibly marked in the
decoded view.
A non-hex message is shown as such rather than as NUL characters.
A test asserts a bidi-override message is rendered without reordering the
visible text.
Model: fable-5-1 (review); opus-4-8 (filing)
Severity: hardening.
**Where.** `src/popup/views/approval.js:369-381` (`decodeHexMessage`) and
`441-447` (the personal_sign message display).
**What is wrong.** `decodeHexMessage` slices two characters off the string and
parses the rest as hex byte pairs, so a message that is not `0x`-prefixed hex
decodes to NUL/garbage; and a valid hex message that decodes to text containing
bidirectional overrides or zero-width characters is shown verbatim, so what the
user reads can differ from the byte order that `signer.signMessage` signs. The
raw hex is not shown alongside the decoded text.
**Why it matters.** A page can make the displayed message read differently from
what is signed.
**Reproduction.** A personal_sign request whose hex decodes to text containing
U+202E (right-to-left override) around a substituted clause renders reordered; a
non-hex message renders as invisible NUL characters.
**Acceptable.** Show the raw hex bytes alongside any decoded text; validate that
the input is hex before decoding; strip or visibly mark control and
bidirectional characters in the decoded view.
**Definition of done.**
- [ ] The personal_sign screen shows the raw hex bytes as well as any decoded
text.
- [ ] Control and bidirectional characters are escaped or visibly marked in the
decoded view.
- [ ] A non-hex message is shown as such rather than as NUL characters.
- [ ] A test asserts a bidi-override message is rendered without reordering the
visible text.
Model: fable-5-1 (review); opus-4-8 (filing)
Built in #435. The signature screen now shows a personal message's hex under "Raw data" alongside the text it decodes to, and shows control, zero-width and bidirectional characters in that text as U+XXXX marks. A message that is not hex is shown as plain text with "Sign" disabled, because signing takes the bytes from the hex and such a message has none to sign.
Model: opus-5-5
Built in https://git.eeqj.de/sneak/AutistMask/pulls/435. The signature screen now shows a personal message's hex under "Raw data" alongside the text it decodes to, and shows control, zero-width and bidirectional characters in that text as `U+XXXX` marks. A message that is not hex is shown as plain text with "Sign" disabled, because signing takes the bytes from the hex and such a message has none to sign.
Model: opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Severity: hardening.
Where.
src/popup/views/approval.js:369-381(decodeHexMessage) and441-447(the personal_sign message display).What is wrong.
decodeHexMessageslices two characters off the string andparses the rest as hex byte pairs, so a message that is not
0x-prefixed hexdecodes to NUL/garbage; and a valid hex message that decodes to text containing
bidirectional overrides or zero-width characters is shown verbatim, so what the
user reads can differ from the byte order that
signer.signMessagesigns. Theraw hex is not shown alongside the decoded text.
Why it matters. A page can make the displayed message read differently from
what is signed.
Reproduction. A personal_sign request whose hex decodes to text containing
U+202E (right-to-left override) around a substituted clause renders reordered; a
non-hex message renders as invisible NUL characters.
Acceptable. Show the raw hex bytes alongside any decoded text; validate that
the input is hex before decoding; strip or visibly mark control and
bidirectional characters in the decoded view.
Definition of done.
text.
decoded view.
visible text.
Model: fable-5-1 (review); opus-4-8 (filing)
clawbot referenced this issue2026-10-03 14:21:22 +02:00
Built in #435. The signature screen now shows a personal message's hex under "Raw data" alongside the text it decodes to, and shows control, zero-width and bidirectional characters in that text as
U+XXXXmarks. A message that is not hex is shown as plain text with "Sign" disabled, because signing takes the bytes from the hex and such a message has none to sign.Model: opus-5-5