Space membership with an "Until" date #1039

Closed
opened 2026-10-28 17:51:01 +00:00 by Cordy · 4 comments
Owner

Follow-up from the #1035 root-share research (2026-10-29). Whole-space access goes only through membership; the real need behind "share the whole space with someone for a while" is temporary membership. OpenCloud lets managers set an expiration date on space members (docs.opencloud.eu/docs/user/spaces/add-members).

Scope (research + mockup first):

  • optional "Until" on a member (app-owned spaces); what happens at expiry (removed, audited, bell to owner and member), reminders before expiry;
  • directory spaces: not applicable (the directory decides), or a Cairn-side overlay?
  • standards angle: NIS2 Annex 11 "third-party access limited in scope and duration", NIST AC-2(2)/(3).
Follow-up from the #1035 root-share research (2026-10-29). Whole-space access goes only through membership; the real need behind "share the whole space with someone for a while" is temporary membership. OpenCloud lets managers set an expiration date on space members (docs.opencloud.eu/docs/user/spaces/add-members). Scope (research + mockup first): - optional "Until" on a member (app-owned spaces); what happens at expiry (removed, audited, bell to owner and member), reminders before expiry; - directory spaces: not applicable (the directory decides), or a Cairn-side overlay? - standards angle: NIS2 Annex 11 "third-party access limited in scope and duration", NIST AC-2(2)/(3).
Author
Owner

Research (2026-10-30). The full write-up with sources and VERIFIED, INFERRED and UNVERIFIED markers is in scratch/b7e/backlog/research-1039.md.

Market

  • OpenCloud (read in its code): access ends at the expiry date, but the member is only removed and notified the next time someone opens the space. There is no reminder and the manager is never told.
  • Box comes closest: an admin switch auto-removes collaborators (applied to external people by default), and owners get mail 7 days before and can extend.
  • GitLab mails the member 7 days before, but lets maintainers extend their own access, which is a pitfall to avoid.
  • SharePoint shows a banner 2 to 3 weeks ahead and mails site admins weekly; its sharing links survive expiry.
  • No member expiry: Nextcloud, ownCloud 10, Dropbox and Google Drive only time-limit shares and links. Keycloak has no built-in expiry for group membership.

Standards: NIS2 Implementing Regulation Annex 11 requires third-party access limited in duration, and NIST AC-2(2)/(3). BSI ORP.4 is marked unverified.

