Documentation ¶
Index ¶
Constants ¶
View Source
const ( // HashSize is the size in bytes of an AddressHash. HashSize = sha256.Size // AddressSize is the size of a pubkey address. AddressSize = 20 )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Address ¶
An address is a []byte, but hex-encoded even in JSON. []byte leaves us the option to change the address length. Use an alias so Unmarshal methods (with ptr receivers) are available too.
func AddressHash ¶
AddressHash computes a truncated SHA-256 hash of bz for use as a peer address.
See: https://docs.tendermint.com/master/spec/core/data_structures.html#address
type BatchVerifier ¶
type BatchVerifier interface { // Add appends an entry into the BatchVerifier. Add(key PubKey, message, signature []byte) error // Verify verifies all the entries in the BatchVerifier, and returns // if every signature in the batch is valid, and a vector of bools // indicating the verification status of each signature (in the order // that signatures were added to the batch). Verify() (bool, []bool) }
If a new key type implements batch verification, the key type must be registered in github.com/ari-anchor/sei-tendermint/crypto/batch
Click to show internal directories.
Click to hide internal directories.