mirror of
https://github.com/bulwarkmail/webmail.git
synced 2026-10-31 16:13:15 +00:00
Three issues addressed in sendImipReply, sendImipInvitation and sendImipCancellation: 1. Line folding (RFC 5545 §3.1) Add foldIcsLine() helper that wraps iCalendar content lines at 74 characters, inserting CRLF + SPACE as required by the spec. Previously, long lines (e.g. ATTENDEE with a full CN and mailto URI) could exceed the 75-octet limit and cause strict parsers to silently reject the ICS. 2. MIME wrapper type (RFC 6047 §3 + CalConnect iMIP Best Practices) Change bodyStructure from multipart/alternative to multipart/mixed. The CalConnect interoperability guide recommends multipart/mixed as the outer wrapper for messages carrying a text/calendar part; many clients skip iTIP processing when they see multipart/alternative. 3. Calendar part metadata Add charset=UTF-8 to the text/calendar Content-Type, disposition inline, and a descriptive filename (reply.ics / invite.ics / cancel.ics) to each outgoing calendar MIME part. Note: Gmail-to-Gmail events are handled by Google's internal scheduling API and cannot be updated via iMIP regardless of MIME structure. This fix improves interoperability with Outlook, Thunderbird, Fastmail and standard CalDAV servers.