Re: POP3 behavior on broken tcp connection

John Gardiner Myers <jgm+@cmu.edu> Wed, 25 May 1994 21:17 UTC

Received: from ietf.nri.reston.va.us by IETF.CNRI.Reston.VA.US id aa10150; 25 May 94 17:17 EDT
Received: from CNRI.RESTON.VA.US by IETF.CNRI.Reston.VA.US id aa10146; 25 May 94 17:17 EDT
Received: from PO6.ANDREW.CMU.EDU by CNRI.Reston.VA.US id aa16208; 25 May 94 17:17 EDT
Received: (from postman@localhost) by po6.andrew.cmu.edu (8.6.7/8.6.6) id RAA28587; Wed, 25 May 1994 17:11:36 -0400
Received: via switchmail; Wed, 25 May 1994 17:11:35 -0400 (EDT)
Received: from hogtown.andrew.cmu.edu via qmail ID </afs/andrew.cmu.edu/service/mailqs/testq0/QF.Yhsvv:C00WBwEgl04S>; Wed, 25 May 1994 17:10:34 -0400 (EDT)
Received: from hogtown.andrew.cmu.edu via qmail ID </afs/andrew.cmu.edu/usr7/jm36/.Outgoing/QF.Uhsvuz200WBwQa39lP>; Wed, 25 May 1994 17:10:23 -0400 (EDT)
Received: from BatMail.robin.v2.14.CUILIB.3.45.SNAP.NOT.LINKED.hogtown.andrew.cmu.edu.sun4c.411 via MS.5.6.hogtown.andrew.cmu.edu.sun4c_411; Wed, 25 May 1994 17:10:20 -0400 (EDT)
Message-ID: <Mhsvuw200WBwEa39Yk@andrew.cmu.edu>
Date: Wed, 25 May 1994 17:10:20 -0400
Sender: ietf-archive-request@IETF.CNRI.Reston.VA.US
From: John Gardiner Myers <jgm+@cmu.edu>
To: POP3 IETF Mailing List <ietf-pop3+@andrew.cmu.edu>
Subject: Re: POP3 behavior on broken tcp connection
In-Reply-To: <MailManager.769898101.3148.mrc@Ikkoku-Kan.Panda.COM>
References: <MailManager.769898101.3148.mrc@Ikkoku-Kan.Panda.COM>
Beak: is Not

Mark Crispin <MRC@Panda.COM> writes:
> There are two interpretations:
> 1) POP deletions set a per-message mailbox flag, which other applications can
>    see and respect.  Only an operation such an a POP QUIT or an IMAP EXPUNGE
>    will actually destroy the messages.
> 2) POP deletions set a per-message session flag, which other applications will
>    never see.  This session flag governs the behavior of the QUIT command of
>    that session.

Presently, I implement (2).  I'm leaning towards thinking the
specification should require (2) if it doesn't already.

> The biggest drawback with (1) seems to be that most POP clients soil their
> pants when they find that messages are pre-deleted at startup. 

I think pre-deleted messages should be prohibited by the spec.

> For this
> reason, I found myself compelled to make initially deleted messages be
> invisible through a mapping table; you can get at such messages with IMAP but
> not with POP.

This is reasonable.  My POP3 implementation simply chooses to
ignore the IMAP \Deleted flag altogether.

> Either way, this POP client screwup has the effect that a POP QUIT
> can destroy many more messages than the POP client is aware of; POP QUIT does
> a c-client expunge which destroys all deleted messages.  The only way I can
> think around it is to undelete the invisible messages temporarily, expunge,
> then redelete them.  But there's a window of vulnerability in this due to
> timing races....

My implementation's expunge routine can take a function pointer which
is called to decide which messages to remove.  The POP3 server
supplies a function that ignores the IMAP \Deleted flag, instead
basing its decision soely on the per-session POP3-deleted state.

-- 
_.John G. Myers		Internet: jgm+@CMU.EDU
			LoseNet:  ...!seismo!ihnp4!wiscvm.wisc.edu!give!up