VOOZH about

URL: https://www.nuget.org/packages/Microsoft.Extensions.Compliance.Redaction

⇱ NuGet Gallery | Microsoft.Extensions.Compliance.Redaction 10.7.0




👁 Image
Microsoft.Extensions.Compliance.Redaction 10.7.0

Prefix Reserved
dotnet add package Microsoft.Extensions.Compliance.Redaction --version 10.7.0
 
 
NuGet\Install-Package Microsoft.Extensions.Compliance.Redaction -Version 10.7.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="Microsoft.Extensions.Compliance.Redaction" Version="10.7.0" />
 
 
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Microsoft.Extensions.Compliance.Redaction" Version="10.7.0" />
 
Directory.Packages.props
<PackageReference Include="Microsoft.Extensions.Compliance.Redaction" />
 
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 Microsoft.Extensions.Compliance.Redaction --version 10.7.0
 
 
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Microsoft.Extensions.Compliance.Redaction, 10.7.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.
#:package Microsoft.Extensions.Compliance.Redaction@10.7.0
 
 
#: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=Microsoft.Extensions.Compliance.Redaction&version=10.7.0
 
Install as a Cake Addin
#tool nuget:?package=Microsoft.Extensions.Compliance.Redaction&version=10.7.0
 
Install as a Cake Tool
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Microsoft.Extensions.Compliance.Redaction

A redaction engine and canonical redactors.

Install the package

From the command-line:

dotnet add package Microsoft.Extensions.Compliance.Redaction

Or directly in the C# project file:

<ItemGroup>
 <PackageReference Include="Microsoft.Extensions.Compliance.Redaction" Version="[CURRENTVERSION]" />
</ItemGroup>

Usage Example

Registering the services

The services can be registered using one of the AddRedaction overloads:

public static IServiceCollection AddRedaction(this IServiceCollection services)
public static IServiceCollection AddRedaction(this IServiceCollection services, Action<IRedactionBuilder> configure)

Configuring a redactor

Redactors are fetched at runtime using an IRedactorProvider. You can choose to implement your own provider and register it inside the AddRedaction call, or alternatively you can just use the default provider. Redactors can be configured using one of these IRedactionBuilder extension methods:

// Using the default redactor provider:
builder.Services.AddRedaction(redactionBuilder =>
{
 // Assigns a redactor to use for a set of data classifications.
 redactionBuilder.SetRedactor<MyRedactor>(MySensitiveDataClassification);
 // Assigns a fallback redactor to use when processing classified data for which no specific redactor has been registered. 
 // The `ErasingRedactor` is the default fallback redactor. If no redactor is configured for a data classification then the data will be erased.
 redactionBuilder.SetFallbackRedactor<MyFallbackRedactor>();
});

// Using a custom redactor provider:
builder.Services.AddSingleton<IRedactorProvider, MyRedactorProvider>();
builder.Services.AddRedaction(redactionBuilder => { });

Configuring the HMAC redactor

The HMAC redactor can be configured using one these IRedactionBuilder extension methods:

public static IRedactionBuilder SetHmacRedactor(this IRedactionBuilder builder, Action<HmacRedactorOptions> configure, params DataClassificationSet[] classifications)
public static IRedactionBuilder SetHmacRedactor(this IRedactionBuilder builder, IConfigurationSection section, params DataClassificationSet[] classifications)

The HmacRedactorOptions requires its KeyId and Key properties to be set. The HmacRedactor is still in the experimental phase, which means that the above two methods will show warning EXTEXP0002 notifying you that the HmacRedactor is not yet stable. In order to use it, you will need to either add <NoWarn>$(NoWarn);EXTEXP0002</NoWarn> to your project file or add #pragma warning disable EXTEXP0002 around the calls to SetHmacRedactor.

Feedback & Contributing

We welcome feedback and contributions in our GitHub repo.

Product Versions Compatible and additional computed target framework versions.
.NET net8.0 net8.0 is compatible.  net8.0-android net8.0-android was computed.  net8.0-browser net8.0-browser was computed.  net8.0-ios net8.0-ios was computed.  net8.0-maccatalyst net8.0-maccatalyst was computed.  net8.0-macos net8.0-macos was computed.  net8.0-tvos net8.0-tvos was computed.  net8.0-windows net8.0-windows was computed.  net9.0 net9.0 is compatible.  net9.0-android net9.0-android was computed.  net9.0-browser net9.0-browser was computed.  net9.0-ios net9.0-ios was computed.  net9.0-maccatalyst net9.0-maccatalyst was computed.  net9.0-macos net9.0-macos was computed.  net9.0-tvos net9.0-tvos was computed.  net9.0-windows net9.0-windows was computed.  net10.0 net10.0 is compatible.  net10.0-android net10.0-android was computed.  net10.0-browser net10.0-browser was computed.  net10.0-ios net10.0-ios was computed.  net10.0-maccatalyst net10.0-maccatalyst was computed.  net10.0-macos net10.0-macos was computed.  net10.0-tvos net10.0-tvos was computed.  net10.0-windows net10.0-windows was computed. 
.NET Framework net462 net462 is compatible.  net463 net463 was computed.  net47 net47 was computed.  net471 net471 was computed.  net472 net472 was computed.  net48 net48 was computed.  net481 net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (12)

Showing the top 5 NuGet packages that depend on Microsoft.Extensions.Compliance.Redaction:

Package Downloads
Cnblogs.Architecture.Ddd.Cqrs.ServiceAgent

Provides abstrations for implementing service agent.

RevolutionaryStuff.Data.JsonStore

Package Description

ControlR.Libraries.DataRedaction

A library for data redaction in ControlR, providing tools to redact sensitive information from logs and outputs.

ControlR.ApiClient

The API client for ControlR, an open-source remote control and remote access solution.

SaaS-Factory.AppBlueprint.Infrastructure

Infrastructure library with database repositories and external services

GitHub repositories (7)

Showing the top 7 popular GitHub repositories that depend on Microsoft.Extensions.Compliance.Redaction:

Repository Stars
dotnet/AspNetCore.Docs
Documentation for ASP.NET Core
mehdihadeli/food-delivery-microservices
🍔 A practical and cloud-native food delivery microservices, built with .Net Aspire, .Net 9, MassTransit, Domain-Driven Design, CQRS, Vertical Slice Architecture, Event-Driven Architecture, and the latest technologies.
getcellm/cellm
Use LLMs in Excel formulas
dotnet/ai-samples
erwinkramer/bank-api
The Bank API is a design reference project suitable to bootstrap development for a compliant and modern API.
foxminchan/BookWorm
The practical implementation of Aspire using Microservices, AI-Agents
bitbound/ControlR
Open-source, self-hostable remote control and remote access.
Version Downloads Last Updated
10.7.0 7,128 6/9/2026
10.6.0 52,002 5/12/2026
10.5.0 110,017 4/15/2026
10.4.0 109,421 3/10/2026
10.3.0 117,706 2/10/2026
10.2.0 102,969 1/13/2026
10.1.0 87,624 12/9/2025
10.0.0 346,691 11/11/2025
9.10.0 90,984 10/14/2025
9.9.0 98,744 9/9/2025
9.8.0 103,635 8/12/2025
9.7.0 44,916 7/8/2025
9.6.0 58,960 6/10/2025
9.5.0 186,369 5/13/2025
9.4.0 123,309 4/8/2025
9.3.0 30,038 3/11/2025
9.2.0 145,066 2/11/2025
9.1.0 96,767 1/14/2025
9.0.0 173,208 11/12/2024
8.10.0 346,805 10/8/2024
Loading failed