[Dovecot] Question about IMAP
Hi Timo,
I have a question that you can maybe answer off the top of your head, considering your vast knowledge of the IMAP protocol...
There is a Thunderbird bug that is near and dear to my heart, that is trying to address how Thunderbird deals with large messages (ie, messages with large attachments).
Current behavior sucks... it downloads the entire message every time the message is clicked on.
My question is:
Using the IMAP protocol, is there a way, *without* downloading the entire message (specifically, binary attachments), that an IMAP client can do the following:
Download *only* the message headers and the text/html/body contents of the body of the message but *not* any binary attachments,
Detect that a message *has* one or more binary attachments, *without* downloading them,
Grab the names of all of the attachments,
Display for the user the email/email headers and text/html body parts,
Display the existence of the attachments in whatever manner the client normally shows them (in TBird, they show at the bottom of the message just above the status bar),
Download the actual attachment on demand - ie, if/when it is dbl-click > opened, right-click > saved, or the message is forwarded?
Pointers to appropriate IMAP protocol docs would be happily passed on to them the Mozilla dev guys.
Thanks!
--
Best regards,
Charles
On May 17, 2009, at 11:18 AM, Charles Marcus wrote:
My question is:
Using the IMAP protocol, is there a way, *without* downloading the entire message (specifically, binary attachments), that an IMAP client can do the following:
Yes. There are even several different ways to do it. Everything starts
by doing FETCH BODYSTRUCTURE command, which gives the client knowledge
of what MIME parts the message contains and also all the MIME headers.
After that it can fetch only those parts it's interested in.
- Download *only* the message headers and the text/html/body contents of the body of the message but *not* any binary attachments,
BODYSTRUCTURE shows Content-Type of each MIME part. After that client
can do e.g. FETCH (BODY[1]) to fetch only the first MIME part.
Detect that a message *has* one or more binary attachments,
*without* downloading them,Grab the names of all of the attachments,
BODYSTRUCTURE should have all that information. If there's something
missing, it's still possible to do FETCH BODY[n.MIME] to get MIME part
headers.
- Display for the user the email/email headers and text/html body
parts,
I'm not sure what you mean by this.
- Display the existence of the attachments in whatever manner the client normally shows them (in TBird, they show at the bottom of the message just above the status bar),
Yeah. The only issue I can think of here is if TB wants to detect the
attachment type by e.g. feeding the file to "file" command or
something. But even then it would be possible to download for example
first and last 1 kB of the attachment and hopefully file would
recognize the type based on only those.
- Download the actual attachment on demand - ie, if/when it is dbl-click > opened, right-click > saved, or the message is forwarded?
Yes.
Pointers to appropriate IMAP protocol docs would be happily passed
on to them the Mozilla dev guys.
It's all in RFC 3501 in FETCH command docs.
BTW. There are many clients that do this on-demand downloading. I use
Apple Mail and Evolution and they both do it.
On 5/17/2009, Timo Sirainen (tss@iki.fi) wrote:
<snip>
It's all in RFC 3501 in FETCH command docs.
BTW. There are many clients that do this on-demand downloading. I use Apple Mail and Evolution and they both do it.
As usual, Timo, you are the man!
Now all I just hope that the Mozilla devs will listen...
Thanks so much!!!
--
Best regards,
Charles
On May 17, 2009, at 12:26 PM, Timo Sirainen wrote:
Pointers to appropriate IMAP protocol docs would be happily passed
on to them the Mozilla dev guys.It's all in RFC 3501 in FETCH command docs.
Also I once wrote something to http://imapwiki.org/ClientImplementation/OpenMessage
On 5/17/2009, Timo Sirainen (tss@iki.fi) wrote:
Pointers to appropriate IMAP protocol docs would be happily passed on to them the Mozilla dev guys.
It's all in RFC 3501 in FETCH command docs.
Also I once wrote something to http://imapwiki.org/ClientImplementation/OpenMessage
Thanks Timo... if you don't mind, I'll also post here for further comment from you any follow-up questions or concerns the mozilla devs post to the bug in question ... I'm hoping they can make TBird's IMAP behavior go from ok (in some respects)/bad (with respect to large attachments) to best all around... :)
--
Best regards,
Charles
On 5/17/2009, Timo Sirainen (tss@iki.fi) wrote:
- Display for the user the email/email headers and text/html body parts,
I'm not sure what you mean by this.
I use the 'Preview Pane' in Thunderbird... all I meant was, when I click/select a message in the message list, I'd like TBird to not d/l the attachments, but I would still like to see the text and/or html content of the body...
--
Best regards,
Charles
participants (2)
-
Charles Marcus
-
Timo Sirainen