java-topology/defects/jellyfin-0002/patch/jellyfin-0002.patch
russell@unturf.com 9335217e94 jellyfin-0001/jellyfin-0002: Jellyfin 5-MOAD scan
jellyfin-0001 (CWE-407): BaseNfoSaver AddCustomTags xmlTagsUsed List.Contains
O(E*T) per NFO save, fix HashSet O(E). 24.6x at T=50,E=200. UNDF-2026-000000952.

jellyfin-0002 (CWE-312): Logged secrets in SessionManager (access token),
SchedulesDirect (auth token), QuickConnectManager (secret). 3 sites. UNDF-2026-000000953.

MOAD-0002 (Intertangle): CLEAN. No god object pattern detected.
MOAD-0003 (Leaked Context): CLEAN. AsyncLocal only for deadlock detection.
MOAD-0005 (Thundering Herd): CLEAN. FastConcurrentLru with GetOrAdd.
2026-03-31 11:46:30 -04:00

39 lines
1.8 KiB
Diff

# UNDF: UNDF-2026-000000953
--- a/Emby.Server.Implementations/Session/SessionManager.cs
+++ b/Emby.Server.Implementations/Session/SessionManager.cs
@@ -1717,7 +1717,7 @@
{
CheckDisposed();
- _logger.LogInformation("Logging out access token {0}", device.AccessToken);
+ _logger.LogInformation("Logging out access token for device {DeviceId}", device.DeviceId);
await _deviceManager.DeleteDevice(device).ConfigureAwait(false);
--- a/src/Jellyfin.LiveTv/Listings/SchedulesDirect.cs
+++ b/src/Jellyfin.LiveTv/Listings/SchedulesDirect.cs
@@ -645,7 +645,7 @@
var root = await Request<TokenDto>(options, false, null, cancellationToken).ConfigureAwait(false);
if (string.Equals(root?.Message, "OK", StringComparison.Ordinal))
{
- _logger.LogInformation("Authenticated with Schedules Direct token: {Token}", root.Token);
+ _logger.LogInformation("Authenticated with Schedules Direct successfully");
return root.Token;
}
--- a/Emby.Server.Implementations/QuickConnect/QuickConnectManager.cs
+++ b/Emby.Server.Implementations/QuickConnect/QuickConnectManager.cs
@@ -219,10 +219,10 @@
foreach (var (secret, (timestamp, _)) in _authorizedSecrets)
{
if (expireAll || timestamp < minTime)
{
- _logger.LogDebug("Removing expired secret {Secret}", secret);
+ _logger.LogDebug("Removing expired quick connect secret");
if (!_authorizedSecrets.TryRemove(secret, out _))
{
- _logger.LogWarning("Secret {Secret} already expired", secret);
+ _logger.LogWarning("Quick connect secret already expired");
}
}
}