@ledgerhq/hw-app-btc 6.10.0-taproot.0 → 6.11.2
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/README.md +660 -107
- package/lib/Btc.d.ts +9 -6
- package/lib/Btc.d.ts.map +1 -1
- package/lib/Btc.js +74 -11
- package/lib/Btc.js.map +1 -1
- package/lib/BtcNew.d.ts +80 -32
- package/lib/BtcNew.d.ts.map +1 -1
- package/lib/BtcNew.js +179 -209
- package/lib/BtcNew.js.map +1 -1
- package/lib/newops/accounttype.d.ts +110 -0
- package/lib/newops/accounttype.d.ts.map +1 -0
- package/lib/newops/accounttype.js +233 -0
- package/lib/newops/accounttype.js.map +1 -0
- package/lib/newops/appClient.d.ts +6 -2
- package/lib/newops/appClient.d.ts.map +1 -1
- package/lib/newops/appClient.js +8 -4
- package/lib/newops/appClient.js.map +1 -1
- package/lib/newops/clientCommands.d.ts +18 -2
- package/lib/newops/clientCommands.d.ts.map +1 -1
- package/lib/newops/clientCommands.js +34 -12
- package/lib/newops/clientCommands.js.map +1 -1
- package/lib/newops/merkelizedPsbt.d.ts +11 -0
- package/lib/newops/merkelizedPsbt.d.ts.map +1 -1
- package/lib/newops/merkelizedPsbt.js +11 -0
- package/lib/newops/merkelizedPsbt.js.map +1 -1
- package/lib/newops/merkle.d.ts +5 -0
- package/lib/newops/merkle.d.ts.map +1 -1
- package/lib/newops/merkle.js +5 -0
- package/lib/newops/merkle.js.map +1 -1
- package/lib/newops/merkleMap.d.ts +10 -0
- package/lib/newops/merkleMap.d.ts.map +1 -1
- package/lib/newops/merkleMap.js +10 -0
- package/lib/newops/merkleMap.js.map +1 -1
- package/lib/newops/policy.d.ts +8 -0
- package/lib/newops/policy.d.ts.map +1 -1
- package/lib/newops/policy.js +9 -1
- package/lib/newops/policy.js.map +1 -1
- package/lib/newops/psbtExtractor.d.ts +6 -0
- package/lib/newops/psbtExtractor.d.ts.map +1 -1
- package/lib/newops/psbtExtractor.js +6 -0
- package/lib/newops/psbtExtractor.js.map +1 -1
- package/lib/newops/psbtFinalizer.d.ts +11 -1
- package/lib/newops/psbtFinalizer.d.ts.map +1 -1
- package/lib/newops/psbtFinalizer.js +26 -1
- package/lib/newops/psbtFinalizer.js.map +1 -1
- package/lib/newops/psbtv2.d.ts +22 -2
- package/lib/newops/psbtv2.d.ts.map +1 -1
- package/lib/newops/psbtv2.js +33 -8
- package/lib/newops/psbtv2.js.map +1 -1
- package/lib-es/Btc.d.ts +9 -6
- package/lib-es/Btc.d.ts.map +1 -1
- package/lib-es/Btc.js +75 -12
- package/lib-es/Btc.js.map +1 -1
- package/lib-es/BtcNew.d.ts +80 -32
- package/lib-es/BtcNew.d.ts.map +1 -1
- package/lib-es/BtcNew.js +176 -210
- package/lib-es/BtcNew.js.map +1 -1
- package/lib-es/newops/accounttype.d.ts +110 -0
- package/lib-es/newops/accounttype.d.ts.map +1 -0
- package/lib-es/newops/accounttype.js +230 -0
- package/lib-es/newops/accounttype.js.map +1 -0
- package/lib-es/newops/appClient.d.ts +6 -2
- package/lib-es/newops/appClient.d.ts.map +1 -1
- package/lib-es/newops/appClient.js +8 -4
- package/lib-es/newops/appClient.js.map +1 -1
- package/lib-es/newops/clientCommands.d.ts +18 -2
- package/lib-es/newops/clientCommands.d.ts.map +1 -1
- package/lib-es/newops/clientCommands.js +34 -12
- package/lib-es/newops/clientCommands.js.map +1 -1
- package/lib-es/newops/merkelizedPsbt.d.ts +11 -0
- package/lib-es/newops/merkelizedPsbt.d.ts.map +1 -1
- package/lib-es/newops/merkelizedPsbt.js +11 -0
- package/lib-es/newops/merkelizedPsbt.js.map +1 -1
- package/lib-es/newops/merkle.d.ts +5 -0
- package/lib-es/newops/merkle.d.ts.map +1 -1
- package/lib-es/newops/merkle.js +5 -0
- package/lib-es/newops/merkle.js.map +1 -1
- package/lib-es/newops/merkleMap.d.ts +10 -0
- package/lib-es/newops/merkleMap.d.ts.map +1 -1
- package/lib-es/newops/merkleMap.js +10 -0
- package/lib-es/newops/merkleMap.js.map +1 -1
- package/lib-es/newops/policy.d.ts +8 -0
- package/lib-es/newops/policy.d.ts.map +1 -1
- package/lib-es/newops/policy.js +10 -2
- package/lib-es/newops/policy.js.map +1 -1
- package/lib-es/newops/psbtExtractor.d.ts +6 -0
- package/lib-es/newops/psbtExtractor.d.ts.map +1 -1
- package/lib-es/newops/psbtExtractor.js +6 -0
- package/lib-es/newops/psbtExtractor.js.map +1 -1
- package/lib-es/newops/psbtFinalizer.d.ts +11 -1
- package/lib-es/newops/psbtFinalizer.d.ts.map +1 -1
- package/lib-es/newops/psbtFinalizer.js +26 -1
- package/lib-es/newops/psbtFinalizer.js.map +1 -1
- package/lib-es/newops/psbtv2.d.ts +22 -2
- package/lib-es/newops/psbtv2.d.ts.map +1 -1
- package/lib-es/newops/psbtv2.js +33 -8
- package/lib-es/newops/psbtv2.js.map +1 -1
- package/package.json +4 -4
- package/src/Btc.ts +113 -15
- package/src/BtcNew.ts +213 -209
- package/src/newops/accounttype.ts +370 -0
- package/src/newops/appClient.ts +12 -4
- package/src/newops/clientCommands.ts +34 -12
- package/src/newops/merkelizedPsbt.ts +11 -0
- package/src/newops/merkle.ts +5 -0
- package/src/newops/merkleMap.ts +10 -0
- package/src/newops/policy.ts +10 -2
- package/src/newops/psbtExtractor.ts +6 -0
- package/src/newops/psbtFinalizer.ts +26 -1
- package/src/newops/psbtv2.ts +34 -14
- package/tests/Btc.integration.test.ts +7 -1
- package/tests/Btc.test.ts +88 -0
- package/tests/newops/BtcNew.test.ts +54 -20
- package/tests/newops/integrationtools.ts +49 -39
- package/tests/newops/testtx.ts +0 -55
package/lib/Btc.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import type Transport from "@ledgerhq/hw-transport";
|
|
3
|
+
import BtcNew from "./BtcNew";
|
|
4
|
+
import BtcOld from "./BtcOld";
|
|
3
5
|
import type { CreateTransactionArg } from "./createTransaction";
|
|
4
6
|
import type { AddressFormat } from "./getWalletPublicKey";
|
|
5
7
|
import type { SignP2SHTransactionArg } from "./signP2SHTransaction";
|
|
@@ -40,7 +42,7 @@ export default class Btc {
|
|
|
40
42
|
*
|
|
41
43
|
* - p2sh format with 49' paths
|
|
42
44
|
*
|
|
43
|
-
* - bech32 format with
|
|
45
|
+
* - bech32 format with 84' paths
|
|
44
46
|
*
|
|
45
47
|
* - cashaddr in case of Bitcoin Cash
|
|
46
48
|
*
|
|
@@ -80,21 +82,21 @@ export default class Btc {
|
|
|
80
82
|
* * sequence is the sequence number to use for this input (when using RBF), or non present
|
|
81
83
|
* @param associatedKeysets is an array of BIP 32 paths pointing to the path to the private key used for each UTXO
|
|
82
84
|
* @param changePath is an optional BIP 32 path pointing to the path to the public key used to compute the change address
|
|
83
|
-
* @param outputScriptHex is the hexadecimal serialized outputs of the transaction to sign
|
|
85
|
+
* @param outputScriptHex is the hexadecimal serialized outputs of the transaction to sign, including leading vararg voutCount
|
|
84
86
|
* @param lockTime is the optional lockTime of the transaction to sign, or default (0)
|
|
85
87
|
* @param sigHashType is the hash type of the transaction to sign, or default (all)
|
|
86
|
-
* @param segwit is an optional boolean indicating wether to use segwit or not
|
|
88
|
+
* @param segwit is an optional boolean indicating wether to use segwit or not. This includes wrapped segwit.
|
|
87
89
|
* @param initialTimestamp is an optional timestamp of the function call to use for coins that necessitate timestamps only, (not the one that the tx will include)
|
|
88
90
|
* @param additionals list of additionnal options
|
|
89
91
|
*
|
|
90
92
|
* - "bech32" for spending native segwit outputs
|
|
91
|
-
* - "bech32m" for spending
|
|
93
|
+
* - "bech32m" for spending segwit v1+ outputs
|
|
92
94
|
* - "abc" for bch
|
|
93
95
|
* - "gold" for btg
|
|
94
96
|
* - "bipxxx" for using BIPxxx
|
|
95
97
|
* - "sapling" to indicate a zec transaction is supporting sapling (to be set over block 419200)
|
|
96
98
|
* @param expiryHeight is an optional Buffer for zec overwinter / sapling Txs
|
|
97
|
-
* @param useTrustedInputForSegwit trust inputs for segwit transactions
|
|
99
|
+
* @param useTrustedInputForSegwit trust inputs for segwit transactions. If app version >= 1.4.0 this should be true.
|
|
98
100
|
* @return the signed transaction ready to be broadcast
|
|
99
101
|
* @example
|
|
100
102
|
btc.createTransaction({
|
|
@@ -141,6 +143,7 @@ export default class Btc {
|
|
|
141
143
|
private _lazyImpl;
|
|
142
144
|
private getCorrectImpl;
|
|
143
145
|
private inferCorrectImpl;
|
|
144
|
-
|
|
146
|
+
protected old(): BtcOld;
|
|
147
|
+
protected new(): BtcNew;
|
|
145
148
|
}
|
|
146
149
|
//# sourceMappingURL=Btc.d.ts.map
|
package/lib/Btc.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Btc.d.ts","sourceRoot":"","sources":["../src/Btc.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,SAAS,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"Btc.d.ts","sourceRoot":"","sources":["../src/Btc.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,SAAS,MAAM,wBAAwB,CAAC;AAEpD,OAAO,MAAyB,MAAM,UAAU,CAAC;AACjD,OAAO,MAAM,MAAM,UAAU,CAAC;AAC9B,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAIhE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAG1D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAEpE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAC3C,YAAY,EAAE,aAAa,EAAE,CAAC;AAC9B;;;;;;GAMG;AAEH,MAAM,CAAC,OAAO,OAAO,GAAG;IACtB,SAAS,EAAE,SAAS,CAAC;gBAET,SAAS,EAAE,SAAS,EAAE,WAAW,SAAQ;IAiBrD;;;;;;OAMG;IACH,aAAa,CAAC,GAAG,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC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W,EAAE,WAAW,EACxB,WAAW,GAAE,KAAK,CAAC,MAAM,CAAM,GAC9B,MAAM;IAUT,OAAO,CAAC,SAAS,CAAgC;YACnC,cAAc;YAQd,gBAAgB;IAU9B,SAAS,CAAC,GAAG,IAAI,MAAM;IAIvB,SAAS,CAAC,GAAG,IAAI,MAAM;CAGxB"}
|
package/lib/Btc.js
CHANGED
|
@@ -58,7 +58,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
58
58
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
59
59
|
};
|
|
60
60
|
exports.__esModule = true;
|
|
61
|
-
var
|
|
61
|
+
var bip32_1 = require("./bip32");
|
|
62
62
|
var BtcNew_1 = __importStar(require("./BtcNew"));
|
|
63
63
|
var BtcOld_1 = __importDefault(require("./BtcOld"));
|
|
64
64
|
var getAppAndVersion_1 = require("./getAppAndVersion");
|
|
@@ -114,7 +114,7 @@ var Btc = /** @class */ (function () {
|
|
|
114
114
|
*
|
|
115
115
|
* - p2sh format with 49' paths
|
|
116
116
|
*
|
|
117
|
-
* - bech32 format with
|
|
117
|
+
* - bech32 format with 84' paths
|
|
118
118
|
*
|
|
119
119
|
* - cashaddr in case of Bitcoin Cash
|
|
120
120
|
*
|
|
@@ -123,6 +123,7 @@ var Btc = /** @class */ (function () {
|
|
|
123
123
|
* btc.getWalletPublicKey("49'/0'/0'/0/0", { format: "p2sh" }).then(o => o.bitcoinAddress)
|
|
124
124
|
*/
|
|
125
125
|
Btc.prototype.getWalletPublicKey = function (path, opts) {
|
|
126
|
+
var _this = this;
|
|
126
127
|
var options;
|
|
127
128
|
if (arguments.length > 2 || typeof opts === "boolean") {
|
|
128
129
|
console.warn("btc.getWalletPublicKey deprecated signature used. Please switch to getWalletPublicKey(path, { format, verify })");
|
|
@@ -136,7 +137,39 @@ var Btc = /** @class */ (function () {
|
|
|
136
137
|
options = opts || {};
|
|
137
138
|
}
|
|
138
139
|
return this.getCorrectImpl().then(function (impl) {
|
|
139
|
-
|
|
140
|
+
/**
|
|
141
|
+
* Definition: A "normal path" is a prefix of a standard path where all
|
|
142
|
+
* the hardened steps of the standard path are included. For example, the
|
|
143
|
+
* paths m/44'/1'/17' and m/44'/1'/17'/1 are normal paths, but m/44'/1'
|
|
144
|
+
* is not. m/'199/1'/17'/0/1 is not a normal path either.
|
|
145
|
+
*
|
|
146
|
+
* There's a compatiblity issue between old and new app: When exporting
|
|
147
|
+
* the key of a non-normal path with verify=false, the new app would
|
|
148
|
+
* return an error, whereas the old app would return the key.
|
|
149
|
+
*
|
|
150
|
+
* See
|
|
151
|
+
* https://github.com/LedgerHQ/app-bitcoin-new/blob/master/doc/bitcoin.md#get_extended_pubkey
|
|
152
|
+
*
|
|
153
|
+
* If format bech32m is used, we'll not use old, because it doesn't
|
|
154
|
+
* support it.
|
|
155
|
+
*
|
|
156
|
+
* When to use new (given the app supports it)
|
|
157
|
+
* * format is bech32m or
|
|
158
|
+
* * path is normal or
|
|
159
|
+
* * verify is true
|
|
160
|
+
*
|
|
161
|
+
* Otherwise use old.
|
|
162
|
+
*/
|
|
163
|
+
if (impl instanceof BtcNew_1["default"] &&
|
|
164
|
+
options.format != "bech32m" &&
|
|
165
|
+
(!options.verify || options.verify == false) &&
|
|
166
|
+
!isPathNormal(path)) {
|
|
167
|
+
console.warn("WARNING: Using deprecated device protocol to get the public key because\n \n * a non-standard path is requested, and\n * verify flag is false\n \n The new protocol only allows export of non-standard paths if the \n verify flag is true. Standard paths are (currently):\n\n M/44'/(1|0)'/X'\n M/49'/(1|0)'/X'\n M/84'/(1|0)'/X'\n M/86'/(1|0)'/X'\n M/48'/(1|0)'/X'/Y'\n\n followed by \"\", \"(0|1)\", or \"(0|1)/b\", where a and b are \n non-hardened. For example, the following paths are standard\n \n M/48'/1'/99'/7'\n M/86'/1'/99'/0\n M/48'/0'/99'/7'/1/17\n\n The following paths are non-standard\n\n M/48'/0'/99' // Not deepest hardened path\n M/48'/0'/99'/7'/1/17/2 // Too many non-hardened derivation steps\n M/199'/0'/1'/0/88 // Not a known purpose 199\n M/86'/1'/99'/2 // Change path item must be 0 or 1\n\n This compatibility safeguard will be removed in the future.\n Please consider calling Btc.getWalletXpub() instead.");
|
|
168
|
+
return _this.old().getWalletPublicKey(path, options);
|
|
169
|
+
}
|
|
170
|
+
else {
|
|
171
|
+
return impl.getWalletPublicKey(path, options);
|
|
172
|
+
}
|
|
140
173
|
});
|
|
141
174
|
};
|
|
142
175
|
/**
|
|
@@ -161,21 +194,21 @@ var Btc = /** @class */ (function () {
|
|
|
161
194
|
* * sequence is the sequence number to use for this input (when using RBF), or non present
|
|
162
195
|
* @param associatedKeysets is an array of BIP 32 paths pointing to the path to the private key used for each UTXO
|
|
163
196
|
* @param changePath is an optional BIP 32 path pointing to the path to the public key used to compute the change address
|
|
164
|
-
* @param outputScriptHex is the hexadecimal serialized outputs of the transaction to sign
|
|
197
|
+
* @param outputScriptHex is the hexadecimal serialized outputs of the transaction to sign, including leading vararg voutCount
|
|
165
198
|
* @param lockTime is the optional lockTime of the transaction to sign, or default (0)
|
|
166
199
|
* @param sigHashType is the hash type of the transaction to sign, or default (all)
|
|
167
|
-
* @param segwit is an optional boolean indicating wether to use segwit or not
|
|
200
|
+
* @param segwit is an optional boolean indicating wether to use segwit or not. This includes wrapped segwit.
|
|
168
201
|
* @param initialTimestamp is an optional timestamp of the function call to use for coins that necessitate timestamps only, (not the one that the tx will include)
|
|
169
202
|
* @param additionals list of additionnal options
|
|
170
203
|
*
|
|
171
204
|
* - "bech32" for spending native segwit outputs
|
|
172
|
-
* - "bech32m" for spending
|
|
205
|
+
* - "bech32m" for spending segwit v1+ outputs
|
|
173
206
|
* - "abc" for bch
|
|
174
207
|
* - "gold" for btg
|
|
175
208
|
* - "bipxxx" for using BIPxxx
|
|
176
209
|
* - "sapling" to indicate a zec transaction is supporting sapling (to be set over block 419200)
|
|
177
210
|
* @param expiryHeight is an optional Buffer for zec overwinter / sapling Txs
|
|
178
|
-
* @param useTrustedInputForSegwit trust inputs for segwit transactions
|
|
211
|
+
* @param useTrustedInputForSegwit trust inputs for segwit transactions. If app version >= 1.4.0 this should be true.
|
|
179
212
|
* @return the signed transaction ready to be broadcast
|
|
180
213
|
* @example
|
|
181
214
|
btc.createTransaction({
|
|
@@ -268,13 +301,12 @@ var Btc = /** @class */ (function () {
|
|
|
268
301
|
case 0: return [4 /*yield*/, (0, getAppAndVersion_1.getAppAndVersion)(this.transport)];
|
|
269
302
|
case 1:
|
|
270
303
|
appAndVersion = _a.sent();
|
|
271
|
-
canUseNewImplementation = BtcNew_1.
|
|
272
|
-
semver_1["default"].major(appAndVersion.version) >= 2;
|
|
304
|
+
canUseNewImplementation = (0, BtcNew_1.canSupportApp)(appAndVersion);
|
|
273
305
|
if (!canUseNewImplementation) {
|
|
274
|
-
return [2 /*return*/,
|
|
306
|
+
return [2 /*return*/, this.old()];
|
|
275
307
|
}
|
|
276
308
|
else {
|
|
277
|
-
return [2 /*return*/,
|
|
309
|
+
return [2 /*return*/, this["new"]()];
|
|
278
310
|
}
|
|
279
311
|
return [2 /*return*/];
|
|
280
312
|
}
|
|
@@ -284,7 +316,38 @@ var Btc = /** @class */ (function () {
|
|
|
284
316
|
Btc.prototype.old = function () {
|
|
285
317
|
return new BtcOld_1["default"](this.transport);
|
|
286
318
|
};
|
|
319
|
+
Btc.prototype["new"] = function () {
|
|
320
|
+
return new BtcNew_1["default"](new appClient_1.AppClient(this.transport));
|
|
321
|
+
};
|
|
287
322
|
return Btc;
|
|
288
323
|
}());
|
|
289
324
|
exports["default"] = Btc;
|
|
325
|
+
function isPathNormal(path) {
|
|
326
|
+
//path is not deepest hardened node of a standard path or deeper, use BtcOld
|
|
327
|
+
var h = 0x80000000;
|
|
328
|
+
var pathElems = (0, bip32_1.pathStringToArray)(path);
|
|
329
|
+
var hard = function (n) { return n > h; };
|
|
330
|
+
var soft = function (n) { return !n || n < h; };
|
|
331
|
+
var change = function (n) { return !n || n == 0 || n == 1; };
|
|
332
|
+
if (pathElems.length >= 3 &&
|
|
333
|
+
pathElems.length <= 5 &&
|
|
334
|
+
[44 + h, 49 + h, 84 + h, 86 + h].some(function (v) { return v == pathElems[0]; }) &&
|
|
335
|
+
[0 + h, 1 + h].some(function (v) { return v == pathElems[1]; }) &&
|
|
336
|
+
hard(pathElems[2]) &&
|
|
337
|
+
change(pathElems[3]) &&
|
|
338
|
+
soft(pathElems[4])) {
|
|
339
|
+
return true;
|
|
340
|
+
}
|
|
341
|
+
if (pathElems.length >= 4 &&
|
|
342
|
+
pathElems.length <= 6 &&
|
|
343
|
+
48 + h == pathElems[0] &&
|
|
344
|
+
[0 + h, 1 + h].some(function (v) { return v == pathElems[1]; }) &&
|
|
345
|
+
hard(pathElems[2]) &&
|
|
346
|
+
hard(pathElems[3]) &&
|
|
347
|
+
change(pathElems[4]) &&
|
|
348
|
+
soft(pathElems[5])) {
|
|
349
|
+
return true;
|
|
350
|
+
}
|
|
351
|
+
return false;
|
|
352
|
+
}
|
|
290
353
|
//# sourceMappingURL=Btc.js.map
|
package/lib/Btc.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Btc.js","sourceRoot":"","sources":["../src/Btc.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,
|
|
1
|
+
{"version":3,"file":"Btc.js","sourceRoot":"","sources":["../src/Btc.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,iCAA4C;AAC5C,iDAAiD;AACjD,oDAA8B;AAE9B,uDAAsD;AACtD,qDAAoD;AACpD,iEAAgE;AAEhE,gDAA+C;AAC/C,+DAAqE;AAErE,uDAAsD;AAGtD;;;;;;GAMG;AAEH;IAGE,aAAY,SAAoB,EAAE,WAAmB;QAAnB,4BAAA,EAAA,mBAAmB;QA4RrD,kDAAkD;QAC1C,cAAS,GAA2B,IA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MAAM,IAAI,CAAC;QACrB,SAAS,CAAC,MAAM,IAAI,CAAC;QACrB,EAAE,GAAG,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC;QACtB,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,UAAC,CAAC,IAAK,OAAA,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC,EAAjB,CAAiB,CAAC;QAC7C,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;QAClB,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;QAClB,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;QACpB,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAClB;QACA,OAAO,IAAI,CAAC;KACb;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
|
package/lib/BtcNew.d.ts
CHANGED
|
@@ -1,14 +1,65 @@
|
|
|
1
1
|
import type { CreateTransactionArg } from "./createTransaction";
|
|
2
|
+
import { AppAndVersion } from "./getAppAndVersion";
|
|
2
3
|
import type { AddressFormat } from "./getWalletPublicKey";
|
|
3
4
|
import { AppClient as Client } from "./newops/appClient";
|
|
4
|
-
export declare
|
|
5
|
+
export declare function canSupportApp(appAndVersion: AppAndVersion): boolean;
|
|
6
|
+
/**
|
|
7
|
+
* This class implements the same interface as BtcOld (formerly
|
|
8
|
+
* named Btc), but interacts with Bitcoin hardware app version 2+
|
|
9
|
+
* which uses a totally new APDU protocol. This new
|
|
10
|
+
* protocol is documented at
|
|
11
|
+
* https://github.com/LedgerHQ/app-bitcoin-new/blob/master/doc/bitcoin.md
|
|
12
|
+
*
|
|
13
|
+
* Since the interface must remain compatible with BtcOld, the methods
|
|
14
|
+
* of this class are quite clunky, because it needs to adapt legacy
|
|
15
|
+
* input data into the PSBT process. In the future, a new interface should
|
|
16
|
+
* be developed that exposes PSBT to the outer world, which would render
|
|
17
|
+
* a much cleaner implementation.
|
|
18
|
+
*/
|
|
5
19
|
export default class BtcNew {
|
|
6
20
|
private client;
|
|
7
21
|
constructor(client: Client);
|
|
22
|
+
/**
|
|
23
|
+
* This is a new method that allow users to get an xpub at a standard path.
|
|
24
|
+
* Standard paths are described at
|
|
25
|
+
* https://github.com/LedgerHQ/app-bitcoin-new/blob/master/doc/bitcoin.md#description
|
|
26
|
+
*
|
|
27
|
+
* This boils down to paths (N=0 for Bitcoin, N=1 for Testnet):
|
|
28
|
+
* M/44'/N'/x'/**
|
|
29
|
+
* M/48'/N'/x'/y'/**
|
|
30
|
+
* M/49'/N'/x'/**
|
|
31
|
+
* M/84'/N'/x'/**
|
|
32
|
+
* M/86'/N'/x'/**
|
|
33
|
+
*
|
|
34
|
+
* The method was added because of added security in the hardware app v2+. The
|
|
35
|
+
* new hardware app will allow export of any xpub up to and including the
|
|
36
|
+
* deepest hardened key of standard derivation paths, whereas the old app
|
|
37
|
+
* would allow export of any key.
|
|
38
|
+
*
|
|
39
|
+
* This caused an issue for callers of this class, who only had
|
|
40
|
+
* getWalletPublicKey() to call which means they have to constuct xpub
|
|
41
|
+
* themselves:
|
|
42
|
+
*
|
|
43
|
+
* Suppose a user of this class wants to create an account xpub on a standard
|
|
44
|
+
* path, M/44'/0'/Z'. The user must get the parent key fingerprint (see BIP32)
|
|
45
|
+
* by requesting the parent key M/44'/0'. The new app won't allow that, because
|
|
46
|
+
* it only allows exporting deepest level hardened path. So the options are to
|
|
47
|
+
* allow requesting M/44'/0' from the app, or to add a new function
|
|
48
|
+
* "getWalletXpub".
|
|
49
|
+
*
|
|
50
|
+
* We opted for adding a new function, which can greatly simplify client code.
|
|
51
|
+
*/
|
|
8
52
|
getWalletXpub({ path, xpubVersion, }: {
|
|
9
53
|
path: string;
|
|
10
54
|
xpubVersion: number;
|
|
11
55
|
}): Promise<string>;
|
|
56
|
+
/**
|
|
57
|
+
* This method returns a public key, a bitcoin address, and and a chaincode
|
|
58
|
+
* for a specific derivation path.
|
|
59
|
+
*
|
|
60
|
+
* Limitation: If the path is not a leaf node of a standard path, the address
|
|
61
|
+
* will be the empty string "", see this.getWalletAddress() for details.
|
|
62
|
+
*/
|
|
12
63
|
getWalletPublicKey(path: string, opts?: {
|
|
13
64
|
verify?: boolean;
|
|
14
65
|
format?: AddressFormat;
|
|
@@ -26,7 +77,7 @@ export default class BtcNew {
|
|
|
26
77
|
*
|
|
27
78
|
* If display is false we *could* generate the address ourselves, but chose to
|
|
28
79
|
* get it from the device to save development time. However, it shouldn't take
|
|
29
|
-
*
|
|
80
|
+
* too much time to implement local address generation.
|
|
30
81
|
*
|
|
31
82
|
* Moreover, if the path is not for a leaf, ie accountPath+/X/Y, there is no
|
|
32
83
|
* way to get the address from the device. In this case we have to create it
|
|
@@ -34,41 +85,38 @@ export default class BtcNew {
|
|
|
34
85
|
*/
|
|
35
86
|
private getWalletAddress;
|
|
36
87
|
/**
|
|
37
|
-
*
|
|
38
|
-
*
|
|
88
|
+
* Build and sign a transaction. See Btc.createPaymentTransactionNew for
|
|
89
|
+
* details on how to use this method.
|
|
39
90
|
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
* * sequence is the sequence number to use for this input (when using RBF), or non present
|
|
44
|
-
* @param associatedKeysets is an array of BIP 32 paths pointing to the path to the private key used for each UTXO
|
|
45
|
-
* @param changePath is an optional BIP 32 path pointing to the path to the public key used to compute the change address
|
|
46
|
-
* @param outputScriptHex is the hexadecimal serialized outputs of the transaction to sign, including leading vararg voutCount
|
|
47
|
-
* @param lockTime is the optional lockTime of the transaction to sign, or default (0)
|
|
48
|
-
* @param sigHashType is the hash type of the transaction to sign, or default (all)
|
|
49
|
-
* @param segwit is an optional boolean indicating wether to use segwit or not. This includes wrapped segwit.
|
|
50
|
-
* @param initialTimestamp is an optional timestamp of the function call to use for coins that necessitate timestamps only, (not the one that the tx will include)
|
|
51
|
-
* @param additionals list of additionnal options
|
|
52
|
-
*
|
|
53
|
-
* - "bech32" for spending native segwit outputs
|
|
54
|
-
* - "bech32m" for spending segwit v1+ outptus
|
|
55
|
-
* - "abc" for bch
|
|
56
|
-
* - "gold" for btg
|
|
57
|
-
* - "bipxxx" for using BIPxxx
|
|
58
|
-
* - "sapling" to indicate a zec transaction is supporting sapling (to be set over block 419200)
|
|
59
|
-
* @param expiryHeight is an optional Buffer for zec overwinter / sapling Txs
|
|
60
|
-
* @param useTrustedInputForSegwit trust inputs for segwit transactions. If app version >= 1.4.0 this should be true.
|
|
61
|
-
* @return the signed transaction ready to be broadcast
|
|
62
|
-
* @example
|
|
63
|
-
btc.createTransaction({
|
|
64
|
-
inputs: [ [tx1, 1] ],
|
|
65
|
-
associatedKeysets: ["0'/0/0"],
|
|
66
|
-
outputScriptHex: "01905f0100000000001976a91472a5d75c8d2d0565b656a5232703b167d50d5a2b88ac"
|
|
67
|
-
}).then(res => ...);
|
|
91
|
+
* This method will convert the legacy arguments, CreateTransactionArg, into
|
|
92
|
+
* a psbt which is finally signed and finalized, and the extracted fully signed
|
|
93
|
+
* transaction is returned.
|
|
68
94
|
*/
|
|
69
95
|
createPaymentTransactionNew(arg: CreateTransactionArg): Promise<string>;
|
|
96
|
+
/**
|
|
97
|
+
* Calculates an output script along with public key and possible redeemScript
|
|
98
|
+
* from a path and accountType. The accountPath must be a prefix of path.
|
|
99
|
+
*
|
|
100
|
+
* @returns an object with output script (property "script"), redeemScript (if
|
|
101
|
+
* wrapped p2wpkh), and pubkey at provided path. The values of these three
|
|
102
|
+
* properties depend on the accountType used.
|
|
103
|
+
*/
|
|
70
104
|
private outputScriptAt;
|
|
105
|
+
/**
|
|
106
|
+
* Adds relevant data about an input to the psbt. This includes sequence,
|
|
107
|
+
* previous txid, output index, spent UTXO, redeem script for wrapped p2wpkh,
|
|
108
|
+
* public key and its derivation path.
|
|
109
|
+
*/
|
|
71
110
|
private setInput;
|
|
111
|
+
/**
|
|
112
|
+
* This implements the "Signer" role of the BIP370 transaction signing
|
|
113
|
+
* process.
|
|
114
|
+
*
|
|
115
|
+
* It ssks the hardware device to sign the a psbt using the specified wallet
|
|
116
|
+
* policy. This method assumes BIP32 derived keys are used for all inputs, see
|
|
117
|
+
* comment in-line. The signatures returned from the hardware device is added
|
|
118
|
+
* to the appropriate input fields of the PSBT.
|
|
119
|
+
*/
|
|
72
120
|
private signPsbt;
|
|
73
121
|
}
|
|
74
122
|
//# sourceMappingURL=BtcNew.d.ts.map
|
package/lib/BtcNew.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BtcNew.d.ts","sourceRoot":"","sources":["../src/BtcNew.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BtcNew.d.ts","sourceRoot":"","sources":["../src/BtcNew.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAS1D,OAAO,EAAE,SAAS,IAAI,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAczD,wBAAgB,aAAa,CAAC,aAAa,EAAE,aAAa,GAAG,OAAO,CAKnE;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,OAAO,OAAO,MAAM;IACb,OAAO,CAAC,MAAM;gBAAN,MAAM,EAAE,MAAM;IAElC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6BG;IACG,aAAa,CAAC,EAClB,IAAI,EACJ,WAAW,GACZ,EAAE;QACD,IAAI,EAAE,MAAM,CAAC;QACb,WAAW,EAAE,MAAM,CAAC;KACrB,GAAG,OAAO,CAAC,MAAM,CAAC;IAYnB;;;;;;OAMG;IACG,kBAAkB,CACtB,IAAI,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE;QACL,MAAM,CAAC,EAAE,OAAO,CAAC;QACjB,MAAM,CAAC,EAAE,aAAa,CAAC;KACxB,GACA,OAAO,CAAC;QACT,SAAS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