DotNetCore.Security 19.16.0

dotnet add package DotNetCore.Security --version 19.16.0
                    
NuGet\Install-Package DotNetCore.Security -Version 19.16.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="DotNetCore.Security" Version="19.16.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="DotNetCore.Security" Version="19.16.0" />
                    
Directory.Packages.props
<PackageReference Include="DotNetCore.Security" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add DotNetCore.Security --version 19.16.0
                    
#r "nuget: DotNetCore.Security, 19.16.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#addin nuget:?package=DotNetCore.Security&version=19.16.0
                    
Install DotNetCore.Security as a Cake Addin
#tool nuget:?package=DotNetCore.Security&version=19.16.0
                    
Install DotNetCore.Security as a Cake Tool

DotNetCore.Security

Cryptography

ICryptographyService

public interface ICryptographyService
{
    string Decrypt(string value, string salt);

    string Encrypt(string value, string salt);
}

CryptographyService

public class CryptographyService : ICryptographyService
{
    public CryptographyService(string key) { }

    public string Decrypt(string value, string salt) { }

    public string Encrypt(string value, string salt) { }
}

Hash

IHashService

public interface IHashService
{
    string Create(string value, string salt);

    bool Validate(string hash, string value, string salt);
}

HashService

public class HashService : IHashService
{
    public string Create(string value, string salt) { }

    public bool Validate(string hash, string value, string salt) { }
}

Extensions

public static class Extensions
{
    public static void AddCryptographyService(this IServiceCollection services, string key) { }

    public static void AddHashService(this IServiceCollection services) { }
}
Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on DotNetCore.Security:

Package Downloads
IGeekFan.FreeKit.Infrastructure

基础包功能模块

GitHub repositories (3)

Showing the top 3 popular GitHub repositories that depend on DotNetCore.Security:

Repository Stars
rafaelfgx/Architecture
.NET, Angular, Clean Architecture, Clean Code, SOLID Principles, KISS Principle, DRY Principle, Fail Fast Principle, Common Closure Principle, Common Reuse Principle, Acyclic Dependencies Principle, Mediator Pattern, Result Pattern, Folder-by-Feature Structure, Separation of Concerns.
luoyunchong/lin-cms-dotnetcore
😃A simple and practical CMS implemented by .NET + FreeSql;前后端分离、Docker部署、OAtuh2授权登录、自动化部署DevOps、自动同步至Gitee、代码生成器、仿掘金专栏
luoyunchong/dotnetcore-examples
about learning DotNetCore via examples. DotNetCore 教程、技术栈示例代码,快速简单上手教程。
Version Downloads Last updated
19.16.0 78 6/5/2025