E-mail for sharing events: shared with you, send a link by e-mail, drop-link uploads, link expiring, digest #1103

Closed
opened 2026-11-04 03:11:09 +00:00 by Cordy · 4 comments
Owner

Gap (v0.7 feature-gap research, 2026-11-04, decided by Nikola; named by all four competitor reports). Cairn's mail pipeline sends security notices only (docs/handbook/mail.md:288-300 at 0e0885db, VERIFIED). Nobody is told by e-mail that something was shared with them, a link cannot be sent from Cairn, and an owner is not told about uploads to a drop link.

Competitors. ownCloud 10 activity e-mails (admin manual); OpenCloud notifications service with e-mail and digests (README); Nextcloud share mails and "send link by mail"; Seafile share and upload notifications.

To research and decide when worked on. Which events, opt-in or opt-out per kind (the bell already has mutes), immediate vs daily digest, recipient language, links to the item without leaking names to the wrong person (#1054/#1077), rate limits, unsubscribe, templates in EN/DE/FR/IT, imprint footer (see the branding issue), mail to external addresses for "send link".

Refs: scratch/b7e/backlog/gap-v07/research-v07-gaps.md A4.

**Gap (v0.7 feature-gap research, 2026-11-04, decided by Nikola; named by all four competitor reports).** Cairn's mail pipeline sends security notices only (`docs/handbook/mail.md:288-300` at 0e0885db, VERIFIED). Nobody is told by e-mail that something was shared with them, a link cannot be sent from Cairn, and an owner is not told about uploads to a drop link. **Competitors.** ownCloud 10 activity e-mails ([admin manual](https://doc.owncloud.com/server/10.16/admin_manual/configuration/server/activity_configuration.html)); OpenCloud notifications service with e-mail and digests ([README](https://raw.githubusercontent.com/opencloud-eu/opencloud/main/services/notifications/README.md)); Nextcloud share mails and "send link by mail"; Seafile share and upload notifications. **To research and decide when worked on.** Which events, opt-in or opt-out per kind (the bell already has mutes), immediate vs daily digest, recipient language, links to the item without leaking names to the wrong person (#1054/#1077), rate limits, unsubscribe, templates in EN/DE/FR/IT, imprint footer (see the branding issue), mail to external addresses for "send link". Refs: `scratch/b7e/backlog/gap-v07/research-v07-gaps.md` A4.
Author
Owner

Research done (at d02f2ba1, scratch/b7e/backlog/research-1103.md; claims marked VERIFIED/INFERRED/UNVERIFIED).

Today mail carries security notices only (internal/mailsvc/plan.go:10-34). Nobody is told when something is shared with them, when they are added to a space, when files arrive through their link, or when a link is about to end; there is no bell item for these either (notify.go:348-423, grants.go:461-483). Mail follows stored bell items only. Docs drift: mail.md:561 still says the store has no conditional write (the sender lease uses coord.Leases since #742 Step 0).

Recommended: e-mail as a second channel for four new bell kinds (shared with you, added to a space, files arrived through your link, your link ends in 3 days), switchable per kind, with an optional daily or weekly summary. "Send by e-mail" beside Copy link (needs the kept key, #1140), with per-send, per-person and per-instance limits; From the instance, Reply-To the sharer; one-click unsubscribe (RFC 8058) on optional mails only; file names in the body, never the subject; the #1054/#1077 account-start rule for reminders and summaries. Ships with #1109 so mails have imprint and privacy links.

Decisions follow.

**Research done** (at d02f2ba1, `scratch/b7e/backlog/research-1103.md`; claims marked VERIFIED/INFERRED/UNVERIFIED). Today mail carries security notices only (`internal/mailsvc/plan.go:10-34`). Nobody is told when something is shared with them, when they are added to a space, when files arrive through their link, or when a link is about to end; there is no bell item for these either (`notify.go:348-423`, `grants.go:461-483`). Mail follows stored bell items only. Docs drift: `mail.md:561` still says the store has no conditional write (the sender lease uses `coord.Leases` since #742 Step 0). Recommended: e-mail as a second channel for four new bell kinds (shared with you, added to a space, files arrived through your link, your link ends in 3 days), switchable per kind, with an optional daily or weekly summary. "Send by e-mail" beside Copy link (needs the kept key, #1140), with per-send, per-person and per-instance limits; From the instance, Reply-To the sharer; one-click unsubscribe (RFC 8058) on optional mails only; file names in the body, never the subject; the #1054/#1077 account-start rule for reminders and summaries. Ships with #1109 so mails have imprint and privacy links. Decisions follow.
Author
Owner

Decided (Nikola, 2026-11-08), all as recommended:

  • v1 events: shared with you (person, group, space share), added to a space, files arrived through your link (batched, per link, on for Upload-only links), your link ends in 3 days.
  • On by default, opt-out per kind; one-click unsubscribe (RFC 8058) on optional mails only, never on security mails.
  • Summary in v1: As it happens / Daily / Weekly / Never.
  • Send by e-mail to outside addresses: yes, up to 10 addresses per send, 50 per person per day, 300 per instance per hour, optional allowed-domains list and an off switch; never the password in the mail.
  • Groups up to 500 members get mails, larger ones bell only and the sharer is told; From the instance, Reply-To the sharer; file names in the body only (admin can hide them); language picker for outside recipients defaulting to the sender's; the #1054/#1077 account-start rule for reminders and summaries.
  • Ships together with #1109 (logo and legal footer in the mails).
**Decided (Nikola, 2026-11-08), all as recommended:** - v1 events: shared with you (person, group, space share), added to a space, files arrived through your link (batched, per link, on for Upload-only links), your link ends in 3 days. - On by default, opt-out per kind; one-click unsubscribe (RFC 8058) on optional mails only, never on security mails. - Summary in v1: As it happens / Daily / Weekly / Never. - Send by e-mail to outside addresses: yes, up to 10 addresses per send, 50 per person per day, 300 per instance per hour, optional allowed-domains list and an off switch; never the password in the mail. - Groups up to 500 members get mails, larger ones bell only and the sharer is told; From the instance, Reply-To the sharer; file names in the body only (admin can hide them); language picker for outside recipients defaulting to the sender's; the #1054/#1077 account-start rule for reminders and summaries. - Ships together with #1109 (logo and legal footer in the mails).
Author
Owner

Mockup approved (Nikola, 2026-11-08): 1103-sharing-email-mockup.html, all frames and mails, and the open points as recommended: one button to the item with the full address printed under it; one general line for the sharer, never per person (only the over-500 group is named); no "don't tell them" choice in v1; Notifications gets its own Account settings entry; outside recipients can refuse further links from the instance (same answer to the sender either way); upload mails for space links to the link's maker only; SVG logo shown as the instance name in mails; Stop in a summary sets How often to Never; summaries at 07:00 server time, weekly on Mondays; end reminders for links only; From "Lea Brunner via {instance}" for mails a person caused, the instance name otherwise.

**Mockup approved (Nikola, 2026-11-08):** `1103-sharing-email-mockup.html`, all frames and mails, and the open points as recommended: one button to the item with the full address printed under it; one general line for the sharer, never per person (only the over-500 group is named); no "don't tell them" choice in v1; Notifications gets its own Account settings entry; outside recipients can refuse further links from the instance (same answer to the sender either way); upload mails for space links to the link's maker only; SVG logo shown as the instance name in mails; Stop in a summary sets How often to Never; summaries at 07:00 server time, weekly on Mondays; end reminders for links only; From "Lea Brunner via {instance}" for mails a person caused, the instance name otherwise.
Author
Owner

Shipped in v0.6.404 (PR #1146, merge 6a086e92), live on both dogfoods.

What shipped: four bell kinds plus optional e-mails (shared with you, added to a space, files arrived through your link after 10 quiet minutes, link ends in 3 days), per kind and channel with How often (As it happens, Daily, Weekly, Never; summaries from 07:00 server time, TZ); Account settings › Notifications as its own page; Send a link by e-mail (domain list, 10 per send, 50 per person per day, 300 per instance per hour, preview in an empty sandbox, password never sent); Stop page /u/ with RFC 8058 one-click (u1/b1 tokens on an HKDF subkey, keyring purpose mail-unsub); Administration › Sharing › Policy › Sharing e-mails box and outbox priority (security first).

Decided 2026-11-09: instance-wide switch Send sharing e-mails (shareMailOptional, pin mail.sharingOptional / CAIRN_MAIL_SHARING_OPTIONAL), default on; off queues no optional e-mail, bells stay. Final-review fixes: coord record names hashed (no link tokens in S3 object names), mail-prefs records exported and deleted with the account, export drops outside addresses and tokens from bell copies, Subjects holding =? always encoded, limits given back when queueing fails; end reminders run with mail off under their own lease link-ending. New strings approved: errSendNotYours, errSendState, chipRemoved, bellMailFailedMetaLate, errNotifPrefsUnread, bellUploads1, shareMailOptional, shareMailOptionalHint, notifMailAdminOff.

Note: the dogfoods' live mail checks (DKIM over both List headers for Gmail/Outlook one-click, a daily summary at 07:00) are on the #1005 list. Follow-ups: #1149. #742 residuals R1-R15 in ARCHITECTURE.md (at-most-once optional mail, per-process Stop rate limit, members-seen index for LDAP, new key file voids Stop links, end reminders up to ~20 min late after a hard kill, the switch reaching other instances within 10 s).

Shipped in **v0.6.404** (PR #1146, merge 6a086e92), live on both dogfoods. What shipped: four bell kinds plus optional e-mails (shared with you, added to a space, files arrived through your link after 10 quiet minutes, link ends in 3 days), per kind and channel with How often (As it happens, Daily, Weekly, Never; summaries from 07:00 server time, `TZ`); Account settings › Notifications as its own page; Send a link by e-mail (domain list, 10 per send, 50 per person per day, 300 per instance per hour, preview in an empty sandbox, password never sent); Stop page `/u/` with RFC 8058 one-click (u1/b1 tokens on an HKDF subkey, keyring purpose mail-unsub); Administration › Sharing › Policy › Sharing e-mails box and outbox priority (security first). Decided 2026-11-09: instance-wide switch **Send sharing e-mails** (`shareMailOptional`, pin `mail.sharingOptional` / `CAIRN_MAIL_SHARING_OPTIONAL`), default on; off queues no optional e-mail, bells stay. Final-review fixes: coord record names hashed (no link tokens in S3 object names), mail-prefs records exported and deleted with the account, export drops outside addresses and tokens from bell copies, Subjects holding `=?` always encoded, limits given back when queueing fails; end reminders run with mail off under their own lease `link-ending`. New strings approved: errSendNotYours, errSendState, chipRemoved, bellMailFailedMetaLate, errNotifPrefsUnread, bellUploads1, shareMailOptional, shareMailOptionalHint, notifMailAdminOff. Note: the dogfoods' live mail checks (DKIM over both List headers for Gmail/Outlook one-click, a daily summary at 07:00) are on the #1005 list. Follow-ups: #1149. #742 residuals R1-R15 in ARCHITECTURE.md (at-most-once optional mail, per-process Stop rate limit, members-seen index for LDAP, new key file voids Stop links, end reminders up to ~20 min late after a hard kill, the switch reaching other instances within 10 s).
Cordy closed this issue 2026-11-09 04:22:24 +00:00
Sign in to join this conversation.
No labels
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Cordy/Cairn#1103
No description provided.