Adds bundled plugin trust and cross-platform native deployment

- embeds the append-only historical and deny trust lists in the API and marks matching bundled plugins as Official without blocking loading
- builds and records the current plugin manifest only for official release builds
- deploys the PDF native libraries for the supported Linux, macOS and Windows runtimes from the plugin dependency manifest
- records release hashes by appending only missing entries to master's manifest and rejects any diff that removes a line
- documents the release flow, the supported runtimes and the plugin installer limits
This commit is contained in:
BinaryAlley committed 2026-11-28 18:00:00 +02:00
1 parent 3fb8912c7f
commit b30cbd6b9e
114 files changed
+2708 -243

No files matched your search

@@ -1,4 +1,7 @@
#region ========================================================================= USING =====================================================================================
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Nemera.Application.Common.DomainEvents;
using Nemera.Application.Common.Infrastructure.Authorization.Policies.ConsumptionActivity;
using Nemera.Application.Common.Infrastructure.Models.DTO.Configuration;
@@ -18,9 +21,6 @@ using Nemera.Infrastructure.Core.MediaLibrary.AudioLibrary.MusicLibrary.Playback
using Nemera.Infrastructure.Core.Security;
using Nemera.Infrastructure.Core.Time;
using Nemera.Plugins.Contracts.Core.Plugins;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
@@ -35,6 +35,8 @@ namespace Nemera.Infrastructure.UnitTests.Common.DependencyInjection;
[ExcludeFromCodeCoverage]
public class InfrastructureLayerServicesTests
{
private static readonly IReadOnlyDictionary<string, IReadOnlySet<string>> s_emptyBundledPluginChecksums = new Dictionary<string, IReadOnlySet<string>>();
[Fact]
public void AddInfrastructureLayerServices_WhenCalled_ShouldRegisterCoreInfrastructureServices()
{
@@ -43,7 +45,7 @@ public class InfrastructureLayerServicesTests
IConfiguration configuration = CreateConfiguration();
// Act
services.AddInfrastructureLayerServices(configuration);
services.AddInfrastructureLayerServices(configuration, s_emptyBundledPluginChecksums);
// Assert
Assert.Contains(services, descriptor => descriptor.ServiceType == typeof(IFileHashService) && descriptor.ImplementationType == typeof(FileHashService));
@@ -68,7 +70,7 @@ public class InfrastructureLayerServicesTests
IConfiguration configuration = CreateConfiguration();
// Act
services.AddInfrastructureLayerServices(configuration);
services.AddInfrastructureLayerServices(configuration, s_emptyBundledPluginChecksums);
// Assert
Assert.Contains(services, descriptor => descriptor.ServiceType == typeof(IValidator<PluginsSettingsDto>));
@@ -82,7 +84,7 @@ public class InfrastructureLayerServicesTests
// Arrange
IServiceCollection services = new ServiceCollection();
IConfiguration configuration = CreateConfiguration();
services.AddInfrastructureLayerServices(configuration);
services.AddInfrastructureLayerServices(configuration, s_emptyBundledPluginChecksums);
// A plugin registers its typed client after the infrastructure layer, so the defaults must reach it too.
services.AddHttpClient("plugin-client");
using ServiceProvider serviceProvider = services.BuildServiceProvider();