SMTP client functions. More...


Go to the source code of this file.
Data Structures | |
| struct | _MAILENVELOPE |
| Mail envelope structure type. More... | |
| struct | _SMTPCLIENTSESSION |
| SMTP session structure type. More... | |
Defines | |
| #define | MAX_MAIL_RCPTS 4 |
| Maximum number of recipients. | |
| #define | SMTP_BUFSIZ 256 |
| Size of the SMTP buffer. | |
Typedefs | |
| typedef struct _MAILENVELOPE | MAILENVELOPE |
| Mail envelope structure type. | |
| typedef struct _SMTPCLIENTSESSION | SMTPCLIENTSESSION |
| SMTP session structure type. | |
Functions | |
| SMTPCLIENTSESSION * | NutSmtpConnect (uint32_t ip, uint16_t port) |
| Start an SMTP session. | |
| void | NutSmtpDisconnect (SMTPCLIENTSESSION *si) |
| Terminate an SMTP session. | |
| int | NutSmtpLogin (SMTPCLIENTSESSION *si, char *host, char *user, char *pass) |
| Identify the client SMTP to the server. | |
| CONST char * | NutSmtpSendMail (SMTPCLIENTSESSION *si, MAILENVELOPE *me) |
| Send an email via an active SMTP session. | |
| int | NutSmtpSendMailRequest (SMTPCLIENTSESSION *si, MAILENVELOPE *me) |
| Send mail request. | |
| int | NutSmtpSendMailHeader (SMTPCLIENTSESSION *si, MAILENVELOPE *me) |
| Send major mail header lines. | |
| int | NutSmtpSendEncodedLines (SMTPCLIENTSESSION *si, CONST char *text) |
| Send encoded email text lines. | |
| CONST char * | NutSmtpSendCommand (SMTPCLIENTSESSION *si, CONST char *fmt,...) |
| Send command to the server and return the first response line. | |
| CONST char * | NutSmtpReceiveResponse (SMTPCLIENTSESSION *si) |
| Read a response line from the server. | |
Recipient Status Bits | |
| #define | MAIL_RCPT_TYPE 0x03 |
| Recipient type mask. | |
| #define | MAIL_RCPT_TO 0x01 |
| Standard recipient type. | |
| #define | MAIL_RCPT_CC 0x02 |
| Carbon copy recipient type. | |
| #define | MAIL_RCPT_BCC 0x03 |
| Blind carbon copy recipient type. | |
| #define | MAIL_RCPT_ACPT 0x20 |
| Recipient accepted flag. | |
| #define | MAIL_RCPT_SENT 0x40 |
| Recipient processed flag. | |
| #define | MAIL_RCPT_FAIL 0x80 |
| Recipient failed flag. | |
| #define | MAIL_RCPT_DONE (MAIL_RCPT_SENT | MAIL_RCPT_FAIL) |
| Recipient done mask. | |
Server Features | |
| #define | SMTPFEAT_VINTAGE 0x00000001 |
| Server doesn't support ESMTP. | |
| #define | SMTPFEAT_AUTH_LOGIN 0x00000002 |
| Server supports LOGIN authentication. | |
| #define | SMTPFEAT_AUTH_PLAIN 0x00000004 |
| Server supports PLAIN authentication. | |