@ledgerhq/zcash-utils 2.5.1 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # @ledgerhq/zcash-utils
2
2
 
3
+ ## 2.6.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 841b576: Transactions now target the next block (tip + 1) instead of anchor + 40, keep the builder's expiry, and cap it below the next network upgrade known to the bundled consensus parameters (none is pending on mainnet or testnet with this release; NU7 is covered once its heights ship). A craft whose capped expiry would leave fewer than 8 blocks (zcashd's 3-block expiring-soon rule plus 5 blocks for signing on the device) is refused with an error containing `expiry too close to activation`. An explicit `anchorHeight` above the chain tip is rejected, and the chain tip is now queried even when `anchorHeight` is given.
8
+
9
+ ### Patch Changes
10
+
11
+ - 378e859: Widen the shard-0 scan-width safety limit so that two years of chain growth still pass at NU7's 25-second block spacing, while a scan started from genesis is still refused.
12
+
3
13
  ## 2.5.1
4
14
 
5
15
  ### Patch Changes
package/index.d.ts CHANGED
@@ -261,6 +261,11 @@ export interface BuildTransactionParams {
261
261
  /** Transparent (P2PKH) UTXOs to spend. Empty for Private→* flows. */
262
262
  transparentInputs: Array<TransparentInputJs>
263
263
  outputs: Array<OutputRequestJs>
264
+ /**
265
+ * Explicit anchor height; omitted → `tip − 10`. An explicit height above the
266
+ * tip is rejected. The transaction always targets the next block, `tip + 1`,
267
+ * so the chain tip is queried in either case.
268
+ */
264
269
  anchorHeight?: number
265
270
  }
266
271
  export interface BuildTransactionResult {
@@ -272,7 +277,7 @@ export interface BuildTransactionResult {
272
277
  pcztHex: string
273
278
  /** Decimal fee in zatoshis. */
274
279
  feeZat: string
275
- /** Block height the Merkle paths were computed against. */
280
+ /** Block height the Merkle paths were computed against (the resolved anchor). */
276
281
  anchorHeight: number
277
282
  /** Orchard action count after dummy padding. */
278
283
  nActionsOrchard: number
@@ -349,6 +354,11 @@ export interface BuildIronwoodTransactionParams {
349
354
  /** Transparent (P2PKH) UTXOs to spend. Empty for Ironwood→* flows. */
350
355
  transparentInputs: Array<TransparentInputJs>
351
356
  outputs: Array<IronwoodOutputRequestJs>
357
+ /**
358
+ * Explicit anchor height; omitted → `tip − 10`. An explicit height above the
359
+ * tip is rejected. The transaction always targets the next block, `tip + 1`,
360
+ * so the chain tip is queried in either case.
361
+ */
352
362
  anchorHeight?: number
353
363
  }
354
364
  export interface BuildIronwoodTransactionResult {
@@ -361,7 +371,7 @@ export interface BuildIronwoodTransactionResult {
361
371
  pcztHex: string
362
372
  /** Decimal fee in zatoshis. */
363
373
  feeZat: string
364
- /** Block height the Merkle paths were computed against. */
374
+ /** Block height the Merkle paths were computed against (the resolved anchor). */
365
375
  anchorHeight: number
366
376
  /** Ironwood action count after dummy padding. */
367
377
  nActionsIronwood: number
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ledgerhq/zcash-utils",
3
- "version": "2.5.1",
3
+ "version": "2.6.0",
4
4
  "description": "Native Zcash key derivation and shielded sync — Node.js (NAPI)",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",