matcha icon indicating copy to clipboard operation
matcha copied to clipboard

BUG: Email split without validation in inbox

Open andrinoff opened this issue 7 months ago • 2 comments

Describe the bug Email parsing at tui/inbox.go:229 uses strings.SplitN(email, "@", 2) without validating result has 2 parts. Malformed email could cause index panic.

To reproduce

  1. Receive malformed email without @ symbol
  2. Split returns 1 element
  3. Accessing [1] panics

Expected behavior Check len(parts) == 2 before accessing parts[1]

Matcha version master

OS All

Additional context File: tui/inbox.go line 229 Missing bounds check on split result

andrinoff avatar Apr 21 '26 14:04 andrinoff

This has had no activity for 30 days. It will be closed in 14 days unless updated. Comment or remove the stale label to keep it open.

floatpanebot avatar May 22 '26 06:05 floatpanebot

Closing due to inactivity. Reopen if still relevant.

floatpanebot avatar Jun 04 '26 19:06 floatpanebot