RingDotNetfor Ring

Microsoft.AspNetCore.DataProtection

14 wrapped types. Load them with using { "Microsoft.AspNetCore.DataProtection" }. Click a class to open it.

DataProtectionAdvancedExtensions class static

Microsoft.AspNetCore.DataProtection.DataProtectionAdvancedExtensions · assembly Microsoft.AspNetCore.DataProtection.Extensions

Methods

MethodRing call.NET overloads
ProtectProtect(p1,p2,p3)static byte[] Protect(ITimeLimitedDataProtector protector, byte[] plaintext, TimeSpan lifetime)
static string Protect(ITimeLimitedDataProtector protector, string plaintext, DateTimeOffset expiration)
static string Protect(ITimeLimitedDataProtector protector, string plaintext, TimeSpan lifetime)
ToTimeLimitedDataProtectorToTimeLimitedDataProtector(p1)static ITimeLimitedDataProtector ToTimeLimitedDataProtector(IDataProtector protector)
UnprotectUnprotect(p1,p2)static string Unprotect(ITimeLimitedDataProtector protector, string protectedData, out DateTimeOffset expiration)
DataProtectionBuilderExtensions class static

Microsoft.AspNetCore.DataProtection.DataProtectionBuilderExtensions · assembly Microsoft.AspNetCore.DataProtection

Methods

MethodRing call.NET overloads
AddKeyEscrowSinkAddKeyEscrowSink(value)
AddKeyEscrowSink([ :builder = … ])
AddKeyEscrowSink([ :builder = …, :sink = … ])
AddKeyEscrowSink([ :builder = …, :factory = … ])
static IDataProtectionBuilder AddKeyEscrowSink(IDataProtectionBuilder builder, IKeyEscrowSink sink)
static IDataProtectionBuilder AddKeyEscrowSink<TImplementation>(IDataProtectionBuilder builder)
static IDataProtectionBuilder AddKeyEscrowSink(IDataProtectionBuilder builder, Func<IServiceProvider, IKeyEscrowSink> factory)
AddKeyManagementOptionsAddKeyManagementOptions(p1,p2)static IDataProtectionBuilder AddKeyManagementOptions(IDataProtectionBuilder builder, Action<KeyManagementOptions> setupAction)
DisableAutomaticKeyGenerationDisableAutomaticKeyGeneration(p1)static IDataProtectionBuilder DisableAutomaticKeyGeneration(IDataProtectionBuilder builder)
PersistKeysToFileSystemPersistKeysToFileSystem(p1,p2)static IDataProtectionBuilder PersistKeysToFileSystem(IDataProtectionBuilder builder, DirectoryInfo directory)
PersistKeysToRegistryPersistKeysToRegistry(p1,p2)static IDataProtectionBuilder PersistKeysToRegistry(IDataProtectionBuilder builder, RegistryKey registryKey)
ProtectKeysWithCertificateProtectKeysWithCertificate(p1,p2)static IDataProtectionBuilder ProtectKeysWithCertificate(IDataProtectionBuilder builder, X509Certificate2 certificate)
static IDataProtectionBuilder ProtectKeysWithCertificate(IDataProtectionBuilder builder, string thumbprint)
ProtectKeysWithDpapiProtectKeysWithDpapi(value)
ProtectKeysWithDpapi([ :builder = … ])
ProtectKeysWithDpapi([ :builder = …, :protectToLocalMachine = … ])
static IDataProtectionBuilder ProtectKeysWithDpapi(IDataProtectionBuilder builder)
static IDataProtectionBuilder ProtectKeysWithDpapi(IDataProtectionBuilder builder, bool protectToLocalMachine)
ProtectKeysWithDpapiNGProtectKeysWithDpapiNG(value)
ProtectKeysWithDpapiNG([ :builder = … ])
ProtectKeysWithDpapiNG([ :builder = …, :protectionDescriptorRule = …, :flags = … ])
static IDataProtectionBuilder ProtectKeysWithDpapiNG(IDataProtectionBuilder builder)
static IDataProtectionBuilder ProtectKeysWithDpapiNG(IDataProtectionBuilder builder, string protectionDescriptorRule, DpapiNGProtectionDescriptorFlags flags)
SetApplicationNameSetApplicationName(p1,p2)static IDataProtectionBuilder SetApplicationName(IDataProtectionBuilder builder, string applicationName)
SetDefaultKeyLifetimeSetDefaultKeyLifetime(p1,p2)static IDataProtectionBuilder SetDefaultKeyLifetime(IDataProtectionBuilder builder, TimeSpan lifetime)
UnprotectKeysWithAnyCertificateUnprotectKeysWithAnyCertificate(p1,p2)static IDataProtectionBuilder UnprotectKeysWithAnyCertificate(IDataProtectionBuilder builder, X509Certificate2[] certificates)
UseCryptographicAlgorithmsUseCryptographicAlgorithms(p1,p2)static IDataProtectionBuilder UseCryptographicAlgorithms(IDataProtectionBuilder builder, AuthenticatedEncryptorConfiguration configuration)
UseCustomCryptographicAlgorithmsUseCustomCryptographicAlgorithms(p1,p2)static IDataProtectionBuilder UseCustomCryptographicAlgorithms(IDataProtectionBuilder builder, CngCbcAuthenticatedEncryptorConfiguration configuration)
static IDataProtectionBuilder UseCustomCryptographicAlgorithms(IDataProtectionBuilder builder, CngGcmAuthenticatedEncryptorConfiguration configuration)
static IDataProtectionBuilder UseCustomCryptographicAlgorithms(IDataProtectionBuilder builder, ManagedAuthenticatedEncryptorConfiguration configuration)
UseEphemeralDataProtectionProviderUseEphemeralDataProtectionProvider(p1)static IDataProtectionBuilder UseEphemeralDataProtectionProvider(IDataProtectionBuilder builder)
DataProtectionCommonExtensions class static

