1
0
Fork 0
mirror of https://git.sr.ht/~rjarry/aerc synced 2025-02-22 14:53:57 +01:00
aerc/worker/jmap
Robin Jarry 985ce7a92b jmap: explicitly fetch body structure subparts
When requesting the bodyStructure email property, the spec says that the
default returned body part properties are: ["partId", "blobId", "size",
"name", "type", "charset", "disposition", "cid", "language",
"location"].

Specifically, the "subParts" property is *NOT* expected by default.

Fastmail servers seem to use a different default "bodyProperties" list
and implicitly return "subParts" even if not requested.

Other JMAP server implementations (e.g. Apache James) do use the RFC
default "bodyProperties" and therefore omit returning "subParts" unless
explicitly asked to.

Change the requested "bodyProperties" to include "subParts" as well.
Aerc needs them to display messages.

NB: for later, we should probably change our message abstraction not to
include any body structure. This makes very little sense to expose that
to users. In fact, aerc has code to explicitly prevent users from
selecting multipart/* parts. Not requesting that information to the
server would make it easier.

Link: https://datatracker.ietf.org/doc/html/rfc8621#section-4.2
Reported-by: Benoit Tellier <btellier@linagora.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
Reviewed-by: Tim Culverhouse <tim@timculverhouse.com>
2025-02-11 21:02:24 +01:00
..
cache jmap: cache threads 2024-12-21 16:49:31 +01:00
configure.go jmap: fix crash when opening multiple instances 2023-07-15 17:09:49 +02:00
connect.go jmap: start listening for changes on Connect message 2024-12-21 16:49:14 +01:00
directories.go jmap: rely on updates to update mailbox list 2024-12-21 16:49:14 +01:00
fetch.go jmap: explicitly fetch body structure subparts 2025-02-11 21:02:24 +01:00
jmap.go treewide: replace uint32 uids with opaque strings 2024-08-28 12:06:01 +02:00
push.go jmap: explicitly fetch body structure subparts 2025-02-11 21:02:24 +01:00
search.go filter: allow workers to combine filter terms 2024-02-11 22:03:56 +01:00
send.go jmap: handle copy-to and :send -t 2024-12-21 17:02:31 +01:00
set.go treewide: fix English spelling 2025-01-21 13:39:01 +01:00
threads.go jmap: explicitly fetch body structure subparts 2025-02-11 21:02:24 +01:00
worker.go treewide: replace uint32 uids with opaque strings 2024-08-28 12:06:01 +02:00