Skip to content

[IOS-IMAP-016] Fix SwiftMail header encoding and MIME filename quoting upstream #10

Description

@tabmail-kmyi

Current status

Sync validation update: the proposed SwiftMail upstream pin is on hold after receive-path compatibility regressions were reproduced against the old app pin. The fork and app pin remain unchanged. The library's 619 passing tests do not establish app compatibility; resolve or adjudicate the regressions before synchronizing. The oversized-metadata train remains parked independently.

Updated 2026-09-09: upstream acceptance is complete. #215 was incorporated through #226, and #216 through #230, both merged September 7 with maintainer follow-ups. The latest published SwiftMail release is still 1.11.0, which predates them. Synchronization is blocked by reproduced receive-path compatibility regressions; this issue stays open and the current fork/app pins remain unchanged.

The separate oversized-metadata train (#74 / draft #103) remains parked for a SwiftNIO IMAP release containing #849 and subsequent SwiftMail adoption. That release dependency does not undo acceptance of this issue's header/MIME fixes.

Open. This issue tracks an upstream contribution to Cocoanetics/SwiftMail, followed by synchronization of TabMail's deviation-free SwiftMail fork.

TabMail should not carry a private fork-only remedy. The defects remain valid upstream even where TabMail has an app-side mitigation or a separately tracked app-owned surface.

The canonical technical record contains the current pin, reachability census, evidence, constraints, and related app-owned work:

Original upstream scope (accepted; retained for reference)

  • Correct SwiftMail's RFC 2047 header encoder so control-bearing values cannot be emitted literally.
  • Bound encoded-words to the RFC 2047 75-octet ceiling without splitting invalid UTF-8.
  • Correct all filename and content-type MIME parameter interpolation sites, with an upstream-compatible quoting/RFC 2231 policy.
  • Add upstream regression tests for the full library surface, including sites not currently reached by TabMail.
  • Submit the fix to Cocoanetics/SwiftMail rather than introducing a TabMail-only fork deviation.
  • After upstream accepts and releases the remedy, synchronize TabMail's SwiftMail fork and update the app pin through the normal fork-sync workflow.

App-owned behavior and compatibility decisions remain tracked separately under IOS-COMPOSE-002 and IOS-COMPOSE-003; they do not replace the upstream library fix.

Completion criteria

  • Upstream fix and regression tests are accepted by Cocoanetics/SwiftMail.
  • A release containing the fix is available, or TabMail has an explicitly approved upstream commit to synchronize.
  • TabMail's deviation-free fork is synchronized to that upstream state.
  • The iOS app is re-pinned and its send/draft/render regression suites pass.
  • The canonical IOS-IMAP-016 record is updated with upstream links, released commit/version, and verification evidence.
  • Close this issue only after all of the above are complete; do not close it merely because an app-side mitigation exists.

Non-goals

  • A permanent TabMail-only SwiftMail deviation.
  • Closing the tracker as “not planned” solely because the work belongs upstream.
  • Treating the app-side mitigations as proof that SwiftMail is fixed for other callers.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingpriority: P3Potential bug with an acceptable self-healing fallback; live behaviour non-ideal but OK

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions