Subject: Re: [imapext] IMAP message size limits

From: "Adrien W. de Croy" <[email-masked]>
Date: Tue, 24 Jul 2012 01:21:54 +0000

------ Original Message ------
From: "Lyndon Nerenberg" <[email-masked]>
>On 2012-07-23, at 17:26 PM, Adrien W. de Croy wrote:
>
>
>>
>>In fact the 32 bit limit is only a comment in the BNF, I can't find it anywhere else.
>>
>
>
>Comments in the BNF are sometimes used to outline restrictions on the protocol. These 'comments' have equal standing with the BNF itself.
>
>32-bits is core to the protocol, and isn't going to change.
>

Forever is a long time.

Messages continue to get bigger and bigger.  Links get faster.  People 
use mail for more things.

32 bits is not a requirement of the protocol itself.  Moses didn't come 
down from the mountain with a bit of stone that said "thou shalt not 
make emails larger than 4GB".

It was an implementation decision that polluted the protocol.  I'm sure 
4GB seemed like an inconceivably enormous message size back in the 
early 80's.  It's still enormous, but not inconceivable now.

FWIW, we already support 64 bit sizes.  So if anyone sends a > 4GB 
message to a WinGate IMAP mailbox, it will go in, and the size will be 
reported correctly.  I guess the clients will barf on that if they 
don't support > 32 bit sizes.

So actually, it already did change.

What's the alternative you suggest?

a) we should for eternity reject any message > 4GB destined for IMAP?
b) advertise a CAPABILITY of 64BIT or something, and "hide" big 
messages from small clients?
c) make IMAP5 64 bit by default...
d) do nothing and wait.

Adrien

>--lyndon

---

From: Randall Gellens <[email-masked]>
Date: Mon, 23 Jul 2012 18:43:31 -0700

At 1:21 AM +0000 7/24/12, Adrien W. de Croy wrote:

>  32 bits is not a requirement of the protocol itself.  Moses didn't 
> come down from the mountain with a bit of stone that said "thou 
> shalt not make emails larger than 4GB".
>
>  It was an implementation decision that polluted the protocol.  I'm 
> sure 4GB seemed like an inconceivably enormous message size back in 
> the early 80's.  It's still enormous, but not inconceivable now.

As an aside, back in the early days of IMAP, I tried to push for 
larger UID sizes, since I was trying to design a mail system capable 
of handling very large mailboxes, and thought 32 bits was not enough 
(the system I used then had 48-bit words).

-- 
Randall Gellens
Opinions are personal;    facts are suspect;    I speak for myself only
-------------- Randomly selected tag: ---------------
Automobile: A four-wheeled vehicle that runs up hills
and down pedestrians.

---

From: Arnt Gulbrandsen <[email-masked]>
Date: Tue, 24 Jul 2012 10:11:44 +0200

On 07/24/2012 03:43 AM, Randall Gellens wrote:
> As an aside, back in the early days of IMAP, I tried to push for larger
> UID sizes, since I was trying to design a mail system capable of
> handling very large mailboxes, and thought 32 bits was not enough (the
> system I used then had 48-bit words).

31 bits (what I use, for fear of lurking signed ints) are enough in this 
case.

If the mailbox is small but with high turnover, you can renumber quickly 
and issue a new uidvalidity.

If the mailbox is big, what you have is an accident waiting to happen. 
I've tried various clients with million-message mailboxes, and... shall 
we say that I saw no point in trying ten-million mailboxes? Mailboxes 
that big can work, but only until someone tries to open it with the 
wrong client, and practically all clients are wrong. An accident waiting 
to happen.

Arnt

PS: Actually, maybe a went a little further than a million. Two, four, I 
don't know. A long way from two billion anyway.

---

From: Timo Sirainen <[email-masked]>
Date: Tue, 24 Jul 2012 11:37:40 +0300

On 24.7.2012, at 4.21, Adrien W. de Croy wrote:

> FWIW, we already support 64 bit sizes.  So if anyone sends a > 4GB message to a WinGate IMAP mailbox, it will go in, and the size will be reported correctly.  I guess the clients will barf on that if they don't support > 32 bit sizes.

Same for Dovecot since the first version.

---

From: Alexey Melnikov <[email-masked]>
Date: Tue, 24 Jul 2012 10:22:30 +0100

Hi Adrien,

On 24 Jul 2012, at 02:21, "Adrien W. de Croy" <[email-masked]> wrote:

> Messages continue to get bigger and bigger.  Links get faster.  People use mail for more things.
>  
> 32 bits is not a requirement of the protocol itself.  Moses didn't come down from the mountain with a bit of stone that said "thou shalt not make emails larger than 4GB".
>  
> It was an implementation decision that polluted the protocol.  I'm sure 4GB seemed like an inconceivably enormous message size back in the early 80's.  It's still enormous, but not inconceivable now.

Actually I believe it improved interoperability at the time.

> b) advertise a CAPABILITY of 64BIT or something, and "hide" big messages from small clients?

Do something like that. Use ENABLE 64BIT to let clients see all messages.

And I hope we are talking about message sizes (+ possibly quotas) and nothing else at this time...

> _______________________________________________
> imapext mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/imapext

---

From: Arnt Gulbrandsen <[email-masked]>
Date: Tue, 24 Jul 2012 11:32:17 +0200

> nothing else at this time...

Quotas may be 32-bit, but their fundamental unit is 1k blocks, so 
there's quite a bit of headroom there.

Arnt