feat(auth): implement session-based authentication and API token management
Server CI / Lint (push) Successful in 19s
Server CI / Build & Push Docker Image (push) Failing after 44s

- Introduced a new authentication system using session cookies for the web dashboard and API tokens for sync clients.
- Replaced the old SERVER_PASSWORD scheme with a more secure API token mechanism.
- Added routes for user setup, login, logout, and credential updates.
- Implemented middleware to require session and API token for protected routes.
- Updated web UI to handle authentication states and provide user feedback.
- Enhanced error handling in API requests and responses.
- Updated README to reflect new authentication flow and database requirements.
This commit is contained in:
Gabriel20xx committed 2026-08-01 12:51:02 +02:00
1 parent 240e1fda4a
commit b150d835a1
18 files changed
+1022 -982

No files matched your search

+4 -2
View File
@@ -17,7 +17,8 @@
"dependencies": {
"express": "^4.18.2",
"cors": "^2.8.5",
"better-sqlite3": "^11.0.0",
"cookie-parser": "^1.4.6",
"bcryptjs": "^2.4.3",
"dotenv": "^16.3.1",
"@typescript-eslint/eslint-plugin": "^7.0.2",
"@typescript-eslint/parser": "^7.0.2",
@@ -29,8 +30,9 @@
"devDependencies": {
"@types/express": "^4.17.21",
"@types/cors": "^2.8.17",
"@types/cookie-parser": "^1.4.7",
"@types/bcryptjs": "^2.4.6",
"@types/node": "^20.10.6",
"@types/better-sqlite3": "^7.6.11",
"@types/pg": "^8.10.2",
"typescript": "5.5.4",
"ts-node-dev": "^2.0.0"