Honeycomb
0.1
Component-Model Framework
|
Data hashing functions. Produce a small fingerprint from a larger data set. Two data sets may 'collide', producing the same fingerprint. More...
Classes | |
struct | sval |
256-bit secure hash value More... | |
Functions | |
szt | fast (ByteBufConst bs, szt seed=0) |
Quickly generate a small hash value. Each seed value produces a unique hash from the same data. More... | |
sval | secure (ByteBufConst bs, optional< const sval & > key=optnull) |
Generate a large secure hash value. More... | |
vector< sval > | secureKeys (const String &password, const Bytes &salt, int iterCount, int keyCount) |
Generate secure keys derived from a password. More... | |
szt | fast (const char *str, szt seed=0) |
fast() for UTF-8 strings More... | |
szt | fast (const std::string &str, szt seed=0) |
fast() for UTF-8 strings More... | |
szt | fast (const String &str, szt seed=0) |
fast() for strings, converted to UTF-8 before hashing More... | |
constexpr szt | fast_ (const char *str, szt len, szt seed=0) |
Compile-time version of fast() for UTF-8 strings. More... | |
sval | secure (const char *str, optional< const sval & > key=optnull) |
secure() for UTF-8 strings More... | |
sval | secure (const std::string &str, optional< const sval & > key=optnull) |
secure() for UTF-8 strings More... | |
sval | secure (const String &str, optional< const sval & > key=optnull) |
secure() for strings, converted to UTF-8 before hashing More... | |
Data hashing functions. Produce a small fingerprint from a larger data set. Two data sets may 'collide', producing the same fingerprint.
fast() for strings, converted to UTF-8 before hashing
szt honey::hash::fast | ( | ByteBufConst | bs, |
szt | seed | ||
) |
Quickly generate a small hash value. Each seed value produces a unique hash from the same data.
Compile-time version of fast() for UTF-8 strings.
sval honey::hash::secure | ( | ByteBufConst | bs, |
optional< const sval & > | key = optnull |
||
) |
Generate a large secure hash value.
bs | |
key | Generate a keyed HMAC that can be used to verify message authenticity. Each key produces a unique hash from the same data. |
secure() for UTF-8 strings
secure() for UTF-8 strings
secure() for strings, converted to UTF-8 before hashing
vector< sval > honey::hash::secureKeys | ( | const String & | password, |
const Bytes & | salt, | ||
int | iterCount, | ||
int | keyCount | ||
) |
Generate secure keys derived from a password.
password | |
salt | randomly generated value to combat precomputed hash table attacks |
iterCount | number of PBKDF2 hash iterations, makes process computationally expensive to attack |
keyCount | number of returned keys |