xmppd is a carrier-grade XMPP server written in Zig, inspired by Postfix's multi-process architecture. It targets FreeBSD first with kqueue-based async I/O, DANE-first federation, and thread-per-core scaling.
Quick Start#
# Install on FreeBSD
pkg install xmppd
# Edit the configuration
cp /usr/local/etc/xmppd/xmppd.conf.sample /usr/local/etc/xmppd/xmppd.conf
vi /usr/local/etc/xmppd/xmppd.conf
# Start the server
service xmppd enable
service xmppd start
Binaries#
xmppd ships as six binaries, each with a specific role:
| Binary | Purpose |
|---|---|
xmppd |
Master supervisor - spawns and monitors all child processes |
xmppd-core |
C2S connection handler - XMPP protocol, routing, MUC, MAM |
xmppd-auth |
Local authentication - SCRAM-SHA-256, PLAIN, user management |
xmppd-auth-oidc |
OIDC authentication - OAUTHBEARER, JWT validation, IdP delegation |
xmppd-s2s |
S2S federation - DANE, SASL EXTERNAL, dialback |
xmppctl |
Admin CLI - user management, lockout, invitations |
Design Principles#
- Postfix-inspired - one config file, one package, one service. Privilege-separated child processes.
- Thread-per-core - each CPU core runs its own kqueue event loop. No shared-nothing message passing between workers for local operations.
- DANE-first - DNS-based authentication is the primary S2S trust path. PKIX/CA is the fallback.
- Zero runtime dependencies - static Zig binaries. Only OpenSSL and your chosen storage backend at runtime.
- Auditable - the entire server is ~30,000 lines of Zig. No transitive dependency surprises.
Requirements#
- FreeBSD 14.0+ (kqueue required)
- OpenSSL (system or ports)
- Zig 0.15.2 (build only - not needed at runtime)
Source Code#
xmppd is free and open source under the BSD-2-Clause license.