nug Createrun NuGet

Microsoft.Bcl.Cryptography

9.0.13 90 download(s)
public

Provides support for some cryptographic primitives for .NET Framework and .NET Standard.

PackageReference
<PackageReference Include="Microsoft.Bcl.Cryptography" Version="9.0.13" />
.NET CLI
dotnet add package Microsoft.Bcl.Cryptography --version 9.0.13

Dependencies

net462
Package Version range
System.Formats.Asn1 [9.0.13, )
System.Memory [4.5.5, )
System.Runtime.CompilerServices.Unsafe [6.0.0, )
net8.0
Package Version range
System.Formats.Asn1 [9.0.13, )
netstandard2.0
Package Version range
System.Formats.Asn1 [9.0.13, )
System.Memory [4.5.5, )
System.Runtime.CompilerServices.Unsafe [6.0.0, )

Readme

## About

This library provides some cryptographic types and functionality for .NET Standard and .NET Framework. This library is not necessary nor recommended when targeting versions of .NET that include the relevant support.

## Key Features

* Enables the use of some cryptographic functionality on older .NET platforms.

## How to Use

This package should only be used by platforms where the desired functionality is not built-in.

```C#
using System.Security.Cryptography;

internal static class Program
{
    private static void Main()
    {
        byte[] key = LoadKey();
        SP800108HmacCounterKdf kbkdf = new(key, HashAlgorithmName.SHA256);
        byte[] derivedKey = kbkdf.DeriveKey("label"u8, "context"u8, derivedKeyLengthInBytes: 32);
    }
}
```

## Main Types

The main types provided by this library are:

* `System.Security.Cryptography.SP800108HmacCounterKdf`

## Additional Documentation

* [API documentation](https://learn.microsoft.com/dotnet/api/System.Security.Cryptography)

## Feedback & Contributing

Microsoft.Bcl.Cryptography is released as open source under the [MIT license](https://licenses.nuget.org/MIT). Bug reports and contributions are welcome at [the GitHub repository](https://github.com/dotnet/runtime).

Versions

Target frameworks

net462 net8.0 netstandard2.0

Metadata

Published
Size
226.16 KB
Authors
Microsoft
License
MIT
Repository
https://github.com/dotnet/runtime commit 9ecbfd4f3f330dc9649bce49cb12570b19d48c87
Flags
SemVer 1
SHA512
IrPXtBpYJAs7wDzzGQ0EjK5LvrSzi3kBiDUEwwCKhldQI48ozZPIMzDHJRq/7H94WE3eLwUN/+VsH4VUDQdgVA==

Release notes

https://go.microsoft.com/fwlink/?LinkID=799421