Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

KeyDerivationAlgorithmProvider.CreateKey | createKey method

Applies to Windows and Windows Phone

Creates a KDF key.

Syntax


var cryptographicKey = keyDerivationAlgorithmProvider.createKey(keyMaterial);

Parameters

keyMaterial

Type: IBuffer

Data used to create the key.

Return value

Type: CryptographicKey

Represents the KDF key.

Examples


public CryptographicKey SampleCreateKDFKey(
    String strAlgName,
    IBuffer buffKeyMaterial)
{
    // Create a KeyDerivationAlgorithmProvider object and open the specified algorithm.
    KeyDerivationAlgorithmProvider objKdfAlgProv = KeyDerivationAlgorithmProvider.OpenAlgorithm(strAlgName);

    // Create a key by using the KDF parameters.
    CryptographicKey key = objKdfAlgProv.CreateKey(buffKeyMaterial);

    return key;
}


Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.Security.Cryptography.Core
Windows::Security::Cryptography::Core [C++]

Metadata

Windows.winmd

See also

KeyDerivationAlgorithmProvider

 

 

Show:
© 2014 Microsoft