Find sensitive API endpoints

Proprietary

Find data models exposed by ASP.NET APIs that contain sensitive information like PII and secrets. Covers ASP.NET Core, ASP.NET MVC and ASP.NET Web API controller actions and ASP.NET Core minimal APIs: the models an endpoint returns (including the values passed to Ok(...), Results.Ok(...) and similar result helpers) and the models it accepts as parameters, following nested properties. Only types declared in the repository (and anonymous objects) are examined.

OpenRewrite.CSharp.Recipes.FindSensitiveApiEndpoints

Optional

Comma-separated names of the sensitive data to search for. A member matches when its name ends with one of them, optionally followed by a word like Number, Hash or Value (password matches UserPassword and PasswordHash, ssn matches SSN). Defaults to common credentials, financial data and PII.

Find model objects that contain other model objects that contain sensitive data. Defaults to true.

mod run . --recipe=OpenRewrite.CSharp.Recipes.FindSensitiveApiEndpoints

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.