Scripts2026年5月25日·1 分钟阅读

Mox — Modern Full-Featured Self-Hosted Mail Server

A secure, low-maintenance mail server written in Go that handles SMTP, IMAP, SPF, DKIM, DMARC, and automatic TLS in a single binary, designed to make self-hosting email practical.

Agent 就绪

先审查再安装

这个资产需要先审查。复制的指令会要求 Agent dry-run、列出写入项,确认后再继续。

Needs Confirmation · 64/100策略:需确认
Agent 入口
任意 MCP/CLI Agent
类型
Skill
安装
Single
信任
信任等级:Established
入口
Mox Overview
先审查命令
npx -y tokrepo@latest install 3f680194-5877-11f1-9bc6-00163e2b0d79 --target codex

先 dry-run,确认写入项后再运行此命令。

Introduction

Mox is a modern, self-hosted mail server that bundles all essential email protocols and security features into a single Go binary. It reduces the operational complexity of running your own mail infrastructure by handling SMTP, IMAP, SPF, DKIM, DMARC, MTA-STS, and automatic TLS out of the box.

What Mox Does

  • Sends and receives email via SMTP with automatic TLS certificate management
  • Provides IMAP4 access for reading mail from any email client
  • Implements SPF, DKIM signing, and DMARC policy enforcement
  • Includes a built-in webmail interface for browser-based access
  • Offers automatic junk mail filtering with Bayesian classification

Architecture Overview

Mox is a single Go binary that runs all mail services in one process. It stores messages in its own database format on the filesystem, with per-account directories. The server manages its own TLS certificates via ACME (Let's Encrypt), handles DNS-based authentication (SPF, DKIM, DMARC), and implements JMAP alongside IMAP for modern client support.

Self-Hosting & Configuration

  • Run the quickstart command to generate configuration and DNS record instructions
  • Requires a VPS with a public IP, reverse DNS configured, and ports 25, 443, 993 open
  • Configuration lives in mox.conf and domains.conf files (auto-generated on quickstart)
  • Automatic daily backups can be configured to a local directory or remote storage
  • Add accounts via CLI commands; each account gets isolated storage

Key Features

  • Single binary deployment with no external database dependency
  • Built-in webmail UI with HTML and plain-text message rendering
  • Automatic ACME TLS certificate provisioning and renewal
  • Reputation-based rate limiting for outbound delivery
  • DANE and MTA-STS enforcement for secure transport between mail servers

Comparison with Similar Tools

  • Mail-in-a-Box — Bundles multiple packages (Postfix, Dovecot, Roundcube) with a setup script; mox is a single binary with fewer moving parts
  • Maddy — Similar single-binary approach; mox adds built-in webmail and more complete MTA-STS/DANE support
  • Stalwart Mail — Rust-based alternative with JMAP focus; mox offers a simpler quickstart experience and Go ecosystem familiarity
  • iRedMail — Install script for traditional mail stack; mox avoids the complexity of managing Postfix, Dovecot, and ClamAV separately

FAQ

Q: Will my emails end up in spam? A: Mox implements all modern authentication standards (SPF, DKIM, DMARC, MTA-STS). Following the DNS setup instructions and using a VPS with clean IP reputation gives good deliverability.

Q: Can mox handle multiple domains? A: Yes, add domains via the admin interface or CLI. Each domain gets its own DKIM keys and DMARC policy.

Q: How does the junk filter work? A: Mox uses per-account Bayesian filtering that learns from messages you mark as junk or not-junk, combined with reputation tracking of sending IPs.

Q: What are the hardware requirements? A: Mox is lightweight. A VPS with 512MB RAM and 10GB storage is sufficient for personal use with a few accounts.

Sources

讨论

登录后参与讨论。
还没有评论,来写第一条吧。

相关资产