git » chasquid » next » tree

[next] / docs / flow.md

Message flows

This document explains at a high level some parts of chasquid's message processing, in particular how messages flow through the system.

Message reception

Authenticated mail, and email spoofing

By default, authenticated users can send emails as any other user or domain. For example, you can authenticate as a@a, and send email as b@b.

This is a design choice made to balance simplicity of operation and use.

Users who want to be strict about "MAIL FROM" or even "From:" validation can add additional checks in the post-DATA hook.

In the future, chasquid may get some option to be strict about it by default, or on a per-domain or per-user basis. But for now, using a post-DATA hook is the best way to make chasquid more strict about this.

Queue processing

Before accepting a message:

Queue processing runs asynchronously, there's a goroutine for each message which does, in a loop: