DataProtectionBuilderExtensions 類別

定義

使用 設定資料保護的 IDataProtectionBuilder 延伸模組。

public ref class DataProtectionBuilderExtensions abstract sealed
public static class DataProtectionBuilderExtensions
type DataProtectionBuilderExtensions = class
Public Module DataProtectionBuilderExtensions
繼承
DataProtectionBuilderExtensions

方法

AddKeyEscrowSink(IDataProtectionBuilder, Func<IServiceProvider,IKeyEscrowSink>)

IKeyEscrowSink註冊 以在金鑰保存到儲存體之前執行委付。

AddKeyEscrowSink(IDataProtectionBuilder, IKeyEscrowSink)

IKeyEscrowSink註冊 以在金鑰保存到儲存體之前執行委付。

AddKeyEscrowSink<TImplementation>(IDataProtectionBuilder)

IKeyEscrowSink註冊 以在金鑰保存到儲存體之前執行委付。

AddKeyManagementOptions(IDataProtectionBuilder, Action<KeyManagementOptions>)

設定資料保護系統的金鑰管理選項。

DisableAutomaticKeyGeneration(IDataProtectionBuilder)

設定資料保護系統,不要自動產生新的金鑰。

PersistKeysToFileSystem(IDataProtectionBuilder, DirectoryInfo)

設定資料保護系統,將金鑰保存到指定的目錄。 此路徑可能位於本機電腦上,或可能指向 UNC 共用。

PersistKeysToRegistry(IDataProtectionBuilder, RegistryKey)

設定資料保護系統,將金鑰保存到 Windows 登錄。

ProtectKeysWithCertificate(IDataProtectionBuilder, String)

將金鑰設定為在保存至儲存體之前,先將金鑰加密至指定的憑證。

ProtectKeysWithCertificate(IDataProtectionBuilder, X509Certificate2)

將金鑰設定為在保存至儲存體之前,先將金鑰加密至指定的憑證。

ProtectKeysWithDpapi(IDataProtectionBuilder)

將金鑰設定為使用 Windows DPAPI 加密,再保存到儲存體。 加密金鑰只能由目前的 Windows 使用者帳戶解密。

ProtectKeysWithDpapi(IDataProtectionBuilder, Boolean)

將金鑰設定為使用 Windows DPAPI 加密,再保存到儲存體。

ProtectKeysWithDpapiNG(IDataProtectionBuilder)

將金鑰設定為使用 Windows CNG DPAPI 加密,再保存到儲存體。 金鑰將由目前的 Windows 使用者帳戶解密。

ProtectKeysWithDpapiNG(IDataProtectionBuilder, String, DpapiNGProtectionDescriptorFlags)

將金鑰設定為使用 Windows CNG DPAPI 加密,再保存到儲存體。

SetApplicationName(IDataProtectionBuilder, String)

在資料保護系統中設定此應用程式的唯一名稱。

SetDefaultKeyLifetime(IDataProtectionBuilder, TimeSpan)

設定資料保護系統所建立金鑰的預設存留期。

UnprotectKeysWithAnyCertificate(IDataProtectionBuilder, X509Certificate2[])

設定可用來解密從儲存體載入之金鑰的憑證。

UseCryptographicAlgorithms(IDataProtectionBuilder, AuthenticatedEncryptionSettings)

設定資料保護系統,以在產生受保護的承載時,預設使用指定的密碼編譯演算法。

UseCryptographicAlgorithms(IDataProtectionBuilder, AuthenticatedEncryptorConfiguration)

設定資料保護系統,以在產生受保護的承載時,預設使用指定的密碼編譯演算法。

UseCustomCryptographicAlgorithms(IDataProtectionBuilder, CngCbcAuthenticatedEncryptionSettings)

設定資料保護系統以使用自訂 Windows CNG 演算法。 此 API 適用于開發人員無法使用 和 ValidationAlgorithm 列舉中指定的 EncryptionAlgorithm 演算法的進階案例。

UseCustomCryptographicAlgorithms(IDataProtectionBuilder, CngCbcAuthenticatedEncryptorConfiguration)

設定資料保護系統以使用自訂 Windows CNG 演算法。 此 API 適用于開發人員無法使用 和 ValidationAlgorithm 列舉中指定的 EncryptionAlgorithm 演算法的進階案例。

UseCustomCryptographicAlgorithms(IDataProtectionBuilder, CngGcmAuthenticatedEncryptionSettings)

設定資料保護系統以使用自訂 Windows CNG 演算法。 此 API 適用于開發人員無法使用 和 ValidationAlgorithm 列舉中指定的 EncryptionAlgorithm 演算法的進階案例。

UseCustomCryptographicAlgorithms(IDataProtectionBuilder, CngGcmAuthenticatedEncryptorConfiguration)

設定資料保護系統以使用自訂 Windows CNG 演算法。 此 API 適用于開發人員無法使用 和 ValidationAlgorithm 列舉中指定的 EncryptionAlgorithm 演算法的進階案例。

UseCustomCryptographicAlgorithms(IDataProtectionBuilder, ManagedAuthenticatedEncryptionSettings)

設定資料保護系統以使用自訂演算法。 此 API 適用于開發人員無法使用 和 ValidationAlgorithm 列舉中指定的 EncryptionAlgorithm 演算法的進階案例。

UseCustomCryptographicAlgorithms(IDataProtectionBuilder, ManagedAuthenticatedEncryptorConfiguration)

設定資料保護系統以使用自訂演算法。 此 API 適用于開發人員無法使用 和 ValidationAlgorithm 列舉中指定的 EncryptionAlgorithm 演算法的進階案例。

UseEphemeralDataProtectionProvider(IDataProtectionBuilder)

設定資料保護系統,以用於 EphemeralDataProtectionProvider 資料保護服務。

適用於