SMTP & LMTP transparent forwarding

Module that implements transparent forwarding of messages over SMTP.

Use in pipeline configuration:

deliver_to smtp tcp://127.0.0.1:5353
# or
deliver_to smtp tcp://127.0.0.1:5353 {
  # Other settings, see below.
}

target.lmtp can be used instead of target.smtp to use LMTP protocol.

Endpoint addresses use format described in Configuration files syntax / Address definitions.

Configuration directives

target.smtp {
    debug no
    tls_client {
        ...
    }
    attempt_starttls yes
    require_tls no
    auth off
    targets tcp://127.0.0.1:2525
    connect_timeout 5m
    command_timeout 5m
    submission_timeout 12m
}

debug boolean

Default: global directive value

Enable verbose logging.


tls_client { ... }

Default: not specified

Advanced TLS client configuration options. See TLS configuration / Client for details.


attempt_starttls boolean

Default: yes (no for target.lmtp)

Attempt to use STARTTLS if it is supported by the remote server. If TLS handshake fails, connection will be retried without STARTTLS unless require_tls is also specified.


require_tls boolean

Default: no

Refuse to pass messages over plain-text connections.


auth off | plain username password | forward | external

Default: off

Specify the way to authenticate to the remote server. Valid values:


targets endpoints...

Required.
Default: not specified

List of remote server addresses to use. See Address definitions for syntax to use. Basically, it is tcp://ADDRESS:PORT for plain SMTP and tls://ADDRESS:PORT for SMTPS (aka SMTP with Implicit TLS).

Multiple addresses can be specified, they will be tried in order until connection to one succeeds (including TLS handshake if TLS is required).


connect_timeout duration

Default: 5m

Same as for target.remote.


command_timeout duration

Default: 5m

Same as for target.remote.


submission_timeout duration

Default: 12m

Same as for target.remote.