This commit is contained in:
11
schema.sql
11
schema.sql
@@ -424,6 +424,17 @@ CREATE TABLE user_tokens (
|
||||
INDEX idx_ut_type (type)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
CREATE TABLE user_calendar_feeds (
|
||||
user_id BIGINT UNSIGNED NOT NULL PRIMARY KEY,
|
||||
token_encrypted TEXT NOT NULL,
|
||||
token_lookup_hash CHAR(64) NOT NULL UNIQUE,
|
||||
created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
rotated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
last_accessed_at DATETIME NULL,
|
||||
CONSTRAINT fk_user_calendar_feed_user FOREIGN KEY (user_id) REFERENCES users(id) ON DELETE CASCADE,
|
||||
INDEX idx_user_calendar_feeds_lookup (token_lookup_hash)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- Audit-Log für wichtige Aktionen
|
||||
CREATE TABLE audit_log (
|
||||
id BIGINT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
|
||||
|
||||
Reference in New Issue
Block a user