Skip to content

feat(auth): walled deployment's declared owner is email-verified at operator-provisioned creation (extends #11343 to production walled boots) #12751

Description

@os-zhuang

Part of objectstack-ai/cloud#1653 (via cloud#1677 — the walled-EE owner-verification half; the maintainer's ruling is recorded there, 2026-08-28).

Deliverable

On a walled deployment (audience invite_only/walled posture family), when the account whose email equals the declared platform owner (OS_PLATFORM_OWNER_EMAIL) is created through the OPERATOR's own bootstrap/provisioning path, stamp it email-verified at creation — the same trust shape as os#11343's dev-boot seeded-admin stamp (that precedent's own comment already argues the class: "provisioned by the deployment's own boot command with operator-known credentials — not an unknown self-registrant"). Today that stamp is NODE_ENV-gated to dev, so a production walled EE deployment whose .env.example ships no mail transport has an owner that can NEVER verify → NEVER elevate (WALLED_OWNER_NO_VERIFICATION_PATH warns and nothing else can happen).

Bounds (the contract, not suggestions):

  • ONLY the account matching the declared owner email, ONLY when created via the operator bootstrap/seed path — never self-registration, never other users, never a later email change (an email UPDATE to the owner address must not inherit the stamp).
  • Walled posture context; dev-boot behaviour (os#11343) unchanged.
  • The WALLED_OWNER_NO_VERIFICATION_PATH warning should stop firing for the case this closes and keep firing for genuinely dead-ended shapes (owner exists, unverified, created outside the operator path, no transport).
  • Consumer: apps/objectos-ee's signup-membership-policy e2e in the cloud repo has 2 red cases asserting exactly this dead end (diagnosis on cloud#1677); they must go green on a rig running your branch WITHOUT fixture changes to those cases.

Verify premises against origin/main first (locate the #11343 stamp, the bootstrap path, the warning's predicate); premise_still_valid:false + evidence is a first-class deliverable. Tests: the stamp matrix (owner-via-operator ⇒ verified; owner-via-self-serve ⇒ not; non-owner-via-operator ⇒ not; email-change ⇒ no inheritance; dev boot unchanged), plus the warning's two-sided behaviour. Ablation, mutation proven on disk. .changeset (never major).

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions