Releases: chaintope/bitcoinrb
v1.5.0 release
This release includes the followings:
New features
- Add implementation of the cryptographic parts of BIP-324 Version 2 P2P Encrypted Transport Protocol. Both ruby and libsepc256k1 implementation.
Other changes
libsecp256k1.dylib
for macOS used in unit tests has been removed. you want to test using libsecp256k1 in an environment other than Linux, please set the path of the libsecp256k1 library to the environment variableTEST_LIBSECP256K1_PATH
.- Now compatible with libsecp256k1 v0.4.0.
- Refactor test case to use shared_example.
- Update bip-schnorr gem from 0.5.0 to 0.7.0.
- Update ecdsa_ext gem from 0.5.0 to 0.5.1. Accordingly, the monkey patch for
ECDSA::Point#to_hex
has been removed.
Bug fix
- Fix a bug where valid signatures would fail to be verified in
Bitcoin::MessageSign#verify_message
. This bug only affects you if you use the Ruby implementation of this library instead of libsecp256k1.
Full Changelog: v1.4.0...v1.5.0
v1.4.0 release
This release includes the following changes:
New Feature
- Add
Bitcoin::Script#p2pk?
method to check whether script is P2PK or not.
Bug Fix
- Fixed a bug where a Key object with a compressed public key was returned even if
TYPES[:uncompressed]
was specified forkey_type
in theBitcoin::Key#generate
method. - Fixed a bug where an error occurred in the
Bitcoin::Script#multisig?
method when the number of signatures was an invalid value.
Removed feature
We have deprecated support for the BIP-70 Payment Protocol, as it has also been removed from Bitcoin Core. Along with this, the dependency on activesupport
is removed.
Full Changelog: v1.3.0...v1.4.0
v1.3.0 release
This release includes the following changes:
- Add
Bitcoin::PSBT::Tx#to_h
method to output each PSBT data in Hash format. - Add
decodepsbt
option inbitcoinrb-cli
to decode Base64-format PSBT into JSON format. - Return address of
Bitcoin::Script#to_h
changed to return a single address. - Add BIP-322 message signing.
- Elliptic curve operations changed to be performed in Jacobian coordinates using ecdsa_ext gem and bip-schnorr gem v 0.5.0.
- Add private key length check in
Bitcoin::Key#new
.
An incorrect public key was derived if a private key was specified with dropped digits that were not exactly 32 bytes and libsecp256k1 was used. This check ensures that an exception is thrown in such cases. The following code, which could also cause such cases, has been corrected:Bitcion::ExtPubkey#derive
Bitcion::Taproot#tweak_private_key
Full Changelog: v1.2.1...v1.3.0
v1.2.0 release
This release contains following changes:
- Add support for
Taproot Fields for PSBT
(BIP-371) - Add
Bitcoin::Script#to_p2tr
which creates P2TR script pubkey using xonly public key - Add
Bitcoin::Key#to_addr
which returns address correspond to key_type value and #to_p2tr which generates P2TR address - Some refactorings
See below for a complete list of changes:
Full Changelog: v1.1.1...v1.2.0
v1.1.1 release
This release fixes the following issues that occur in Ruby 3.1
psych 4.0.0 is now bundled with Ruby 3.1. Psych.load
has been incompatible since psych 4.0.0. Accordingly, YAML.load
has also become incompatible.
In bitcoinrb, YAML.load
is used to load network settings in Bitcoin::ChainParams
. This results in an error in Bitcoin::ChainParams
when using bitcoinrb with Ruby 3.1.
This release resolves the error by using YAML.unsafe_load
instead of YAML.load
in Ruby 3.1+.
Full Changelog: v1.1.0...v1.1.1
v1.1.0 release
The following change are included in this release:
- Compliant with the BIP-174 specification for PSBT:
We have been providing PSBT feature for some time now, but several keys have since been added to BIP-174. This release supports the following keys that have been added:PSBT_GLOBAL_PROPRIETARY
PSBT_IN_PROPRIETARY
PSBT_OUT_PROPRIETARY
PSBT_IN_RIPEMD160
PSBT_IN_SHA256
PSBT_IN_HASH160
PSBT_IN_HASH256
- Replace extension of
Object#build_json
andto_h
by open class with refinement(e4d4968).
Full Changelog: v1.0.0...v1.1.0
v1.0.0 release
The following change are included in this release:
Taproot-related flags are now standard
The following flags when processing scripts are now standard flags:
- SCRIPT_VERIFY_TAPROOT
- SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_TAPROOT_VERSION
- SCRIPT_VERIFY_DISCOURAGE_OP_SUCCESS
- SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_PUBKEYTYPE
In previous versions, these flags had to be explicitly set when evaluating Taproot-related scripts.
v0.9.0 release
The following fixes and improvements are included in this release:
Bitcoin::PSBT
supports PSBT data read from file and write to file.Bitcoin::Taproot::SimpleBuilder
change following:- The interface that receives script and leaf version has been changed to an interface that receives
Bitcoin::Taproot::LeafNode
. Bitcoin::Taproot
provides some utility methods to help spending P2TR.
- The interface that receives script and leaf version has been changed to an interface that receives
For more detail about how to build and spend P2TR, see the Wiki page.
v0.8.0 release
The following fixes and improvements are included in this release:
- Add strict data check for transaction parsing(8e3f985)
- Accelerating taproot testing through parallel execution
- Speed up to use libsecp256k1 with
Bitcoin::ExtPubkey#derive
same asExtKey#derive
(b3b2ec9) - Implement Bitcoin::MessageSign that sign any message using key(see wiki)
- Add
Bitcoin::Script#p2tr?
which check script whether P2TR or not(f164afe) - Add
Bitcoin::Taproot::SimpleBuilder
to support building Taproot P2TR and creating transactions when spending it.
v0.7.0 release
This release includes the following improvements and features:
P2P
The new P2P messages sendaddrv2
and addrv2
defined in BIP-155 have been added.
Bitcoin::Message::SendAddrV2
Bitcoin::Message::AddrV2
In addition, the following features have been added that are useful for handling P2P messages.
Bitcoin::Message::Base#from_pkt(message)
: This method decodes a single P2P message containing the magic bytes and creates an instance of the corresponding message class.Bitcoin::Message#decode(command, payload)
: This method creates an instance of the corresponding message class from the P2P command and payload specified in the arguments.
Improvements
- Improve
String#opcode
performance: The performance ofString#opcode
, which is extended with open classes, has been improved. It used to convert all data to bytes, but nowString#ord
is executed after specifying the character encoding. This change is not expected to have any impact, but if it does, please report it. - Update the dependent library bech32rb: The version of the dependent library bech32rb has been updated to v1.1.0. It now supports bech32m, the Taproot address encoding.