deno.land / std@0.157.0 / hash / mod.ts

نووسراو ببینە
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
// Copyright 2018-2022 the Deno authors. All rights reserved. MIT license.
/** **Deprecated**. Use * [Web Crypto](https://developer.mozilla.org/en-US/docs/Web/API/Web_Crypto_API) * or `std/crypto` instead. * * This module is browser compatible. * * @deprecated (will be removed after 0.157.0) Use Web Crypto API or std/crypto instead. * @module */
import { Hash } from "./_wasm/hash.ts";import type { Hasher } from "./hasher.ts";
/** @deprecated (will be removed after 0.157.0) Use Web Crypto API or std/crypto instead. */export type { Hasher } from "./hasher.ts";/** @deprecated (will be removed after 0.157.0) Use Web Crypto API or std/crypto instead. */export const supportedAlgorithms = [ "md2", "md4", "md5", "ripemd160", "ripemd320", "sha1", "sha224", "sha256", "sha384", "sha512", "sha3-224", "sha3-256", "sha3-384", "sha3-512", "keccak224", "keccak256", "keccak384", "keccak512", "blake3", "tiger",] as const;/** @deprecated (will be removed after 0.157.0) Use Web Crypto API or std/crypto instead. */export type SupportedAlgorithm = typeof supportedAlgorithms[number];/** * Creates a new `Hash` instance. * * @param algorithm name of hash algorithm to use * @deprecated (will be removed after 0.157.0) Use Web Crypto API or std/crypto instead. */export function createHash(algorithm: SupportedAlgorithm): Hasher { return new Hash(algorithm as string);}
std

Version Info

Tagged at
a year ago