On Tue, Nov 04, 2003 at 12:46:47PM -0500, Paul Jarc wrote:
> I'm writing an entirely read-only IMAP server; it's mainly intended
> for serving mailing list archives.  Just like a web archive, it lets
> anyone in (PREAUTH greeting),

Many clients don't understand it and will try to login anyway. I'm not sure
if some even completely break because of it.. You could also support
ANONYMOUS SASL and LOGIN anonymous with empty password (actually at least
one client couldn't send empty password).

> but maintains no per-user persistent
> state.  So - how should I handle flags?  My PERMANENTFLAGS set will be
> empty.  \Answered, \Deleted, \Draft, and \Flagged will be initially
> clear for every message; should I bother making them modifiable for
> the current session via STORE, or is a NO response for any STORE
> command good enough?  What about \Recent and \Seen - how should they be
> set initially, and should they be automatically updated during the
> session?

RFC allowed just ignoring flag changes for read-only mailboxes. I wouldn't
reply with NO or some clients keep complaining about it constantly. This is
how my server works and it seems to work fine with clients:

1 store 1 +flags \seen
* NO Mailbox is read-only, ignoring flag changes
* 1 FETCH (FLAGS (\Recent))
1 OK Store completed.
2 store 1 +flags \seen
* 1 FETCH (FLAGS (\Recent))
2 OK Store completed.

ie. the read-only warning is sent only once.

Now that I think of it, I think +flags.silent should also reply with
untagged FETCH if it doesn't change the flag.

> Also, should \Recent be included in the untagged FLAGS response?  The
> description of the FLAGS response seems to require it (\Recent is a
> system-defined flag), but none of the examples include it.

Hmm. None of the implementations send it, but I don't actually see it
mentioned in RFC...

Reply via email to