Founding sign-in: lower the kanidm credential floor to any — passwords commit, passkeys offered not required (ADR 0170) #485

Closed
opened 2026-08-12 18:16:55 +00:00 by ben · 1 comment
Owner

Why now

Ben ruled 2026-08-12: founding must not require a passkey. Real founders on Linux
laptops can lack any platform authenticator (the DDR 0163 ceremony window has no
synced passkey store), dead-ending S12. But kanidm 1.10's default account
policy on idm_all_persons sets credential-type-minimum = mfa, so today a bare
password refuses to commit (can_commit:false, MfaRequired) — proven twice:
docs/spike-findings/smoke-idp-178.md:78 and docs/spike-findings/mail-apppw-320.md:127.
This also contradicts the member signup contract ("passkey recommended, never
required" — internal/member/signup.go story 7), whose password fallback the IdP
currently refuses.

The ruling is the middle path, not dropping passkeys: lower the policy floor
to any so kanidm's own reset page offers both a password and a passkey;
passkeys stay offered and recommended everywhere, never required. ADR 0046's
token/reset machinery is untouched — only the credential class the ceremony must
produce widens.

Stories

1. Mint ADR 0170 (text below)

  • Land the ADR under docs/adr/0170-credential-floor-is-any-passkeys-offered-not-required.md.
  • Verify 0170 is still free against origin/main at commit time; renumber if
    taken
    (the 0145 collision lesson).
  • Update STATUS.md in the same commit (CLAUDE.md rule).

2. Policy push lands in both gateway renders

  • Add the account-policy relaxation to the runtime push machinery (same pattern
    as the kanidm-brand-push oneshot in internal/clan/vmguest.go /
    frontdoor.go):
    kanidm group account-policy credential-type-minimum idm_all_persons any
  • Identity: account-policy ops are IDM ops — authenticate as idm_admin
    (the mail-apppw-320 lab used recovered idm_admin for exactly this op), not
    domain admin (that identity is for domain ops only; kanidm masks
    unauthorized as "Item not found" — vmguest.go:432 comment).
  • Acceptance: both render tests (vmguest_test.go, frontdoor_test.go) assert
    the policy line, mirroring how the brand-push lines are asserted; the oneshot
    fails loud (non-zero) if the CLI call fails, consistent with brand-push.

3. AwaitPasskey generalises to AwaitCredential

  • internal/founding/handoff.go + internal/fleetwire/enrolment.go: the S12
    advance gate becomes "any committed credential", i.e. passkey or password.
  • Detection: keep the proven passkeys-attribute read
    (internal/kanidm/kanidm.go:283 HasPasskey) OR a committed primary
    credential via GET /v1/person/<id>/_credential/_status. Note: that endpoint
    answered {"creds":[]} on 1.10 for passkeys; a password primary credential
    may well appear there — but this is unverified live. Implement the OR so
    the passkey path cannot regress either way.
  • Keep DDR 0138 semantics exactly: wait visibly, cancel cleanly, re-mint on
    token expiry; never fabricate advance (ADR 0100 — the e2e sink still times
    out to the token-expired sentinel).
  • Rename the contract marker data-status="passkey-enrolled" →
    "credential-enrolled" consistently across
    app/src/components/founding/FoundingHandOff.vue,
    app/tests/e2e/fixtures/foundingPrefix.ts, and the wireframe frame (story 4).
  • Unit coverage via the existing fake-IDP port tests (enrolment_test.go).

4. S12 copy + wireframe stay in contract

  • FoundingHandOff.vue copy: "A sign-in window opened — create your passkey
    there" → neutral sign-in wording, passkey-first, e.g. "A sign-in window
    opened — create your sign-in there: a passkey if your device supports one, or
    a password."
  • docs/ux/wireframes/p1-founding/p1-s12-hand-off.html updated in the same
    commit (the wireframe is the UI contract).

5. Member password fallback is real now

  • No contract change: signup.go story 7 already offers the fallback. With the
    policy floor at any, a member following the branded reset link can commit a
    lone password. Add/extend a test asserting the contract still records
    PasskeyOffered=true, PasskeyRequired=false, and note in the ADR that the
    IdP and the contract now agree.

6. e2e stays green

  • The CDP passkey ceremony (app/tests/e2e/fixtures/ceremony.ts) remains the
    primary founding spec — do not remove the virtual-authenticator machinery
    (Nextcloud OIDC spec reuses it, page-scoped).
  • Adjust the data-status assertion per story 3.
  • A password-path founding variant spec is a welcome addition but not
    gating
    for this ticket.

Live-proof gate (drive residue — stays open until proven)

Final acceptance is the next founding drive: complete the ceremony with a
password only and watch AwaitCredential advance S12. If
_credential/_status still answers empty on kanidmd 1.10.3 for a committed
password, the wait will time out visibly (correct DDR 0138 behaviour) — file
a follow-up with the drive log rather than working around it. Eyeball the
screenshots (drive-15 FALSE-green lesson).

Out of scope

  • Dropping passkeys entirely (explicitly rejected — this is the middle path).
  • Hiding/reordering the reset page's credential sections via
    brandkit/idp_override.go CSS.
  • TOTP flows; per-community configurable policy floors (see ADR revisit
    criterion).
  • Nextcloud OIDC spec changes beyond the data-status rename.

Proposed ADR 0170 text

# 0170 — The credential floor is `any`: passwords commit, passkeys offered not required

Status: accepted
Date: 2026-08-12
Amends: 0046 (operator first-login: token + two credentials). Relates: 0077, DDR 0138, DDR 0163.

## Context

Kanidm 1.10's default account policy on `idm_all_persons` sets
`credential-type-minimum = mfa`: a bare password refuses to commit
(`can_commit:false, MfaRequired` — spike findings smoke-idp-178, mail-apppw-320).
Founding therefore effectively required a passkey, and the member signup
contract ("passkey recommended, never required", story 7) promised a password
fallback the IdP refused. Real founders on Linux laptops can lack any platform
authenticator, dead-ending the DDR 0163 ceremony window.

## Decision

- Seeding lowers `credential-type-minimum` on `idm_all_persons` to `any` via a
  runtime push (the kanidm-brand-push pattern, authenticated as `idm_admin`).
- Kanidm's reset page then offers both credential classes. Passkeys stay
  offered and recommended on every surface; they are never required.
- The founding hand-off gate generalises: `AwaitPasskey` → `AwaitCredential` —
  any committed credential advances S12.
- ADR 0046's single-use reset-token machinery is unchanged.

## Consequences

- The member password fallback actually works; contract and IdP agree.
- Credential loss stays operator-mediated (`MintReset`) — unchanged.
- A weaker floor than `mfa` is accepted deliberately for v1 founding UX.
  Revisit criterion: a community that wants a stricter floor gets a per-group
  policy raise — a knob, not a rework.

References

  • ADR 0046 (reset-token hand-off), ADR 0077 (member auth), DDR 0138 (visible
    wait + re-mint), DDR 0163 (CA-pinned ceremony window), ADR 0100 (never
    fabricate), ADR 0122 (wireframe = contract).
  • docs/spike-findings/smoke-idp-178.md, docs/spike-findings/mail-apppw-320.md.
  • Kanidm docs: Account Policy,
    Customising.
## Why now Ben ruled 2026-08-12: founding must not *require* a passkey. Real founders on Linux laptops can lack any platform authenticator (the DDR 0163 ceremony window has no synced passkey store), dead-ending S12. But kanidm 1.10's **default** account policy on `idm_all_persons` sets `credential-type-minimum = mfa`, so today a bare password refuses to commit (`can_commit:false, MfaRequired`) — proven twice: `docs/spike-findings/smoke-idp-178.md:78` and `docs/spike-findings/mail-apppw-320.md:127`. This also contradicts the member signup contract ("passkey recommended, never required" — `internal/member/signup.go` story 7), whose password fallback the IdP currently refuses. The ruling is the middle path, **not** dropping passkeys: lower the policy floor to `any` so kanidm's own reset page offers *both* a password and a passkey; passkeys stay offered and recommended everywhere, never required. ADR 0046's token/reset machinery is untouched — only the credential class the ceremony must produce widens. ## Stories ### 1. Mint ADR 0170 (text below) - Land the ADR under `docs/adr/0170-credential-floor-is-any-passkeys-offered-not-required.md`. - **Verify 0170 is still free against `origin/main` at commit time; renumber if taken** (the 0145 collision lesson). - Update `STATUS.md` in the same commit (CLAUDE.md rule). ### 2. Policy push lands in both gateway renders - Add the account-policy relaxation to the runtime push machinery (same pattern as the `kanidm-brand-push` oneshot in `internal/clan/vmguest.go` / `frontdoor.go`): `kanidm group account-policy credential-type-minimum idm_all_persons any` - **Identity:** account-policy ops are IDM ops — authenticate as **`idm_admin`** (the mail-apppw-320 lab used recovered `idm_admin` for exactly this op), *not* domain `admin` (that identity is for domain ops only; kanidm masks unauthorized as "Item not found" — `vmguest.go:432` comment). - Acceptance: both render tests (`vmguest_test.go`, `frontdoor_test.go`) assert the policy line, mirroring how the brand-push lines are asserted; the oneshot fails loud (non-zero) if the CLI call fails, consistent with brand-push. ### 3. `AwaitPasskey` generalises to `AwaitCredential` - `internal/founding/handoff.go` + `internal/fleetwire/enrolment.go`: the S12 advance gate becomes "any committed credential", i.e. passkey **or** password. - Detection: keep the proven `passkeys`-attribute read (`internal/kanidm/kanidm.go:283` `HasPasskey`) **OR** a committed primary credential via `GET /v1/person/<id>/_credential/_status`. Note: that endpoint answered `{"creds":[]}` on 1.10 *for passkeys*; a password primary credential may well appear there — but this is **unverified live**. Implement the OR so the passkey path cannot regress either way. - Keep DDR 0138 semantics exactly: wait visibly, cancel cleanly, re-mint on token expiry; never fabricate advance (ADR 0100 — the e2e sink still times out to the token-expired sentinel). - Rename the contract marker `data-status="passkey-enrolled"` → `"credential-enrolled"` consistently across `app/src/components/founding/FoundingHandOff.vue`, `app/tests/e2e/fixtures/foundingPrefix.ts`, and the wireframe frame (story 4). - Unit coverage via the existing fake-IDP port tests (`enrolment_test.go`). ### 4. S12 copy + wireframe stay in contract - `FoundingHandOff.vue` copy: "A sign-in window opened — create your passkey there" → neutral sign-in wording, passkey-first, e.g. "A sign-in window opened — create your sign-in there: a passkey if your device supports one, or a password." - `docs/ux/wireframes/p1-founding/p1-s12-hand-off.html` updated in the same commit (the wireframe is the UI contract). ### 5. Member password fallback is real now - No contract change: `signup.go` story 7 already offers the fallback. With the policy floor at `any`, a member following the branded reset link can commit a lone password. Add/extend a test asserting the contract still records `PasskeyOffered=true, PasskeyRequired=false`, and note in the ADR that the IdP and the contract now agree. ### 6. e2e stays green - The CDP passkey ceremony (`app/tests/e2e/fixtures/ceremony.ts`) remains the primary founding spec — do not remove the virtual-authenticator machinery (Nextcloud OIDC spec reuses it, page-scoped). - Adjust the `data-status` assertion per story 3. - A password-path founding variant spec is a welcome addition but **not gating** for this ticket. ## Live-proof gate (drive residue — stays open until proven) Final acceptance is the next founding drive: complete the ceremony with a **password only** and watch `AwaitCredential` advance S12. If `_credential/_status` still answers empty on kanidmd 1.10.3 for a committed password, the wait will time out *visibly* (correct DDR 0138 behaviour) — file a follow-up with the drive log rather than working around it. Eyeball the screenshots (drive-15 FALSE-green lesson). ## Out of scope - Dropping passkeys entirely (explicitly rejected — this is the middle path). - Hiding/reordering the reset page's credential sections via `brandkit/idp_override.go` CSS. - TOTP flows; per-community configurable policy floors (see ADR revisit criterion). - Nextcloud OIDC spec changes beyond the `data-status` rename. ## Proposed ADR 0170 text ```markdown # 0170 — The credential floor is `any`: passwords commit, passkeys offered not required Status: accepted Date: 2026-08-12 Amends: 0046 (operator first-login: token + two credentials). Relates: 0077, DDR 0138, DDR 0163. ## Context Kanidm 1.10's default account policy on `idm_all_persons` sets `credential-type-minimum = mfa`: a bare password refuses to commit (`can_commit:false, MfaRequired` — spike findings smoke-idp-178, mail-apppw-320). Founding therefore effectively required a passkey, and the member signup contract ("passkey recommended, never required", story 7) promised a password fallback the IdP refused. Real founders on Linux laptops can lack any platform authenticator, dead-ending the DDR 0163 ceremony window. ## Decision - Seeding lowers `credential-type-minimum` on `idm_all_persons` to `any` via a runtime push (the kanidm-brand-push pattern, authenticated as `idm_admin`). - Kanidm's reset page then offers both credential classes. Passkeys stay offered and recommended on every surface; they are never required. - The founding hand-off gate generalises: `AwaitPasskey` → `AwaitCredential` — any committed credential advances S12. - ADR 0046's single-use reset-token machinery is unchanged. ## Consequences - The member password fallback actually works; contract and IdP agree. - Credential loss stays operator-mediated (`MintReset`) — unchanged. - A weaker floor than `mfa` is accepted deliberately for v1 founding UX. Revisit criterion: a community that wants a stricter floor gets a per-group policy raise — a knob, not a rework. ``` ## References - ADR 0046 (reset-token hand-off), ADR 0077 (member auth), DDR 0138 (visible wait + re-mint), DDR 0163 (CA-pinned ceremony window), ADR 0100 (never fabricate), ADR 0122 (wireframe = contract). - `docs/spike-findings/smoke-idp-178.md`, `docs/spike-findings/mail-apppw-320.md`. - Kanidm docs: [Account Policy](https://kanidm.github.io/kanidm/stable/accounts/account_policy.html), [Customising](https://kanidm.github.io/kanidm/stable/customising.html).
Author
Owner

close-report for #485 — status success

✅ close-report gates passed — every claim verified against main; closing.

envelope
{
  "issue": 485,
  "status": "success",
  "commits": [
    "a54545eaf4cd5f7c232454f83a4ac703ed264b51"
  ],
  "changed_files": [
    "STATUS.md",
    "app/src/components/founding/FoundingHandOff.vue",
    "app/tests/e2e/fixtures/foundingPrefix.ts",
    "app/tests/e2e/journey.droplet.spec.ts",
    "app/tests/e2e/private-path-tail.resume.spec.ts",
    "app/tests/unit/foundingHandOff.test.ts",
    "docs/adr/0170-credential-floor-is-any-passkeys-offered-not-required.md",
    "docs/ux/wireframes/p1-founding/p1-s12-hand-off.html",
    "internal/clan/frontdoor.go",
    "internal/clan/frontdoor_test.go",
    "internal/clan/vmguest.go",
    "internal/clan/vmguest_test.go",
    "internal/fleetwire/enrolment.go",
    "internal/fleetwire/enrolment_test.go",
    "internal/founding/handoff.go",
    "internal/founding/testing/fakes.go",
    "internal/kanidm/kanidm.go",
    "internal/kanidm/kanidm_test.go",
    "internal/member/signup_test.go"
  ],
  "tests": [
    {
      "command": "go test ./internal/clan/ ./internal/kanidm/ ./internal/fleetwire/ ./internal/founding/... ./internal/member/",
      "exit_code": 0
    },
    {
      "command": "go test ./... (full Go suite)",
      "exit_code": 0
    },
    {
      "command": "cd app && node_modules/.bin/vitest run (858 passed, boot.test needs go on PATH)",
      "exit_code": 0
    },
    {
      "command": "cd app && vue-tsc -p tsconfig.json",
      "exit_code": 0
    }
  ],
  "criteria": {
    "Story 1 — ADR 0170 minted (0170 free vs origin/main), STATUS.md updated same commit": "docs/adr/0170-credential-floor-is-any-passkeys-offered-not-required.md + STATUS.md header/milestone-log in a54545e",
    "Story 2 — account-policy relaxation in BOTH gateway renders as a runtime oneshot (kanidm-brand-push pattern), authenticated as idm_admin, fails loud": "kanidmCredentialFloorBlock in internal/clan/vmguest.go (renderGatewayGuest, localhost:8443) + internal/clan/frontdoor.go (RenderFrontDoor, 127.0.0.1:<KanidmPort>); policy op is the script's last command",
    "Story 2 — both render tests assert the policy line": "internal/clan/vmguest_test.go (TestGatewayRender) + internal/clan/frontdoor_test.go (TestRenderFrontDoor_CredentialFloorIsAny) assert `kanidm group account-policy credential-type-minimum idm_all_persons any` — go test ./internal/clan/ green",
    "Story 3 — AwaitPasskey generalises to AwaitCredential (handoff.go + enrolment.go); passkey OR primary-credential detection": "internal/founding/handoff.go + internal/fleetwire/enrolment.go renamed; internal/kanidm/kanidm.go HasCredential ORs HasPasskey with _credential/_status (best-effort password arm so passkey path cannot regress)",
    "Story 3 — DDR 0138/ADR 0100 semantics kept (visible wait, cancel, re-mint, never fabricate)": "AwaitCredential unchanged poll/timeout->ErrEnrolmentTokenExpired; seeded operator has no credential pre-ceremony (provision owns existence only) so no fabricated advance",
    "Story 3 — data-status passkey-enrolled -> credential-enrolled across component, foundingPrefix.ts, wireframe": "FoundingHandOff.vue, app/tests/e2e/fixtures/foundingPrefix.ts, journey.droplet + private-path-tail specs, unit test, and p1-s12 wireframe provenance note",
    "Story 3 — unit coverage via fake-IDP port tests": "internal/fleetwire/enrolment_test.go (scriptedIDP.HasCredential) + internal/kanidm/kanidm_test.go (4 HasCredential tests)",
    "Story 4 — S12 copy neutral/passkey-first + wireframe updated same commit": "FoundingHandOff.vue enrol-pending copy + docs/ux/wireframes/p1-founding/p1-s12-hand-off.html (copy + amendment note)",
    "Story 5 — member password fallback test (PasskeyOffered=true, PasskeyRequired=false), ADR notes IdP/contract agree": "internal/member/signup_test.go TestSignupContract_AgreesWithCredentialFloorAny; ADR 0170 Consequences note the agreement",
    "Story 6 — e2e stays green: CDP ceremony machinery untouched, data-status assertion adjusted": "ceremony.ts virtual-authenticator untouched; foundingPrefix.ts data-status assertion -> credential-enrolled"
  },
  "summary": "Lowered the kanidm person credential floor to `any` (ADR 0170) so passwords commit at founding, generalised the S12 gate to any committed credential, and kept passkeys offered-not-required across the UI contract.",
  "reason": "",
  "blockers": []
}
**close-report** for #485 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; closing. <details><summary>envelope</summary> ```json { "issue": 485, "status": "success", "commits": [ "a54545eaf4cd5f7c232454f83a4ac703ed264b51" ], "changed_files": [ "STATUS.md", "app/src/components/founding/FoundingHandOff.vue", "app/tests/e2e/fixtures/foundingPrefix.ts", "app/tests/e2e/journey.droplet.spec.ts", "app/tests/e2e/private-path-tail.resume.spec.ts", "app/tests/unit/foundingHandOff.test.ts", "docs/adr/0170-credential-floor-is-any-passkeys-offered-not-required.md", "docs/ux/wireframes/p1-founding/p1-s12-hand-off.html", "internal/clan/frontdoor.go", "internal/clan/frontdoor_test.go", "internal/clan/vmguest.go", "internal/clan/vmguest_test.go", "internal/fleetwire/enrolment.go", "internal/fleetwire/enrolment_test.go", "internal/founding/handoff.go", "internal/founding/testing/fakes.go", "internal/kanidm/kanidm.go", "internal/kanidm/kanidm_test.go", "internal/member/signup_test.go" ], "tests": [ { "command": "go test ./internal/clan/ ./internal/kanidm/ ./internal/fleetwire/ ./internal/founding/... ./internal/member/", "exit_code": 0 }, { "command": "go test ./... (full Go suite)", "exit_code": 0 }, { "command": "cd app && node_modules/.bin/vitest run (858 passed, boot.test needs go on PATH)", "exit_code": 0 }, { "command": "cd app && vue-tsc -p tsconfig.json", "exit_code": 0 } ], "criteria": { "Story 1 — ADR 0170 minted (0170 free vs origin/main), STATUS.md updated same commit": "docs/adr/0170-credential-floor-is-any-passkeys-offered-not-required.md + STATUS.md header/milestone-log in a54545e", "Story 2 — account-policy relaxation in BOTH gateway renders as a runtime oneshot (kanidm-brand-push pattern), authenticated as idm_admin, fails loud": "kanidmCredentialFloorBlock in internal/clan/vmguest.go (renderGatewayGuest, localhost:8443) + internal/clan/frontdoor.go (RenderFrontDoor, 127.0.0.1:<KanidmPort>); policy op is the script's last command", "Story 2 — both render tests assert the policy line": "internal/clan/vmguest_test.go (TestGatewayRender) + internal/clan/frontdoor_test.go (TestRenderFrontDoor_CredentialFloorIsAny) assert `kanidm group account-policy credential-type-minimum idm_all_persons any` — go test ./internal/clan/ green", "Story 3 — AwaitPasskey generalises to AwaitCredential (handoff.go + enrolment.go); passkey OR primary-credential detection": "internal/founding/handoff.go + internal/fleetwire/enrolment.go renamed; internal/kanidm/kanidm.go HasCredential ORs HasPasskey with _credential/_status (best-effort password arm so passkey path cannot regress)", "Story 3 — DDR 0138/ADR 0100 semantics kept (visible wait, cancel, re-mint, never fabricate)": "AwaitCredential unchanged poll/timeout->ErrEnrolmentTokenExpired; seeded operator has no credential pre-ceremony (provision owns existence only) so no fabricated advance", "Story 3 — data-status passkey-enrolled -> credential-enrolled across component, foundingPrefix.ts, wireframe": "FoundingHandOff.vue, app/tests/e2e/fixtures/foundingPrefix.ts, journey.droplet + private-path-tail specs, unit test, and p1-s12 wireframe provenance note", "Story 3 — unit coverage via fake-IDP port tests": "internal/fleetwire/enrolment_test.go (scriptedIDP.HasCredential) + internal/kanidm/kanidm_test.go (4 HasCredential tests)", "Story 4 — S12 copy neutral/passkey-first + wireframe updated same commit": "FoundingHandOff.vue enrol-pending copy + docs/ux/wireframes/p1-founding/p1-s12-hand-off.html (copy + amendment note)", "Story 5 — member password fallback test (PasskeyOffered=true, PasskeyRequired=false), ADR notes IdP/contract agree": "internal/member/signup_test.go TestSignupContract_AgreesWithCredentialFloorAny; ADR 0170 Consequences note the agreement", "Story 6 — e2e stays green: CDP ceremony machinery untouched, data-status assertion adjusted": "ceremony.ts virtual-authenticator untouched; foundingPrefix.ts data-status assertion -> credential-enrolled" }, "summary": "Lowered the kanidm person credential floor to `any` (ADR 0170) so passwords commit at founding, generalised the S12 gate to any committed credential, and kept passkeys offered-not-required across the UI contract.", "reason": "", "blockers": [] } ``` </details>
ben closed this issue 2026-08-12 20:58:48 +00:00
Sign in to join this conversation.
No milestone
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
Matou/idss#485
No description provided.