99 references to CipherMode
Microsoft.AspNetCore.DataProtection (1)
Managed\ManagedAuthenticatedEncryptor.cs (1)
148retVal.Mode = CipherMode.CBC;
mscorlib (1)
src\libraries\shims\mscorlib\ref\mscorlib.cs (1)
863[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Security.Cryptography.CipherMode))]
netstandard (1)
netstandard.cs (1)
1853[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Security.Cryptography.CipherMode))]
System.Security.Cryptography (85)
System\Security\Cryptography\Aes.cs (1)
20ModeValue = CipherMode.CBC;
System\Security\Cryptography\AesCryptoServiceProvider.cs (1)
53public override CipherMode Mode
System\Security\Cryptography\AesImplementation.cs (8)
104CipherMode.ECB, 127CipherMode.ECB, 152CipherMode.CBC, 177CipherMode.CBC, 205CipherMode.CFB, 233CipherMode.CFB, 269if (Mode == CipherMode.CFB) 290throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\AesImplementation.OpenSsl.cs (15)
9CipherMode cipherMode, 26CipherMode cipherMode, 38private static IntPtr GetAlgorithm(int keySize, int feedback, CipherMode cipherMode) => 43(128, CipherMode.CBC) => Interop.Crypto.EvpAes128Cbc(), 44(128, CipherMode.ECB) => Interop.Crypto.EvpAes128Ecb(), 45(128, CipherMode.CFB) when feedback == 8 => Interop.Crypto.EvpAes128Cfb8(), 46(128, CipherMode.CFB) when feedback == 128 => Interop.Crypto.EvpAes128Cfb128(), 48(192, CipherMode.CBC) => Interop.Crypto.EvpAes192Cbc(), 49(192, CipherMode.ECB) => Interop.Crypto.EvpAes192Ecb(), 50(192, CipherMode.CFB) when feedback == 8 => Interop.Crypto.EvpAes192Cfb8(), 51(192, CipherMode.CFB) when feedback == 128 => Interop.Crypto.EvpAes192Cfb128(), 53(256, CipherMode.CBC) => Interop.Crypto.EvpAes256Cbc(), 54(256, CipherMode.ECB) => Interop.Crypto.EvpAes256Ecb(), 55(256, CipherMode.CFB) when feedback == 8 => Interop.Crypto.EvpAes256Cfb8(), 56(256, CipherMode.CFB) when feedback == 128 => Interop.Crypto.EvpAes256Cfb128(),
System\Security\Cryptography\AesManaged.cs (1)
51public override CipherMode Mode
System\Security\Cryptography\DESCryptoServiceProvider.Unix.cs (1)
76public override CipherMode Mode
System\Security\Cryptography\DesImplementation.cs (8)
80if (Mode == CipherMode.CFB) 103CipherMode.ECB, 124CipherMode.ECB, 146CipherMode.CBC, 168CipherMode.CBC, 193CipherMode.CFB, 218CipherMode.CFB, 237throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\DesImplementation.OpenSsl.cs (6)
11CipherMode cipherMode, 30CipherMode cipherMode, 45private static IntPtr GetAlgorithm(CipherMode cipherMode, int feedbackSize) 49CipherMode.CBC => Interop.Crypto.EvpDesCbc(), 50CipherMode.ECB => Interop.Crypto.EvpDesEcb(), 51CipherMode.CFB when feedbackSize == 1 => Interop.Crypto.EvpDesCfb8(),
System\Security\Cryptography\Helpers.cs (5)
33public static bool UsesIv(this CipherMode cipherMode) 35return cipherMode != CipherMode.ECB; 38public static byte[]? GetCipherIv(this CipherMode cipherMode, byte[]? iv) 330public static int GetPaddingSize(this SymmetricAlgorithm algorithm, CipherMode mode, int feedbackSizeInBits) 332return (mode == CipherMode.CFB ? feedbackSizeInBits : algorithm.BlockSize) / 8;
System\Security\Cryptography\OpenSslCipher.cs (1)
15CipherMode cipherMode,
System\Security\Cryptography\RC2CryptoServiceProvider.Unix.cs (1)
96public override CipherMode Mode
System\Security\Cryptography\RC2Implementation.cs (8)
73if (Mode == CipherMode.CFB) 93CipherMode.ECB, 117CipherMode.ECB, 142CipherMode.CBC, 167CipherMode.CBC, 188throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeNotSupported, CipherMode.CFB)); 199throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeNotSupported, CipherMode.CFB)); 205throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\RC2Implementation.OpenSsl.cs (5)
11CipherMode cipherMode, 30CipherMode cipherMode, 44private static IntPtr GetAlgorithm(CipherMode cipherMode) 48CipherMode.CBC => Interop.Crypto.EvpRC2Cbc(), 49CipherMode.ECB => Interop.Crypto.EvpRC2Ecb(),
System\Security\Cryptography\RijndaelImplementation.cs (1)
70public override CipherMode Mode
System\Security\Cryptography\RijndaelManaged.cs (1)
66public override CipherMode Mode
System\Security\Cryptography\SymmetricAlgorithm.cs (6)
14ModeValue = CipherMode.CBC; 140public virtual CipherMode Mode 149if (!(value == CipherMode.CBC || value == CipherMode.ECB || value == CipherMode.CFB)) 1685protected CipherMode ModeValue;
System\Security\Cryptography\TripleDESCryptoServiceProvider.Wrap.cs (1)
50public override CipherMode Mode
System\Security\Cryptography\TripleDesImplementation.cs (8)
77if (Mode == CipherMode.CFB) 100CipherMode.ECB, 121CipherMode.ECB, 143CipherMode.CBC, 165CipherMode.CBC, 190CipherMode.CFB, 215CipherMode.CFB, 234throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\TripleDesImplementation.OpenSsl.cs (7)
11CipherMode cipherMode, 28CipherMode cipherMode, 48private static IntPtr GetAlgorithm(CipherMode cipherMode, int feedbackSizeInBytes) => cipherMode switch 50CipherMode.CBC => Interop.Crypto.EvpDes3Cbc(), 51CipherMode.ECB => Interop.Crypto.EvpDes3Ecb(), 52CipherMode.CFB when feedbackSizeInBytes == 1 => Interop.Crypto.EvpDes3Cfb8(), 53CipherMode.CFB when feedbackSizeInBytes == 8 => Interop.Crypto.EvpDes3Cfb64(),
System.Security.Cryptography.Pkcs (1)
Internal\Cryptography\Pal\AnyOS\ManagedPal.cs (1)
202alg.Mode = CipherMode.CBC;
System.Security.Cryptography.Primitives (1)
System.Security.Cryptography.Primitives.cs (1)
9[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Security.Cryptography.CipherMode))]
System.Security.Cryptography.Xml (9)
System\Security\Cryptography\Xml\EncryptedXml.cs (7)
70private CipherMode _mode; 97_mode = CipherMode.CBC; 157public CipherMode Mode 675CipherMode origMode = symmetricAlgorithm.Mode; 695if (_mode == CipherMode.ECB) 729CipherMode origMode = symmetricAlgorithm.Mode; 735if (_mode != CipherMode.ECB)
System\Security\Cryptography\Xml\SymmetricKeyWrap.cs (2)
136aes.Mode = CipherMode.ECB; 199aes.Mode = CipherMode.ECB;