Network Working Group M. Rose
Request for Comments: 1460 Dover Beach Consulting, Inc.
Obsoletes: 1225 June 1993
Post Office Protocol - Version 3
1. Introduction
On certain types of smaller nodes in the Internet it is often impractical to maintain a message transport system (MTS). For example, a workstation may not have sufficient resources (cycles, disk space) in order to permit a SMTP server [RFC821] and associated local mail delivery system to be kept resident and continuously running.
Rose [Page 1]
RFC 1460 POP3 June 1993
For the remainder of this memo, the term "client host" refers to a host making use of the POP3 service, while the term "server host" refers to a host which offers the POP3 service.
2. A Short Digression
This memo does not specify how a client host enters mail into the transport system, although a method consistent with the philosophy of this memo is presented here:
3. Basic Operation
Initially, the server host starts the POP3 service by listening on TCP port 110. When a client host wishes to make use of the service, it establishes a TCP connection with the server host. When the connection is established, the POP3 server sends a greeting. The client and POP3 server then exchange commands and responses (respectively) until the connection is closed or aborted.
Rose [Page 2]
RFC 1460 POP3 June 1993
Hence a multi-line response is terminated with the five octets "CRLF.CRLF". When examining a multi-line response, the client checks to see if the line begins with the termination octet. If so and if octets other than CRLF follow, the the first octet of the line (the termination octet) is stripped away. If so and if CRLF immediately follows the termination character, then the response from the POP server is ended and the line containing ".CRLF" is not considered part of the multi-line response.
4. The AUTHORIZATION State
Once the TCP connection has been opened by a POP3 client, the POP3 server issues a one line greeting. This can be any string terminated by CRLF. An example might be:
Rose [Page 3]
RFC 1460 POP3 June 1993
NOTE: Minimal implementations of the POP3 need only be able to break a maildrop into its component messages; they need NOT be able to parse individual messages. More advanced implementations may wish to have this capability, for reasons discussed later.
Rose [Page 4]
RFC 1460 POP3 June 1993
...
5. The TRANSACTION State
Once the client has successfully identified itself to the POP3 server and the POP3 server has locked and burst the appropriate maildrop, the POP3 session is now in the TRANSACTION state. The client may now issue any of the following POP3 commands repeatedly. After each command, the POP3 server issues a response. Eventually, the client issues the QUIT command and the POP3 session enters the UPDATE state.
Rose [Page 5]
RFC 1460 POP3 June 1993
The POP3 server issues a positive response with a line containing information for the maildrop. This line is called a "drop listing" for that maildrop.
Rose [Page 6]
RFC 1460 POP3 June 1993
In order to simplify parsing, all POP3 servers are required to use a certain format for scan listings. The first octets present must be the message-id of the message. Following the message-id is the size of the message in octets. This memo makes no requirement on what follows the message size in the scan listing. Minimal implementations should just end that line of the response with a CRLF pair. More advanced implementations may include other information, as parsed from the message.
Rose [Page 7]
RFC 1460 POP3 June 1993
If the number associated with this message is higher than the "highest number accessed" in the maildrop, the POP3 server updates the "highest number accessed" to the number associated with this message.
Rose [Page 8]
RFC 1460 POP3 June 1993
The POP3 server does nothing, it merely replies with a positive response.
Rose [Page 9]
RFC 1460 POP3 June 1993
RSET
6. The UPDATE State
When the client issues the QUIT command from the TRANSACTION state, the POP3 session enters the UPDATE state. (Note that if the client issues the QUIT command from the AUTHORIZATION state, the POP3 session terminates but does NOT enter the UPDATE state.)
Rose [Page 10]
RFC 1460 POP3 June 1993 7. Optional POP3 CommandsThe POP3 commands discussed above must be supported by all minimal implementations of POP3 servers.
Rose [Page 11]
RFC 1460 POP3 June 1993
APOP name digest
Rose [Page 12]
RFC 1460 POP3 June 1993
When the POP3 server receives the APOP command, it verifies the digest provided. If the digest is correct, the POP3 server issues a positive response, and the POP3 session enters the TRANSACTION state. Otherwise, a negative response is issued and the POP3 session remains in the AUTHORIZATION state.
8. POP3 Command Summary
Minimal POP3 Commands:
Rose [Page 13]
RFC 1460 POP3 June 1993
Optional POP3 Commands:
9. Example POP3 Session
S: <wait for connection on TCP port 110>
Rose [Page 14]
RFC 1460 POP3 June 1993 10. Message FormatAll messages transmitted during a POP3 session are assumed to conform to the standard for the format of Internet text messages [RFC822].
11. The POP and the Split-UA model
The underlying paradigm in which the POP3 functions is that of a split-UA model. The POP3 client host, being a remote PC based workstation, acts solely as a client to the message transport system. It does not provide delivery/authentication services to others. Hence, it is acting as a UA, on behalf of the person using the workstation. Furthermore, the workstation uses SMTP to enter mail into the MTS.
Rose [Page 15]
RFC 1460 POP3 June 1993
After successfully verifying the identity of the client, a modified SMTP server is started, and the PC posts mail with the server host. After the QUIT command is given to the SMTP server and it terminates, a modified POP3 server is started, and the PC retrieves mail from the server host. After the QUIT command is given to the POP3 server and it terminates, the login shell for the pseudo-user terminates the terminal protocol and logs the job out. The PC then closes the terminal connection to the server host.
Rose [Page 16]
RFC 1460 POP3 June 1993 12. References[MZnet] Stefferud, E., Sweet, J., and T. Domae, "MZnet: Mail
13. Security Considerations
It is conjectured that use of the APOP command provides origin identification and replay protection for a POP3 session. Accordingly, a POP3 server which implements both the PASS and APOP commands must not allow both methods of access for a given user; that is, for a given "USER name" either the PASS or APOP command is allowed, but not both.
14. Acknowledgements
The POP family has a long and checkered history. Although primarily a minor revision to [RFC1225], POP3 is based on the ideas presented in RFCs 918, 937, and 1081.
15. Author's Address
Marshall T. Rose Dover Beach Consulting, Inc. Mountain View, CA 94043-2186