imapext-2007
diff src/c-client/smtp.h @ 0:ada5e610ab86
imap-2007e
author | yuuji@gentei.org |
---|---|
date | Mon, 14 Sep 2009 15:17:45 +0900 |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/src/c-client/smtp.h Mon Sep 14 15:17:45 2009 +0900 1.3 @@ -0,0 +1,76 @@ 1.4 +/* ======================================================================== 1.5 + * Copyright 1988-2007 University of Washington 1.6 + * 1.7 + * Licensed under the Apache License, Version 2.0 (the "License"); 1.8 + * you may not use this file except in compliance with the License. 1.9 + * You may obtain a copy of the License at 1.10 + * 1.11 + * http://www.apache.org/licenses/LICENSE-2.0 1.12 + * 1.13 + * 1.14 + * ======================================================================== 1.15 + */ 1.16 + 1.17 +/* 1.18 + * Program: Simple Mail Transfer Protocol (SMTP) routines 1.19 + * 1.20 + * Author: Mark Crispin 1.21 + * Networks and Distributed Computing 1.22 + * Computing & Communications 1.23 + * University of Washington 1.24 + * Administration Building, AG-44 1.25 + * Seattle, WA 98195 1.26 + * Internet: MRC@CAC.Washington.EDU 1.27 + * 1.28 + * Date: 27 July 1988 1.29 + * Last Edited: 15 August 2007 1.30 + * 1.31 + * This original version of this file is 1.32 + * Copyright 1988 Stanford University 1.33 + * and was developed in the Symbolic Systems Resources Group of the Knowledge 1.34 + * Systems Laboratory at Stanford University in 1987-88, and was funded by the 1.35 + * Biomedical Research Technology Program of the NationalInstitutes of Health 1.36 + * under grant number RR-00785. 1.37 + */ 1.38 + 1.39 +/* Constants (should be in smtp.c) */ 1.40 + 1.41 +#define SMTPTCPPORT (long) 25 /* assigned TCP contact port */ 1.42 +#define SUBMITTCPPORT (long) 587/* assigned TCP contact port */ 1.43 + 1.44 + 1.45 +/* SMTP open options 1.46 + * For compatibility with the past, SOP_DEBUG must always be 1. 1.47 + */ 1.48 + 1.49 +#define SOP_DEBUG (long) 1 /* debug protocol negotiations */ 1.50 +#define SOP_DSN (long) 2 /* DSN requested */ 1.51 + /* DSN notification, none set mean NEVER */ 1.52 +#define SOP_DSN_NOTIFY_FAILURE (long) 4 1.53 +#define SOP_DSN_NOTIFY_DELAY (long) 8 1.54 +#define SOP_DSN_NOTIFY_SUCCESS (long) 16 1.55 + /* DSN return full msg vs. header */ 1.56 + 1.57 +#define SOP_DSN_RETURN_FULL (long) 32 1.58 +#define SOP_8BITMIME (long) 64 /* 8-bit MIME requested */ 1.59 +#define SOP_SECURE (long) 256 /* don't do non-secure authentication */ 1.60 +#define SOP_TRYSSL (long) 512 /* try SSL first */ 1.61 +#define SOP_TRYALT SOP_TRYSSL /* old name */ 1.62 + /* reserved for application use */ 1.63 +#define SOP_RESERVED (unsigned long) 0xff000000 1.64 + 1.65 + 1.66 +/* Compatibility support names */ 1.67 + 1.68 +#define smtp_open(hostlist,options) \ 1.69 + smtp_open_full (NIL,hostlist,"smtp",NIL,options) 1.70 + 1.71 + 1.72 +/* Function prototypes */ 1.73 + 1.74 +void *smtp_parameters (long function,void *value); 1.75 +SENDSTREAM *smtp_open_full (NETDRIVER *dv,char **hostlist,char *service, 1.76 + unsigned long port,long options); 1.77 +SENDSTREAM *smtp_close (SENDSTREAM *stream); 1.78 +long smtp_mail (SENDSTREAM *stream,char *type,ENVELOPE *msg,BODY *body); 1.79 +long smtp_verbose (SENDSTREAM *stream);