mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
27 lines
656 B
TypeScript
27 lines
656 B
TypeScript
// Type definitions for create-hmac 1.1
|
|
// Project: https://github.com/crypto-browserify/createHmac
|
|
// Definitions by: BendingBender <https://github.com/BendingBender>
|
|
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
|
// TypeScript Version: 2.1
|
|
|
|
/// <reference types="node" />
|
|
|
|
import { Hmac } from 'crypto';
|
|
|
|
export = createHmac;
|
|
|
|
declare function createHmac(algo: createHmac.Algorithm, key: string | Buffer): Hmac;
|
|
|
|
declare namespace createHmac {
|
|
type Algorithm =
|
|
| 'rmd160'
|
|
| 'ripemd160'
|
|
| 'md5'
|
|
| 'sha'
|
|
| 'sha1'
|
|
| 'sha224'
|
|
| 'sha256'
|
|
| 'sha384'
|
|
| 'sha512';
|
|
}
|