Table of Contents

Method CreateHmac

Namespace
DocWright.Cryptography
Assembly
DocWright.Cryptography.dll

CreateHmac(OfficeHashAlgorithmKind, byte[])

Creates a keyed HMAC instance.

public static HMAC CreateHmac(OfficeHashAlgorithmKind kind, byte[] key)

Parameters

kind OfficeHashAlgorithmKind

The underlying hash algorithm.

key byte[]

The HMAC key.

Returns

HMAC

A new instance the caller must dispose.

Exceptions

ArgumentNullException

key is null.

UnsupportedFeatureException

The algorithm is not implemented, or the platform refuses it.