JMAP support for GNOME Evolution, written in Rust — mail, contacts, and calendars over a single modern protocol, structured like evolution-ews.
All four backends work end-to-end in real Evolution and have been operator-verified against a real JMAP server.
| Component | Crate(s) |
|---|---|
| JMAP protocol types | evolution-jmap-proto |
| Blocking JMAP client | evolution-jmap-client |
Stateful in-memory mock JMAP server (jmap-mockd) |
evolution-jmap-mock |
Address book backend (EBookMetaBackend) |
jmap-backend-book(-module), jmap-book-sync, jmap-object-sync |
Calendar backend (ECalMetaBackend) |
jmap-backend-cal(-module), jmap-cal-sync, jmap-object-sync |
| Mail provider (Camel store/transport) | jmap-mail(-sync) |
| Collection backend (one account, all three above) | jmap-backend-collection(-module), jmap-collection-sync |
Account-setup UI (module-jmap-configuration.so), incl. OAuth2 |
jmap-config(-module) |
| JMAP-only UI features (vacation autoresponder, scheduled send, snooze) | jmap-ui |
| vCard/iCalendar mapping (JSContact/JSCalendar) | jmap-vcard, jmap-ical |
| Evolution UI module template (Rust port of the wiki example, unused by the above) | example-module |
Address book, calendar, mail send/receive, and OAuth2 via JMAP SRV
autodiscovery (_jmap._tcp) have all round-tripped and persisted against a
real deployment (Stalwart, then Fastmail), confirmed by the operator in real
Evolution — not just against the mock. The mapping crates
(jmap-vcard/jmap-ical) carry extensive round-trip and fuzz tests; a
measured spike into externalising that layer onto the calcard crate's own
converter found it a worse fit against our acceptance suite and kept the
hand-written mapping. docs/ROADMAP.md tracks what's next.
A jmap-ui module puts three JMAP-only features into Evolution's own UI,
which has no concept of them: a vacation-autoresponder page in the account
editor, scheduled send in the composer, and snooze in the message-list
context menu. Each is gated on the account's server actually offering the
feature; see docs/manual-test-ui-features.md.
The test suite covers sending and receiving email (including
EmailSubmission with envelope derivation and onSuccessUpdateEmail),
contacts CRUD, calendar CRUD, incremental sync via /changes, blob
upload/download, authentication (Basic, Bearer, and OAuth2), and protocol
edge cases, plus functional tests that drive the built .so modules against
a real EDS registry and GUI-smoke tests against a real Evolution/Xvfb.
ctest --test-dir build reports the count.
Rust is pinned via rust/rust-toolchain.toml (rustup installs it automatically). The JMAP crates need no system libraries:
cd rust && cargo testThe full build (including the Evolution module template) needs Evolution's
development headers, 3.52 being the pinned floor.
ci/install-deps.sh is the authoritative list and
installs them:
cmake -S . -B build -G Ninja
cmake --build build
ctest --test-dir buildThe modules also install as one Debian package, built from that same install tree:
cpack -G DEB --config build/CPackConfig.cmake -B build/package
sudo apt install ./build/package/evolution-jmap_*.debIts dependencies are derived from the built objects by dpkg-shlibdeps
rather than written down, so the package pins the Evolution and EDS ABI it
was compiled against. That is the contract for modules Evolution and EDS
dlopen: build them against the versions they will be installed alongside.
ctest -R package-deb builds the package and checks its contents and
control fields.
Packaging this for a distro? docs/PACKAGING.md is
addressed to you: what's already lintian-clean and CI-checked, what the
debian/ skeleton does and doesn't solve, and the one open question
(crate vendoring) an official upload needs answered.
cd rust && cargo run -p evolution-jmap-mock --bin jmap-mockdthen discover the session the way any JMAP client would:
curl -s http://127.0.0.1:8080/.well-known/jmap | jq .Against that same mock server, with hand-written accounts:
- Address book backend: docs/manual-test-book-backend.md
- Calendar backend: docs/manual-test-cal-backend.md
- Mail provider: docs/manual-test-mail-provider.md
- Collection backend (all three together): docs/manual-test-collection-backend.md
User-facing setup guide: docs/USER-GUIDE.md
rust/crates/
├── jmap-proto/ pure serde types; no I/O; fixture round-trip tests
├── jmap-client/ blocking client; HTTP behind a Transport trait with a
│ cancellation hook (GCancellable seam); ureq default;
│ SRV autodiscovery via an injectable Resolver seam
├── jmap-mock/ stateful mock server (tiny_http): auth (incl. OAuth2),
│ id allocation, per-type state + changes log, outbox
├── jmap-vcard/, jmap-ical/ JSContact<->vCard and JSCalendar<->iCalendar mapping
├── jmap-backend-core/ shared EDS/GObject FFI plumbing (evo-sys, eds-sys)
├── jmap-backend-book(-module)/ EBookMetaBackend + jmap-book-sync
├── jmap-backend-cal(-module)/ ECalMetaBackend + jmap-cal-sync
├── jmap-mail(-sync)/ CamelStore/Transport provider
├── jmap-backend-collection(-module)/ ECollectionBackend fanning one account
│ out into the three backends above
├── jmap-config(-module)/ account-setup UI (EMailConfigServiceBackend,
│ EConfigLookup) incl. OAuth2 discovery/registration
├── jmap-ui/ vacation, scheduled send and snooze in Evolution's
│ own UI; rides in jmap-config-module's .so
├── jmap-functional/ functional tests driving the built .so modules
│ against a real EDS registry (no display needed)
└── example-module/ Evolution UI module template (hand-written FFI,
unrelated to the crates above)
Structured like evolution-ews
(design notes in the commit history). FFI via glib-sys/gobject-sys plus
hand-written and bindgen-generated EDS bindings (evo-sys, eds-sys);
integration tests against Stalwart (mock-first, plus a
--features live-server harness against a real deployment) and, manually,
real Fastmail for OAuth2.
- One definition of the build, run everywhere: the
ci/scripts (checks.sh,build.sh,reproducible.sh) are the single source of truth. GitHub Actions and GitLab CI are thin wrappers that call them, the autonomous agent runsci/checks.shbefore every push, and you can run the same script on your laptop — so "green" means the same thing everywhere and the platforms can't drift. - A dedicated cacheless CI job builds the mock twice in different paths
and fails on any checksum difference (
--remap-path-prefix,SOURCE_DATE_EPOCH, pinned toolchain, committed lockfile). - Releases ship
SHA256SUMSplus Sigstore provenance recorded in the public Rekor log — see docs/verifying-artifacts.md. cargo denygates dependency licenses (GPLv3-compatible only); REUSE tracks per-file licensing.- Regular FFI and security audits. Each finding and its fix is listed in docs/SECURITY-AUDITS.md.
New code: GPL-3.0-or-later. The example-module files (C sources from the GNOME wiki and their Rust port) remain LGPL-2.1-or-later (Red Hat copyright). See REUSE.toml and LICENSES/.