dorfteich/apps/api/src/auth
Claude Fable 5 c2a4dde5cc
Some checks failed
CI / Lint, typecheck, test (pull_request) Successful in 6m50s
CI / Build container images (pull_request) Successful in 3m57s
CI / Auth e2e pack (pull_request) Failing after 6m18s
CI / Import/export fidelity gate (pull_request) Has been skipped
Invitation flow with per-user quota (#332)
Any authenticated user can invite an e-mail address; the mailed
single-use token lets exactly one signup through even while
registration is closed. Open (pending, unexpired) invitations count
against the new instance setting invitations.maxOpenPerUser (default 5,
0 disables inviting) — plus a 20/day per-user rate limit so a
revoke-and-recreate loop cannot become a mail cannon. Only the SHA-256
token hash is stored (auth-tokens pattern); a failed signup (taken
username) un-redeems the token so the invitee can retry.

Surfaces: invitations section in the user settings (list, invite,
revoke, quota line; wide table in a focusable .table-scroll region),
signup page reads ?invitation=<token> (preview banner, e-mail prefill,
closed-mode gate opens only for a previewed-valid token), admin general
card gets the quota field (flat RHF name per #322; VS-NfD marked and
hideable).

Governance: audit actions invitation.created/revoked/accepted
(catalogue 1.10), VS-NfD profile entry (compliant: 0) + hardening-guide
row, i18n de+en including the invitation mail template.

Tests: api e2e-db (mail link, closed-mode single-use signup with
un-redeem on failure, quota + revoke frees slot, quota 0 = 403, auth
matrix), new web e2e pack invitations.spec.ts (full UI loop through
Mailpit, wired into ci.yml with its own rate-limit reset), a11y scan
waits for the new section. Full api suite (107 files / 607 tests),
auth/admin-settings/a11y packs green against a fresh local stack.

Closes #332
2026-08-05 12:44:20 +02:00
..
auth-tokens.service.ts Add authentication: signup, verification, sessions, password reset 2026-07-05 05:22:31 +02:00
auth.controller.ts #216: hard AUTH_LOCAL_ENABLED switch over every local credential flow 2026-07-31 12:58:07 +02:00
auth.e2e.db.test.ts #302: configurable pond start page, created with every new pond 2026-08-01 08:06:35 +02:00
auth.guard.ts #216: hard AUTH_LOCAL_ENABLED switch over every local credential flow 2026-07-31 12:58:07 +02:00
auth.module.ts Invitation flow with per-user quota (#332) 2026-08-05 12:44:20 +02:00
auth.service.ts Invitation flow with per-user quota (#332) 2026-08-05 12:44:20 +02:00
claim-mapping.e2e.db.test.ts #217: map IdP groups and roles onto the permission model 2026-07-31 13:09:11 +02:00
claim-mapping.service.ts #217: map IdP groups and roles onto the permission model 2026-07-31 13:09:11 +02:00
csrf.e2e.db.test.ts #189: make the CSRF origin check fail closed 2026-07-30 09:34:44 +02:00
local-auth-switch.e2e.db.test.ts #216: hard AUTH_LOCAL_ENABLED switch over every local credential flow 2026-07-31 12:58:07 +02:00
oidc.controller.ts #214: OIDC Authorization Code with PKCE, Keycloak as reference IdP 2026-07-31 12:44:52 +02:00
oidc.e2e.db.test.ts #214: OIDC Authorization Code with PKCE, Keycloak as reference IdP 2026-07-31 12:44:52 +02:00
oidc.service.ts #217: map IdP groups and roles onto the permission model 2026-07-31 13:09:11 +02:00
proxy-identity.e2e.db.test.ts #215: trusted reverse-proxy header / mTLS client-certificate path 2026-07-31 12:50:09 +02:00
proxy-identity.service.ts #215: trusted reverse-proxy header / mTLS client-certificate path 2026-07-31 12:50:09 +02:00
sessions.module.ts Add account/session endpoints and typed instance settings with admin API 2026-07-05 05:26:45 +02:00
sessions.service.db.test.ts #190: configurable session lifetime with a server-side idle timeout 2026-07-30 11:11:15 +02:00
sessions.service.ts #190: configurable session lifetime with a server-side idle timeout 2026-07-30 11:11:15 +02:00