Closed Bug 523860 Opened 16 years ago Closed 14 years ago

Do not escape double quote character " to \" in iCalendar output (potential RFC 2445 violation)

Categories

(Calendar :: Internal Components, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: ssitter, Assigned: Fallen)

References

Details

(Whiteboard: [needed beta][no l10n impact])

Attachments

(1 file)

User-Agent: Opera/9.80 (Windows NT 6.1; U; de) Presto/2.2.15 Version/10.00 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.5pre) Gecko/20091022 Calendar/1.0pre Do not escape double quote character " to \" in iCalendar output (potential RFC 2445 violation) Reproducible: Always Steps to Reproduce: 1. Create new event an enter the following description: Meeting to provide technical review for "Phoenix" design. Happy Face Conference Room. Phoenix design team MUST attend this meeting. RSVP to team leader. 2. Export event into the iCalendar format and check the output Actual Results: Double quote character " has been escaped to \" > DESCRIPTION:Meeting to provide technical review for \"Phoenix\" design.\nH > appy Face Conference Room. Phoenix design team MUST attend this meeting.\n > RSVP to team leader. Expected Results: Double quote character " is not escaped as shown in the example of the Description property in RFC2445 <http://tools.ietf.org/html/rfc2445#section-4.8.1.5> > DESCRIPTION:Meeting to provide technical review for "Phoenix" > design.\n Happy Face Conference Room. Phoenix design team > MUST attend this meeting.\n RSVP to team leader.
OS: Windows 7 → All
Hardware: x86 → All
Flags: blocking-calendar1.0+
Whiteboard: [not needed beta][no l10n impact]
I have discovered this issue today and before reporting it here, I thought it was a bug in my calendar server. There is discussion about this in http://trac.calendarserver.org/ticket/419. Cyrus Daboo one of the involved people in RFC5545 commented there. In my duplicate Bernard Desruisseaux the Editor of RFC5545 commented. With the Apple Calendar Server this is a major problem as events which are not valid are rejected. And all events containing a " cannot be saved therefore.
The Calendar Server has changed its VObject library to PyCalendar. But one again has to patch it to be usable with Lightning. It would be really great to have this fixed...
Felix, do you think you could take a look at libical to find out where this happens? We could very well patch this, if we also send the patch upstream.
I cannot test this at the moment and I am really not sure. But the following might be a hint: fm@thinkpad:~/libical/src/libical # svn info icalvalue.c | grep ^URL URL: https://freeassociation.svn.sourceforge.net/svnroot/freeassociation/trunk/libical/src/libical/icalvalue.c fm@thinkpad:~/libical/src/libical # svn diff Index: icalvalue.c =================================================================== --- icalvalue.c (Revision 1071) +++ icalvalue.c (Arbeitskopie) @@ -322,7 +322,6 @@ icalmemory_append_char(&str,&str_p,&buf_sz,*p); break; } - case '"': case '\\': { icalmemory_append_char(&str,&str_p,&buf_sz,'\\'); icalmemory_append_char(&str,&str_p,&buf_sz,*p);
Attached patch Fix - v1 β€” β€” Splinter Review
Looks good. This patch adds a unit test, if you can't get the tests to run please ignore that part. We should get this patch upstream too.
Assignee: nobody → philipp
Status: NEW → ASSIGNED
Attachment #549052 - Flags: review?
Allen, could you push this patch upstream if you agree?
Attachment #549052 - Flags: review? → review?(mozilla)
Whiteboard: [not needed beta][no l10n impact] → [not needed beta][no l10n impact][needs review]
Philipp, We can take a look. Would you mind putting the patch up on the freeassociation patch tracker at https://sourceforge.net/tracker/?group_id=16077&atid=316077
Whiteboard: [not needed beta][no l10n impact][needs review] → [needed beta][no l10n impact][needs review]
Attachment #549052 - Flags: review?(mozilla) → review?(matthew.mecca)
Comment on attachment 549052 [details] [diff] [review] Fix - v1 Looks good to me. r=mmecca
Attachment #549052 - Flags: review?(matthew.mecca) → review+
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → Trunk
Target Milestone: Trunk → 1.0b8
Target Milestone: 1.0b8 → 1.0b7
Whiteboard: [needed beta][no l10n impact][needs review] → [needed beta][no l10n impact]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: