Patrick Buckley
108714a48d
fix(auth): isolate server/console session cookies by name
...
The server (:8080) and console (:8090) both set a cookie named
`turnstone_auth`. Cookies ignore port (RFC 6265), so on a shared host
(localhost dev, the Electron build, single-box installs) logging into one
surface overwrote the other's cookie and 401'd the first session.
Give each surface its own cookie name -- `turnstone_auth_server` /
`turnstone_auth_console` -- threaded as a required `cookie_name` argument
through the cookie builders, `check_request`, `AuthMiddleware`, and the six
shared auth handlers (login/logout/setup/whoami/refresh/oidc_callback). Each
app passes its own constant; the parameter is required (no default) so a
forgotten caller fails loudly instead of silently reverting to the legacy name.
Names key on role, not node: the cluster shares one JWT identity and the
console->node proxy re-mints a bearer token (dropping Set-Cookie), so
per-instance names would break identity portability and aren't used.
Hard cutover: the legacy `turnstone_auth` cookie is no longer read and
self-expires within its 24h TTL (one forced re-login). JWT audience was
already enforced, so the shared cookie was a session clobber, not an auth
bypass.
2026-06-15 02:48:50 -07:00
..
2026-06-04 11:03:13 -07:00
2026-03-02 00:33:37 -08:00
2026-04-30 23:20:14 -07:00
2026-05-06 16:16:57 -07:00
2026-05-31 19:54:43 -07:00
2026-05-09 02:45:13 -07:00
2026-05-04 22:00:23 -07:00
2026-05-05 15:27:14 -07:00
2026-06-01 21:34:12 -07:00
2026-05-19 08:09:33 -07:00
2026-05-29 21:11:16 -07:00
2026-05-06 23:29:08 -07:00
2026-06-01 15:47:14 -07:00
2026-04-26 22:14:22 -07:00
2026-06-11 14:00:06 -07:00
2026-06-04 11:03:13 -07:00
2026-05-30 14:03:39 -07:00
2026-04-27 22:51:31 -07:00
2026-06-15 02:48:50 -07:00
2026-06-15 02:48:50 -07:00
2026-06-01 12:56:45 -07:00
2026-05-31 19:03:16 -07:00
2026-06-04 11:03:13 -07:00
2026-05-23 14:20:36 -07:00
2026-06-04 11:03:13 -07:00
2026-04-18 05:49:54 -07:00
2026-05-31 19:54:43 -07:00
2026-05-31 19:54:43 -07:00
2026-04-18 05:49:54 -07:00
2026-03-23 11:11:40 -07:00
2026-05-12 13:15:09 -07:00
2026-05-11 01:06:47 -07:00
2026-04-30 23:20:14 -07:00
2026-04-30 23:20:14 -07:00
2026-05-24 18:31:23 -07:00
2026-05-30 16:27:15 -07:00
2026-05-31 19:54:43 -07:00
2026-05-31 19:03:16 -07:00
2026-05-09 17:06:47 -07:00
2026-05-11 01:06:47 -07:00
2026-04-27 21:52:57 -07:00
2026-04-16 13:30:25 -07:00
2026-04-18 19:02:52 -07:00
2026-05-24 18:31:23 -07:00
2026-05-09 17:06:47 -07:00
2026-06-08 10:08:30 -07:00
2026-06-08 10:08:30 -07:00
2026-06-08 10:08:30 -07:00
2026-05-29 14:40:10 -07:00
2026-04-30 23:20:14 -07:00
2026-05-31 19:54:43 -07:00
2026-06-10 22:03:08 -07:00
2026-04-24 16:56:06 -07:00
2026-05-11 01:06:47 -07:00
2026-06-04 11:03:13 -07:00
2026-04-24 16:56:06 -07:00
2026-06-04 11:03:13 -07:00
2026-06-12 00:11:08 -07:00
2026-04-16 21:40:50 -07:00
2026-06-12 13:54:49 -07:00
2026-03-13 21:21:09 -07:00
2026-06-09 18:37:46 -07:00
2026-04-04 17:53:20 -07:00
2026-03-02 00:33:37 -08:00
2026-05-04 00:46:43 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-03-03 22:57:34 -08:00
2026-05-24 18:31:23 -07:00
2026-05-24 18:31:23 -07:00
2026-06-10 13:31:53 -07:00
2026-06-09 18:37:46 -07:00
2026-04-04 23:44:29 -07:00
2026-06-09 20:00:55 -07:00
2026-06-04 11:03:13 -07:00
2026-05-30 01:11:48 -07:00
2026-06-04 11:03:13 -07:00
2026-05-06 12:02:27 -07:00
2026-05-31 19:54:43 -07:00
2026-06-11 13:48:28 -07:00
2026-06-04 11:03:13 -07:00
2026-05-31 19:54:43 -07:00
2026-04-05 01:53:33 -07:00
2026-06-09 20:00:55 -07:00
2026-06-09 20:00:55 -07:00
2026-03-04 06:47:30 -08:00
2026-06-04 11:03:13 -07:00
2026-03-02 16:55:12 -08:00
2026-05-05 15:27:14 -07:00
2026-05-12 13:15:09 -07:00
2026-06-11 20:42:34 -07:00
2026-05-07 13:59:50 -07:00
2026-05-04 22:00:23 -07:00
2026-05-04 22:00:23 -07:00
2026-05-06 11:29:25 -07:00
2026-05-04 22:00:23 -07:00
2026-05-07 13:59:50 -07:00
2026-05-07 13:59:50 -07:00
2026-05-12 13:15:09 -07:00
2026-05-04 22:00:23 -07:00
2026-05-04 22:00:23 -07:00
2026-05-05 15:27:14 -07:00
2026-05-07 13:59:50 -07:00
2026-05-07 13:59:50 -07:00
2026-05-12 13:15:09 -07:00
2026-05-12 13:15:09 -07:00
2026-05-12 13:15:09 -07:00
2026-05-07 13:59:50 -07:00
2026-05-07 13:59:50 -07:00
2026-05-06 22:09:47 -07:00
2026-05-07 13:59:50 -07:00
2026-03-12 16:57:31 -07:00
2026-03-21 16:12:50 -07:00
2026-03-20 20:01:26 -07:00
2026-03-23 11:11:40 -07:00
2026-05-07 13:59:50 -07:00
2026-05-04 22:00:23 -07:00
2026-05-06 22:09:47 -07:00
2026-05-07 13:59:50 -07:00
2026-03-15 14:28:03 -07:00
2026-06-12 13:54:49 -07:00
2026-05-06 16:16:57 -07:00
2026-05-04 22:00:23 -07:00
2026-06-04 11:03:13 -07:00
2026-06-12 13:54:49 -07:00
2026-05-31 16:05:21 -07:00
2026-05-09 02:45:13 -07:00
2026-06-11 20:27:29 -07:00
2026-06-01 15:47:14 -07:00
2026-06-11 20:27:29 -07:00
2026-06-04 11:03:13 -07:00
2026-04-28 13:49:31 -07:00
2026-04-06 03:08:19 -07:00
2026-06-04 11:03:13 -07:00
2026-05-11 01:23:54 -07:00
2026-04-05 17:18:26 -07:00
2026-03-07 12:49:07 -08:00
2026-05-14 15:13:00 -07:00
2026-05-04 22:00:23 -07:00
2026-06-15 02:48:50 -07:00
2026-05-04 14:27:19 -07:00
2026-05-04 14:27:19 -07:00
2026-05-31 19:54:43 -07:00
2026-06-04 11:03:13 -07:00
2026-06-11 14:00:42 -07:00
2026-05-24 17:49:27 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-04-27 11:41:14 -07:00
2026-05-31 19:54:43 -07:00
2026-04-28 19:51:00 -07:00
2026-06-11 20:27:29 -07:00
2026-05-09 02:45:13 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-05-09 17:19:40 -07:00
2026-05-24 18:26:54 -07:00
2026-04-15 13:30:22 -07:00
2026-06-09 10:50:58 -07:00
2026-04-26 22:14:22 -07:00
2026-05-28 17:14:50 -07:00
2026-06-04 11:03:13 -07:00
2026-06-09 13:37:35 -07:00
2026-04-18 19:02:52 -07:00
2026-06-01 14:44:30 -07:00
2026-06-01 21:34:12 -07:00
2026-03-30 20:30:05 -07:00
2026-06-04 11:03:13 -07:00
2026-05-31 19:54:43 -07:00
2026-05-31 19:54:43 -07:00
2026-03-02 00:33:37 -08:00
2026-06-08 10:08:30 -07:00
2026-06-10 13:31:53 -07:00
2026-03-23 11:11:40 -07:00
2026-03-30 20:30:05 -07:00
2026-03-02 16:55:12 -08:00
2026-05-31 19:54:43 -07:00
2026-05-31 19:54:43 -07:00
2026-04-04 22:19:03 -07:00
2026-04-16 13:30:25 -07:00
2026-05-31 19:54:43 -07:00
2026-04-26 22:14:22 -07:00
2026-04-26 13:11:07 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-05-31 19:54:43 -07:00
2026-05-30 14:03:39 -07:00
2026-05-03 13:37:50 -07:00
2026-05-04 22:00:23 -07:00
2026-05-31 19:54:43 -07:00
2026-05-02 20:22:25 -07:00
2026-05-22 15:13:39 -07:00
2026-03-30 20:30:05 -07:00
2026-06-04 11:03:13 -07:00
2026-05-10 16:43:52 -07:00
2026-05-20 22:41:40 -07:00
2026-05-06 12:02:27 -07:00
2026-05-07 13:59:50 -07:00
2026-06-04 11:03:13 -07:00
2026-05-28 21:02:51 -07:00
2026-05-20 22:41:40 -07:00
2026-06-09 20:00:55 -07:00
2026-04-26 22:14:22 -07:00
2026-06-12 13:54:49 -07:00
2026-06-04 11:03:13 -07:00
2026-05-31 19:03:16 -07:00
2026-05-31 19:54:43 -07:00
2026-06-12 00:11:08 -07:00
2026-05-24 14:56:43 -07:00
2026-05-24 14:56:43 -07:00
2026-05-24 14:56:43 -07:00
2026-05-31 19:54:43 -07:00
2026-03-17 01:26:44 -07:00
2026-03-23 11:11:40 -07:00
2026-03-16 15:45:21 -07:00
2026-05-08 13:58:02 -07:00
2026-06-04 11:03:13 -07:00
2026-05-31 19:54:43 -07:00
2026-06-04 11:03:13 -07:00
2026-05-29 18:35:16 -07:00
2026-04-25 20:11:47 -07:00
2026-06-04 11:03:13 -07:00
2026-05-11 01:23:54 -07:00
2026-04-04 17:53:20 -07:00
2026-05-24 14:56:43 -07:00
2026-04-18 10:20:19 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-05-02 23:52:49 -07:00
2026-05-02 23:52:49 -07:00
2026-05-24 14:56:43 -07:00
2026-04-01 19:38:24 -07:00
2026-06-09 18:37:46 -07:00
2026-04-01 19:38:24 -07:00
2026-05-30 16:27:15 -07:00
2026-03-25 16:07:05 -07:00
2026-06-04 11:03:13 -07:00
2026-03-30 20:30:05 -07:00
2026-03-12 14:49:58 -07:00
2026-06-01 12:56:45 -07:00
2026-06-04 11:03:13 -07:00
2026-05-31 19:54:43 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-03-23 11:11:40 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-05-14 15:13:00 -07:00
2026-06-04 11:03:13 -07:00
2026-05-23 11:33:36 -07:00
2026-06-01 11:01:30 -07:00
2026-04-27 15:51:01 -07:00
2026-04-30 23:20:14 -07:00
2026-06-04 11:03:13 -07:00
2026-06-04 11:03:13 -07:00
2026-06-12 13:54:49 -07:00