DMS.SecurityManager
1.0.7
The owner has unlisted this package.
This could mean that the package is deprecated, has security vulnerabilities or shouldn't be used anymore.
dotnet add package DMS.SecurityManager --version 1.0.7
NuGet\Install-Package DMS.SecurityManager -Version 1.0.7
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="DMS.SecurityManager" Version="1.0.7" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="DMS.SecurityManager" Version="1.0.7" />
<PackageReference Include="DMS.SecurityManager" />
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 DMS.SecurityManager --version 1.0.7
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: DMS.SecurityManager, 1.0.7"
#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.
#:package DMS.SecurityManager@1.0.7
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=DMS.SecurityManager&version=1.0.7
#tool nuget:?package=DMS.SecurityManager&version=1.0.7
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
DMS.SecurityManager
DMS.SecurityManager es una librería de clases en C# que proporciona funcionalidades de encriptación y desencriptación utilizando los algoritmos AES, RSA y ECC.
Instalación
Puedes instalar el paquete NuGet utilizando el siguiente comando:
dotnet add package DMS.SecurityManager
Uso
Encriptación y Desencriptación con AES
using DMS.SecurityManager;
public class AESEncryptionExample
{
public void Example()
{
// Generar clave y IV
AESEncryption aes = AESEncryption.GenerateKeys(out string key, out string iv);
// Datos a encriptar
string originalData = "Este es un mensaje secreto.";
// Encriptar los datos
string encryptedData = aes.Encrypt(originalData);
// Desencriptar los datos
AESEncryption aesWithExistingKeys = new AESEncryption(key, iv);
string decryptedData = aesWithExistingKeys.Decrypt(encryptedData);
Console.WriteLine($"Original: {originalData}");
Console.WriteLine($"Encrypted: {encryptedData}");
Console.WriteLine($"Decrypted: {decryptedData}");
}
}
Encriptación y Desencriptación con RSA
using DMS.SecurityManager;
public class RSAEncryptionExample
{
public void Example()
{
// Generar claves para el remitente y el destinatario
RSAEncryption sender = RSAEncryption.GenerateKeys(out string senderPublicKey, out string senderPrivateKey);
RSAEncryption recipient = RSAEncryption.GenerateKeys(out string recipientPublicKey, out string recipientPrivateKey);
// Datos a encriptar
string originalData = "Este es un mensaje secreto.";
// Encriptar los datos
string encryptedData = sender.Encrypt(originalData, recipientPublicKey);
// Desencriptar los datos
string decryptedData = recipient.Decrypt(encryptedData, recipientPrivateKey);
Console.WriteLine($"Original: {originalData}");
Console.WriteLine($"Encrypted: {encryptedData}");
Console.WriteLine($"Decrypted: {decryptedData}");
}
}
Encriptación y Desencriptación con ECC
using DMS.SecurityManager;
public class ECCEncryptionExample
{
public void Example()
{
// Generar claves para el remitente y el destinatario
ECCEncryption sender = ECCEncryption.GenerateKeys(out string senderPublicKey, out string senderPrivateKey);
ECCEncryption recipient = ECCEncryption.GenerateKeys(out string recipientPublicKey, out string recipientPrivateKey);
// Datos a encriptar
string originalData = "Este es un mensaje secreto.";
// Encriptar los datos
string encryptedData = sender.Encrypt(originalData, recipientPublicKey);
// Desencriptar los datos
string decryptedData = recipient.Decrypt(encryptedData, senderPublicKey);
Console.WriteLine($"Original: {originalData}");
Console.WriteLine($"Encrypted: {encryptedData}");
Console.WriteLine($"Decrypted: {decryptedData}");
}
}
Licencia
Este proyecto está licenciado bajo la Licencia Apache-2.0.
| Product | Versions 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.
-
net9.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|