(gen-tx-hash tx-flakes)
(gen-tx-hash tx-flakes sorted?)
From a list of transaction flakes, returns the sha3 hash.
Note, this assumes the _tx/hash flake is NOT included in this list, else the resulting hash will be different from the one that would have been computed when performing the transaction.
From a list of transaction flakes, returns the sha3 hash. Note, this assumes the _tx/hash flake is NOT included in this list, else the resulting hash will be different from the one that would have been computed when performing the transaction.
(generate-merkle-root & hashes)
hashes should already be in the correct order.
hashes should already be in the correct order.
(get-tx-meta-from-tx txn)
Separates tx-meta from the rest of the transaction. If by chance tx-meta was included twice, will throw an exception.
Separates tx-meta from the rest of the transaction. If by chance tx-meta was included twice, will throw an exception.
(validate-command {:keys [sig cmd]})
Takes a command (map) and validates signature, adds in auth or authority and does some additional checks. This can be done before putting the command into the queue for processing.
Puts original :cmd string and :sig string into this one map for use downstream.
Takes a command (map) and validates signature, adds in auth or authority and does some additional checks. This can be done before putting the command into the queue for processing. Puts original :cmd string and :sig string into this one map for use downstream.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close