This article explains how to add redaction to logs in ASP.NET Core using the Microsoft.Extensions.Compliance.Redaction package. Redaction is important for protecting sensitive data in logs, especially for privacy- and security-conscious companies. The article outlines the steps to enable redaction, define a data classification taxonomy, and configure redaction services. It also provides examples of how to mark up data models for redaction and how to create a custom redactor.
Table of contents
Why do you need redaction?Adding redaction with Microsoft.Extensions.Compliance.RedactionApplying data classifications with [TagProvider]Creating a custom redactorThings to watch out forSummarySort: