Text preview for : 19770809_Mail_Update_To_Mesa_FTP_Specification.pdf part of xerox 19770809 Mail Update To Mesa FTP Specification xerox sdd memos_1977 19770809_Mail_Update_To_Mesa_FTP_Specification.pdf



Back to : 19770809_Mail_Update_To_M | Home

Inter-Office Memorandum

To Distdbution Date 9 August 71


From Jim White Location Palo Alto


Subject Mail Update to Mesa FTP Specification Organization SDD/SO/es


XEROX
XEtaX SDD ARCHIVES
I have read and undelstood
Filed on: Reviewer ________- Date--------
# of Pages Ref 't115>OD~!>co
Introduction
This memo updates the interface specification for the mail portion of the Mesa FTP
Package proposed in the author's memo, "Mesa FTP Specification", dated 15 June 77. This
new interface specification corresponds to the new Mail Transfer Protocol specification
contained in Ed Taft's memo, "Pup Mail Transfer Protocol (Edition 3)", dated 13 July 77.


Already Proposed Support Procedures
The mail application requires certain general purpose program management, connection
management. and file access procedures already proposed for FTP. These procedures are
enumerated below; the reader is referred to the complete Mesa FTP specification for a
detailed description of their use:
FTPMukeUser: PROCEDURE RETURNS [ftpuser: FTPUser];

Fl'POpenConnection: PROCEDURE [ftpuser: FTPUser, host: STRING, purpose: Purpose];

Purpose: TYPE = {files. mail, filesandmail};

FTPSetAccessibleDirectory: PROCEDURE [ftpuser: FTPUser, directoryid: Directoryld, directory,
password: STRING];

Directoryld: TYPE = {primary, secondary};

FTPCloseConnection: PROCEDURE [ftpuser: FTPUser];

FTPDestroyUser: PROCED.URE [ftpuser: FTPUser];



Newly Proposed Mail Procedures
The FTP Package provides procedures for delivering or forwarding mail to and extracting
mail from remote mailboxes. Rather than signalling the presence of exceptional condilions,
each of these procedures returns a numeric error code as one of its results. (Note that the
Sl.lpport procedures described above, on the other hand, signal when exceptional conditions
arise.) The following error codes are currently defined:
Mail Update to Mesa FTP Specification 2

MailErrorCode: TYPE = {ok, noValidRecipients, noDiskSpace, noSuchMailbox. accessDcnied,
noMoreMessages, noMoreBlocks}:

Mail Delivery
The FrP Package provides three procedures for delivering or forwarding mail to remote
mailboxes. The use of these procedures is illustrated by the following slice of Mesa code:

mailbox1. to [next: @mailbox2. mailboxName: "Wegbreit", mailboxHostName: "Maxc2'", dmsName:
"Wegbreit.Palo Alto", errorCode: ok, errorMessage: NIL];
mailbox2 to [next: NIL, mailboxName: "Brotz", mailboxHostName: NIL, dmsName: NIL. errorCode: ok,
errorMessage: NIL]:
errorCode .. FTPBeginDeliveryOfMessage[ftpuser. @mailbox1, AllocateHeapString];
IF errorCode = ok THEN errorCode .. FTPSendBlockOfMessage[ftpuser.
LOOPHOLE[messageHeader, POINTER]+2, messageHeader.length]:
IF errorCode = ok THEN errorCode .. FTPSendBlockOfMessage[ftpuser.
LOOPHOLE[messageBody. POINTER] +2, messageBody.length];
IF errorCode :: ok THEN errorCode .. FTPEndDeliveryOfMessage[ftpuser];
mailbox .. @mailbox1;
WHILE mailbox # NIL DO
IF mailbox.errorCode # ok THEN SIGNAL MailboxException[mailbox]:
mailbox .. mailbox.next;
ENDLOOP;
IF errorCode # ok THEN ERROR DeliveryError[errorCode]:

The first procedure, FTPBeginDeliveryOfMessage. initiates the delivery and/or forwarding
of a message by.enumerating its intended recipients via a linked Jist, mailboxUst. In the
simpler case, called delivery, in which a recipient's mailbox resides on the connected host (a
case which the procedure distinguishes by finding mailboxHostName set to NIL), the
corresponding list element need contain only a pointer, next, to the next element in the list
(NIL signalling the end of the list) and the host-specific name, mailboxName, of the remote
mailbox to which a copy of the message is to be appended. In the more complex case, called
forwarding, in which a recipient's mailbox resides on a third host (a case which not all hosts
will support), the corresponding list element must also contain the name, mailboxHoslName,
of the target host and (optionally) the full dmsName of the target mailbox (which the
forwarder may be able to use to locate the recipient if he is found to have moved):

FTPBeginDeliveryOfMessage: PROCEDURE [ftpuser: FTPUser. mailboxUst: MailboxPlr,
allocate String: PROCEDURE [INTEGER] RETURNS [STRING]] RETURNS [mailErrorCode:
MailErrorCode ]:

MailboxPtr: TYPE = POINTER TO Mailbox;

Mailbox: TYPE = RECORD [next: MailboxPtr. mailboxNarne, mailboxHostName. dmsName:
STRING, errorCode: ErrorCode, errorMessage: STRING];

ErrorCode: TYPE = {Ok, noSuchMailbox, noSuchMailboxHost. noSuchDmsName,
noForwardingProvided, unspecifiedTransientError. unspecifiedPermanentError.
unspecifiedError1:

Delivery of the message succeeds or fails for each of its intended recipients independently.
Either FTPBegillDeliveryOjMessage or the FTPEndDeliveryOjMessage procedure described
below may report the failure of an individual delivery attempt by despositing in the
appropriate list element a numeric errorCode intended for examination by the client (ok
signalling successful delivery, but only tentatively until' FTPEndDeliveryOjll4essage has
returned) and, if errorCode is one of the three having the form unspecified ... Error, a
textual error Message intended for examination by a human user. Storage for any error
messages that may be returned is allocated via the al/ocaleString procedure provided by the
client. which assumes responsibility for releasing the storage.
Mail Update to