Export (0) Print
Expand All

ECDiffieHellmanCng.HashAlgorithm Property

Gets or sets the hash algorithm to use when generating key material.

Namespace:  System.Security.Cryptography
Assembly:  System.Core (in System.Core.dll)

member HashAlgorithm : CngAlgorithm with get, set

Property Value

Type: System.Security.Cryptography.CngAlgorithm
An object that specifies the hash algorithm.

ExceptionCondition
ArgumentNullException

The value is null.

This property is used by Cryptography Next Generation (CNG) objects only if the Hash or Hmac value is set in the KeyDerivationFunction property.

This property accepts the following algorithms: MD5, Sha1, Sha256, Sha384, and Sha512.

Other custom hash algorithms may also be used.

The default algorithm is Sha256.

.NET Framework

Supported in: 4, 3.5

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 7, Windows Vista SP1 or later, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Community Additions

ADD
Show:
© 2015 Microsoft