package
0.1.0
Repository: https://github.com/gatechain/crypto.git
Documentation: pkg.go.dev

# README

Files in this package were copied from Google's (Apache-licensed) Trillian package (github.com/google/trillian) and modified by us to avoid needing to import the entire trillian package

# Packages

nolint: dupl dupl is reading this as the same file as crypto/merkle/result.go.
No description provided by the author

# Functions

DefaultProofRuntime only knows about Simple value proofs.
Decode a path to a list of keys.
New creates a new Hashers.LogHasher on the passed in hash function.
NewInMemoryMerkleTree creates a new empty Merkle Tree using the specified Hasher.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Order returns whether one byte slice is greater than another it returns true if a < b.
Root returns the root of a merkle tree with the leaves given as input.
SimpleHashFromByteSlices computes a Merkle tree where the leaves are the byte slice, in the provided order.
SimpleHashFromByteSliceIterative is an iterative alternative to SimpleHashFromByteSlice motivated by potential performance improvements.
SimpleHashFromMap computes a Merkle tree from sorted map.
SimpleProofsFromByteSlices computes inclusion proof for given items.
SimpleProofsFromMap generates proofs from a map.
No description provided by the author

# Constants

No description provided by the author
Number of known encodings.
No description provided by the author
Domain separation prefixes.
Domain separation prefixes.
No description provided by the author

# Variables

XXX TODO make SHA512_256 and update test vectors.
No description provided by the author
No description provided by the author

# Structs

Hasher implements the RFC6962 tree hashing algorithm but with SHA512-256 instead of SHA256.
InMemoryMerkleTree holds a Merkle Tree in memory as a 2D node array.
No description provided by the author
Proof is Merkle proof defined by the list of ProofOps.
ProofOp defines an operation used for calculating Merkle root The data could be arbitrary format, providing nessecary data for example neighbouring node hash.
No description provided by the author
SimpleProof represents a simple Merkle proof.
SimpleProofNode is a helper structure to construct merkle proof.
SimpleValueOp takes a key and a single value as argument and produces the root hash.
TreeEntry is used for nodes in the tree for better readability.
TreeEntryDescriptor wraps a node and is used to describe tree paths, which are useful to have access to when testing the code and examining how it works.

# Interfaces

ProofOperator is a layer for calculating intermediate Merkle roots when a series of Merkle trees are chained together.
Tree is a Merkle tree interface.

# Type aliases

No description provided by the author
A local extension to KVPair that can be hashed.
No description provided by the author
ProofOperators is a slice of ProofOperator(s).