Click to Rate and Give Feedback
MSDN
MSDN Library
.NET Development
.NET Framework 3.5
HMACSHA384 Class
 ProduceLegacyHmacValues Property

  Switch on low bandwidth view
This page is specific to
Microsoft Visual Studio 2008/.NET Framework 3.5

Other versions are also available for the following:
.NET Framework Class Library
HMACSHA384..::.ProduceLegacyHmacValues Property

Provides a workaround for the .NET Framework version 2.0 implementation of the HMACSHA384 algorithm, which is inconsistent with the .NET Framework version 2.0 Service Pack 1 implementation of the algorithm.

Namespace:  System.Security.Cryptography
Assembly:  mscorlib (in mscorlib.dll)
Visual Basic (Declaration)
Public Property ProduceLegacyHmacValues As Boolean
Visual Basic (Usage)
Dim instance As HMACSHA384
Dim value As Boolean

value = instance.ProduceLegacyHmacValues

instance.ProduceLegacyHmacValues = value
C#
public bool ProduceLegacyHmacValues { get; set; }
Visual C++
public:
property bool ProduceLegacyHmacValues {
    bool get ();
    void set (bool value);
}
JScript
public function get ProduceLegacyHmacValues () : boolean
public function set ProduceLegacyHmacValues (value : boolean)

Property Value

Type: System..::.Boolean
true to enable .NET Framework version 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications; otherwise, false.

The purpose of the ProduceLegacyHmacValues Boolean property is to enable .NET Framework version 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications. When you set this property to true, the HMACSHA384 object produces values that match the values produced by the .NET Framework 2.0. You should set this property only once after you create your HMAC object. You will need to reset your key afterwards, as shown in the following example.

public static void Test()
    {
    HMACSHA384 hmac = new HMACSHA384();
    hmac.ProduceLegacyHmacValues = true;
    hmac.Key = // ...Get the HMAC key.
    // ...
    // Use the HMAC algorithm.
    // ...
    }

For additional information about the changes introduced by .NET Framework 2.0 SP1 to support HMACSHA384 output in the .NET Framework 2.0 environment, see the HMACSHA384 class.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

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

.NET Framework

Supported in: 3.5 SP1, 3.0 SP1, 2.0 SP1
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker