[][src]Module ctclient::utils

Some utility functions.

Functions

combine_tree_hash

Calculate sha256(0x01 || left || right)

hex_to_u8

Convert a hex string with no whitespace or other sepreator into &[u8].

largest_power_of_2_smaller_than

For a tree of size n, return the size of the left branch of the root.

sha256

Computes the SHA256 hash of some data.

u8_to_hex

Convert a &[u8] byte array to a lower-case, no-sepreator hex string.