Find insecure Rfc2898DeriveBytes constructors (SYSLIB0041)
Recipe ID
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.FindRfc2898InsecureCtorsArtifactOpenRewrite.Recipes.CSharp.Migration.DotnetFinds Rfc2898DeriveBytes constructor calls that use default SHA1 or low iteration counts, which are obsolete in .NET 7 (SYSLIB0041). Specify HashAlgorithmName and at least 600,000 iterations.
Single recipesearchdotnetnet7cryptographyProprietary
Usage
This recipe has no required configuration options. You’ll need the Moderne CLI configured before running the command below.
mod run . --recipe OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.FindRfc2898InsecureCtorsIf the recipe isn’t available locally, install it with:
mod config recipes nuget install OpenRewrite.Recipes.CSharp.Migration.Dotnet