mirror of
https://github.com/hanzoai/iam.git
synced 2026-11-19 18:37:16 +00:00
An org's admin runs members' profiles, roles and machine accounts, and no longer writes a person's password, email, phone, factors, passkeys, or the tokens and keys that speak as them: users.Credential admits the person, a SuperAdmin or an application's allowlist. Nothing an admin files for a member signs in as them once they own the org, or in another org they belong to. Onboarding writes the owner row only for the org's founder, its creator or the recorded founder resuming, never for an admin re-driving its own org, and records founders by subject id. An organization create names its founder by subject id alone and runs in one transaction. Deleting an org files a tombstone on the trail in the delete's transaction, and Leftovers refuses the name forever after. Rekey refuses a move that would take an org's last owner and keeps the higher role where the new id already holds one. A membership names a live account under its own id; a revoke is decided on the org-wide row and removes every scope. An as() token acts in the key's org alone, and a target holding an admin or owner role anywhere is refused. Role writes by onboarding, Rekey and ForgetUser are on the trail.