jcoffey 82dc877fe1 Start at once on a device marked as your own (#395)
* Start at once on a device marked as your own

On a distant link, opening the app waited on four round trips before the
inbox showed: the app page, the session, the folder list, then the folder.

A trusted device now starts from what it kept:

- the service worker answers an app route from its kept page and fetches a
  fresh one behind it; the app checks the server's version at start, and a
  reload for a new build puts the new page in place first, so it is not
  answered with the old one. Assets of the page just replaced are kept one
  build longer for a tab still running it.
- the session's public details, so requests for mail go out before the
  server has confirmed the session; the answer replaces it, and a session
  that has ended lands on the sign-in form as before.
- the folder list and the first page of up to four recently read folders,
  list properties only, so the folders and the inbox paint before any reply
  and the folder query does not wait on the folder list. The "folder no
  longer exists" check still waits for the server's list.

All of it goes through the storage gate: nothing is written or read on a
device not marked as the reader's own, and signing out clears it.

* Show nothing kept before the session is confirmed

Starting from a kept session put the kept inbox on screen before the
server had said the session was still good; a session that had ended
showed mail and then the sign-in form. The spinner stays until the
server answers, as before.

The kept session is gone -- it existed only to start early. The kept
folder list and rows are still applied, from setAccount, which runs once
the session is confirmed: the inbox paints the moment that answer
arrives, and the folder query goes out then without waiting on the
folder list. An unreachable server lands on the sign-in form as before.
2026-09-16 13:47:59 -07:00

ihasmail

Try the demo
A working copy with an invented mailbox behind it — no sign-up, nothing real, nothing kept.

License: AGPL-3.0-or-later Requires Stalwart 0.16 or newer; tested against 0.16.22 Documentation: docs.ihasmail.org by Coffey Labs

ihasmail

Immutable webmail for Stalwart Mail Server. Mail, calendars, contacts, files and filters in one app that works as well on a phone as on a desktop — and a container with nothing to persist.

ihasmail talks only JMAP to Stalwart. There is no database, no IMAP or SMTP, and with IMMUTABLE=1 no writable filesystem either: everything durable, settings included, belongs to Stalwart, so the container is disposable.

🌐 ihasmail.org What it is, what it looks like, the full feature list
📘 docs.ihasmail.org Installing · Configuring · Using it · Shortcuts · Rebranding · Troubleshooting
📋 FEATURES.md Everything it does, feature by feature, with the capability each one needs
🧪 KNOWN-ISSUES.md What was verified live, and where Stalwart departs from a spec
🛣 ROADMAP.md What ihasmail does not do, and why

Screenshots

Inbox & conversation (dark) Inbox, dark theme Inbox & conversation (light) Inbox, light theme
Composer Composer Calendar Calendar
Contacts Contacts Sieve filter builder Filters

Taken against the built-in mock with sample data. More, including the phone layout, on ihasmail.org.

What's in it

  • Mail — conversations, labels, search operators, keyboard shortcuts, scheduled and undo send, invitations and RSVP, filters made from a message
  • Calendar — month, week, day and agenda views, recurrence, attendees and free-busy
  • Contacts — address books, groups, vCard import and export
  • Files — browse, upload, move, share
  • Signature checking — S/MIME signed mail verified as you read it
  • Settings that follow the account, kept in the account's own storage on Stalwart
  • On a phone — swipe to archive or delete, pull to refresh, hold to select
  • Administration — a dashboard, accounts, groups, mailing lists, roles, tenants and domains, each shown only when the Stalwart role allows it
  • Ten interface languages and twelve themes — the nine translations are marked Beta until a native speaker has read them
  • Platform — installable PWA, Web Push, mailto: handler, no credentials in the browser, strict CSP

The long version is FEATURES.md and ihasmail.org.

Requirements

Stalwart 0.16 or newer — sign-in refuses anything older, by name. Tested against 0.16.22; what changed in each release is in KNOWN-ISSUES.md.

Quick start (Docker)

cp .env.example .env
# edit: STALWART_URL=https://mail.example.com  and  APP_SECRET=$(openssl rand -base64 48)
docker compose up --build -d
# → http://localhost:8080 — put a reverse proxy in front for TLS

Or pull the published image, ghcr.io/coffey-labs/ihasmail. Releases are weekly, so it is usually a few days behind main.

People sign in with their Stalwart mailbox credentials. An account with two-factor authentication needs an app password, created in Stalwart's own settings.

Everything else — TLS, running immutably, several Stalwart servers, settings the installation decides, every environment variable — is in Installing and Configuring.

Development

npm install
npm run dev:mock     # built-in mock Stalwart ([email protected] / demo)
npm test

Architecture, the mock's switches and how versions are numbered are in CONTRIBUTING.md.

Contributing

CONTRIBUTING.md · CODE_OF_CONDUCT.md · SECURITY.md — please report vulnerabilities privately.

License

Copyright (C) 2026 Coffey Labs — AGPL-3.0-or-later. See LICENSE.

If you run a modified ihasmail, set SOURCE_URL to your own repository: the sign-in page and Settings About both show it. See Rebranding.

S
Description
Imported from github.com during the 2026-09-20 standup (local dir: ihasmail)
Readme AGPL-3.0
6.5 MiB
v2026.9.20
Latest
2026-09-21 09:23:45 +00:00
Languages
TypeScript 94.7%
CSS 2.9%
JavaScript 1.7%
Python 0.4%
Shell 0.2%