stack/apps/backend
Bilal Godil 2d1db7a56e fix(saml): harden route guards and accept Response-level signature
Two bugs surfaced when running the SAML e2e suite against the live
backend (in a separate PR):

1. Routes accessed `tenancy.config.auth.saml.connections[id].field`
   without first checking that the entry exists. With strict null
   checks off, TS types this as always-defined and the route 500'd
   with a TypeError on missing connections instead of returning 404.
   Add an explicit `id in connections` guard at the top of each
   route (login, acs, metadata).

2. SAML responses signed at the Response element (samlify default,
   also what Okta + Azure AD emit) failed verification because the
   backend was configured with wantAssertionsSigned=true,
   wantAuthnResponseSigned=false — i.e. demanded an Assertion-level
   signature. Per SAML 2.0 §4.1.4.2 either is valid. Flip to
   wantAuthnResponseSigned=true so we accept what real-world IdPs
   actually send.
2026-04-29 16:46:22 -07:00
..
prisma feat(backend): add SAML SSO Prisma models + migration 2026-04-29 16:46:22 -07:00
scripts Fix ClickHouse OOM in MAU query + optimize /internal/metrics route (#1344) 2026-04-19 22:57:46 -07:00
src fix(saml): harden route guards and accept Response-level signature 2026-04-29 16:46:22 -07:00
.env Move internal MCP server to backend, use Mintlify MCP for docs tools (#1389) 2026-04-29 09:45:52 -07:00
.env.development Move internal MCP server to backend, use Mintlify MCP for docs tools (#1389) 2026-04-29 09:45:52 -07:00
.eslintrc.cjs tsup for stack-shared (#647) 2025-04-28 21:26:52 -07:00
.gitignore private files n sm build shit (#1276) 2026-03-23 12:31:36 -07:00
instrumentation-client.ts Upgrade backend to Next.js 16 2025-12-12 16:59:07 -08:00
LICENSE Split backend and dashboard (#83) 2024-06-18 15:49:31 +02:00
next.config.mjs private files n sm build shit (#1276) 2026-03-23 12:31:36 -07:00
package.json feat(backend): extract email-merge helper and add SAML account helpers 2026-04-29 16:46:22 -07:00
prisma.config.ts [Fix]: Assortment of Bugs with Timefold Table and Payments (#1348) 2026-04-18 14:17:24 -07:00
tsconfig.json Fix lint 2026-02-27 09:59:26 -08:00
vercel.json External db sync (#1036) 2026-02-05 12:04:31 -08:00
vitest.config.ts Customizable ports (#962) 2025-10-20 15:24:47 -07:00
vitest.setup.ts Customizable ports (#962) 2025-10-20 15:24:47 -07:00