Subject: [lemonade] URLAUTH RESETKEY

From: Timo Sirainen <[email-masked]>
Date: Tue, 22 May 2012 14:52:47 +0300

> BASE.6.3.RESETKEY.  RESETKEY Command
..
>    Any current IMAP session logged in as the user that has the mailbox
>    selected will receive an untagged OK response with the URLMECH status
>    response code (see section BASE.7.1.URLMECH for more details about
>    the URLMECH status response code).

This is a bit confusing. First of all, what is the purpose of sending the URLMECH response to other clients? Can they assume that if it's received then a RESETKEY command has been issued? Doesn't seem very IMAPy to assume that, since it is also sent during SELECT/EXAMINE. Is it simply to handle the cases when non-INTERNAL mechanisms are used and they might have changed the mech-specific data? Is there really even a need to send this if server only supports INTERNAL?

And when would the message be sent? Does "will receive" mean immediately? Before the next command? After the next command? Maybe sometimes later?

---

From: Alexey Melnikov <[email-masked]>
Date: Thu, 24 May 2012 16:22:22 +0100

Hi Timo,

On 22/05/2012 12:52, Timo Sirainen wrote:
> This is a bit confusing. First of all, what is the purpose of sending the URLMECH response to other clients?
I think the purpose is to notify the client that previously issued 
URLAUTH keys are no longer valid. The client might want to regenerate 
some URLs upon seeing that.
> Can they assume that if it's received then a RESETKEY command has been issued?
Not necessarily. This might also be caused by some administrative 
interface that doesn't necessarily use IMAP.
> Doesn't seem very IMAPy to assume that, since it is also sent during SELECT/EXAMINE. Is it simply to handle the cases when non-INTERNAL mechanisms are used and they might have changed the mech-specific data? Is there really even a need to send this if server only supports INTERNAL?
On SELECT/EXAMINE this response code is used to advertise supported 
URLAUTH mechanisms.
> And when would the message be sent? Does "will receive" mean immediately? Before the next command? After the next command? Maybe sometimes later?
Well, if your session is in IDLE, you should receive it immediately. 
Otherwise sending it on the next command would be fine, unless the next 
command is GENURLAUTH...