|
1 | 1 | # `@bitauth/libauth`
|
2 | 2 |
|
| 3 | +## 3.0.0 |
| 4 | + |
| 5 | +### Major Changes |
| 6 | + |
| 7 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - Add support for relative BIP32 derivation |
| 8 | + |
| 9 | + Relative BIP32 Hierarchical Deterministic (HD) derivation is now supported via the [`deriveHdPathRelative`](https://libauth.org/functions/deriveHdPathRelative.html) utility, and the Libauth compiler has been updated to explicitly use relative derivation by default for `HdKey`s. Absolute derivation has also been enhanced to validate the expected depth of provided HD keys. |
| 10 | + |
| 11 | + If you application relies on relative derivation but uses [`deriveHdPath`](https://libauth.org/functions/deriveHdPath.html), you'll need to switch to using the new [`deriveHdPathRelative`](https://libauth.org/functions/deriveHdPathRelative.html), as absolute derivation will now fail if provided with a non-zero depth HD key. |
| 12 | + |
| 13 | + Fixes [#49](https://github.com/bitauth/libauth/issues/49). |
| 14 | + |
| 15 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - CashAssembly: `.signature` is now `.ecdsa_signature` |
| 16 | + |
| 17 | + All CashAssembly scripts using the `.signature` operation should instead call `.ecdsa_signature` or switch to `.schnorr_signature`. |
| 18 | + |
| 19 | + Additionally, `signing_serialization.token_prefix` is now available. |
| 20 | + |
| 21 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - Unify object parameters and error handling across library |
| 22 | + |
| 23 | + A number of existing Libauth utilities have been modified to adhere to Libauth's object parameter and error handling conventions: |
| 24 | + |
| 25 | + - CashAddress utilities: |
| 26 | + - [`encodeCashAddress`](https://libauth.org/functions/encodeCashAddress.html)/[`decodeCashAddress`](https://libauth.org/functions/decodeCashAddress.html) |
| 27 | + - [`lockingBytecodeToCashAddress`](https://libauth.org/functions/lockingBytecodeToCashAddress.html)/[`cashAddressToLockingBytecode`](https://libauth.org/functions/cashAddressToLockingBytecode.html) |
| 28 | + - [`encodeCashAddressFormat`](https://libauth.org/functions/encodeCashAddressFormat.html)/[`decodeCashAddressFormat`](https://libauth.org/functions/decodeCashAddressFormat.html) |
| 29 | + - BIP32 (HD Key) utilities: |
| 30 | + - [`crackHdPrivateNodeFromHdPublicNodeAndChildPrivateNode`](https://libauth.org/functions/crackHdPrivateNodeFromHdPublicNodeAndChildPrivateNode.html) |
| 31 | + - [`decodeHdKey`](https://libauth.org/functions/decodeHdKey.html) ([`decodeHdKeyUnchecked`](https://libauth.org/functions/decodeHdKeyUnchecked.html)) |
| 32 | + - [`decodeHdPrivateKey`](https://libauth.org/functions/decodeHdPrivateKey.html)/[`encodeHdPrivateKey`](https://libauth.org/functions/encodeHdPrivateKey.html) |
| 33 | + - [`decodeHdPublicKey`](https://libauth.org/functions/decodeHdPublicKey.html)/[`encodeHdPrivateKey`](https://libauth.org/functions/encodeHdPrivateKey.html) |
| 34 | + - [`deriveHdPath`](https://libauth.org/functions/deriveHdPath.html) |
| 35 | + - [`deriveHdPathRelative`](https://libauth.org/functions/deriveHdPathRelative.html) |
| 36 | + - [`deriveHdPrivateNodeFromSeed`](https://libauth.org/functions/deriveHdPrivateNodeFromSeed.html) |
| 37 | + - [`deriveHdPrivateNodeIdentifier`](https://libauth.org/functions/deriveHdPrivateNodeIdentifier.html)/[`deriveHdPublicNodeIdentifier`](https://libauth.org/functions/deriveHdPublicNodeIdentifier.html) |
| 38 | + - [`deriveHdPrivateNodeChild`](https://libauth.org/functions/deriveHdPrivateNodeChild.html)/[`deriveHdPublicNodeChild`](https://libauth.org/functions/deriveHdPublicNodeChild.html) |
| 39 | + - [`deriveHdPublicKey`](https://libauth.org/functions/deriveHdPublicKey.html) |
| 40 | + - [`deriveHdPublicNode`](https://libauth.org/functions/deriveHdPublicNode.html) |
| 41 | + - [`hdKeyVersionIsPrivateKey`](https://libauth.org/functions/hdKeyVersionIsPrivateKey.html)/[`hdKeyVersionIsPublicKey`](https://libauth.org/functions/hdKeyVersionIsPublicKey.html) |
| 42 | + - [`hdPrivateKeyToIdentifier`](https://libauth.org/functions/hdPrivateKeyToIdentifier.html)/[`hdPublicKeyToIdentifier`](https://libauth.org/functions/hdPublicKeyToIdentifier.html) |
| 43 | + - BIP39 (Mnemonic Phrase) Utilities: |
| 44 | + - [`deriveHdPrivateNodeFromBip39Mnemonic`](https://libauth.org/functions/deriveHdPrivateNodeFromBip39Mnemonic.html) |
| 45 | + - [`deriveSeedFromBip39Mnemonic`](https://libauth.org/functions/deriveSeedFromBip39Mnemonic.html) |
| 46 | + - [`encodeBip39Mnemonic`](https://libauth.org/functions/encodeBip39Mnemonic.html)/[`decodeBip39Mnemonic`](https://libauth.org/functions/decodeBip39Mnemonic.html) |
| 47 | + - [`generateBip39Mnemonic`](https://libauth.org/functions/generateBip39Mnemonic.html) |
| 48 | + - Key Utilities: |
| 49 | + - [`generateDeterministicEntropy`](https://libauth.org/functions/generateDeterministicEntropy.html) |
| 50 | + |
| 51 | + Please see the relevant guide(s) for usage examples: |
| 52 | + |
| 53 | + - [Handling Errors](https://github.com/bitauth/libauth/blob/master/docs/errors.md) |
| 54 | + - [Keys](https://github.com/bitauth/libauth/blob/master/docs/keys.md) |
| 55 | + - [Addresses](https://github.com/bitauth/libauth/blob/master/docs/addresses.md) |
| 56 | + - [Wallets & Transaction Creation](https://github.com/bitauth/libauth/blob/master/docs/wallets.md) |
| 57 | + |
| 58 | +### Minor Changes |
| 59 | + |
| 60 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - Add usage guides and API overview |
| 61 | + |
| 62 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - Add P2PKH CashAddress utilities |
| 63 | + |
| 64 | + The following utilities are now available: |
| 65 | + |
| 66 | + - [`hdPrivateKeyToP2pkhLockingBytecode`](https://libauth.org/functions/hdPrivateKeyToP2pkhLockingBytecode.html) |
| 67 | + - [`hdPrivateKeyToP2pkhCashAddress`](https://libauth.org/functions/hdPrivateKeyToP2pkhCashAddress.html) |
| 68 | + - [`hdPublicKeyToP2pkhLockingBytecode`](https://libauth.org/functions/hdPublicKeyToP2pkhLockingBytecode.html) |
| 69 | + - [`hdPublicKeyToP2pkhCashAddress`](https://libauth.org/functions/hdPublicKeyToP2pkhCashAddress.html) |
| 70 | + - [`privateKeyToP2pkhLockingBytecode`](https://libauth.org/functions/privateKeyToP2pkhLockingBytecode.html) |
| 71 | + - [`privateKeyToP2pkhCashAddress`](https://libauth.org/functions/privateKeyToP2pkhCashAddress.html) |
| 72 | + - [`publicKeyToP2pkhLockingBytecode`](https://libauth.org/functions/publicKeyToP2pkhLockingBytecode.html) |
| 73 | + - [`publicKeyToP2pkhCashAddress`](https://libauth.org/functions/publicKeyToP2pkhCashAddress.html) |
| 74 | + |
| 75 | + For usage examples, see [`wallets.md`](https://github.com/bitauth/libauth/blob/master/docs/wallets.md). |
| 76 | + |
| 77 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - Validate all keys prior to compilation, expose `validateCompilationData` |
| 78 | + |
| 79 | + The compiler now validates all compilation data (i.e. validate all public and private keys), prior to compilation, regardless of whether or not the offending public or private key material is used. This is intended to surface software defects (particularly in the software used by counterparties) as early as possible. |
| 80 | + |
| 81 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - Add support for `decodeTransactionOutputs` |
| 82 | + |
| 83 | +### Patch Changes |
| 84 | + |
| 85 | +- [#127](https://github.com/bitauth/libauth/pull/127) [`e5c275f`](https://github.com/bitauth/libauth/commit/e5c275fdc8c9007a443958454346c46e647cf26c) Thanks [@bitjson](https://github.com/bitjson)! - `generateRandomBytes`: always verify unique results across two runs |
| 86 | + |
| 87 | + Fixes [#119](https://github.com/bitauth/libauth/issues/119). Old behavior is available at `generateRandomBytesUnchecked`. |
| 88 | + |
3 | 89 | ## 2.1.0
|
4 | 90 |
|
5 | 91 | ### Minor Changes
|
|
0 commit comments