KeyManagementOptions Class

Options that control how an Microsoft.AspNetCore.DataProtection.KeyManagement.IKeyManager should behave.

Namespace
Microsoft.AspNetCore.DataProtection.KeyManagement
Assemblies
  • Microsoft.AspNetCore.DataProtection

Syntax

public class KeyManagementOptions
class Microsoft.AspNetCore.DataProtection.KeyManagement.KeyManagementOptions

Constructors

KeyManagementOptions()
public KeyManagementOptions()

Properties

Microsoft.AspNetCore.DataProtection.KeyManagement.KeyManagementOptions.AutoGenerateKeys

Specifies whether the data protection system should auto-generate keys.

Return type:System.Boolean
public bool AutoGenerateKeys { get; set; }
Microsoft.AspNetCore.DataProtection.KeyManagement.KeyManagementOptions.NewKeyLifetime

Controls the lifetime (number of days before expiration) for newly-generated keys.

Return type:System.TimeSpan
public TimeSpan NewKeyLifetime { get; set; }