UW IMAP

Although it has not been actively developed in many years, it still works well as a basic IMAPS server. (For other IMAP servers, see Mail server#POP3/IMAP servers.)

From Wikipedia:

UW IMAP is the reference server implementation of the IMAP protocol, developed at the University of Washington.

Installation

In arch, UW IMAP is simply called imap.

Install imap. It does not use a configuration file.

Setup

Although it was originally designed to be used with inetd, on modern Arch systems a better solution is to use a systemd socket file:

/etc/systemd/system/imaps.socket
[Unit]
Description=IMAP Server Activation Socket
Documentation=https://www.washington.edu/imap/

[Socket]
ListenStream=0.0.0.0:993
Accept=true

[Install]
WantedBy=sockets.target

Also, a corresponding .service file needs to be created:

/etc/systemd/system/imaps@.service
[Unit]
Description=IMAP Server

[Service]
ExecStart=-/usr/bin/imapd
StandardInput=socket

UW-IMAPD uses PAM, so a PAM authorization file will also need to be created. This example will provide authentication using standard system passwords:

/etc/pam.d/imap
auth		required	pam_unix.so
account		required	pam_unix.so
session		required	pam_unix.so

Enable and start imaps.socket and test.

SSL

A generic SSL certificate and key will be created at /etc/ssl/certs/imapd.pem if it does not yet exist. This can (and should) be replaced with a signed certificate for the specific server.

gollark: Wow, that sounds *intensely* trustworthy.
gollark: Interesting fact: Cap and WS is actually the only raider. They are trying to scam people into a "free Nitro" server.
gollark: I would trust them with SSH keys for a totally irrelevant system I don't care about.
gollark: They're so trustworthy that they're a Trusted User.
gollark: Factually incorrect.
This article is issued from Archlinux. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.