Move smtp.RelayMessage into a new smtp.MTA interface.
[mailpopbox.git] / README.md
1 # mailpopbox
2
3 Mailpopbox is a single-user mail server with SMTP and POP facilities. Its purpose is to provide
4 privacy through anonymity by acting as a catch-all, wildcard email server for an entire domain name.
5 Any message addressed to an account at the configured domain will be deposited into a single
6 mailbox, which can then be accessed using the POP3 protocol.
7
8 The usage scenario is to configure your primary email provider (e.g.,
9 [Gmail](https://support.google.com/mail/answer/7104828)) or client to POP messages off the
10 server. Any time you need to provide an email address, you can give out
11 `arbitrary-string@domain.com`, allowing you to use site/service/person-specific email addresses.
12 Mail is collected into a single maildrop that can be POP'd out into your normal mailbox.
13
14 ## Send-As SMTP
15
16 Mailpopbox also provides a way to reply to messages from an arbitrary email address at the domain.
17 Since mailpopbox is designed as a catch-all mail server, it would be impractical to administer SMTP
18 accounts to enable replying from any address handled by the server. Instead, the SMTP authenticates
19 a single *mailbox* user, and if the message's Subject header has a special `[sendas:ADDRESS]`
20 string, the server will alter the From message header to be from ADDRESS@DOMAIN.
21
22 ## Installation
23
24 Installation requires a server capable of binding on port 25 for SMTP and 995 for POP3. A TLS
25 certificate is also required to have a secure connection for authenticating to the server. See the
26 [installation guide](docs/install.md) for a full set of steps.
27
28 ## Building
29
30 Building mailpopbox only requires [Go](https://golang.org) and git. Clone the repository and type
31 `go build`. Cross-compilation is supported since the server is written in pure Go.
32
33 ## Contributing
34
35 [![CI](https://github.com/rsesek/mailpopbox/workflows/CI/badge.svg)](https://github.com/rsesek/mailpopbox/actions?query=workflow%3ACI)
36
37 The canonical home for the repository is on
38 [src.bluestatic.org](https://src.bluestatic.org/?p=mailpopbox.git), but it is also hosted on
39 [Github](https://github.com/rsesek/mailpopbox) to enable collaboration.
40
41 Issues should be reported on the [Github issue tracker](https://github.com/rsesek/mailpopbox/issues).
42
43 Contributions are welcome. Please:
44 - Ensure tests pass and that new changes have adequate code coverage (`make coverage`)
45 - Code is formatted with `go fmt`
46 - Commit history is clean (one logical change per commit)
47 - Commit message is well-formatted
48
49 ## RFCs
50
51 This server implements (partially) the following RFCs:
52
53 - [Post Office Protocol - Version 3, RFC 1939](https://tools.ietf.org/html/rfc1939)
54 - [Simple Mail Transfer Protocol, RFC 5321](https://tools.ietf.org/html/rfc5321)
55 - [Message Submission for Mail, RFC 6409](https://tools.ietf.org/html/rfc6409)
56 - [SMTP Service Extension for Secure SMTP over Transport Layer Security, RFC 3207](https://tools.ietf.org/html/rfc3207)
57 - [SMTP Service Extension for Authentication, RFC 2554](https://tools.ietf.org/html/rfc2554)
58 - [The PLAIN Simple Authentication and Security Layer (SASL) Mechanism, RFC 4616](https://tools.ietf.org/html/rfc4616)
59 - [Simple Mail Transfer Protocol (SMTP) Service Extension for Delivery Status Notifications (DSNs), RFC 3461](https://tools.ietf.org/html/rfc3461)
60 - [POP3 Extension Mechanism, RFC 2449](https://tools.ietf.org/html/rfc2449)