Crate zksync_consensus_crypto

source ·
Expand description

Collection of cryptographic primitives used in zksync-bft repository.

Modules§

  • Currently replaced by [bn254] and unused. This module implements the BLS signature over the BLS12_381 curve. This is just an adapter of blst, exposing zksync-bft-specific API. The implementation is based on the IRTF draft v5.
  • ed25519 signature scheme. This is just an adapter of ed25519_dalek, exposing zksync-bft-specific API.
  • Wrappers for the Keccak256 cryptographic hash algorithm.
  • ECDSA signatures over the Secp256k1 curve, chosen to work with EVM precompiles.

Structs§

  • Utility for parsing human-readable text representations via TextFmt::decode. It keeps a reference to the initial text and a reference to the remaining unparsed text. This allows to provide more context when a parsing error is encountered.

Traits§

  • Trait converting a type from/to a sparse byte format. It is roughly equivalent to serde::Serialize + serde::Deserialize, but has additional requirements:
  • Trait converting a type from/to a human-readable text format. It is roughly equivalent to str::FromStr + std::fmt::Display, but has additional requirements:

Functions§