FileSystemXmlRepository Class¶
An XML repository backed by a file system.
- Namespace
Microsoft.AspNetCore.DataProtection.Repositories
- Assemblies
- Microsoft.AspNetCore.DataProtection
Syntax¶
public class FileSystemXmlRepository : IXmlRepository
-
class
Microsoft.AspNetCore.DataProtection.Repositories.
FileSystemXmlRepository
Constructors¶
-
FileSystemXmlRepository
(System.IO.DirectoryInfo)¶ Creates a
Microsoft.AspNetCore.DataProtection.Repositories.FileSystemXmlRepository
with keys stored at the given directory.Arguments: directory (System.IO.DirectoryInfo) – The directory in which to persist key material. public FileSystemXmlRepository(DirectoryInfo directory)
-
FileSystemXmlRepository
(System.IO.DirectoryInfo, System.IServiceProvider) Creates a
Microsoft.AspNetCore.DataProtection.Repositories.FileSystemXmlRepository
with keys stored at the given directory.Arguments: - directory (System.IO.DirectoryInfo) – The directory in which to persist key material.
- services (System.IServiceProvider) – An optional
System.IServiceProvider
to provide ancillary services.
public FileSystemXmlRepository(DirectoryInfo directory, IServiceProvider services)
-
Properties¶
-
Microsoft.AspNetCore.DataProtection.Repositories.FileSystemXmlRepository.
DefaultKeyStorageDirectory
¶ The default key storage directory, which currently corresponds to “%LOCALAPPDATA%ASP.NETDataProtection-Keys”.
Return type: System.IO.DirectoryInfo public static DirectoryInfo DefaultKeyStorageDirectory { get; }
-
Microsoft.AspNetCore.DataProtection.Repositories.FileSystemXmlRepository.
Directory
¶ The directory into which key material will be written.
Return type: System.IO.DirectoryInfo public DirectoryInfo Directory { get; }
-
Microsoft.AspNetCore.DataProtection.Repositories.FileSystemXmlRepository.
Services
¶ The
System.IServiceProvider
provided to the constructor.Return type: System.IServiceProvider protected IServiceProvider Services { get; }
-