From bf155ab82f18e7aae5d02e0b500da081e9de4f52 Mon Sep 17 00:00:00 2001 From: shiyuesong Date: Wed, 13 Dec 2017 20:49:21 +0800 Subject: [PATCH] Added "hmac" to interface Hash. (#12) --- index.d.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/index.d.ts b/index.d.ts index 3ac12ed..da11b96 100644 --- a/index.d.ts +++ b/index.d.ts @@ -53,6 +53,14 @@ interface Hash { * @param message The message you want to hash. */ update(message: Message): Hasher; + + /** + * Computes a Hash-based message authentication code (HMAC) using a secret key + * + * @param secretKey The Secret Key + * @param message The message you want to hash. + */ + hmac(secretKey: string, message: Message): string; } export var sha256: Hash;