feat(auth): harden session management and security

- Implement server-side session revocation on logout
- Add IP extraction utility and admin setup error handling
- Improve error codes and response consistency for auth endpoints
- Refine landing page redirect logic to handle transient DB outages
- Update deployment documentation and configuration defaults
This commit is contained in:
Team Dark Devil committed 2026-11-19 20:22:01 +06:00
1 parent 935f12a1e9
commit 89e4d68690
81 files changed
+11530 -6916

No files matched your search

+1 -4
View File
@@ -113,11 +113,8 @@ export function getSessionCookieOptions(request: Request, maxAge: number) {
?.split(",")[0]
?.trim()
.toLowerCase();
const originHeader = request.headers.get("origin")?.toLowerCase() ?? "";
const isHttps =
forwardedProto === "https" ||
originHeader.startsWith("https://") ||
request.url.startsWith("https://");
forwardedProto === "https" || request.url.startsWith("https://");
if (isHttps) {
return {