34 references to EncryptionAlgorithm
Microsoft.AspNetCore.DataProtection (34)
AuthenticatedEncryption\AuthenticatedEncryptorFactory.cs (24)
108internal static bool IsGcmAlgorithm(EncryptionAlgorithm algorithm) 110return (EncryptionAlgorithm.AES_128_GCM <= algorithm && algorithm <= EncryptionAlgorithm.AES_256_GCM); 113private static int GetAlgorithmKeySizeInBits(EncryptionAlgorithm algorithm) 117case EncryptionAlgorithm.AES_128_CBC: 118case EncryptionAlgorithm.AES_128_GCM: 121case EncryptionAlgorithm.AES_192_CBC: 122case EncryptionAlgorithm.AES_192_GCM: 125case EncryptionAlgorithm.AES_256_CBC: 126case EncryptionAlgorithm.AES_256_GCM: 134private static string GetBCryptAlgorithmNameFromEncryptionAlgorithm(EncryptionAlgorithm algorithm) 138case EncryptionAlgorithm.AES_128_CBC: 139case EncryptionAlgorithm.AES_192_CBC: 140case EncryptionAlgorithm.AES_256_CBC: 141case EncryptionAlgorithm.AES_128_GCM: 142case EncryptionAlgorithm.AES_192_GCM: 143case EncryptionAlgorithm.AES_256_GCM: 167private static Type GetManagedTypeFromEncryptionAlgorithm(EncryptionAlgorithm algorithm) 171case EncryptionAlgorithm.AES_128_CBC: 172case EncryptionAlgorithm.AES_192_CBC: 173case EncryptionAlgorithm.AES_256_CBC: 174case EncryptionAlgorithm.AES_128_GCM: 175case EncryptionAlgorithm.AES_192_GCM: 176case EncryptionAlgorithm.AES_256_GCM:
AuthenticatedEncryption\CngCbcAuthenticatedEncryptorFactory.cs (1)
106throw Error.Common_PropertyCannotBeNullOrEmpty(nameof(EncryptionAlgorithm));
AuthenticatedEncryption\CngGcmAuthenticatedEncryptorFactory.cs (1)
73throw Error.Common_PropertyCannotBeNullOrEmpty(nameof(EncryptionAlgorithm));
AuthenticatedEncryption\ConfigurationModel\AuthenticatedEncryptorConfiguration.cs (3)
18/// The default value is <see cref="EncryptionAlgorithm.AES_256_CBC"/>. 20public EncryptionAlgorithm EncryptionAlgorithm { get; set; } = EncryptionAlgorithm.AES_256_CBC;
AuthenticatedEncryption\ConfigurationModel\AuthenticatedEncryptorDescriptorDeserializer.cs (2)
34configuration.EncryptionAlgorithm = (EncryptionAlgorithm)Enum.Parse(typeof(EncryptionAlgorithm), (string)encryptionElement.Attribute("algorithm")!);
DataProtectionBuilderExtensions.cs (3)
436/// algorithms specified in the <see cref="EncryptionAlgorithm"/> and 458/// algorithms specified in the <see cref="EncryptionAlgorithm"/> and 480/// algorithms specified in the <see cref="EncryptionAlgorithm"/> and