Data encoding, hash and uuid methods


_ <- fat.zcode


Name Signature Brief
getHash (msg: Text): Number Get 32-bit hash of text
getUuid (): Text Generate a UUID (version 4)
encrypt (msg: Text, key: Text = ø): Text Encode msg to zCode using key
decrypt (msg: Text, key: Text = ø): Text Decode zCoded msg using key

Usage Notes

You can omit or pass a blank key '' for using the default key.

Heads Up!

Although zCode makes encoded text "non-human-readable", this schema is not cryptographically safe! DO NOT use it alone to protect data!

If paired with a custom key that is not stored alongside the message it may offer some data protection.

UUID method conformance

A UUID, or Universally Unique Identifier, is a 128-bit number used to identify objects or entities in computer systems. The provided implementation generates random UUIDs as text that follow the format of version 4 RFC 4122 specification, but does not strictly adhere to the required cryptographically secure randomness. In practice, the collision risk has an extremely low probability and is very unlikely to occur, and for most applications can be considered good enough.

See also

results matching ""

    No results matching ""