Soenneker.Hashing.Slhdsa 4.0.558

Prefix Reserved
dotnet add package Soenneker.Hashing.Slhdsa --version 4.0.558
                    
NuGet\Install-Package Soenneker.Hashing.Slhdsa -Version 4.0.558
                    
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="Soenneker.Hashing.Slhdsa" Version="4.0.558" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Hashing.Slhdsa" Version="4.0.558" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Hashing.Slhdsa" />
                    
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 Soenneker.Hashing.Slhdsa --version 4.0.558
                    
#r "nuget: Soenneker.Hashing.Slhdsa, 4.0.558"
                    
#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 Soenneker.Hashing.Slhdsa@4.0.558
                    
#: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=Soenneker.Hashing.Slhdsa&version=4.0.558
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Hashing.Slhdsa&version=4.0.558
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

Soenneker.Hashing.Slhdsa

Generates SLH-DSA post-quantum key pairs, signs UTF-8 messages, and verifies signatures using Bouncy Castle. This is a digital-signature utility, not a password-hashing API.

Installation

dotnet add package Soenneker.Hashing.Slhdsa

Generate keys, sign, and verify

using Soenneker.Hashing.Slhdsa;

(string privateKey, string publicKey) = SlhDsaHashingUtil.GenerateKeyPair();

string signature = SlhDsaHashingUtil.SignMessage(
    "release-manifest-v42",
    privateKey);

bool valid = SlhDsaHashingUtil.VerifySignature(
    "release-manifest-v42",
    signature,
    publicKey);

Keys and signatures are returned as Base64 strings. The private key contains a DER-encoded PKCS#8 PrivateKeyInfo; the public key contains a DER-encoded X.509 SubjectPublicKeyInfo.

Choose a parameter set

using Soenneker.Hashing.Slhdsa.Enums;

const SlhDsaParameterType parameters = SlhDsaParameterType.SLH_DSA_SHA2_192S;

(string privateKey, string publicKey) =
    SlhDsaHashingUtil.GenerateKeyPair(parameters);

string signature = SlhDsaHashingUtil.SignMessage(message, privateKey, parameters);
bool valid = SlhDsaHashingUtil.VerifySignature(message, signature, publicKey, parameters);

The same parameter set must be used for key generation, signing, and verification. The default is SLH_DSA_SHAKE_128F. In the enum names, 128, 192, and 256 identify security categories; F variants favor faster signing with larger signatures, while S variants favor smaller signatures with slower signing.

The overloads accepting Bouncy Castle’s SlhDsaParameters or a signer-name string are available for advanced interoperability scenarios. Prefer the enum overloads when both sides use this package.

VerifySignature() returns false for malformed Base64, invalid keys, invalid signatures, unsupported signer names, and encoded inputs above its defensive size limits. Signing and key generation surface configuration/key errors. Decoded private-key and message buffers are cleared after signing, but the returned private-key string is immutable managed data: protect it with an appropriate secret store, restrict access, and never log it.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  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

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
4.0.558 97 9/30/2026
4.0.557 108 9/25/2026
4.0.556 87 9/25/2026
4.0.555 85 9/24/2026
4.0.554 95 9/24/2026
4.0.553 93 9/20/2026
4.0.552 100 9/16/2026
4.0.551 104 9/16/2026
4.0.550 91 9/16/2026
4.0.549 92 9/15/2026
4.0.548 93 9/15/2026
4.0.547 97 9/13/2026
4.0.546 107 9/13/2026
4.0.545 94 9/13/2026
4.0.544 95 9/12/2026
4.0.543 97 9/12/2026
4.0.542 94 9/12/2026
4.0.539 98 9/9/2026
4.0.538 99 9/8/2026
4.0.537 103 9/8/2026
Loading failed

Updated Soenneker.Extensions.String to 4.0.770