Encrypting and decrypting data
In .NET, there are multiple encryption algorithms you can choose from.
In legacy .NET Framework, some encryption algorithms are implemented by the operating system (OS) and their names are suffixed with CryptoServiceProvider
or Cng
. Some encryption algorithms are implemented in the .NET BCL and their names are suffixed with Managed
.
In modern .NET, all encryption algorithms are implemented by the OS. If the OS encryption algorithms are certified by the Federal Information Processing Standards (FIPS), then .NET uses FIPS-certified encryption algorithms rather than implementing the encryption algorithm in the .NET base class library.
Cryptographic operations are performed by OS implementations so that when an OS has a security vulnerability fixed, then .NET apps benefit immediately. But this means that those .NET apps can only use those features that the OS supports. You can read about which features are supported by which OS at the...