8.2 KiB
3.2.0
added
- Added
address.fromBech32/toBech32
(#846)
3.1.0
added
- Added
Transaction.prototype.virtualSize
(#811) - Added
Transaction.prototype.weight
(#811)
3.0.0
From this release users can expect out-of-the-box Segregated Witness support.
The majority of breaking changes have been in how script
encoding/decoding occurs, with the introduction of witness stacks.
added
- Added
script.types
enums (#679) - Added
script.*.*.{check,encode,decode[,encodeStack,decodeStack]}
functions (#681, #682) - Added minimal
TransactionBuilder.prototype.build
absurd fee-safety (#696) - Added
script.(decompile/compile)PushOnly
andscript.toStack
functions (#700) - Added
Transaction.prototype.toBuffer
Segregated Witness serialization support (#684, #701) - Added
Transaction.prototype.hasWitnesses
(#718) - Added
script.witnessCommitment.*
template - Added
TransactionBuilder.prototype.sign
now has two additional parameters,witnessValue
, andwitnessScript
- Added
Transaction.hashForWitnessV0
andTransaction.setWitness
(5c2fdb6043
)
fixed
- Fixed
script
must compile minimally (#638) - Fixed
Transaction
andBlock
versions should be Int32, signed integers (#662)
removed
- Removed
ecdsa.calcPubKeyRecoveryParam
,ecdsa.recoverPubKey
(#456) - Removed
buffer-equals
/buffer-compare
dependencies (#650) - Removed
HDNode.prototype.toString
(#665) - Removed
dogecoin
network (#675) - Removed
message
export, moved tobitcoinjs-message
(#456)
renamed
- Removed
script.*
functions in favour ofbitcoin.script.*.(input/output).(encode/decode/check)
style (#682)
2.3.0
added
- Added
HDNode.prototype.isNeutered
(#536) - Added
HDNode.prototype.derivePath
(#538) - Added typeforce checking for
HDNode.prototype.derive*
(#539) - Added
Transaction.prototype.isCoinbase
(#578) - Added
Block.prototype.checkMerkleRoot
(#580) - Added
Block.calculateMerkleRoot
(#580) - Added
TransactionBuilder.prototype.setVersion
(#599) - Added
script.isWitnessPubKeyHashOutput
(#602) - Added
script.isWitnessScriptHashOutput
(#602) - Added
script.witnessPubKeyHashOutput
(#602) - Added
script.witnessScriptHashOutput
(#602) - Added
script.witnessScriptHashInput
(#602)
fixed
- Fixed "BIP32 is undefined" when network list given to
HDNode
but no compatible version found (#550) - Fixed
writePushDataInt
output to adhere to minimal data push policy (#617)
2.2.0
added
- Added
Block.calculateTarget
for difficulty calculations (#509) - Added
Block.prototype.checkProofOfWork
(#509) - Added
opcodes.OP_CHECKLOCKTIMEVERIFY
alias forOP_NOP2
(#511) - Added
script.number.[encode/decode]
for CScriptNum-encodedBuffer
s (#516) - Added
TransactionBuilder.prototype.setLockTime
(#507)
fixed
- Bumped
typeforce
version to fix erroneous error message fromtypes.Hash*bit
types (#534)
2.1.4
fixed
- script.isPubKeyHashOutput and script.isScriptHashOutput no longer allow for non-minimal data pushes (per bitcoin/bitcoin
IsStandard
policy) (#499) - TransactionBuilder.addOutput now allows for SIGHASH_SINGLE, throwing if the contract is violated (#504)
- remove use of
const
, use ES5 only (#502)
2.1.3
fixed
- Bumped typeforce to 1.5.5 (see #493)
2.1.2
fixed
- Add missing CHANGELOG entry for 2.1.1
2.1.1
changed
- removed use of
buffer-reverse
, dependency only kept forbufferutils.reverse
, to be deprecated (#478)
fixed
isMultisigOutput
no longer allows data chunks form
/n
(#482)isMultisigOutput
'sn
value must now match the number of public keys (as per bitcoin/bitcoin) (#484)
2.1.0
From this release users should use the HDNode directly (compared to accessing .keyPair
) when performing ECDSA operations such as sign
or verify
.
Ideally you shoud not have to directly access HDNode
internals for general usage, as it can often be confusing and error prone.
added
ECPair.prototype.getNetwork
HDNode.prototype.getNetwork
, wraps the underyling keyPair'sgetNetwork
methodHDNode.prototype.getPublicKeyBuffer
, wraps the underyling keyPair'sgetPublicKeyBuffer
methodHDNode.prototype.sign
, wraps the underlying keyPair'ssign
methodHDNode.prototype.verify
, wraps the underlying keyPair'sverify
method
2.0.0
In this release we have strived to simplify the API, using native types wherevever possible to encourage cross-compatibility with other open source community modules.
The ecdsa
module has been removed in lieu of using a new ECDSA module (for performance and safety reasons) during the 2.x.y
major release.
Several other cumbersome modules have been removed, with their new independent modules recommended for usage instead for greater modularity in your projects.
Backward incompatible changes:
added
- export
address
, foraddress
based utility functions, most compatible, just withoutAddress
instantiation, see #401, #444 - export
script
, forscript
based utility functions, mostly compatible, just withoutScript
instantiation, see #438, #444 - export
ECPair
, a merged replacement forECKey
/ECPubKey
, invalid types will throw viatypeforce
changed
-
address.toOutputScript
,ECPair.prototype.fromWIF
andHDNode.prototype.fromBase58
no longer automatically detect the network,networks.bitcoin
is always assumed unless given. -
assert
was used for type checking, now replaced bytypeforce
-
BIP66
compliant strict DER signature validation was added toECSignature.fromDER
, changing the exact exception messages slightly, see #448. -
new HDNode(d/Q, chainCode, network)
->new HDNode(keyPair, chainCode)
, now usesECPair
-
HDNode.prototype.toBase58(false)
->HDNode.prototype.neutered().toBase58()
for exporting an extended public key -
HDNode.prototype.toBase58(true)
->HDNode.prototype.toBase58()
for exporting an extended private key -
Transaction.prototype.hashForSignature(prevOutScript, inIndex, hashType)
->Transaction.prototype.hashForSignature(inIndex, prevOutScript, hashType)
-
Transaction.prototype.addInput(hash, ...)
:hash
could be a string, Transaction or Buffer ->hash
can now only be aBuffer
. -
Transaction.prototype.addOutput(scriptPubKey, ...)
:scriptPubKey
could be a string,Address
or aBuffer
->scriptPubKey
can now only be aBuffer
. -
TransactionBuilder
API unchanged.
removed
-
export
Address
,strings
are now used, benchwith no performance loss for most use cases -
export
base58check
, usebs58check
instead -
export
ecdsa
, useecurve
instead -
export
ECKey
, use new exportECPair
instead -
export
ECPubKey
, use new exportECPair
instead -
export
Wallet
, see README.md#complementing-libraries instead -
export
Script
, use new utility exportscript
instead (#438 for more information) -
crypto.HmacSHA256
, use node crypto instead -
crypto.HmacSHA512
, use node crypto instead -
Transaction.prototype.sign
, useTransactionBuilder.prototype.sign
-
Transaction.prototype.signInput
, useTransactionBuilder.prototype.sign
-
Transaction.prototype.validateInput
, useTransaction.prototype.hashForSignature
andECPair.verify
-
HDNode.fromBuffer
, useHDNode.fromBase58
instead -
HDNode.fromHex
, useHDNode.fromBase58
instead -
HDNode.toBuffer
, useHDNode.prototype.toBase58
instead -
HDNode.toHex
, useHDNode.prototype.toBase58
instead -
networks.*.magic
, see the comment here -
networks.[viacoin|viacointestnet|gamerscoin|jumbucks|zetacoin]
, import these yourself (see #383/a0e6ee7) -
networks.*.estimateFee
, out-dated
renamed
Message
->message
scripts
->script
scripts.dataOutput
->script.nullDataOutput
(per convention)