summaryrefslogtreecommitdiffstats
path: root/doc/wiki/LMTP.txt
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 09:51:24 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 09:51:24 +0000
commitf7548d6d28c313cf80e6f3ef89aed16a19815df1 (patch)
treea3f6f2a3f247293bee59ecd28e8cd8ceb6ca064a /doc/wiki/LMTP.txt
parentInitial commit. (diff)
downloaddovecot-upstream.tar.xz
dovecot-upstream.zip
Adding upstream version 1:2.3.19.1+dfsg1.upstream/1%2.3.19.1+dfsg1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'doc/wiki/LMTP.txt')
-rw-r--r--doc/wiki/LMTP.txt131
1 files changed, 131 insertions, 0 deletions
diff --git a/doc/wiki/LMTP.txt b/doc/wiki/LMTP.txt
new file mode 100644
index 0000000..ead650a
--- /dev/null
+++ b/doc/wiki/LMTP.txt
@@ -0,0 +1,131 @@
+LMTP Server
+===========
+
+LMTP uses the same settings as <LDA.txt>, as specified in 'conf.d/15-lda.conf'
+in example configuration. There is also a bit of extra configuration in
+'conf.d/20-lmtp.conf'. The main difference is that the LDA is a short-running
+process, started as a binary from command line, while LMTP is a long-running
+process started by Dovecot's master process.
+
+Envelope Addresses
+------------------
+
+Compared to dovecot-lda parameters, the addresses are taken from:
+
+ * -f / Envelope sender address: This is the MAIL FROM: value from LMTP
+ session.
+ * -r / Final envelope recipient address: This is the RCPT TO: value from LMTP
+ session.
+ * -a / Original envelope recipient address: This defaults to same as RCPT TO:
+ value, but may be overridden by reading it from a header specified by
+ 'lda_original_recipient_header' setting.
+ * -d / Destination username: This is the same as RCPT TO: value, but with the
+ "+extension" part removed when 'recipient_delimiter' setting is set. If
+ usernames differ from recipient email addresses, the userdb must handle the
+ translation.
+
+Listeners
+---------
+
+You can configure LMTP to be listening on TCP or UNIX sockets:
+
+---%<-------------------------------------------------------------------------
+# add lmtp to protocols, otherwise its listeners are ignored
+protocols = imap pop3 lmtp
+
+service lmtp {
+ inet_listener lmtp {
+ address = 192.168.0.24 127.0.0.1 ::1
+ port = 24
+ }
+
+ unix_listener lmtp {
+ #mode = 0666
+ }
+}
+---%<-------------------------------------------------------------------------
+
+The UNIX listener on $base_dir/lmtp is enabled by default when protocols
+setting contains lmtp.
+
+Security
+--------
+
+Unfortunately LMTP process currently needs to run as root, and only temporarily
+drop privileges to users. Otherwise it couldn't handle mail deliveries to more
+than a single user with different UID. If you're using only a single global
+UID/GID, you can improve security by running lmtp processes as that user:
+
+---%<-------------------------------------------------------------------------
+service lmtp {
+ user = vmail
+}
+---%<-------------------------------------------------------------------------
+
+LMTP Proxying
+-------------
+
+It's possible to use Dovecot LMTP server as a proxy to remote LMTP or SMTP
+servers. The configuration is similar to <IMAP/POP3 proxying>
+[PasswordDatabase.ExtraFields.Proxy.txt], but you'll need to tell Dovecot LMTP
+to issue passdb lookups:
+
+---%<-------------------------------------------------------------------------
+lmtp_proxy = yes
+---%<-------------------------------------------------------------------------
+
+Performance
+-----------
+
+For higher volume sites, it may be desirable to increase the number of active
+listener processes. A range of 5 to 20 is probably good for most sites:
+
+---%<-------------------------------------------------------------------------
+service lmtp {
+ process_min_avail = 5
+}
+---%<-------------------------------------------------------------------------
+
+Logging
+-------
+
+If you want to store LMTP delivery logs to a different file, you can do it
+with:
+
+---%<-------------------------------------------------------------------------
+service lmtp {
+ executable = lmtp -L
+}
+protocol lmtp {
+ info_log_path = /var/log/dovecot-lmtp.log
+}
+---%<-------------------------------------------------------------------------
+
+For rawlogs, please see <Debugging.Rawlog.txt>
+
+Plugins
+-------
+
+ * Most of the <Dovecot plugins> [Plugins.txt] work with LMTP.
+ * Virtual quota can be enforced using <Quota plugin> [Quota.txt].
+ * 'lmtp_rcpt_check_quota = yes' enables quota checking already at RCPT TO
+ stage. This check isn't done for proxied connections.
+ * Sieve language support can be added with the <Pigeonhole Sieve plugin>
+ [Pigeonhole.Sieve.txt].
+
+Address extension delivery
+--------------------------
+
+To make address extension work with LMTP you must check these variables are set
+
+ * lmtp_save_to_detail_mailbox = yes
+ * recipient_delimiter = +
+
+Using LMTP with different MTAs
+------------------------------
+
+ * <Postfix> [HowTo.PostfixDovecotLMTP.txt]
+ * <Exim> [LMTP.Exim.txt]
+ * HALON [http://wiki.halon.se/LMTP]
+
+(This file was created from the wiki on 2019-06-19 12:42)