MBOX-Line: From MRC at Washington.EDU  Thu Jan 31 18:49:49 2008
To: imap-protocol@u.washington.edu
From: Mark Crispin <MRC@Washington.EDU>
Date: Fri Jun  8 12:34:41 2018
Subject: [Imap-protocol] Should IMAP APPEND create a sent or unsent
	message? 
In-Reply-To: <08Jan31.184027pst."58696"@synergy1.parc.xerox.com>
References: <fc.00802cf1026ac56600802cf1026ac566.26adfec@cciu.org>
	<alpine.OSX.1.00.0801302244470.10877@pangtzu.panda.com>
	<fc.00802cf1026ae3b200802cf1026ac566.26b3de0@cciu.org>
	<alpine.OSX.1.00.0801311231290.10877@pangtzu.panda.com>
	<08Jan31.180102pst."58696"@synergy1.parc.xerox.com>
	<alpine.OSX.1.00.0801311803590.10877@pangtzu.panda.com>
	<08Jan31.184027pst."58696"@synergy1.parc.xerox.com>
Message-ID: <alpine.WNT.1.00.0801311842320.1804@Shimo-Tomobiki.Panda.COM>

On Thu, 31 Jan 2008, Bill Janssen wrote:
> OK [PERMANENTFLAGS (<list of flags>)]
>  A list of message flags that the client can change
>  permanently. If this is missing, the client should
>  assume that all flags can be changed permanently.
> Since PERMANENTFLAGS is a required response, I assumed that "this"
> referred to the <list of flags> argument.

No.  That text refers to how to deal with old servers that did not send 
any PERMANENTFLAGS response at all.

> Since we also see in 6.3.2 that [PERMANENTFLAGS ()] means "no
> permanent flags permitted", I guess I sort of assumed that
>  OK [PERMANENTFLAGS]
> would be the way to tell the client that all flags can be changed
> permanently.

The syntax for resp-text-code in RFC 3501 page 89 does not permit such a 
thing:
                   "PERMANENTFLAGS" SP "("
                   [flag-perm *(SP flag-perm)] ")" /

Always refer to the formal syntax first!  It is the holy of holies! 
Don't ever jump to conclusions based upon what you read in the text! 
Note well the warning in RFC 3501 section 1.1!

> So is PERMANENTFLAGS optional for the SELECT command?

No, but ancient servers might not send it anyway.  PERMANENTFLAGS was 
introduced in 1994, and was made mandatory in 2003.  It was "optional" 
only for IMAP2 compatibility.

-- Mark --

http://staff.washington.edu/mrc
Science does not emerge from voting, party politics, or public debate.
Si vis pacem, para bellum.

