be527f9745
LICENSE is the Domi CPAL-1.0 text with Exhibit A and B filled in (domi-licence's LICENSE.template, only
{ORIGINAL_CODE} = EpistulaPublic). Cargo.toml license = CPAL-1.0, version 0.2.1. The README says that v0.1.0
and v0.2.0 stay MPL-2.0 for those who received them, and that a redistributor shows the Exhibit B credit.
2.3 KiB
2.3 KiB
Epistula Domi — core (public)
Epistula is the Domi family mail client. This repository is the public, CPAL-1.0 core (MPL-2.0 up to v0.2.0; README, Licence), epistula-core:
everything that reads or writes mail content, so that anyone can check how hostile mail is handled.
The app (Tauri, storage, IMAP/SMTP, UI) lives in the private Epistula repo and depends on this one by git tag.
Remote: https://gitea.marek-novak.cz/mnovak/EpistulaPublic.git (public; a read-only GitHub mirror for CI).
What is here
src/mime.rs parse (mail-parser): bodies, attachments, inline cid parts, headers
src/compose.rs compose (mail-builder): multipart/alternative, attachments, reply, reply all, forward
src/filename.rs hostile attachment names -> safe names (../, reserved Windows names, bidi controls)
src/thread.rs threading: Message-ID / In-Reply-To / References, normalised-subject fallback
src/rules.rs incoming rules (from/to/subject contains -> move to folder), first match wins; Sieve export
src/sanitize.rs HTML sanitiser (ammonia allow-list), remote images -> placeholders, the dark reader's colours
src/sanitize/colour.rs CSS colours: parse, WCAG contrast, grey, lighten in hue to 4.5 : 1
src/search.rs search query parser (free text, from:, to:, subject:, has:attachment, is:starred) -> FTS5
tests/ the mandatory tests (fixtures are built in code; no corpora in git)
Commands
cargo test # all mandatory tests (unit + proptest)
cargo test --release # same; the 8 MB fixture is faster
On the dev machine set CARGO_HOME=F:\C-Drive-Migration\future-caches\cargo (C: is off limits).
Rules
- Pure. No I/O, no clock, no randomness, no network. Message-IDs and dates are parameters.
- Mail is hostile input: never panic on it, never
unwrap()on it. Every limit is a constant with a test. - Commits:
[core] <Feature>: <description>. No AI attribution in commits, PRs or tags, ever. - Branch → Gitea PR via API (
$GITEA_TOKEN, never echoed) → self-review in the PR body → merge--no-ff→ push →git rev-parse HEAD origin/maintwice the same. A release is a tagvX.Y.Z; the app bumps its tag. - Tests first. Quote counts. No binaries or test corpora in git.
- The rules model must stay expressible as Sieve (
header :contains+fileinto): V2 compiles it.