Microsoft.AspNetCore.DataProtection.DataProtectionCommonExtensions · assembly Microsoft.AspNetCore.DataProtection.Abstractions

Methods

MethodRing call.NET overloads
CreateProtectorCreateProtector([ :provider = …, :purposes = … ])
CreateProtector([ :provider = …, :purpose = …, :subPurposes = … ])
static IDataProtector CreateProtector(IDataProtectionProvider provider, IEnumerable<string> purposes)
static IDataProtector CreateProtector(IDataProtectionProvider provider, string purpose, string[] subPurposes)
GetDataProtectionProviderGetDataProtectionProvider(p1)static IDataProtectionProvider GetDataProtectionProvider(IServiceProvider services)
GetDataProtectorGetDataProtector([ :services = …, :purposes = … ])
GetDataProtector([ :services = …, :purpose = …, :subPurposes = … ])
static IDataProtector GetDataProtector(IServiceProvider services, IEnumerable<string> purposes)
static IDataProtector GetDataProtector(IServiceProvider services, string purpose, string[] subPurposes)
ProtectProtect(p1,p2)static string Protect(IDataProtector protector, string plaintext)
UnprotectUnprotect(p1,p2)static string Unprotect(IDataProtector protector, string protectedData)
DataProtectionOptions class

Microsoft.AspNetCore.DataProtection.DataProtectionOptions · assembly Microsoft.AspNetCore.DataProtection

Constructors

new DataProtectionOptions()

Ring: new DataProtectionOptions(args) uses one constructor; the others are chosen by the parameter names: new DataProtectionOptions().@New([ :param = value ]) or dnNew("DataProtectionOptions",[ :param = value ]).

Properties and fields

NameTypeAccessIn Ring
ApplicationDiscriminatorstringread, writeo.ApplicationDiscriminator o.ApplicationDiscriminator = v
DataProtectionProvider class static

Microsoft.AspNetCore.DataProtection.DataProtectionProvider · assembly Microsoft.AspNetCore.DataProtection.Extensions

Methods

MethodRing call.NET overloads
CreateCreate(value)
Create([ :applicationName = … ])
Create([ :keyDirectory = … ])
Create([ :keyDirectory = …, :setupAction = … ])
Create([ :applicationName = …, :certificate = … ])
static IDataProtectionProvider Create(string applicationName)
static IDataProtectionProvider Create(DirectoryInfo keyDirectory)
static IDataProtectionProvider Create(DirectoryInfo keyDirectory, Action<IDataProtectionBuilder> setupAction)
static IDataProtectionProvider Create(string applicationName, X509Certificate2 certificate)
static IDataProtectionProvider Create(DirectoryInfo keyDirectory, X509Certificate2 certificate)
static IDataProtectionProvider Create(DirectoryInfo keyDirectory, Action<IDataProtectionBuilder> setupAction, X509Certificate2 certificate)
DataProtectionUtilityExtensions class static

