docs: 210 Architektur-Fehler (ARCH-001 bis ARCH-210) durch systematisches Code-Review dokumentiert
This commit is contained in:
@@ -2012,3 +2012,63 @@ Playwright E2E: 10 passed, 24 failed (BUG-011/012/013 — Mock-Daten und data-te
|
|||||||
- **Problem:** Mehrere Models speichern sensitive Daten als Plaintext. Nur mail/models.py verschlüsselt passwords. Andere sensitive Felder (IBAN, API-Keys, Webhook-Secrets, Tax-Numbers) sind unverschlüsselt.
|
- **Problem:** Mehrere Models speichern sensitive Daten als Plaintext. Nur mail/models.py verschlüsselt passwords. Andere sensitive Felder (IBAN, API-Keys, Webhook-Secrets, Tax-Numbers) sind unverschlüsselt.
|
||||||
- **Schweregrad:** High
|
- **Schweregrad:** High
|
||||||
- **Status:** ⏳ Nicht gefixt
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-201: .env.example und .env.docker.example — ADMIN_PASSWORD hardcoded
|
||||||
|
- **Datei:** .env.example:79, .env.docker.example:55, docker-compose.yaml:55
|
||||||
|
- **Problem:** `ADMIN_PASSWORD=Admin123!` — hardcoded Default-Admin-Password in allen Config-Dateien. Security Risk.
|
||||||
|
- **Schweregrad:** High
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-202: tsconfig.json — noUnusedLocals/noUnusedParameters false
|
||||||
|
- **Datei:** frontend/tsconfig.json:16-17
|
||||||
|
- **Problem:** `noUnusedLocals: false` und `noUnusedParameters: false` — TypeScript strict mode ist nicht vollständig aktiviert. Unbenutzte Variablen werden nicht erkannt.
|
||||||
|
- **Schweregrad:** Low
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-203: prestart.sh — f-string SQL injection risk
|
||||||
|
- **Datei:** prestart.sh:42
|
||||||
|
- **Problem:** `ALTER ROLE {role} WITH LOGIN PASSWORD '{pwd}'` — pwd wird direkt in SQL eingefügt. Wenn pwd Sonderzeichen enthält (z.B. '), kann SQL injection auftreten.
|
||||||
|
- **Schweregrad:** High
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-204: vite.config.ts — PWA Reste (manifest.json ohne PWA plugin)
|
||||||
|
- **Datei:** frontend/public/manifest.json, frontend/vite.config.ts
|
||||||
|
- **Problem:** public/manifest.json existiert aber vite-plugin-pwa ist nicht in vite.config.ts importiert. PWA-Reste die verwirren.
|
||||||
|
- **Schweregrad:** Low
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-205: pyproject.toml — mypy disallow_untyped_defs = false
|
||||||
|
- **Datei:** pyproject.toml:55
|
||||||
|
- **Problem:** `disallow_untyped_defs = false` — mypy strict mode ist nicht vollständig aktiviert. Ungetypte Funktionen werden akzeptiert.
|
||||||
|
- **Schweregrad:** Low
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-206: alembic/env.py — wildcard import `from app.models import *`
|
||||||
|
- **Datei:** alembic/env.py:14
|
||||||
|
- **Problem:** `from app.models import *` — wildcard import. Unklar welche Models importiert werden. Kann zu fehlenden Migrationen führen wenn neue Models nicht in __init__.py stehen.
|
||||||
|
- **Schweregrad:** Medium
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-207: requirements.txt — passlib[bcrypt]==1.7.4 gepinnt
|
||||||
|
- **Datei:** requirements.txt:14
|
||||||
|
- **Problem:** `passlib[bcrypt]==1.7.4` — exact version pinned. passlib 1.7.4 ist veraltet, neuere Versionen haben Bugfixes.
|
||||||
|
- **Schweregrad:** Low
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-208: tailwind.config.js — Hardcoded color values
|
||||||
|
- **Datei:** frontend/tailwind.config.js:10-80
|
||||||
|
- **Problem:** Alle Farben sind hardcoded (primary: #2563eb, etc.). themeStore.ts hat DEFAULT_THEME mit denselben Werten — zwei Quellen für dieselben Farben. Sollte CSS variables verwenden.
|
||||||
|
- **Schweregrad:** Low
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-209: tsconfig.json — target ES2020 statt ES2022+
|
||||||
|
- **Datei:** frontend/tsconfig.json:4
|
||||||
|
- **Problem:** `target: ES2020` — moderne JavaScript Features (top-level await, class fields, etc.) werden nicht genutzt. Sollte ES2022+ sein.
|
||||||
|
- **Schweregrad:** Low
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|
||||||
|
### ARCH-210: docker-compose.yaml — DB_PASSWORD als einzelnes Password für alle Roles
|
||||||
|
- **Datei:** docker-compose.yaml:38-40
|
||||||
|
- **Problem:** `DB_PASSWORD` wird für alle DB-Roles (crm_api, crm_auth, crm_worker, crm_user) verwendet. Jede Role sollte ein eigenes Password haben für Security-Isolation.
|
||||||
|
- **Schweregrad:** Medium
|
||||||
|
- **Status:** ⏳ Nicht gefixt
|
||||||
|
|||||||
Reference in New Issue
Block a user