Documentation home / Native Module API
Native Module API
Non-cryptographic Hash Functions
FNV-1a and DJB2 hashes with a hash-comparison helper.
Purpose
FNV-1a and DJB2 hashes with a hash-comparison helper.
Exports registered by the module initializer
| Export | Role |
|---|---|
fnv1a | fnv1a helper |
djb2 | djb2 helper |
same_hash | same hash helper |
Usage
import gs_hash;
print(gs_hash.fnv1a("greenServeFE"));
print(gs_hash.djb2("greenServeFE"));
print(gs_hash.same_hash("greenServeFE", "greenServeFE"));These are not cryptographic hashes. Do not use for password storage, authentication, signatures or security checks.
Related: Module catalog · Native ABI · Language guide.
greenServeFE