Microsoft.AspNetCore.DataProtection.DataProtectionUtilityExtensions · assembly Microsoft.AspNetCore.DataProtection

Methods

MethodRing call.NET overloads
GetApplicationUniqueIdentifierGetApplicationUniqueIdentifier(p1)static string GetApplicationUniqueIdentifier(IServiceProvider services)
EphemeralDataProtectionProvider class sealed

Microsoft.AspNetCore.DataProtection.EphemeralDataProtectionProvider · assembly Microsoft.AspNetCore.DataProtection

Constructors

new EphemeralDataProtectionProvider()
new EphemeralDataProtectionProvider(ILoggerFactory loggerFactory)

Ring: new EphemeralDataProtectionProvider(args) uses one constructor; the others are chosen by the parameter names: new EphemeralDataProtectionProvider().@New([ :param = value ]) or dnNew("EphemeralDataProtectionProvider",[ :param = value ]).

Methods

MethodRing call.NET overloads
CreateProtectorcallMethod("CreateProtector",[p1])IDataProtector CreateProtector(string purpose)
IDataProtectionBuilder interface

Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder · assembly Microsoft.AspNetCore.DataProtection

Properties and fields

NameTypeAccessIn Ring
ServicesIServiceCollectionreado.Services
IDataProtectionProvider interface

Microsoft.AspNetCore.DataProtection.IDataProtectionProvider · assembly Microsoft.AspNetCore.DataProtection.Abstractions

Methods

MethodRing call.NET overloads
CreateProtectorcallMethod("CreateProtector",[p1])IDataProtector CreateProtector(string purpose)
IDataProtector interface

Microsoft.AspNetCore.DataProtection.IDataProtector · assembly Microsoft.AspNetCore.DataProtection.Abstractions

Methods

MethodRing call.NET overloads
ProtectcallMethod("Protect",[p1])byte[] Protect(byte[] plaintext)
UnprotectcallMethod("Unprotect",[p1])byte[] Unprotect(byte[] protectedData)
IPersistedDataProtector interface

Microsoft.AspNetCore.DataProtection.IPersistedDataProtector · assembly Microsoft.AspNetCore.DataProtection

Methods

MethodRing call.NET overloads
DangerousUnprotectDangerousUnprotect(p1,p2)byte[] DangerousUnprotect(byte[] protectedData, bool ignoreRevocationErrors, out bool requiresMigration, out bool wasRevoked)
ISecret interface

Microsoft.AspNetCore.DataProtection.ISecret · assembly Microsoft.AspNetCore.DataProtection

Implements: IDisposable

Properties and fields

NameTypeAccessIn Ring
Lengthintreado.Length

Methods

MethodRing call.NET overloads
WriteSecretIntoBufferWriteSecretIntoBuffer(p1)void WriteSecretIntoBuffer(ArraySegment<byte> buffer)
ITimeLimitedDataProtector interface

Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector · assembly Microsoft.AspNetCore.DataProtection.Extensions

Methods

MethodRing call.NET overloads
CreateProtectorcallMethod("CreateProtector",[p1])ITimeLimitedDataProtector CreateProtector(string purpose)
ProtectProtect([ :plaintext = …, :expiration = … ])byte[] Protect(byte[] plaintext, DateTimeOffset expiration)
UnprotectUnprotect(p1)byte[] Unprotect(byte[] protectedData, out DateTimeOffset expiration)
Secret class sealed

Microsoft.AspNetCore.DataProtection.Secret · assembly Microsoft.AspNetCore.DataProtection

Implements: IDisposable

Constructors

new Secret(ArraySegment<byte> value)
new Secret(byte[] value)
new Secret(Byte* secret, int secretLength)
new Secret(ISecret secret)

Ring: new Secret(args) uses one constructor; the others are chosen by the parameter names: new Secret().@New([ :param = value ]) or dnNew("Secret",[ :param = value ]).

Properties and fields

NameTypeAccessIn Ring
Lengthintreado.Length

Methods

MethodRing call.NET overloads
DisposecallMethod("Dispose",[])void Dispose()
RandomRandom(p1)static Secret Random(int numBytes)
WriteSecretIntoBufferWriteSecretIntoBuffer(p1)void WriteSecretIntoBuffer(ArraySegment<byte> buffer)
void WriteSecretIntoBuffer(Byte* buffer, int bufferLength)