|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. --> |
|
3 <!-- This component and the accompanying materials are made available under the terms of the License |
|
4 "Eclipse Public License v1.0" which accompanies this distribution, |
|
5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". --> |
|
6 <!-- Initial Contributors: |
|
7 Nokia Corporation - initial contribution. |
|
8 Contributors: |
|
9 --> |
|
10 <!DOCTYPE concept |
|
11 PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd"> |
|
12 <concept id="GUID-2E253B30-2611-546D-AE5B-1752556FC8E8" xml:lang="en"><title>SMTP |
|
13 Concepts</title><prolog><metadata><keywords/></metadata></prolog><conbody> |
|
14 <p>This section section describes the Simple Mail Transfer Protocol (SMTP) |
|
15 and its implementation on Symbian platform. </p> |
|
16 <section id="GUID-DBF1C87D-7360-54B7-8658-B6659BF77F06-GENID-1-7-1-16-1-1-7-1-7-1-4-1-2-2"><title>SMTP protocol</title> <p>SMTP |
|
17 is the most widely used protocol for sending emails. It is a text-based and <b>push</b> protocol |
|
18 that cannot <b>pull</b> messages from a remote server on demand. </p> <p>One |
|
19 or more recipients of a message are specified in a message along with the |
|
20 message text and other encoded objects. The message is then transferred to |
|
21 a remote server using a procedure of queries and responses between the client |
|
22 and server. Either an end-user's email client (Mail User Agent (MUA)) or a |
|
23 relaying server's Mail Transport Agents (MTA) can act as an SMTP client. The |
|
24 SMTP client initiates a TCP connection to SMTP server on port 25 (unless overridden |
|
25 by configuration). </p> <p>SMTP is more suitable for a machine permanently |
|
26 connected to the Internet. To retrieve messages only on demand, which is the |
|
27 most common requirement on a single-user computer, a mail client must use |
|
28 POP3 or IMAP4. POP3 is mostly preferred when single-user computers connected |
|
29 to the Internet only intermittently. </p> </section> |
|
30 <section><title>Symbian platform implementation of SMTP</title> <p>SMTP is |
|
31 a Mail Transfer Agent (MTA) used to transfer emails to a SMTP server which |
|
32 then forwards them on to a specified destination. </p> <p>Sending an email |
|
33 generally consists of three phases: connect and authorise to server, send |
|
34 emails and quit. </p> <p>The SMTP component is responsible for sending email |
|
35 messages composed and stored in the Message Server’s Message Store. </p> <ol id="GUID-8FCD7F76-46FD-58E9-9EBA-B178B98F0782"> |
|
36 <li id="GUID-A8B5A1FA-DE84-51E8-B2B3-B4FCD073E0D2"><p>The SMTP client initiates |
|
37 a connection with the SMTP server. Depending on the user’s email settings, |
|
38 this may have been initiated over a secure SSL/TLS socket on port 465. </p> </li> |
|
39 <li id="GUID-F18E9E52-DF7A-5127-B6DD-FB08663025E0"><p>Depending on how the |
|
40 user has configured the email settings and the capabilities of the SMTP server, |
|
41 SMTP authentication may also be required. </p> </li> |
|
42 <li id="GUID-74561ABB-4B7A-58E7-B79D-5473C3149476"><p>Mail <b>From</b> and |
|
43 recipient <b>To</b> are sent. </p> </li> |
|
44 <li id="GUID-7ABADE92-CAF1-524A-A8AB-288E9849BED1"><p>The message header fields |
|
45 for the email message stored in the Message Store are then transmitted, each |
|
46 one separated by a CRLF. </p> </li> |
|
47 <li id="GUID-7932B3D6-270F-5983-8521-8AC83C7AA450"><p>The last CRLF is sent |
|
48 to indicate the end of the RFC 2822 header. </p> </li> |
|
49 <li id="GUID-2A05FF85-4E42-5EEE-A2C5-4763C887E3D2"><p>The message body and |
|
50 encoded attachments are sent. </p> <p>The encoding format (uuencode or MIME, |
|
51 character sets) depends on the user’s email settings and locale. </p> </li> |
|
52 <li id="GUID-7040A4EB-AA7C-5932-B7FF-89595D9256D0"><p>Finally, the body is |
|
53 terminated by a CRLF. </p> <p>CRLF sequence, and the email is queued by the |
|
54 SMTP server for sending. </p> </li> |
|
55 </ol> </section> |
|
56 <section><title>SMTP example</title> <p>For more details on implementing the |
|
57 IMAP4 MTM functions, see <xref href="GUID-D73AD200-BE4D-50BF-BCF9-14627DE530B7.dita">example |
|
58 code</xref>. </p> </section> |
|
59 </conbody><related-links> |
|
60 <link href="GUID-4F703F85-080F-5B77-B94D-5449764828F3.dita"><linktext>SMTP MTM</linktext> |
|
61 </link> |
|
62 </related-links></concept> |