Removes every other screen, API route, component, test and the dependencies only they used. Cookie colite_admin, Co-Lite branding, BO_USERS/BO_ROLES modules only. The user form no longer loads branches, events or country scope. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EFUzfj5akPxyikzGc2iAHM
11 lines
593 B
TypeScript
11 lines
593 B
TypeScript
// host-prefixed-session-cookie (F29): the session cookie carries the `__Host-` prefix, so a browser accepts it only
|
|
// when set over HTTPS by this exact host with Path=/ and no Domain; a sibling host cannot set or
|
|
// overwrite it. SESSION_COOKIE_NAME sets the base name only; the prefix is applied exactly once. Edge-safe (used by
|
|
// the middleware and the server session code).
|
|
const HOST_PREFIX = "__Host-";
|
|
|
|
export function sessionCookieName(): string {
|
|
const base = process.env.SESSION_COOKIE_NAME || "colite_admin";
|
|
return base.startsWith(HOST_PREFIX) ? base : HOST_PREFIX + base;
|
|
}
|