Skip to content

Commit e5c275f

Browse files
authored
Prepare v3 release (#127)
1 parent ec18dad commit e5c275f

File tree

140 files changed

+33670
-26442
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

140 files changed

+33670
-26442
lines changed

.changeset/chilly-dragons-burn.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@bitauth/libauth': minor
3+
---
4+
5+
Add usage guides and API overview

.changeset/dry-geese-whisper.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
'@bitauth/libauth': patch
3+
---
4+
5+
`generateRandomBytes`: always verify unique results across two runs
6+
7+
Fixes [#119](https://github.com/bitauth/libauth/issues/119). Old behavior is available at `generateRandomBytesUnchecked`.

.changeset/grumpy-seals-grow.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
'@bitauth/libauth': major
3+
---
4+
5+
Add support for relative BIP32 derivation
6+
7+
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.
8+
9+
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.
10+
11+
Fixes [#49](https://github.com/bitauth/libauth/issues/49).

.changeset/old-islands-scream.md

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@bitauth/libauth': minor
3+
---
4+
5+
Add P2PKH CashAddress utilities
6+
7+
The following utilities are now available:
8+
9+
- [`hdPrivateKeyToP2pkhLockingBytecode`](https://libauth.org/functions/hdPrivateKeyToP2pkhLockingBytecode.html)
10+
- [`hdPrivateKeyToP2pkhCashAddress`](https://libauth.org/functions/hdPrivateKeyToP2pkhCashAddress.html)
11+
- [`hdPublicKeyToP2pkhLockingBytecode`](https://libauth.org/functions/hdPublicKeyToP2pkhLockingBytecode.html)
12+
- [`hdPublicKeyToP2pkhCashAddress`](https://libauth.org/functions/hdPublicKeyToP2pkhCashAddress.html)
13+
- [`privateKeyToP2pkhLockingBytecode`](https://libauth.org/functions/privateKeyToP2pkhLockingBytecode.html)
14+
- [`privateKeyToP2pkhCashAddress`](https://libauth.org/functions/privateKeyToP2pkhCashAddress.html)
15+
- [`publicKeyToP2pkhLockingBytecode`](https://libauth.org/functions/publicKeyToP2pkhLockingBytecode.html)
16+
- [`publicKeyToP2pkhCashAddress`](https://libauth.org/functions/publicKeyToP2pkhCashAddress.html)
17+
18+
For usage examples, see [`wallets.md`](https://github.com/bitauth/libauth/blob/master/docs/wallets.md).

.changeset/pink-hotels-admire.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
'@bitauth/libauth': minor
3+
---
4+
5+
Validate all keys prior to compilation, expose `validateCompilationData`
6+
7+
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.

.changeset/serious-camels-help.md

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
'@bitauth/libauth': major
3+
---
4+
5+
CashAssembly: `.signature` is now `.ecdsa_signature`
6+
7+
All CashAssembly scripts using the `.signature` operation should instead call `.ecdsa_signature` or switch to `.schnorr_signature`.
8+
9+
Additionally, `signing_serialization.token_prefix` is now available.

.changeset/smooth-sheep-fly.md

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
---
2+
'@bitauth/libauth': major
3+
---
4+
5+
Unify object parameters and error handling across library
6+
7+
A number of existing Libauth utilities have been modified to adhere to Libauth's object parameter and error handling conventions:
8+
9+
- CashAddress utilities:
10+
- [`encodeCashAddress`](https://libauth.org/functions/encodeCashAddress.html)/[`decodeCashAddress`](https://libauth.org/functions/decodeCashAddress.html)
11+
- [`lockingBytecodeToCashAddress`](https://libauth.org/functions/lockingBytecodeToCashAddress.html)/[`cashAddressToLockingBytecode`](https://libauth.org/functions/cashAddressToLockingBytecode.html)
12+
- [`encodeCashAddressFormat`](https://libauth.org/functions/encodeCashAddressFormat.html)/[`decodeCashAddressFormat`](https://libauth.org/functions/decodeCashAddressFormat.html)
13+
- BIP32 (HD Key) utilities:
14+
- [`crackHdPrivateNodeFromHdPublicNodeAndChildPrivateNode`](https://libauth.org/functions/crackHdPrivateNodeFromHdPublicNodeAndChildPrivateNode.html)
15+
- [`decodeHdKey`](https://libauth.org/functions/decodeHdKey.html) ([`decodeHdKeyUnchecked`](https://libauth.org/functions/decodeHdKeyUnchecked.html))
16+
- [`decodeHdPrivateKey`](https://libauth.org/functions/decodeHdPrivateKey.html)/[`encodeHdPrivateKey`](https://libauth.org/functions/encodeHdPrivateKey.html)
17+
- [`decodeHdPublicKey`](https://libauth.org/functions/decodeHdPublicKey.html)/[`encodeHdPrivateKey`](https://libauth.org/functions/encodeHdPrivateKey.html)
18+
- [`deriveHdPath`](https://libauth.org/functions/deriveHdPath.html)
19+
- [`deriveHdPathRelative`](https://libauth.org/functions/deriveHdPathRelative.html)
20+
- [`deriveHdPrivateNodeFromSeed`](https://libauth.org/functions/deriveHdPrivateNodeFromSeed.html)
21+
- [`deriveHdPrivateNodeIdentifier`](https://libauth.org/functions/deriveHdPrivateNodeIdentifier.html)/[`deriveHdPublicNodeIdentifier`](https://libauth.org/functions/deriveHdPublicNodeIdentifier.html)
22+
- [`deriveHdPrivateNodeChild`](https://libauth.org/functions/deriveHdPrivateNodeChild.html)/[`deriveHdPublicNodeChild`](https://libauth.org/functions/deriveHdPublicNodeChild.html)
23+
- [`deriveHdPublicKey`](https://libauth.org/functions/deriveHdPublicKey.html)
24+
- [`deriveHdPublicNode`](https://libauth.org/functions/deriveHdPublicNode.html)
25+
- [`hdKeyVersionIsPrivateKey`](https://libauth.org/functions/hdKeyVersionIsPrivateKey.html)/[`hdKeyVersionIsPublicKey`](https://libauth.org/functions/hdKeyVersionIsPublicKey.html)
26+
- [`hdPrivateKeyToIdentifier`](https://libauth.org/functions/hdPrivateKeyToIdentifier.html)/[`hdPublicKeyToIdentifier`](https://libauth.org/functions/hdPublicKeyToIdentifier.html)
27+
- BIP39 (Mnemonic Phrase) Utilities:
28+
- [`deriveHdPrivateNodeFromBip39Mnemonic`](https://libauth.org/functions/deriveHdPrivateNodeFromBip39Mnemonic.html)
29+
- [`deriveSeedFromBip39Mnemonic`](https://libauth.org/functions/deriveSeedFromBip39Mnemonic.html)
30+
- [`encodeBip39Mnemonic`](https://libauth.org/functions/encodeBip39Mnemonic.html)/[`decodeBip39Mnemonic`](https://libauth.org/functions/decodeBip39Mnemonic.html)
31+
- [`generateBip39Mnemonic`](https://libauth.org/functions/generateBip39Mnemonic.html)
32+
- Key Utilities:
33+
- [`generateDeterministicEntropy`](https://libauth.org/functions/generateDeterministicEntropy.html)
34+
35+
Please see the relevant guide(s) for usage examples:
36+
37+
- [Handling Errors](https://github.com/bitauth/libauth/blob/master/docs/errors.md)
38+
- [Keys](https://github.com/bitauth/libauth/blob/master/docs/keys.md)
39+
- [Addresses](https://github.com/bitauth/libauth/blob/master/docs/addresses.md)
40+
- [Wallets & Transaction Creation](https://github.com/bitauth/libauth/blob/master/docs/wallets.md)

.changeset/three-readers-unite.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@bitauth/libauth': minor
3+
---
4+
5+
Add support for `decodeTransactionOutputs`

.cspell.json

+14-1
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,14 @@
4848
"CHECKSEQUENCEVERIFY",
4949
"CHECKSIG",
5050
"CHECKSIGVERIFY",
51+
"checksummed",
5152
"chipnet",
5253
"chuhai",
5354
"codecov",
5455
"codepoint",
5556
"CODESEPARATOR",
5657
"coinbase",
58+
"Coldcard's",
5759
"combinator",
5860
"combinators",
5961
"convertbits",
@@ -156,6 +158,7 @@
156158
"seckey",
157159
"secp",
158160
"secp256k1",
161+
"secretkey",
159162
"sidechain",
160163
"sigchecks",
161164
"sighash",
@@ -183,6 +186,7 @@
183186
"Uint",
184187
"uncompress",
185188
"unintuitive",
189+
"UNROT",
186190
"unspendable",
187191
"untrusted",
188192
"utxo",
@@ -221,7 +225,16 @@
221225
{
222226
"name": "cash-address-format",
223227
"pattern": "/:[qpzry9x8gf2tvdw0s3jn54khce6mua7l]+/g"
228+
},
229+
{
230+
"name": "secret-key-format",
231+
"pattern": "/secret-key:[-qpzry9x8gf2tvdw0s3jn54khce6mua7l]+/g"
224232
}
225233
],
226-
"ignoreRegExpList": ["Base64", "HexValues", "cash-address-format"]
234+
"ignoreRegExpList": [
235+
"Base64",
236+
"HexValues",
237+
"cash-address-format",
238+
"secret-key-format"
239+
]
227240
}

0 commit comments

Comments
 (0)