Cairn today

  • A space member has only a user and a role; every access check (devices, WebDAV, Office) reads that from memory.
  • Share "Until" is checked silently when used: no audit, no bell, no reminder.
  • Member removal (#1035) needs a signed-in web request, so an automatic expiry cannot reuse it as is. It also leaves the member's locks in place.
  • Several instances: #1011 is still open (membership is cached in memory per instance), and persisted bells can be lost between instances.

Recommended design

  • End date: an optional end date per member, enforced in the one shared access check, so access ends at that instant everywhere without depending on a background job.
  • Who sets it: only the owner or an admin, using the same presets as share "Until", stored as the end of the chosen day. Members cannot change their own date.
  • Reminder: a bell 7 days before, to both owner and member.
  • At expiry: one instance (the one already running the periodic group checks) removes the member once.
    • The member goes into a "Recently ended" list for 30 days, with "Add again".
    • The removal is audited as space-member-expired.
    • Shares the member made stay (the #1035 rule) and their locks are released.
    • Bells are computed from the space record, so two instances never send duplicates.
  • Restore: restoring a deleted space never brings back members whose date has passed.
  • Directory spaces: not applicable; the directory decides.
  • 11 mockup frames.

Open questions, with my recommendations

  1. Reminder: 7 days, to owner and member, no second reminder in v1.
  2. A member's shares cannot end after their membership; existing shares stay at expiry.
  3. "Recently ended" list kept 30 days: yes.
  4. The member's reminder cannot be muted; the owner's can.
  5. Date only, not a time.
  6. App-group-linked spaces: allow an end date, with a note in the dialog.
  7. An admin maximum or required end date: later, as its own issue.
  8. Release locks on expiry and on manual removal: yes.
  9. A Cairn-side override for directory spaces: no.
  10. Email reminders: not in v1 (#896 mail could be added later).
  11. Rollback makes temporary members permanent: say so in the upgrade notes and offer a CSV export first.
**Research (2026-10-30).** The full write-up with sources and VERIFIED, INFERRED and UNVERIFIED markers is in `scratch/b7e/backlog/research-1039.md`. **Market** - **OpenCloud (read in its code):** access ends at the expiry date, but the member is only removed and notified the next time someone opens the space. There is no reminder and the manager is never told. - **Box** comes closest: an admin switch auto-removes collaborators (applied to external people by default), and owners get mail 7 days before and can extend. - **GitLab** mails the member 7 days before, but lets maintainers extend their own access, which is a pitfall to avoid. - **SharePoint** shows a banner 2 to 3 weeks ahead and mails site admins weekly; its sharing links survive expiry. - **No member expiry:** Nextcloud, ownCloud 10, Dropbox and Google Drive only time-limit shares and links. Keycloak has no built-in expiry for group membership. **Standards:** NIS2 Implementing Regulation Annex 11 requires third-party access limited in duration, and NIST AC-2(2)/(3). BSI ORP.4 is marked unverified. **Cairn today** - A space member has only a user and a role; every access check (devices, WebDAV, Office) reads that from memory. - Share "Until" is checked silently when used: no audit, no bell, no reminder. - Member removal (#1035) needs a signed-in web request, so an automatic expiry cannot reuse it as is. It also leaves the member's locks in place. - Several instances: #1011 is still open (membership is cached in memory per instance), and persisted bells can be lost between instances. **Recommended design** - **End date:** an optional end date per member, enforced in the one shared access check, so access ends at that instant everywhere without depending on a background job. - **Who sets it:** only the owner or an admin, using the same presets as share "Until", stored as the end of the chosen day. Members cannot change their own date. - **Reminder:** a bell 7 days before, to both owner and member. - **At expiry:** one instance (the one already running the periodic group checks) removes the member once. - The member goes into a "Recently ended" list for 30 days, with "Add again". - The removal is audited as `space-member-expired`. - Shares the member made stay (the #1035 rule) and their locks are released. - Bells are computed from the space record, so two instances never send duplicates. - **Restore:** restoring a deleted space never brings back members whose date has passed. - **Directory spaces:** not applicable; the directory decides. - 11 mockup frames. **Open questions, with my recommendations** 1. Reminder: 7 days, to owner and member, no second reminder in v1. 2. A member's shares cannot end after their membership; existing shares stay at expiry. 3. "Recently ended" list kept 30 days: yes. 4. The member's reminder cannot be muted; the owner's can. 5. Date only, not a time. 6. App-group-linked spaces: allow an end date, with a note in the dialog. 7. An admin maximum or required end date: later, as its own issue. 8. Release locks on expiry and on manual removal: yes. 9. A Cairn-side override for directory spaces: no. 10. Email reminders: not in v1 (#896 mail could be added later). 11. Rollback makes temporary members permanent: say so in the upgrade notes and offer a CSV export first.
Author
Owner

Decision (Nikola, 2026-10-30): all 11 recommendations from the research comment are approved. Next step: a whole-page mockup.

**Decision (Nikola, 2026-10-30):** all 11 recommendations from the research comment are approved. Next step: a whole-page mockup.
Author
Owner

Mockup approved (Nikola, 2026-10-30): 1039-member-until-mockup.html, with all its strings and open-point recommendations.

  • Nobody can change their own end date, admins included (403 member-until-self).
  • Setting a date shortens no existing shares; the dialog shows how many will outlast it.
  • On app-group-linked spaces, a sync role change keeps the date. After the end, a re-add by the sync comes back without a date and is audited as sync.
**Mockup approved (Nikola, 2026-10-30):** `1039-member-until-mockup.html`, with all its strings and open-point recommendations. - Nobody can change their own end date, admins included (403 `member-until-self`). - Setting a date shortens no existing shares; the dialog shows how many will outlast it. - On app-group-linked spaces, a sync role change keeps the date. After the end, a re-add by the sync comes back without a date and is audited as `sync`.
Cordy closed this issue 2026-10-31 10:44:38 +00:00
Author
Owner

Shipped in v0.6.379 (PR #1061), live on both dogfoods (pods ready, no restarts, no new WARN lines).

  • Until per member in Members (30 days, 90 days, 1 year, a chosen date, Never): access ends after the end of that day; choosing today asks first.
  • A per-minute pass on the group-pass lease holder removes the row, keeps the person's shares (counted and reported), releases their locks, and lists them under Recently ended for 30 days with Add again.
  • Reminders: owner and member bell items 7 days before and at the end (mute key "Memberships ending in my spaces"); the member sees the date on the space and in the Spaces list.
  • Shares and links by a temporary member are capped at their end date (share-expiry-membership); raising a share past it is refused.
  • Members CSV, admin Spaces counts and panel, audit space-member-until, space-member-expired, space-member-export; restore drops expired members; directory (power-mode) spaces show no Until.
  • Works with #1033 and #929: approving a request re-adds a member past their end date without a date.
  • Docs: CHANGELOG v0.6.379, spaces.md, sharing.md, account.md, admin-policy.md, security-standards.md, compliance-support.md, data protection and export pages, ARCHITECTURE.md.
Shipped in **v0.6.379** (PR #1061), live on both dogfoods (pods ready, no restarts, no new WARN lines). - **Until** per member in Members (30 days, 90 days, 1 year, a chosen date, Never): access ends after the end of that day; choosing today asks first. - A per-minute pass on the group-pass lease holder removes the row, keeps the person's shares (counted and reported), releases their locks, and lists them under **Recently ended** for 30 days with **Add again**. - Reminders: owner and member bell items 7 days before and at the end (mute key "Memberships ending in my spaces"); the member sees the date on the space and in the Spaces list. - Shares and links by a temporary member are capped at their end date (`share-expiry-membership`); raising a share past it is refused. - Members CSV, admin Spaces counts and panel, audit `space-member-until`, `space-member-expired`, `space-member-export`; restore drops expired members; directory (power-mode) spaces show no Until. - Works with #1033 and #929: approving a request re-adds a member past their end date without a date. - Docs: CHANGELOG v0.6.379, spaces.md, sharing.md, account.md, admin-policy.md, security-standards.md, compliance-support.md, data protection and export pages, ARCHITECTURE.md.
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#1039
No description provided.