Session 2026-04-20: Medien-Konvertierung, Umami Analytics, Username/Privacy
- HEIC→JPEG, MOV/AVI→MP4 Konvertierung bei allen Upload-Endpoints (media_utils.py) - ffmpeg im Docker-Image, Video-Thumbnails (extract_video_thumb, poster-Attribut) - Google Analytics entfernt, Umami self-hosted eingebunden (index.html, datenschutz.js) - Admin-Panel Analytics-Tab: Stat-Cards, Sparkline 7 Tage, Top-Seiten (Umami-API-Proxy) - Admin-Panel Tab-Icons korrigiert (aus vorhandenem Phosphor-Sprite) - users.real_name Spalte: Username öffentlich, echter Name privat und optional - Registrierung: Label "Benutzername", Leerzeichen verboten, Profanity-Blockliste - Datenschutzerklärung: GA-Abschnitt durch Umami-Text ersetzt
This commit is contained in:
parent
9a78121a3e
commit
5141ba9969
20 changed files with 524 additions and 143 deletions
28
backend/username_blocklist.py
Normal file
28
backend/username_blocklist.py
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
"""Blockliste für Benutzernamen — Teilstring-Matching (case-insensitive)."""
|
||||
|
||||
_BLOCKED = {
|
||||
# Deutsch
|
||||
"arsch", "arschloch", "scheiß", "scheiss", "scheiße", "scheisse",
|
||||
"fotze", "wichser", "wichse", "ficken", "fick", "hurensohn", "hure",
|
||||
"nutte", "schlampe", "dreckau", "drecksau", "idiot", "vollidiot",
|
||||
"nazi", "hitler", "heil", "neger", "nigger", "kanake", "spast",
|
||||
"spastiker", "behinderter", "opfer", "opfa", "missgeburt",
|
||||
"penisgesicht", "penis", "vagina", "schwanz", "schwanzlutscher",
|
||||
"pisser", "kackbratze", "kacke", "kacker", "bastard",
|
||||
"dummkopf", "depp", "trottel", "blödmann", "blödian",
|
||||
"wanker", "scheißkopf", "shithead",
|
||||
# Englisch
|
||||
"fuck", "fucker", "fucking", "shit", "bitch", "asshole", "ass",
|
||||
"cunt", "cock", "dick", "pussy", "whore", "slut", "fag", "faggot",
|
||||
"retard", "moron", "nigga", "porn", "sex", "horny",
|
||||
"rape", "kill", "murder", "terrorist", "isis",
|
||||
# Generisch anstößig
|
||||
"admin", "administrator", "moderator", "support", "banyaro",
|
||||
"root", "system",
|
||||
}
|
||||
|
||||
|
||||
def is_username_blocked(name: str) -> bool:
|
||||
"""True wenn der Username einen gesperrten Begriff enthält."""
|
||||
lower = name.lower()
|
||||
return any(blocked in lower for blocked in _BLOCKED)
|
||||
Loading…
Add table
Add a link
Reference in a new issue