Expand description
Rust Elements Library
Extensions to rust-bitcoin
to support deserialization and serialization
of Elements transactions and blocks.
Re-exports
pub extern crate bitcoin;
pub extern crate secp256k1_zkp;
pub use bitcoin::bech32;
pub use bitcoin::hashes;
pub use address::Address;
pub use address::AddressParams;
pub use address::AddressError;
pub use hash_types::*;
pub use issuance::AssetId;
pub use issuance::ContractHash;
pub use script::Script;
pub use sighash::SchnorrSigHashType;
pub use schnorr::SchnorrSig;
pub use schnorr::SchnorrSigError;
Modules
Addresses
Blech32
Confidential Commitments
Dynamic Federations
Consensus-encodable types
File defines types for hashes used throughout the library. These types are needed in order to avoid mixing data of the same hash format (like SHA256d) but of different meaning (transaction id, block hash etc).
Asset Issuance
Opcodes
Partially Signed Elements Transactions (PSET)
Schnorr Bitcoin keys.
Script
BIP143 Implementation
Implemenation of SLIP-0077: Deterministic blinding key derivation for Confidential Transactions
Taproot
Structs
Description of an asset issuance in a transaction input
Elements block
Elements block header
A reference to a transaction output
Parsed data from a transaction input’s pegin witness
Information about a pegout
Elements transaction
A transaction input, which defines old coins to be consumed
Transaction input witness
Transaction output
Information about Transaction Input Asset
Transaction output witness
A variable-length unsigned integer
Enums
Errors encountered when blinding transaction outputs.
Data related to block signatures
Errors encountered when constructing confidential transaction outputs.
Hashtype of a transaction, encoded in the last byte of a signature Fixed values so they can be casted as integer types for encoding
Transaction Output related errors
Errors encountered when unblinding TxOut
s.
Transaction Verification Errors
Functions
Compute the Merkle root of the give hashes using mid-state only. The inputs must be byte slices of length 32. Note that the merkle root calculated with this method is not the same as the one computed by a normal SHA256(d) merkle root.