Versions in this module Expand all Collapse all v0 v0.9.2202 Apr 21, 2024 v0.8.2202 Apr 19, 2024 v0.7.2202 Apr 19, 2024retracted v0.6.2010 Oct 12, 2023 v0.5.208 Sep 10, 2023 v0.4.210-rc.2 Jun 30, 2023 v0.4.206 Jul 14, 2023 v0.3.205 Jun 10, 2023 v0.2.196 Feb 14, 2023 v0.2.3 Nov 6, 2022 v0.2.0 Oct 31, 2022 Changes in this version + const HashSize + func CheckRecord(p RecordProof, t int64, th Hash, n int64, h Hash) error + func CheckTree(p TreeProof, t int64, th Hash, n int64, h Hash) error + func FormatRecord(id int64, text []byte) (msg []byte, err error) + func FormatTree(tree Tree) []byte + func ParseRecord(msg []byte) (id int64, text, rest []byte, err error) + func ReadTileData(t Tile, r HashReader) ([]byte, error) + func SplitStoredHashIndex(index int64) (level int, n int64) + func StoredHashCount(n int64) int64 + func StoredHashIndex(level int, n int64) int64 + type Hash [HashSize]byte + func HashFromTile(t Tile, data []byte, index int64) (Hash, error) + func NodeHash(left, right Hash) Hash + func ParseHash(s string) (Hash, error) + func RecordHash(data []byte) Hash + func StoredHashes(n int64, data []byte, r HashReader) ([]Hash, error) + func StoredHashesForRecordHash(n int64, h Hash, r HashReader) ([]Hash, error) + func TreeHash(n int64, r HashReader) (Hash, error) + func (h *Hash) UnmarshalJSON(data []byte) error + func (h Hash) MarshalJSON() ([]byte, error) + func (h Hash) String() string + type HashReader interface + ReadHashes func(indexes []int64) ([]Hash, error) + func TileHashReader(tree Tree, tr TileReader) HashReader + type HashReaderFunc func([]int64) ([]Hash, error) + func (f HashReaderFunc) ReadHashes(indexes []int64) ([]Hash, error) + type RecordProof []Hash + func ProveRecord(t, n int64, r HashReader) (RecordProof, error) + type Tile struct + H int + L int + N int64 + W int + func NewTiles(h int, oldTreeSize, newTreeSize int64) []Tile + func ParseTilePath(path string) (Tile, error) + func TileForIndex(h int, index int64) Tile + func (t Tile) Path() string + type TileReader interface + Height func() int + ReadTiles func(tiles []Tile) (data [][]byte, err error) + SaveTiles func(tiles []Tile, data [][]byte) + type Tree struct + Hash Hash + N int64 + func ParseTree(text []byte) (tree Tree, err error) + type TreeProof []Hash + func ProveTree(t, n int64, h HashReader) (TreeProof, error) v0.1.0-go.1.18.5.beta.3 Aug 11, 2022 v0.1.0-go.1.18.5.beta.2 Aug 11, 2022