DB-gestützte Sessions (opt-in) + 'überall abmelden'

- includes/DbSessionHandler.php (SessionHandlerInterface, fehlertolerant)
- Auth: opt-in-Registrierung (Setting session_driver=db), activeSessionCount(),
  logoutOtherSessions()
- Migration 0004 (sessions.user_id NULL) + database.sql
- Settings-Toggle in integrations.php; 'überall abmelden' in security.php
This commit is contained in:
Claude 2026-06-06 05:49:53 +00:00
parent ebfa27d5c3
commit 1a51721477
No known key found for this signature in database
6 changed files with 144 additions and 2 deletions

View file

@ -114,7 +114,7 @@ CREATE TABLE IF NOT EXISTS `vouchers` (
CREATE TABLE IF NOT EXISTS `sessions` (
`id` VARCHAR(128) PRIMARY KEY,
`user_id` INT NOT NULL,
`user_id` INT NULL,
`data` TEXT,
`expires_at` TIMESTAMP NOT NULL,
`created_at` TIMESTAMP DEFAULT CURRENT_TIMESTAMP,