Signature containing file link to non-existent file and file-based image leads to wrong blocked content notification

RESOLVED FIXED in Thunderbird 53.0

Status

Thunderbird
Message Compose Window
RESOLVED FIXED
7 months ago
7 months ago

People

(Reporter: Jorg K (GMT+2), Assigned: Jorg K (GMT+2))

Tracking

(Blocks: 1 bug)

Trunk
Thunderbird 53.0

Thunderbird Tracking Flags

(thunderbird52+ fixed, thunderbird53 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

7 months ago
This signature

<html>
<body>
<img src='file://D:/Desktop/Dell%20Latitude%203150.png'><br>
<a href='file://D:/Desktop/BVG%20Preise%202016.pdf'>BVG</a>
</body>
</html>

leads to a blocked content notification for the PNG, not the PDF.

Without the PDF reference it works fine.

Without the PNG reference there is no blocked content notification.

I was just thinking: What about people who include their vCard via a file link? Maybe we should process links in signatures as well. Another bug for that?
Flags: needinfo?(mkmelin+mozilla)
(Assignee)

Updated

7 months ago
Blocks: 1322155
(Assignee)

Comment 1

7 months ago
Filed bug 1322173 for the links in signatures.
(Assignee)

Updated

7 months ago
Flags: needinfo?(mkmelin+mozilla)

Comment 2

7 months ago
Huh? I don't get a notification for that. And we bail on setting up the notification for event.target.localName != "img" so I don't see how it would happen code wise either.
(Assignee)

Comment 3

7 months ago
Hah, there is a trick ;-)

<html>
<body>
<img src='file://D:/Desktop/Dell%20Latitude%203150.png'><br>
<a href='file://D:/Desktop/BVG%20Preise%202016.pdf'>BVG</a>
</body>
</html>

And I happen to have renamed "BVG Preise 2016.pdf" to BVG-Preise-2016.pdf.

I don't know why these things happen to me. I find bugs that no one else finds. My first job in IT was testing and they hated me.
Summary: Signature containing file link and file-based image leads to wrong blocked content notification → Signature containing file link to non-existent file and file-based image leads to wrong blocked content notification
(Assignee)

Comment 4

7 months ago
Works fine if the file exists. Sorry ;-(
(Assignee)

Comment 5

7 months ago
Caused by faulty error handling in nsMsgCompose.cpp. The loop that replaces file URLs in the signature goes from the end and finds the non-existent PDF first. I gets an error and bails not processing the PNG.
(Assignee)

Comment 6

7 months ago
Created attachment 8817591 [details] [diff] [review]
1322145-sig-processing.patch (v1)

There, I've done it for you.
Assignee: nobody → jorgk
Status: NEW → ASSIGNED
Attachment #8817591 - Flags: review?(mkmelin+mozilla)
(Assignee)

Comment 7

7 months ago
Created attachment 8817592 [details] [diff] [review]
1322145-sig-processing.patch (v1b).

Fixed comment.
Attachment #8817591 - Attachment is obsolete: true
Attachment #8817591 - Flags: review?(mkmelin+mozilla)
Attachment #8817592 - Flags: review?(mkmelin+mozilla)

Comment 8

7 months ago
Comment on attachment 8817592 [details] [diff] [review]
1322145-sig-processing.patch (v1b).

Review of attachment 8817592 [details] [diff] [review]:
-----------------------------------------------------------------

Ah, great! r=mkmelin
Attachment #8817592 - Flags: review?(mkmelin+mozilla) → review+
(Assignee)

Comment 9

7 months ago
C-C (TB 53): https://hg.mozilla.org/comm-central/rev/29b034f30fcb12b0e252a33502ba44521f5768d9
C-A (TB 52): https://hg.mozilla.org/releases/comm-aurora/rev/5c2c3abb9ae3885bd0558ed90671d15c5be367b2
Status: ASSIGNED → RESOLVED
Last Resolved: 7 months ago
status-thunderbird52: affected → fixed
status-thunderbird53: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 53.0
(Assignee)

Updated

7 months ago
Attachment #8817592 - Flags: approval-comm-aurora+
You need to log in before you can comment on or make changes to this bug.