System.Web 2.0.0.0 System.Enum

ASP.NET uses a hash-based message authentication code (HMAC) to help detect whether data that is used for forms authentication or view state has been tampered with. The HMAC is generated when view state content is created, and the HMAC is checked on subsequent requests. The HMAC helps ASP.NET determine whether someone has changed data that is sent between the server and the client, but the data can be read by anyone as it travels through the Internet unless it is also encrypted. By default, view state is validated but not encrypted. For more information, see and .

The enumeration lets you specify the algorithm that ASP.NET uses to create the HMAC. The default value is . ASP.NET uses the value of the property with the selected algorithm to generate the HMAC.

Specifies the hashing algorithm that ASP.NET uses for forms authentication and for validating view state data, and for out-of-process session state identification.

- Field
  System.Web.Configuration.MachineKeyValidation

  Choose this option if you want to encrypt view state in your Web application. If you choose this option, the property will be used for encryption and decryption, and the HMACSHA1 hash algorithm will be used with the property for validation.

  Specifies that ASP.NET uses the AES (Rijndael) encryption algorithm.

  2.0.0.0
- Field
  System.Web.Configuration.MachineKeyValidation

  MD5 is a hashing algorithm that generates a 128-bit hash value. This option is included for legacy purposes and should be selected only if compatibility with earlier versions of ASP.NET is required.

  Specifies that ASP.NET uses the Message Digest 5 (MD5) hashing algorithm.

  2.0.0.0
- Field
  System.Web.Configuration.MachineKeyValidation

  HMACSHA1 is a hashing algorithm that generates a 160-bit hash value. This option is included for legacy purposes and should be selected only if compatibility with earlier versions of ASP.NET is required.

  Specifies that ASP.NET uses the HMACSHA1 hash algorithm.

  2.0.0.0
- Field
  System.Web.Configuration.MachineKeyValidation

  TripleDES is an encryption algorithm that is used only if you specify that view state is encrypted. This option is included for legacy purposes and should be selected only if compatibility with earlier versions of ASP.NET is required.

  Specifies that ASP.NET uses the TripleDES (3DES) encryption algorithm.

  2.0.0.0