fix: 6 Claude-Audit-Fixes (3 CRIT + 3 HIGH)

CRITICAL:
- Logout: LoginScreen statt MeloHome pushen (home_screen.dart)
- Path Traversal: sanitizeDateiname() zentral + sync-loop abgesichert
- SecureStorage: flutter_secure_storage für Token+Passwort (auth_service, navidrome)

HIGH:
- Seek: PlayerService.seek() reload-frei (audio_handler)
- Play/Pause: Zielzustand statt Toggle für System-Controls
- X-User: Header entfernt, Server verlässt sich auf JWT
This commit is contained in:
Dustin
2026-08-03 01:41:04 +02:00
parent de71119235
commit e46ffa76a3
10 changed files with 76 additions and 34 deletions
+18
View File
@@ -86,6 +86,24 @@ class PlayerService {
}
}
/// Explizit abspielen (kein Toggle) — für System-Controls (Bluetooth, etc.)
Future<void> play() async {
if (_player == null || aktuellerSong == null) return;
await _p.play();
}
/// Explizit pausieren (kein Toggle) — für System-Controls (Bluetooth, etc.)
Future<void> pause() async {
if (_player == null) return;
await _p.pause();
}
/// Nur seeken ohne Reload der Quelle
Future<void> seek(Duration position) async {
if (_player == null) return;
await _p.seek(position);
}
Future<void> vorheriges() async {
if (_player == null || aktuellerSong == null) return;
final pos = _p.position;