Closed Bug 1793918 Opened 2 years ago Closed 2 years ago

Message with missing/empty/corrupt From: header has no message header buttons (reply, forward, delete etc.)

Categories

(Thunderbird :: Message Reader UI, defect)

Thunderbird 102
defect

Tracking

(thunderbird_esr102+ fixed, thunderbird110 affected)

VERIFIED FIXED
111 Branch
Tracking Status
thunderbird_esr102 + fixed
thunderbird110 --- affected

People

(Reporter: markus, Assigned: eprendergast)

References

Details

(Keywords: good-first-bug)

Attachments

(3 files)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:105.0) Gecko/20100101 Firefox/105.0

Steps to reproduce:

I get several spam-mails missing the From-Address. I cannot delete them.

This is part of the source of the e-mail (you see a corrupt From-Header):

X-Spam-Status: Yes, score=100.00, required=95.00
rom: "Transformation Insider"
Subject:Oprah's Weight Loss
To: me@mydomain.com
Cc: me@mydomain.com <Thu, 06 Oct 2022 01:10:28 +0200 -0400>
Date: Thu, 06 Oct 2022 01:10:28 +0200
Content-Type: multipart/mixed;
...

Actual results:

I cannot delete the spam-mail, as the toolbar with "reply, Forward, Archive, Junk, Delete , More..." is also missing. This problem only appears on e-mails missing the From:-Header

Expected results:

The buttons should still be there (except "Reply", as you cannot reply to an address which does not exist)

See Also: → 1797728
Summary: no reply, forward, view-source or delete-buttons when from-address is missing → Message with missing/empty/corrupt From: header has no message header buttons (eply, forward, view-source or delete-buttons when from-address is missing

Confirming on TB 102.5.0, Win10 (see screenshot 1 above).
The presence of message action buttons should really not depend on the correctness/presence of the From: header (should be easy to fix).
This holds especially true for spam messages which are most likely to be affected (as in reporter's case) - Thunderbird should allow user to easily delete them or mark as spam using the header butttons.

(In reply to markus@senoner.com from comment #0)

Steps to reproduce:
I get several spam-mails missing the From-Address.

Valid scenario, odd outcome!

I cannot delete them.

Well, you still can, but not using the header buttons: After selecting message(s)...

  • press (Shift+)Del key for (permanent) deletion
  • right-click on message and delete via Context menu
  • From main menu, Edit > Delete Message
  • likewise, pretty much all message actions will be available from context menu, main menu, or even dedicated shortcuts.
Severity: -- → S3
Status: UNCONFIRMED → NEW
Component: Untriaged → Message Reader UI
Ever confirmed: true
Keywords: good-first-bug
Summary: Message with missing/empty/corrupt From: header has no message header buttons (eply, forward, view-source or delete-buttons when from-address is missing → Message with missing/empty/corrupt From: header has no message header buttons (reply, forward, delete etc.)
Duplicate of this bug: 1807955
Duplicate of this bug: 1808034

Added EnsureFromValue() in order to make messages w/o a from header have a blank value there so that the header toolbar so the header toolbar shows up.

Assignee: nobody → eprendergast
Status: NEW → ASSIGNED

Thank you so much for your help and contribution.
This could benefit from adding a check to our tests. Would you be able to provide an .eml file without any personal data with a missing From so we can add a test for it?
Also, is the patch created against daily/tip, right?

Flags: needinfo?(eprendergast)
Attached file nofrom.eml

Here is an .eml file lacking a from header.

And yes, this patch is against the tip branch.

Flags: needinfo?(eprendergast)

I reviewed and approved the patch, but let's wait for a try-run before merging: https://treeherder.mozilla.org/jobs?repo=try-comm-central&revision=eea7ec63a5982bf0ad968af0daf485ffec8ebee5
Never know if these changes might affect a test.

Target Milestone: --- → 111 Branch

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/49167e4ec375
Ensure that messages always have a from header r=aleca

Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Duplicate of this bug: 1797728

Verified fixed (for present, but empty From: header) on Daily 114.0a1 (2023-04-17) (64-bit), Win10, using testcase attachment 9302505 [details] from duplicate bug 1797728. Should be uplifted to ESR.

Status: RESOLVED → VERIFIED

Comment on attachment 9313437 [details]
Bug 1793918 - Ensure that messages always have a from header r=aleca

[Approval Request Comment]
Regression caused by (bug #):
User impact if declined: Generated/malformed/spam messages without a From: header or with empty From: header are harder to act on and the interface looks broken because we're not showing header buttons.
Testing completed (on c-c, etc.): Yes.
Risk to taking this patch (and alternatives if risky): Low. Small, contained, and pretty straightforward code change.

Attachment #9313437 - Flags: approval-comm-esr102?

Comment on attachment 9313437 [details]
Bug 1793918 - Ensure that messages always have a from header r=aleca

[Triage Comment]
Approved for esr102

Attachment #9313437 - Flags: approval-comm-esr102? → approval-comm-esr102+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: