Skip to main content
  • 产品
  • Evaluate our Software
  • 下载
  • Free Utilities
  • 购买
  • 芯片厂商
  • 支持
  • 关于我们
  • Search
  • 工作机会
  • 新闻简报
  • 联系我们
  • emNet
  • About SMTP Client

    SMTP client

    The emNet Simple Mail Transfer Protocol (SMTP) client is an optional extension which can be seamlessly integrated into your TCP/IP application. It combines a maximum of performance with a small memory footprint. The SMTP client allows an embedded system to send emails with dynamically generated content. The RAM usage of the SMTP client module has been kept to a minimum by smart buffer handling.

    Contact us
    Downloads
    Documentation
    SEGGER emNet
    1. 1.SMTP Backgrounds
    2. 2.Relevant parts
    3. 3.Resource Usage
    4. 4.Requirements
    5. 5.SMTP Relay
    6. 6.emNet SMTP Client with TLS Support

    Overview

    The Simple Mail Transfer Protocol is a text based communication protocol for electronic mail transmission across IP networks.

    Application layerApplication layer protocol:
    SMTP
    Transport layerTranport layer protocol:
    TCP
    Network layerNetwork layer protocol:
    IP
    Link layerLink layer protocol:
    Ethernet (IEEE 802.3), ...

    Key features

    • Low memory footprint.
    • Independent of the TCP/IP stack: any stack with sockets can be used.
    • Example applications included.
    • Project for executable on PC for Microsoft Visual Studio included.
    • Send emails securely via TLS with emSSL. This allows using almost any mail server on the internet.1

    1 emSSL delivers the secure connection and has to be purchased separately.

    SMTP Backgrounds

    Using SMTP, an emNet application can transfer mail to an SMTP server on the same network or to SMTP servers in other networks via a relay or gateway server accessible to both networks. When the emNet SMTP client has a message to transmit, it establishes a TCP connection to an SMTP server and transmits the message content after the handshaking.

    The handshaking mechanism normally includes an authentication process. The RFC define the following four different authentication schemes:

    • PLAIN
    • LOGIN
    • CRAM-MD5
    • NTLM

    In the current version, the emNet SMTP client supports only LOGIN authentication.
    The following listing shows a typical SMTP session:

    S:  220 srv.sample.com ESMTP
    C:    HELO
    S:  250 srv.sample.com
    C:    AUTH LOGIN
    S:  334 VXNlcm5hbWU6
    C:    c3BzZXk29IulbkY29tZcZXIbtZ
    S:  334 UGFzc3dvcmQ6
    C:    UlblhFz7ZlblsZlZQ==
    S:  235 go ahead
    C:    Mail from:
    S:  250 ok
    C:    Rcpt to:
    S:  250 ok
    C:    Rcpt to:
    S:  250 ok
    C:    Rcpt to:
    S:  250 ok
    C:    DATA
    S:  354 go ahead
    C:    Message-ID: <1000.2234@sample.com>
    C:    From: "User0" 
    C:    TO: "User1" 
    C:    CC: "User2" , "User3" 
    C:    Subject: Testmail
    C:    Date: 1 Jan 2008 00:00 +0100
    C:    
    C:    This is a test!
    C:
    C:    .
    S:  250 ok 1231221612 qp 3364
    C:    quit
    S:  221 srv.sample.com

    Relevant parts

    The SMTP client implements the relevant parts of the following Request For Comments (RFC).

    RFC#Description
    [RFC 821]Direct Link: Simple Mail Transfer Protocol (Aug 1982)
    [RFC 974]Direct Link: Mail routing and the domain system
    [RFC 5321]Direct Link: Simple Mail Transfer Protocol (Oct 2008)

    Resource Usage

    The ROM usage depends on the compiler options, the compiler version and the used CPU. The memory requirements of the SMTP Client module presented in the tables below have been measured on an ARM7 and a Cortex-M3 system. Details about the further configuration can be found in the sections of the specific example.

    Configuration used:

    #define SMTPC_OUT_BUFFER_SIZE   256

    ROM Usage on an ARM7 System: The following resource usage has been measured on an ARM7 system using IAR Embedded Workbench V6.30.6, Thumb mode, no interwork, size optimization.

    Add-onROM
    emNet SMTP ClientApproximately 7.1 KByte

    ROM Usage on a Cortex-M3 System: The following resource usage has been measured on a Cortex-M3 system using IAR Embedded Workbench V6.30.6, size optimization.

    Add-onROM
    emNet SMTP ClientApproximately 6.5 KByte

    RAM Usage:

    Add-onRAM
    emNet SMTP ClientApproximately 4.7 KByte

    Requirements

    TCP/IP stack: The emNet SMTP client requires a TCP/IP stack. It is optimized for emNet, but any RFC compliant TCP/IP stack can be used. The shipment includes a Win32 simulation, which uses the standard Winsock API and an implementation which uses the socket API of emNet.

    Multi Tasking: The SMTP client needs to run as a separate thread. Therefore, a multi tasking system is required to use the emNet SMTP client.

    SMTP Relay

    The emNet SMTP Client may also be used in combination with an SMTP Relay Client. A document descibing the configuration of an exemplary SMTP Relay Client application, the Mercury Mail Transport System, is available at our download page.

    emNet SMTP Client with TLS Support

    Many mail servers on the internet accept only secure connections. The emNet SMTP client can be extended with emSSL to create a secure connection using TLS. This allows using almost any mail server on the internet. emSSL has to be purchased in addition to emNet and comes with the sources for using the SMTP client with TLS.

    • User manual
    • Online documentation
    • List of downloads
    • Release notes
    • Update notification
    • Pricing
    • Support
    • Silicon vendor resources

    全球总部

    德国: SEGGER Microcontroller GmbH

    地址: Ecolab-Allee 5
    40789 Monheim am Rhein, Germany
    电邮: info@segger.com
    电话: +49-2173-99312-0
    传真: +49-2173-99312-28

    网点分布

    中国:哲戈微系统科技(上海)有限公司

    地址: 中国上海市闵行区秀涟路133号
    大虹桥国际A 栋218室
    邮编201199
    电邮: china@segger.com
    电话: +86-133-619-907-60


    简易信息聚合

    通过ISO 9001认证

    ISO 9001

    30多年的嵌入式行业经验

    First-class embedded software tools since 1992
    • 版本说明
    • 免责声明
    • 行为准则
    • 隐私策略
    • 沪ICP备2022005181号
    • 沪公网安备 31011202014525号
    © 2025 SEGGER - 版权所有.

    您即将离开 segger.cn 而访问境外网站,是否继续?