XmlKeyManager Class

Definition

A key manager backed by an IXmlRepository.

public ref class XmlKeyManager sealed : Microsoft::AspNetCore::DataProtection::KeyManagement::IKeyManager, Microsoft::AspNetCore::DataProtection::KeyManagement::Internal::IInternalXmlKeyManager
public sealed class XmlKeyManager : Microsoft.AspNetCore.DataProtection.KeyManagement.IKeyManager, Microsoft.AspNetCore.DataProtection.KeyManagement.Internal.IInternalXmlKeyManager
type XmlKeyManager = class
    interface IKeyManager
    interface IInternalXmlKeyManager
Public NotInheritable Class XmlKeyManager
Implements IInternalXmlKeyManager, IKeyManager
Inheritance
XmlKeyManager
Implements
IKeyManager Microsoft.AspNetCore.DataProtection.KeyManagement.Internal.IInternalXmlKeyManager

Constructors

XmlKeyManager(IOptions<KeyManagementOptions>, IActivator)

Creates an XmlKeyManager.

XmlKeyManager(IOptions<KeyManagementOptions>, IActivator, ILoggerFactory)

Creates an XmlKeyManager.

XmlKeyManager(IXmlRepository, IAuthenticatedEncryptorConfiguration, IServiceProvider)

Creates an XmlKeyManager.

Methods

CreateNewKey(DateTimeOffset, DateTimeOffset)

Creates a new key with the specified activation and expiration dates and persists the new key to the underlying repository.

GetAllKeys()

Fetches all keys from the underlying repository.

GetCacheExpirationToken()

Retrieves a token that signals that callers who have cached the return value of GetAllKeys should clear their caches. This could be in response to a call to CreateNewKey or RevokeKey, or it could be in response to some other external notification. Callers who are interested in observing this token should call this method before the corresponding call to GetAllKeys.

RevokeAllKeys(DateTimeOffset, String)

Revokes all keys created before a specified date and persists the revocation to the underlying repository.

RevokeKey(Guid, String)

Revokes a specific key and persists the revocation to the underlying repository.

Explicit Interface Implementations

IInternalXmlKeyManager.CreateNewKey(Guid, DateTimeOffset, DateTimeOffset, DateTimeOffset)
IInternalXmlKeyManager.DeserializeDescriptorFromKeyElement(XElement)
IInternalXmlKeyManager.RevokeSingleKey(Guid, DateTimeOffset, String)

Applies to