JGUZDV.AspNetCore.DataProtection 1.0.2

There is a newer version of this package available.
See the version list below for details.
dotnet add package JGUZDV.AspNetCore.DataProtection --version 1.0.2
                    
NuGet\Install-Package JGUZDV.AspNetCore.DataProtection -Version 1.0.2
                    
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="JGUZDV.AspNetCore.DataProtection" Version="1.0.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="JGUZDV.AspNetCore.DataProtection" Version="1.0.2" />
                    
Directory.Packages.props
<PackageReference Include="JGUZDV.AspNetCore.DataProtection" />
                    
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 JGUZDV.AspNetCore.DataProtection --version 1.0.2
                    
#r "nuget: JGUZDV.AspNetCore.DataProtection, 1.0.2"
                    
#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 JGUZDV.AspNetCore.DataProtection@1.0.2
                    
#: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=JGUZDV.AspNetCore.DataProtection&version=1.0.2
                    
Install as a Cake Addin
#tool nuget:?package=JGUZDV.AspNetCore.DataProtection&version=1.0.2
                    
Install as a Cake Tool

JGUZDV.AspNetCore.DataProtection

This package allows to configure data protection via the appsettings.json file (or the AspNetCore configuration system to be more precise). If you want to configure multiple applications running on a shared host, set those keys via the environment variables. E.g. JGUZDV__DataProtection__UsePersistance.

{ 
  "JGUZDV" : {
    "DataProtection" : {    // default section JGUZDV:DataProtection - a custom section can be passed
      "ApplicationName" : "MyApp",    // Name to be used by SetApplicationName and UsePathIsolation, if not set, IHostingEnvironment.ApplicationName will be used as default.
      "SetApplicationName" : false,    // if true, calls SetApplicationName and passes the aforementioned ApplicationName, default: false
      "DisableAutomaticKeyGeneration" : false    // if true automatic key generation is disabled, default: false

      "UsePersistence" : true    // enables persistence configuration, default: true
      "Persistance" : {    // must be defined if UsePersistance is true
        "UseFileSystem" : false,    // if true, persists to file system, default: false
        "FileSystem" : {    // must be defined if UseFileSystem is true
          "Path" : "/my-dataprot-path/",    // path for file system persistence
          "UseIsolatedPath" : true    // if true, combines Path with ApplicationName, e.g. /my-dataprot-path/MyApp, default: true
        }
      },

      "UseProtection" : true    // if true, protect keys, default: true
      "Protection" : {    // must be defined if UseProtection is true
        "UseCertificate" : false,    // if true, use certificate for protection
        "Certificate" : {    // optional, must be defined if UseCertificate is true
          "Thumbprint" : "",    // certificate thumbprint - must be set if file name is empty
          "FileName" : "name",    // certificate filename - must be set if thumbprint empty
          "Password" : "password"    // optional password for certificate
        },
        "UseDpapi" : true,    // if true, use Windows DPAPI
        "UseDpapiNG" : true    // if true, use Windows Server DpapiNG
      }
    }
  }
}
Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net6.0

    • No dependencies.
  • net7.0

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on JGUZDV.AspNetCore.DataProtection:

Package Downloads
JGUZDV.AspNetCore.Hosting

HostBuilders for our default setup.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.1.0 143 11/3/2026
2.0.1 734 3/31/2025
2.0.0 367 2/25/2025
1.1.1 625 6/12/2023
1.1.0 320 5/16/2023
1.0.2 495 1/23/2023
1.0.1 490 1/3/2023
1.0.0 476 1/2/2023