modulepackage
0.0.0-20210121151755-f6208871c388
Repository: https://github.com/prysmaticlabs/go-ssz.git
Documentation: pkg.go.dev
# README
DEPRECATED
⛔️This project is no longer supported and actively discouraged! ⛔️ Please use fastssz instead. This repository is known to have security issues, bugs, and be extremely inefficient. If you use this project, YOU RUN SERIOUS RISKS.
Simple Serialize (SSZ)
Simple Serialize is the serialization algorithm standard for all data structures common across Ethereum 2.0 client implementations. It is outlined in the official Ethereum 2.0 specification.
# Functions
DeepEqual reports whether two SSZ-able values x and y are ``deeply equal,'' defined as follows: Two values of identical type are deeply equal if one of the following cases applies:
Values of distinct types are never deeply equal.
HashTreeRoot determines the root hash using SSZ's Merkleization.
HashTreeRootBitfield determines the root hash of a bitfield type using SSZ's Merkleization.
HashTreeRootWithCapacity determines the root hash of a dynamic list using SSZ's Merkleization and applies a max capacity value when computing the root.
Marshal a value and output the result into a byte slice.
SigningRoot truncates the last property of the struct passed in and returns its tree hash.
Unmarshal SSZ encoded data and output it into the object pointed by pointer val.