Create a new hasher
Search the reference...
/
constructor
The algorithm to use. See algorithms for a list of supported algorithms
Optional key for HMAC. Must be a string or TypedArray. If not provided, the hasher will be a non-HMAC hasher.
Hardware-accelerated cryptographic hash functions
Used for crypto.createHash()
The algorithm chosen to hash the data
The length of the output hash in bytes
List of supported hash algorithms
These are hardware accelerated with BoringSSL
Perform a deep copy of the hasher
Finalize the hash. Resets the CryptoHasher so it can be reused.
DigestEncoding to return the hash in. If none is provided, it will return a Uint8Array.
Finalize the hash and return a Buffer
Finalize the hash
TypedArray to write the hash into. Faster than creating a new one each time
Update the hash with data
Run the hash over the given data
string, Uint8Array, or ArrayBuffer to hash. Uint8Array or ArrayBuffer is faster.
Run the hash over the given data
string, Uint8Array, or ArrayBuffer to hash. Uint8Array or ArrayBuffer is faster.
TypedArray to write the hash into. Faster than creating a new one each time
Run the hash over the given data
string, Uint8Array, or ArrayBuffer to hash. Uint8Array or ArrayBuffer is faster.
DigestEncoding to return the hash in
Resources
ReferenceDocsGuidesDiscordMerch StoreGitHubBlogToolkit
RuntimePackage managerTest runnerBundlerPackage runnerProject
Bun 1.0Bun 1.1Bun 1.2Bun 1.3RoadmapContributingLicenseBaked with ❤️ in San Francisco
We're hiring →CryptoHasher.constructor constructor | Bun module | Bun,AI智能索引,全网链接索引,智能导航,网页索引
- API documentation for constructor bun.CryptoHasher.constructor | Bun