This section describes how the .NET Framework supports common cryptographic tasks. The reader should be familiar with the basics of cryptography, a description of which is outside the scope of this book. There is only a surface-level similarity between the cipher support in .NET and the Java Cryptographic Extension (JCE); however, the basic principles behind both are the same.

Encrypting and Decrypting Data

The .NET Framework supports encryption algorithms that can be broken down into two groups: symmetric and asymmetric. Symmetric algorithms use the same key to encrypt and decrypt data, whereas asymmetric algorithms use a public and a private key.

Symmetric algorithms are usually used to encrypt large amounts of data; the processing ...

Get C# for Java Developers now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.