- Add
Amount
andSignedAmount
types. - Add BIP-158 support with
BlockFilter
and related types. - Add
util::misc::signed_msg_hash()
for signing messages. - Add
MerkleBlock
andPartialMerkleTree
types. - bip32: Support serde serializaton for types and add some utility methods:
ChildNumber::increment
DerivationPath::children_from
DerivationPath::normal_children
DerivationPath::hardened_children
- Add
blockdata::script::Builder::push_verify
to verify-ify an opcode. - Add
sendheaders
network message. - Add
OutPoint::new()
method and JSON-serialize as<txid>:<vout>
. - Refactor
Address
type:- Now supports segwit addresses with version >0.
- Add
Address::from_script
constructor. - Add
Address::address_type
inspector. - Parsing now returns an
address::Error
instead ofencode::Error
. - Removed
bitcoin_bech32
dependency for bech32 payloads.
- bip143: Rename
witness_script
toscript_code
- Rename
BlockHeader::spv_validate
tovalidate_pow
- Rename
OP_NOP2
andOP_NOP3
toOP_CLTV
andOP_CSV
- psbt: Use
BTreeMap
instead ofHashMap
to ensure serialization roundtrips. - Drop
Decimal
type. - Drop
LoneHeaders
type. - Replace
strason
dependency with (optional)serde_json
. - Export the
bitcoin_hashes
andsecp256k1
dependent crates. - Updated
bitcoin_hashes
dependency to v0.7. - Removed
rand
andserde_test
dependencies. - Internal improvements to consensus encoding logic.
- Update
bitcoin-bech32
version to 0.9 - add
to_bytes
method forutil::key
types - add serde impls for
util::key
types - contracthash: minor cleanups, use
util::key
types instead ofsecp256k1
types
- Add some trait impls to
PublicKey
for miniscript interoperability
- Update minimum rustc version to 1.22.
- Replace
rust-crypto
withbitcoin_hashes
; refactor hash types - Remove
Address::p2pk
- Remove misleading blanket
MerkleRoot
implementation; it is now only defined forBlock
- Add BIP157 (client-side block filtering messages)
- Allow network messages to be deserialized even across multiple packets
- Replace all key types to better match abstractions needed for PSBT
- Clean up BIP32 in preparation for PSBT; use new native key types rather than
secp256k1
ones - Remove apparently-used
Option
serialization code - Finally merge PSBT after nearly nine months
- Reorganize opcode types to eliminate unsafe code
- Un-expose some macros that were unintentionally exported
- Update rust-secp256k1 dependency to 0.12
- Remove
util::iter::Pair
type which does not belong in this library - Minor bugfixes and optimizations
- Significant API overhaul:
- Remove
nu_select
macro and low-level networking support - Move
network::consensus_params
toconsensus::params
- Move many other things into
consensus::params
- Move
BitcoinHash
fromnetwork::serialize
toutil::hash
; remove impl forVec<u8>
- Rename/restructure error types
- Rename
Consensus{De,En}coder
toconsensus::{De,En}coder
- Replace
Raw{De,En}coder
with blanket impls ofconsensus::{De,En}coder
onio::Read
andio::Write
- make
serialize
andserialize_hex
infallible
- Remove
- Make 0-input transaction de/serialization always use segwit
- Implement
FromStr
andDisplay
for many more types
- Add serde support for
Address
- Reject non-compact
VarInt
s on various types - Expose many types at the top level of the crate
- Add
Ord
,PartialOrd
impls forScript
- Add regtest network to
Network
enum - Add
Script::is_op_return()
which is more specific thanScript::is_provably_unspendable()
- Update to bech32 0.8.0; add Regtest bech32 address support
- Replace rustc-serialize dependency with hex as a stopgap toward eliminating any extra dependencies for this; clean up the many independent hex encoders and decoders throughout the codebase.
- Add conversions between
ChildNumber
andu32
; make representation non-public; fix documentation - Add several derivation convenience to
bip32
extended keys - Make
deserialize::deserialize()
enforce no trailing bytes - Replace
TxOutRef
withOutPoint
; use it inTxIn
struct. - Use modern
as_
to_
into_
conventions for array-wrapping types; implDisplay
rather thanToString
for most types - Change
script::Instructions
iterator to allow rejecting non-minimal pushes; fix bug where errors would iterate forever. - Overhaul
util::Error
; introduceserialize::Error
and use it forSimpleDecoder
andSimpleDecoder
rather than parameterizing these over their error type. - Overhaul
UDecimal
andDecimal
serialization and parsing and fix many lingering parsing bugs - Update to serde 1.0 and strason 0.4
- Update to secp256k1 0.11.0
- Many, many documentation and test improvements.
- Add
Display
trait to uints,FromStr
trait toNetwork
enum - Add witness inv types to inv enum, constants for Bitcoin regtest network,
is_coin_base
accessor for tx inputs - Expose
merkleroot(Vec<Sha256dHash>)
- Move witnesses inside the
TxIn
structure - Add
Transaction::get_weight()
- Update bip143
sighash_all
API to be more ergonomic
- The in-memory blockchain was moved into a dedicated project rust-bitcoin-chain.
- Removed old script interpreter
- A new optional feature "bitcoinconsensus" lets this library use Bitcoin Core's native
script verifier, wrappend into Rust by the rust-bitcoinconsenus project.
See
Transaction::verify
andScript::verify
methods. - Replaced Base58 traits with
encode_slice
,check_encode_slice
, from andfrom_check
functions in the base58 module. - Un-reversed the Debug output for Sha256dHash
- Add bech32 support
- Support segwit address types
- Remove
num
dependency at Matt's request; agree this is obnoxious to require all downstream users to also have anum
dependency just so they can useUint256::from_u64
.