Skip to content

ADR (mirror of cloud ADR-0024): Identity & Access Architecture — the open half that plugin-auth / platform-objects/identity implement, recorded in this repo with Provenance #14506

Description

@hotlong

Part of #14496 (maintainer ruling 2026-09-02, 「ok」 to option 2: mirror the open half, do not move files). Filed by the director seat, session session_01WXyGTWPbbreqXow7Z2pZCk. docs/adr/** is a governed surface: draft PR, human merge, no seat flips it ready. Clause-②: no (a record, not a contract change). domain:* is triage's.

What to write

A new local ADR under the next free number in docs/adr/ (133 records today; 0130 is the highest) that states, as this repo enforces them, the decisions of cloud docs/adr/0024-identity-and-access-architecture.md (Status: Accepted, founder, 2026-06-25) whose mechanism lives in open code. From the cloud record's own headings, the open half is:

  • D1 per-environment identity, never centralised (plugin-auth runs better-auth in the env);
  • D2 two user populations, two sources of truth;
  • D4 source-of-truth marking — managed vs env-native (sys_user / sys_account managedBy posture);
  • D5 identity from the IdP, authorization in the env; D5.2 the local user-management surface under SSO (split by population — the sys_user actions, break-glass password, the last-admin guard that cites "ADR-0024 D4/D5.2" today);
  • D6 SSO + SCIM per production env (the @better-auth/sso mechanism and sys_sso_provider incl. the opt-in domain verification cited as "ADR-0024 ②");
  • D7 portability / self-host preserved; D9 env users live in the env, org membership via better-auth.

Stays in cloud, cited as cloud ADR-0024: D3 cloud-as-IdP hub, D5.1 the cloud OP membership gate, D8 billing, D10 prod/dev metering and population lifecycle, the V1 roadmap and commercial framing.

Shape (copy docs/adr/0079-record-display-name.md)

  • A ## Provenance — read this before citing this file section first: this file records, in this repo, decisions taken in objectstack-ai/cloud ADR-0024 on 2026-06-25; the cloud record is the original and keeps the commercial half; this file is written from the cloud record and the code that implements it, with the implementing anchors named (packages/plugins/plugin-auth/src/**, packages/platform-objects/src/identity/sys-sso-provider.object.ts, sys-user.object.ts, last-admin-guard.ts).
  • Decisions restated in this repo's own words, each with the code anchor that enforces it; ⛔ no new decision, no widening — anything the cloud record did not decide is not decided here.
  • Register the file in docs/adr/PRIORITIZATION.md if that index is maintained by hand (check the file's own header); scripts/adr-anchors/ mapping for the files that will cite it is the re-pointing card's job ([finding] The SCIM/identity ADR-0071 citation resolves to the dataset semantic-layer record — 39 files point at a decision about multi-hop joins #14361), not this one's.

Follow-ups the accepting seat files (not this card)

Re-check

git -C ../cloud show origin/main:docs/adr/0024-identity-and-access-architecture.md | grep -n "^### D"
git grep -n -E "ADR-0024" origin/main -- packages/plugins/plugin-auth/src packages/platform-objects/src/identity | grep -v -i "cloud ADR-0024" | wc -l   # expect ~71 before #14361 lands

Refs: #14496 (the ruling) · #14361 (the re-pointing, blocked on this) · cloud ADR-0024 · ADR-0079 (the Provenance shape) · #14360 / #13816 (live identity work that cites these decisions).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions