Skip to main content

Changelog

All notable changes to the Archenstack specification are recorded here.

This project versions two things independently:

  • Spec version (this document, semver MAJOR.MINOR.PATCH) — the prose contract and conformance corpus.
  • Wire version (integer, on every payload) — the serialized format and, per specification §2, the resolution semantics. Any change to resolution semantics is breaking and MUST bump the wire version.

The format follows the spirit of Keep a Changelog.

[0.6.0] — 2026-11-17 — terminology + app registration — wire_version 1 (unchanged)​

No serialized shape, resolution rule or access-level ordering moves, so wire_version stays 1 and the entire conformance corpus is unchanged.

Changed — NORMATIVE​

  • §15.3 — app registration is PLATFORM-OR-ADMIN, not delegated. The previous text said an org's own admin registers that org's apps "not the platform tier", which every adapter contradicts: Java and Django both accept either tier, deliberately. The provisioning case requires it — an org's first app is registered before any org admin exists to register it. The spec now permits what the implementations do; an adapter that accepts only the org admin is still conformant.

Added — NORMATIVE​

  • principal_kind on a member row, "human" (the default) or "service_account". Every implementation already emitted it; the wire block in §15.3 did not acknowledge it, so six ports were shipping a field the normative shape omitted. It is a display and filtering hint and never an input to resolve — authorization is identical for both kinds — and a reader that does not recognize it MUST ignore it. Additive and optional, so no existing reader changes. There is no members JSON Schema, so nothing in schema/ needed updating.

Changed — EDITORIAL​

  • An adapter exposing the check endpoint MUST also expose a scope authorizer — previously "scope guard". The requirement is unchanged; only the term is.
  • guard_feature is now manage_feature throughout §12. It is a concept name, not a wire field: it appears in no schema and no vector, so nothing in the corpus depends on it. The libraries' constants moved with it (MANAGE_FEATURE, manageHolders).
  • The implementation list in the header names all of them rather than two.

[0.5.0] — 2026-07-21 — the tenant tree (additive) — wire_version 1 (unchanged)​

Makes a bounded platform grant able to express the case it exists for: "this parent company governs its subsidiaries, including the ones it opens next quarter."

Added — NORMATIVE​

  • §15.3 — the bound is a SUBTREE, not a list. Organizations MAY form a tree via an OPTIONAL parent, and a bounded grant reaches every org it names plus every descendant, transitively.

    A grant expressed as an enumeration of slugs can authorize operations on orgs that already exist but can never authorize creating one — the new slug is in no grant until after it exists, and a self-service provisioner derives slugs nobody can enumerate in advance. Provisioning is the operation platform authority exists for, so a flat bound was absent from precisely the place it mattered.

  • A create is authorized against the target's parent when one is named; with no parent the target is the new slug itself, so a bounded principal cannot mint arbitrary root tenants.

  • Governance flows downward only — a grant over a child confers nothing over its parent or siblings. An unknown org is out-of-bound unless named outright. The ancestry walk MUST terminate on a cycle.

  • The identity provider names governed roots; the adapter expands them. A claim carrying the bound MUST NOT be derived from the subject's membership: a membership-derived claim cannot name a tenant that does not exist yet, and forcing an operator into each tenant to bound them grants administration inside tenants they govern only from outside. security model §2.7 records the threat.

Changed​

  • The org entity gains an OPTIONAL parent (a slug, or null for a root tenant).

This is additive (§2.3). The tree bounds control-plane authority only: a child inherits no matrix, roles, assignments or overrides from its parent, resolve never sees parent, the canonical snapshot body is untouched, and every vector and wire-golden is unchanged. An adapter with no control plane has nothing to bound and needs no tree, which is why the single-org Node, Go and Rust adapters do not implement one.

[0.4.0] — 2026-07-21 — advisory vs enforcement (additive) — wire_version 1 (unchanged)​

Closes the gap between what the check endpoint answers and what a host may authorize on, and catches the spec up with three library releases it never recorded.

Added — NORMATIVE​

  • §8.6 — Where the object comes from. POST /permissions/check/ takes its object from the request body, so the caller chooses the attributes the scope predicate reads and can describe an object it does not own. The response is therefore advisory: an implementation MUST NOT present it as an enforcement mechanism, and a host MUST NOT authorize a mutation or a data load on it.
  • Enforcement MUST re-evaluate the same scope against a server-loaded object, and any adapter exposing the check endpoint MUST also expose a scope authorizer — (caller, feature, host_loaded_object) → allow/deny — resolving through the same resolve (§7) and eval_scope (§8.2) with the same registered atoms (§8.4). The only difference between the two paths is the provenance of the object.
  • security model §2.6 records the corresponding threat. It is deliberately separate from §2.5 (a mis-wired predicate): here every component behaves exactly as specified and the result is still a bypass, so predicate-correctness testing cannot detect it.
  • §15.1 now states inline that object is caller-supplied in the single form and every batch item alike.

This is additive (§2.3): no envelope, schema, vector or wire-golden changes, and a wire_version: 1 resolver reaches identical decisions. It constrains how an implementation may describe and supplement an existing endpoint, not how any payload resolves.

Conformance note — args reaches the predicate​

§8.4 has always specified that an atom maps its name and OPTIONAL args to a boolean. Four implementations honour it; the Java adapter's AtomPredicate dropped args before the atom saw it, so an atom such as {"atom": "in_region", "args": {"region": "emea"}} was implementable everywhere except Java. Fixed in the Java adapter without breaking existing atoms. The shared corpus does not cover this, because host atoms are by definition outside it.

Library releases recorded​

The spec sat at 0.3.0 through three library releases. versioning §4 maps one library line per spec version, so those lines had no row:

Library lineWhat it wasWire
0.4.0Security fix: an explicitly empty platform bound granted every tenant instead of none. A cross-language conformance rule, hence released in lockstep.1
1.0.0Archenstack owns roles. The persistent multi-tenant adapters take identity only; the role comes from the (org, sub) assignment store.1
2.0.0Audit attribution: a write records its actor even when the caller is token-authenticated. Breaking in the Spring starter's MatrixStore.1

None changed resolution semantics, the canonical body, or any schema, so wire_version stayed 1 throughout and the conformance corpus is unchanged.

archenstack-rbac-go is a documented exception to the one-line rule. Go's semantic import versioning makes a major bump a module path change, so the Go module stays on the v1 line rather than force an import rewrite for releases in which nothing broke. It runs the same corpus and speaks the same wire_version, which is what actually governs interoperability. See versioning §4.

[0.3.0] — 2026-07-20 — control plane (additive) — wire_version 1 (unchanged)​

Adds the control plane — org/app lifecycle, a platform capability above per-org rbac.manage, an app defined as a registered OIDC client bound to one org, and the member registry as the subject source of truth — as a fully additive change. None of it touches resolve, Cell = (feature, role), the canonical matrix body, or the anti-lockout kernel; it is persistence + identity state exactly like assignments. So wire_version stays 1 and the entire existing conformance corpus (all vectors/*.json and every wire-golden/*.json fixture) is untouched. This is a spec MINOR (0.3.0); a v1 reader that ignores the new optional field / kinds resolves identically (specification §2.3, §15.3).

Added​

  • Control plane (specification §15.3 "Control plane"). Defines the org & app lifecycle (an org is the authorization tenant; an app is a registered OIDC client bound to exactly one org, never a second tenancy dimension or a per-app matrix; per-product isolation is modeled as multiple orgs), the idempotent born-inactive → seed → bind-first-admin → activate provisioning posture (an org is never both active and lockout-unsafe), the platform capability (a cross-org authority above per-org rbac.manage, orthogonal to any matrix and never a resolver input, asserted as a token scope/claim with a ARCHENSTACK_RBAC_PLATFORM_SUBJECTS env platform-subject and no code fallback; app registration is delegated to each org's own admin), and the member registry as the sole subject-picker source (JIT-on-first-login + invite-by-email + optional SCIM reconcile; no free-text subject entry).
  • Optionally BOUNDED platform grants (specification §15.3 "Platform capability"). A platform grant may be bounded to an explicit set of org slugs — the shape a parent organization needs to govern exactly its own subsidiaries and no other tenant. An adapter that supports bounding MUST check the operation's target org on every control-plane route and MUST treat an empty bound as no authority. An unbounded grant (the default when a host asserts no bound) keeps today's full reach, including provisioning orgs that do not yet exist; a bounded grant may provision only the slugs it names. The env platform-subject stays unbounded so the first operator can create the first org. Bounding only ever NARROWS authority, so a host that asserts no bound is unaffected. No wire change — the bound is adapter/identity state, never a payload field.
  • New list-envelope kinds members / apps (specification §15, §15.3). Org-scoped, collection envelopes requiring rbac.manage FULL mirroring the shipped orgs / assignments list envelopes: members carries results: [{subject, email, display, status}]; apps carries results: [{client_id, audience, label, redirect_uris, is_active}]. Additive (a client that never requests them never receives the new kind, §2.3); no dedicated list schema, same as orgs/assignments. Cross-org isolation: one org's members/apps are never visible to another.
  • Optional is_platform_admin envelope field on me (schema/me.schema.json). A boolean surfacing the cross-org platform capability so a UI can reveal control-plane affordances; not in any required[], omitted ⇒ non-platform. matrix.schema.json required[] is unchanged and no existing wire-golden fixture is touched (the org-less/platform-less me_envelope stays byte-identical).

Changed​

  • versioning — added a 0.3.0 compatibility-matrix row (wire 1 ⇄ 0.3.x libs) and a note explaining the additive-optional control-plane change.

[0.2.0] — 2026-07-18 — multi-org tenancy (additive) — wire_version 1 (unchanged)​

Adds multi-org tenancy as a fully additive change. org is an out-of-band snapshot-selection dimension: it selects which org's MatrixSnapshot a caller resolves and is never part of the canonical matrix body or an argument to resolve. The resolution kernel, Cell = (feature, role), and canonical JSON are byte-for-byte unchanged, so wire_version stays 1 and the entire existing conformance corpus (all vectors/*.json and every wire-golden/*.json fixture) is untouched — the pre-existing fixtures are declared to belong to an implicit root org. This is a spec MINOR (0.2.0); a v1 reader that ignores the new optional field resolves identically (specification §2.3).

Added​

  • Organizations (specification §15.2 "Organizations"). Defines an organization as an out-of-band persistence/routing/transport dimension that selects one org's snapshot before resolve runs; org is never in the canonical body nor a resolver input, so isolation is a property of snapshot-per-org. Records where org lives on the wire (optional envelope field + transport header/claim, never a path prefix) and the fail-closed posture (missing org denies; unknown org → unknown_org; root is backfill/dev-only, never a runtime default).
  • Optional org envelope field on me / policy / policy-batch (schema/me.schema.json, schema/policy.schema.json, schema/policy-batch.schema.json). A string org slug (same grammar as a role/group slug, §14.1), not in any required[]; omitted ⇒ root org. matrix.schema.json required[] is unchanged — the canonical snapshot body carries no org key.
  • unknown_org ErrorCode (specification §16; schema/error.schema.json). Fail closed for an org that does not exist, or a cross-org reference that bridges two orgs. Additive (an unrecognized code degrades to a generic failure, §2.3).
  • New org-bearing wire-golden fixtures (wire-golden/envelopes.json): me_envelope_org and policy_envelope_org carry the optional org field, proving it round-trips through canonical JSON, added alongside the existing org-less me_envelope/policy_envelope (which stay byte-identical).

Changed​

  • Anti-lockout is PER ORG (specification §12.3). check_no_lockout runs on exactly one org's snapshot and applies only to that org's mutations; every org must independently retain an active non-super rbac.manage-FULL holder. SECURITY's "≥1 active super per deployment" reads as "≥1 active super per org."
  • Slug/feature-key uniqueness is PER ORG (specification §14.3). The slug/key grammar is unchanged (org is never a key prefix); uniqueness is scoped per organization, so two orgs may each own a manager role or reports.export feature. Cross-org refs are rejected at the adapter/validator layer.
  • resolve documented as org-invariant (specification §7.2). Its signature and semantics are unchanged; org only selects the snapshot M passed to it.
  • versioning — added a 0.2.0 compatibility-matrix row (wire 1 ⇄ 0.2.x libs) and a note explaining the additive-optional tenancy change.
  • vectors/README.md — noted that org is a snapshot-selection dimension and that isolation is verified at the adapter layer, not inside vector bodies.

[0.1.1] — 2026-07-12 — review hardening — wire_version 1 (unchanged)​

Adversarial-review hardening: clarifications and added conformance coverage only. No resolution-semantics or wire change — wire_version stays 1.

Changed​

  • ErrorCode mapping made explicit (specification §7.3.1, §16). Added a normative alias/super/override → ErrorCode table so a spec-faithful validator returns the same code the vectors assert: a dangling alias_target is unknown_role; a non-standard alias target, a super carrying an alias_target, an alias with a null/missing target, and an override on a super/alias role are all validation.
  • resolve ignores is_active (specification §7.2). Stated normatively that a deactivated role still resolves to its effective grid level; is_active affects only the lock-out invariant (§12) and role assignment.
  • immutable_field vs validation disambiguated (specification §4.4, §16). A static snapshot override referencing a super/alias role is validation; immutable_field is reserved for mutations that deactivate or alias-convert a system/super role.
  • U+007F (DEL) canonicalization (specification §13 rule 6). Made explicit that DEL and every code point >= U+0020 are emitted as raw UTF-8; only the C0 controls U+0000-U+001F are escaped.
  • Non-null Feature.cell_scope rejection (specification §5.4). A stored snapshot whose reserved cell_scope is non-null is rejected by validate as validation.

Added​

  • Batch check (policy-batch) (specification §15.1, §2.3, §15; schema/policy-batch.schema.json). POST /permissions/check/ additionally accepts a { checks: [{ feature, object? }, …] } batch and returns a policy-batch envelope with a positional results[] (results[i] ↔ checks[i]) plus each distinct feature's resolved cell once — so a client resolves a whole PARTIAL-scoped list in one round-trip instead of N. Fully additive (a client that never sends a batch never sees the new kind); per-item fail-closed on an unknown feature, whole-request validation on a malformed item, and a config-bounded batch size (default 200). No wire change.
  • versioning — the two-clock versioning policy written up: libraries use semver, the wire carries an integer wire_version, resolution semantics are pinned to the wire major (client-side resolution means old clients must be rejected, not best-effort parsed), plus a wire-version ⇄ library compatibility matrix (wire 1 ⇄ current 0.1.x libs). Cross-linked from every repo README.
  • security model — the threat model: the lock-out escape hatch and its "at least one active super user" assumption, fail-closed scope evaluation, the caller-must-have-a-role contract, canonical-JSON determinism, and that atom predicates are app-supplied (their correctness is the adapter's responsibility), plus a placeholder responsible-disclosure section.
  • Closed entity schemas. additionalProperties: false on the Role, Feature, Group, and Override object $defs (schema/*.json), making the reserved cell_scope-must-be-null discipline enforceable; the enveloped payload objects keep their forward-compat policy.
  • Negative validate vectors (vectors/validate-errors.json): one case per previously-uncovered ErrorCode — invalid_slug (bad role slug + bad dotted feature key), duplicate_key, unknown_feature, unknown_role, validation (override on super role, override on alias role, non-null cell_scope), unknown_scope — plus a valid baseline.
  • Resolution vectors (vectors/resolution.json): override_zero_beats_nonzero_default (an override of 0 beats a non-zero default/fallback — the ?? vs || check) and alias_inherits_target_override (an alias inherits its target's override, not just its default).
  • Canonical goldens (wire-golden/envelopes.json): error, me, policy, overrides, role, feature, and group envelopes; plus del_u007f_raw in wire-golden/string-escaping.json asserting U+007F is emitted raw.

[0.1.0] — 2026-07-04 — wire_version 1​

Initial normative specification and conformance-corpus contract.

Added​

  • AccessLevel — frozen, closed, ordered enum NONE=0 < VIEW=1 < PARTIAL=2 < FULL=3; integers on the wire (specification §3).
  • Matrix snapshot shape — roles, groups, features (with seed-owned defaults), overrides, aliases, superusers, and default_partial_scope (specification §4–§5).
  • Versioning contract — client-side resolution is allowed; resolution semantics are pinned to the wire MAJOR version, so any semantic change is breaking (specification §2).
  • Resolution algorithm — exact ordered precedence super → alias → override → default → fallback, with the super check on the original role before alias resolution, and the invariant that a super role is never an alias source or target (specification §7).
  • ScopeExpr grammar — {const} | {atom, args?} | {any_of[]} | {all_of[]}, snake_case, with a reserved-but-ignorable args object on atom and no not in v1; eval_scope pure tree-walk with edge identities (empty any_of = false, empty all_of = true) and fail-closed on unknown/malformed nodes (specification §8).
  • Write-scope binding — scope constrains writes only; reads are authorized at the feature level only and object/list read filtering is out of core (specification §8.5, §9).
  • Override delta semantics — overrides stored as a delta from default; setting a cell to its current default clears the override; reseeding defaults intentionally moves un-overridden cells (specification §10–§11).
  • Lock-out invariant — check_no_lockout requires at least one active, non-super role at FULL on the management feature rbac.manage, enforced across overrides, deactivation, alias edits, and group deletes; super and system roles are the non-deactivatable escape hatch (specification §12).
  • minimum_write — a per-call parameter deciding PARTIAL-vs-FULL for a write; the feature-level write_hint is non-authoritative (specification §12.3).
  • Canonical JSON — UTF-8, object keys sorted by UTF-16 code unit, compact separators, integer levels, lowercase \u00XX escapes for control characters, deterministic array ordering by the producer (specification §13).
  • Error shape & ErrorCode — {kind:"error", code, detail, field?} with the closed code set unknown_role, unknown_feature, unknown_group, unknown_scope, invalid_slug, immutable_field, lockout, duplicate_key, not_found, validation (specification §16).
  • Slug rules — role/group ^[a-z][a-z0-9_-]*$ (max 64); feature keys ^[a-z][a-z0-9_]*(\.[a-z0-9_]+)*$ (max 128) (specification §14).
  • Wire envelope — every payload carries integer wire_version (starts at 1) and string kind ∈ {matrix, me, policy, role, feature, group, overrides, error} (specification §15).
  • Scale envelope — v1 targets O(10³–10⁴) cells, full-snapshot load; lazy load is a future adapter concern (specification §18).

Reserved (forward-compatible wire slots, semantics deferred)​

  • Per-cell scope (Feature.cell_scope, MUST be null in v1).
  • atom.args object (permitted on the wire; v1 evaluators MAY ignore).

Deferred / out of scope for v1 (breaking when added)​

Read scoping in core (view_scope / to_filter), not in ScopeExpr, transitive aliases, meaningful atom.args, lazy snapshot load, localized error detail. See specification §17 for dispositions and rationale.