Email invitation may not be displayed when description contains non ascii characters

RESOLVED FIXED in 4.7.5

Status

Calendar
E-mail based Scheduling (iTIP/iMIP)
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: kkapsner, Assigned: MakeMyDay)

Tracking

Lightning 4.7.2
4.7.5
x86_64
Windows 7

Details

Attachments

(1 attachment)

(Reporter)

Description

2 years ago
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:48.0) Gecko/20100101 Firefox/48.0
Build ID: 20160726073904

Steps to reproduce:

Create an event and add yourself (best with a differen mail adress) as participant. Add "+/-" to the description and save the event.
A mail with a ics is generated and sent to your other mail adress.
Open that mail with thunderbird with installed lightning.


Actual results:

The event invitation is not displayed.


Expected results:

The event invitation should be displayed.

The Problem is that .kGlyphSubstitution is used with scanHTML (file ltnInvitationUtils.jsm line 98) which produces non-standard HTML (see ). Removing this line solves the problem.
(Reporter)

Updated

2 years ago
OS: Unspecified → Windows 7
Hardware: Unspecified → x86_64
(Assignee)

Updated

2 years ago
Assignee: nobody → makemyday
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Summary: certain ics requests can not be displayed → Email invitation may not be displayed when description contains non ascii characters
(Assignee)

Comment 2

2 years ago
Created attachment 8795730 [details] [diff] [review]
FixNonAsciiCharacterProblemInInvitationPreview-V1.diff

This patch takes care. I'm not removing kGlyphSubstitution mode because in most cases it works properly to convert smilies. Long term, we may make use of the chat implementation for that, but for now this is sufficient that way.

This needs to go up to esr, although we unfortunately missed the train for 4.7.4.
Attachment #8795730 - Flags: review?(philipp)
Attachment #8795730 - Flags: approval-calendar-esr?(philipp)
Attachment #8795730 - Flags: approval-calendar-beta?(philipp)
Attachment #8795730 - Flags: approval-calendar-aurora?(philipp)
Comment on attachment 8795730 [details] [diff] [review]
FixNonAsciiCharacterProblemInInvitationPreview-V1.diff

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

The IDL says that kGlyphSubstitution should not be used with scanHTML at all. Maybe we should just remove it? Or does something speak for keeping it? 

Also, I'd appreciate if you could add a test that attempts to add a <script> tag or <img onerror="evil()"/>.

r/a=philipp with these changes
Attachment #8795730 - Flags: review?(philipp)
Attachment #8795730 - Flags: review+
Attachment #8795730 - Flags: approval-calendar-esr?(philipp)
Attachment #8795730 - Flags: approval-calendar-esr+
Attachment #8795730 - Flags: approval-calendar-beta?(philipp)
Attachment #8795730 - Flags: approval-calendar-beta+
Attachment #8795730 - Flags: approval-calendar-aurora?(philipp)
Attachment #8795730 - Flags: approval-calendar-aurora+
Ah I read your comment now. Fine for me to keep kGlyphSubstitution then.
(Assignee)

Comment 5

2 years ago
https://hg.mozilla.org/comm-central/rev/150b63fa66ecd865927c8c34e22e3e88f2608e04
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 5.4
Whiteboard: [update target milestone: 4.7.5]
Target Milestone: 5.2 → 4.7.5
You need to log in before you can comment on or make changes to this bug.