@dekkonot/sha384
v1.0.1
Published
Implementation of the SHA-384 hashing algorithm
Downloads
3
Readme
SHA-384 Luau
A pure Luau implementation of the SHA-384 hashing algorithm. Blazing fast (for Luau) and well-tested.
Note that due to limitations with Luau, this module is substantially slower than it would be with native 64-bit integers. It is as fast as it can reasonably be in Luau though.
API
This module returns a single function with the following type signature:
sha384(message: string): (string, {number})
The message
passed to this function will be hashed using the hashing algorithm. The hash is returned in two forms:
- As a sequence of 96 hexadecimal digits
- A read-only array of twelve 32-bit words that represent the hash.
In the returned array, the first word represents the most significant half of the first 'real' word of the hash, and the second word represents the least significant half. This pattern repeats for the remaining 10 words.