refactor(AsymCryptHandler): Renamed to Cryptograph

This commit is contained in:
Developer 02 2025-01-07 12:03:01 +01:00
parent d9d61368e3
commit ac0b6f739b
2 changed files with 3 additions and 3 deletions

View File

@ -6,7 +6,7 @@ using Microsoft.Extensions.Options;
namespace DigitalData.Core.Security
{
public class AsymCryptHandler : RSAFactory<AsymCryptParams>, ICryptograph, IAsymmetricKeyFactory
public class Cryptograph : RSAFactory<AsymCryptParams>, ICryptograph, IAsymmetricKeyFactory
{
public IEnumerable<IAsymmetricPrivateKey> PrivateKeys { get; }
@ -21,7 +21,7 @@ namespace DigitalData.Core.Security
public IEnumerable<TokenDescription> TokenDescriptions { get; init; } = new List<TokenDescription>();
public AsymCryptHandler(IOptions<AsymCryptParams> options, ILogger<AsymCryptHandler>? logger = null) : base(options)
public Cryptograph(IOptions<AsymCryptParams> options, ILogger<Cryptograph>? logger = null) : base(options)
{
logger?.LogInformation("Core.Secrets version: {Version}, Created on: {CreationDate}.", Secrets.Version, Secrets.CreationDate.ToString("dd.MM.yyyy"));

View File

@ -16,7 +16,7 @@ namespace DigitalData.Core.Security
private static IServiceCollection AddAsymCryptHandler(this IServiceCollection services) => services
.AddParamsConfigureOptions<AsymCryptParams>()
.AddAutoMapper(typeof(MappingProfile).Assembly)
.AddSingleton<ICryptograph, AsymCryptHandler>();
.AddSingleton<ICryptograph, Cryptograph>();
/// <summary>
/// Registers a custom asym crypt service with specified parameters from the given configuration section.