Adds artwork provider system and Calibre plugin

This commit is contained in:
BinaryAlley committed 2026-08-24 14:18:14 -07:00
1 parent c82fadc7a2
commit 6693ff3f60
124 files changed
+9715 -74

No files matched your search

+7 -1
View File
@@ -166,7 +166,13 @@ public class Program
app.UseStaticFiles(new StaticFileOptions
{
FileProvider = new PhysicalFileProvider(mediaRootPath),
RequestPath = "/media"
RequestPath = "/media",
OnPrepareResponse = staticFileContext =>
{
// the served media must not run as active content, so that attacker-influenced files (e.g. SVG covers) cannot execute scripts on the API origin
staticFileContext.Context.Response.Headers["X-Content-Type-Options"] = "nosniff";
staticFileContext.Context.Response.Headers["Content-Security-Policy"] = "default-src 'none'; script-src 'none'; style-src 'unsafe-inline'; img-src 'self' data:";
}
});
app.MapHub<MediaLibraryScanProgressHub>("/scanProgressHub");