@ledgerhq/hw-app-eth 7.0.0-nightly.2 → 7.0.0-nightly.20251120135143
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/.turbo/turbo-build.log +2 -2
- package/.unimportedrc.json +3 -28
- package/CHANGELOG.md +994 -17
- package/README.md +100 -0
- package/jest.config.ts +18 -0
- package/lib/Eth.d.ts +3 -18
- package/lib/Eth.d.ts.map +1 -1
- package/lib/Eth.js +160 -198
- package/lib/Eth.js.map +1 -1
- package/lib/errors.d.ts +3 -0
- package/lib/errors.d.ts.map +1 -1
- package/lib/errors.js +2 -1
- package/lib/errors.js.map +1 -1
- package/lib/modules/Domains/index.js +6 -15
- package/lib/modules/Domains/index.js.map +1 -1
- package/lib/modules/EIP712/index.d.ts.map +1 -1
- package/lib/modules/EIP712/index.js +112 -125
- package/lib/modules/EIP712/index.js.map +1 -1
- package/lib/modules/EIP712/types.d.ts +1 -0
- package/lib/modules/EIP712/types.d.ts.map +1 -1
- package/lib/modules/EIP712/utils.d.ts +1 -0
- package/lib/modules/EIP712/utils.d.ts.map +1 -1
- package/lib/modules/EIP712/utils.js +14 -24
- package/lib/modules/EIP712/utils.js.map +1 -1
- package/lib/modules/Uniswap/constants.d.ts.map +1 -1
- package/lib/modules/Uniswap/constants.js +1 -0
- package/lib/modules/Uniswap/constants.js.map +1 -1
- package/lib/modules/Uniswap/decoders.d.ts.map +1 -1
- package/lib/modules/Uniswap/decoders.js +8 -3
- package/lib/modules/Uniswap/decoders.js.map +1 -1
- package/lib/modules/Uniswap/index.d.ts +2 -1
- package/lib/modules/Uniswap/index.d.ts.map +1 -1
- package/lib/modules/Uniswap/index.js +11 -20
- package/lib/modules/Uniswap/index.js.map +1 -1
- package/lib/modules/Uniswap/types.d.ts +1 -1
- package/lib/modules/Uniswap/types.d.ts.map +1 -1
- package/lib/services/ledger/contracts.js +4 -13
- package/lib/services/ledger/contracts.js.map +1 -1
- package/lib/services/ledger/erc20.d.ts +2 -1
- package/lib/services/ledger/erc20.d.ts.map +1 -1
- package/lib/services/ledger/erc20.js +16 -32
- package/lib/services/ledger/erc20.js.map +1 -1
- package/lib/services/ledger/index.d.ts.map +1 -1
- package/lib/services/ledger/index.js +34 -32
- package/lib/services/ledger/index.js.map +1 -1
- package/lib/services/ledger/loadConfig.d.ts.map +1 -1
- package/lib/services/ledger/loadConfig.js +7 -1
- package/lib/services/ledger/loadConfig.js.map +1 -1
- package/lib/services/ledger/nfts.js +9 -19
- package/lib/services/ledger/nfts.js.map +1 -1
- package/lib/services/types.d.ts +3 -0
- package/lib/services/types.d.ts.map +1 -1
- package/lib/utils.d.ts +56 -9
- package/lib/utils.d.ts.map +1 -1
- package/lib/utils.js +175 -81
- package/lib/utils.js.map +1 -1
- package/lib-es/Eth.d.ts +3 -18
- package/lib-es/Eth.d.ts.map +1 -1
- package/lib-es/Eth.js +160 -198
- package/lib-es/Eth.js.map +1 -1
- package/lib-es/errors.d.ts +3 -0
- package/lib-es/errors.d.ts.map +1 -1
- package/lib-es/errors.js +1 -0
- package/lib-es/errors.js.map +1 -1
- package/lib-es/modules/Domains/index.js +6 -15
- package/lib-es/modules/Domains/index.js.map +1 -1
- package/lib-es/modules/EIP712/index.d.ts.map +1 -1
- package/lib-es/modules/EIP712/index.js +112 -125
- package/lib-es/modules/EIP712/index.js.map +1 -1
- package/lib-es/modules/EIP712/types.d.ts +1 -0
- package/lib-es/modules/EIP712/types.d.ts.map +1 -1
- package/lib-es/modules/EIP712/utils.d.ts +1 -0
- package/lib-es/modules/EIP712/utils.d.ts.map +1 -1
- package/lib-es/modules/EIP712/utils.js +14 -24
- package/lib-es/modules/EIP712/utils.js.map +1 -1
- package/lib-es/modules/Uniswap/constants.d.ts.map +1 -1
- package/lib-es/modules/Uniswap/constants.js +1 -0
- package/lib-es/modules/Uniswap/constants.js.map +1 -1
- package/lib-es/modules/Uniswap/decoders.d.ts.map +1 -1
- package/lib-es/modules/Uniswap/decoders.js +8 -3
- package/lib-es/modules/Uniswap/decoders.js.map +1 -1
- package/lib-es/modules/Uniswap/index.d.ts +2 -1
- package/lib-es/modules/Uniswap/index.d.ts.map +1 -1
- package/lib-es/modules/Uniswap/index.js +11 -20
- package/lib-es/modules/Uniswap/index.js.map +1 -1
- package/lib-es/modules/Uniswap/types.d.ts +1 -1
- package/lib-es/modules/Uniswap/types.d.ts.map +1 -1
- package/lib-es/services/ledger/contracts.js +4 -13
- package/lib-es/services/ledger/contracts.js.map +1 -1
- package/lib-es/services/ledger/erc20.d.ts +2 -1
- package/lib-es/services/ledger/erc20.d.ts.map +1 -1
- package/lib-es/services/ledger/erc20.js +16 -32
- package/lib-es/services/ledger/erc20.js.map +1 -1
- package/lib-es/services/ledger/index.d.ts.map +1 -1
- package/lib-es/services/ledger/index.js +34 -32
- package/lib-es/services/ledger/index.js.map +1 -1
- package/lib-es/services/ledger/loadConfig.d.ts.map +1 -1
- package/lib-es/services/ledger/loadConfig.js +7 -1
- package/lib-es/services/ledger/loadConfig.js.map +1 -1
- package/lib-es/services/ledger/nfts.js +9 -19
- package/lib-es/services/ledger/nfts.js.map +1 -1
- package/lib-es/services/types.d.ts +3 -0
- package/lib-es/services/types.d.ts.map +1 -1
- package/lib-es/utils.d.ts +56 -9
- package/lib-es/utils.d.ts.map +1 -1
- package/lib-es/utils.js +148 -81
- package/lib-es/utils.js.map +1 -1
- package/package.json +19 -15
- package/src/Eth.ts +51 -82
- package/src/errors.ts +3 -0
- package/src/modules/EIP712/index.ts +17 -4
- package/src/modules/Uniswap/constants.ts +1 -0
- package/src/modules/Uniswap/decoders.ts +10 -3
- package/src/modules/Uniswap/index.ts +9 -8
- package/src/modules/Uniswap/types.ts +2 -1
- package/src/services/ledger/erc20.ts +16 -19
- package/src/services/ledger/index.ts +50 -22
- package/src/services/ledger/loadConfig.ts +4 -1
- package/src/services/ledger/nfts.ts +1 -1
- package/src/services/types.ts +12 -0
- package/src/utils.ts +170 -85
- package/tests/EIP712/filtered-signMessage.unit.test.ts +28 -116
- package/tests/EIP712/noFilter-signMessage.unit.test.ts +0 -2
- package/tests/ERC20/ERC20-CAL-KO.unit.test.ts +14 -25
- package/tests/ERC20/ERC20-CAL-OK.unit.test.ts +15 -10
- package/tests/Eth.unit.test.ts +242 -314
- package/tests/Uniswap/decoders.unit.test.ts +10 -0
- package/tests/Uniswap/index.unit.test.ts +17 -26
- package/tests/fixtures/messages/15-permit.json +3 -3
- package/tests/fixtures/messages/16-permit2.json +3 -3
- package/tests/fixtures/messages/17-uniswapx.json +5 -5
- package/tests/fixtures/utils.ts +17 -18
- package/tests/ledgerService.unit.test.ts +5 -7
- package/tests/utils.unit.test.ts +341 -0
package/lib/utils.js
CHANGED
|
@@ -1,33 +1,60 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
2
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
26
|
+
exports.safeChunkTransaction = exports.getV = exports.getChainIdAsUint32 = exports.getParity = exports.mergeResolutions = exports.nftSelectors = exports.tokenSelectors = exports.intAsHexBytes = exports.maybeHexBuffer = exports.hexBuffer = exports.splitPath = exports.padHexString = exports.DAPP_SELECTORS = exports.ERC1155_CLEAR_SIGNED_SELECTORS = exports.ERC721_CLEAR_SIGNED_SELECTORS = exports.ERC20_CLEAR_SIGNED_SELECTORS = void 0;
|
|
4
27
|
const bignumber_js_1 = require("bignumber.js");
|
|
28
|
+
const rlp = __importStar(require("@ethersproject/rlp"));
|
|
5
29
|
const index_1 = require("@ledgerhq/evm-tools/selectors/index");
|
|
6
30
|
Object.defineProperty(exports, "ERC20_CLEAR_SIGNED_SELECTORS", { enumerable: true, get: function () { return index_1.ERC20_CLEAR_SIGNED_SELECTORS; } });
|
|
7
31
|
Object.defineProperty(exports, "ERC721_CLEAR_SIGNED_SELECTORS", { enumerable: true, get: function () { return index_1.ERC721_CLEAR_SIGNED_SELECTORS; } });
|
|
8
32
|
Object.defineProperty(exports, "ERC1155_CLEAR_SIGNED_SELECTORS", { enumerable: true, get: function () { return index_1.ERC1155_CLEAR_SIGNED_SELECTORS; } });
|
|
9
|
-
|
|
33
|
+
Object.defineProperty(exports, "DAPP_SELECTORS", { enumerable: true, get: function () { return index_1.DAPP_SELECTORS; } });
|
|
10
34
|
const padHexString = (str) => {
|
|
11
35
|
return str.length % 2 ? "0" + str : str;
|
|
12
36
|
};
|
|
13
37
|
exports.padHexString = padHexString;
|
|
14
38
|
function splitPath(path) {
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
let
|
|
19
|
-
if (isNaN(
|
|
39
|
+
const splittedPath = [];
|
|
40
|
+
const paths = path.split("/");
|
|
41
|
+
paths.forEach(path => {
|
|
42
|
+
let value = parseInt(path, 10);
|
|
43
|
+
if (isNaN(value)) {
|
|
20
44
|
return; // FIXME shouldn't it throws instead?
|
|
21
45
|
}
|
|
22
|
-
|
|
23
|
-
|
|
46
|
+
// Detect hardened paths
|
|
47
|
+
if (path.length > 1 && path[path.length - 1] === "'") {
|
|
48
|
+
value += 0x80000000;
|
|
24
49
|
}
|
|
25
|
-
|
|
50
|
+
splittedPath.push(value);
|
|
26
51
|
});
|
|
27
|
-
return
|
|
52
|
+
return splittedPath;
|
|
28
53
|
}
|
|
29
54
|
exports.splitPath = splitPath;
|
|
30
55
|
function hexBuffer(str) {
|
|
56
|
+
if (!str)
|
|
57
|
+
return Buffer.alloc(0);
|
|
31
58
|
const strWithoutPrefix = str.startsWith("0x") ? str.slice(2) : str;
|
|
32
59
|
return Buffer.from((0, exports.padHexString)(strWithoutPrefix), "hex");
|
|
33
60
|
}
|
|
@@ -38,76 +65,6 @@ function maybeHexBuffer(str) {
|
|
|
38
65
|
return hexBuffer(str);
|
|
39
66
|
}
|
|
40
67
|
exports.maybeHexBuffer = maybeHexBuffer;
|
|
41
|
-
const decodeTxInfo = (rawTx) => {
|
|
42
|
-
const VALID_TYPES = [1, 2];
|
|
43
|
-
const txType = VALID_TYPES.includes(rawTx[0]) ? rawTx[0] : null;
|
|
44
|
-
const rlpData = txType === null ? rawTx : rawTx.slice(1);
|
|
45
|
-
const rlpTx = (0, rlp_1.decode)(rlpData).map(hex => Buffer.from(hex.slice(2), "hex"));
|
|
46
|
-
let chainIdTruncated = 0;
|
|
47
|
-
const rlpDecoded = (0, rlp_1.decode)(rlpData);
|
|
48
|
-
let decodedTx;
|
|
49
|
-
if (txType === 2) {
|
|
50
|
-
// EIP1559
|
|
51
|
-
decodedTx = {
|
|
52
|
-
data: rlpDecoded[7],
|
|
53
|
-
to: rlpDecoded[5],
|
|
54
|
-
chainId: rlpTx[0],
|
|
55
|
-
};
|
|
56
|
-
}
|
|
57
|
-
else if (txType === 1) {
|
|
58
|
-
// EIP2930
|
|
59
|
-
decodedTx = {
|
|
60
|
-
data: rlpDecoded[6],
|
|
61
|
-
to: rlpDecoded[4],
|
|
62
|
-
chainId: rlpTx[0],
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
else {
|
|
66
|
-
// Legacy tx
|
|
67
|
-
decodedTx = {
|
|
68
|
-
data: rlpDecoded[5],
|
|
69
|
-
to: rlpDecoded[3],
|
|
70
|
-
// Default to 1 for non EIP 155 txs
|
|
71
|
-
chainId: rlpTx.length > 6 ? rlpTx[6] : Buffer.from("01", "hex"),
|
|
72
|
-
};
|
|
73
|
-
}
|
|
74
|
-
const chainIdSrc = decodedTx.chainId;
|
|
75
|
-
let chainId = new bignumber_js_1.BigNumber(0);
|
|
76
|
-
if (chainIdSrc) {
|
|
77
|
-
// Using BigNumber because chainID could be any uint256.
|
|
78
|
-
chainId = new bignumber_js_1.BigNumber(chainIdSrc.toString("hex"), 16);
|
|
79
|
-
const chainIdTruncatedBuf = Buffer.alloc(4);
|
|
80
|
-
if (chainIdSrc.length > 4) {
|
|
81
|
-
chainIdSrc.copy(chainIdTruncatedBuf);
|
|
82
|
-
}
|
|
83
|
-
else {
|
|
84
|
-
chainIdSrc.copy(chainIdTruncatedBuf, 4 - chainIdSrc.length);
|
|
85
|
-
}
|
|
86
|
-
chainIdTruncated = chainIdTruncatedBuf.readUInt32BE(0);
|
|
87
|
-
}
|
|
88
|
-
let vrsOffset = 0;
|
|
89
|
-
if (txType === null && rlpTx.length > 6) {
|
|
90
|
-
const rlpVrs = Buffer.from((0, rlp_1.encode)(rlpTx.slice(-3)).slice(2), "hex");
|
|
91
|
-
vrsOffset = rawTx.length - (rlpVrs.length - 1);
|
|
92
|
-
// First byte > 0xf7 means the length of the list length doesn't fit in a single byte.
|
|
93
|
-
if (rlpVrs[0] > 0xf7) {
|
|
94
|
-
// Increment vrsOffset to account for that extra byte.
|
|
95
|
-
vrsOffset++;
|
|
96
|
-
// Compute size of the list length.
|
|
97
|
-
const sizeOfListLen = rlpVrs[0] - 0xf7;
|
|
98
|
-
// Increase rlpOffset by the size of the list length.
|
|
99
|
-
vrsOffset += sizeOfListLen - 1;
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
return {
|
|
103
|
-
decodedTx,
|
|
104
|
-
txType,
|
|
105
|
-
chainId,
|
|
106
|
-
chainIdTruncated,
|
|
107
|
-
vrsOffset,
|
|
108
|
-
};
|
|
109
|
-
};
|
|
110
|
-
exports.decodeTxInfo = decodeTxInfo;
|
|
111
68
|
/**
|
|
112
69
|
* @ignore for the README
|
|
113
70
|
*
|
|
@@ -141,4 +98,141 @@ const mergeResolutions = (resolutionsArray) => {
|
|
|
141
98
|
return mergedResolutions;
|
|
142
99
|
};
|
|
143
100
|
exports.mergeResolutions = mergeResolutions;
|
|
101
|
+
/**
|
|
102
|
+
* @ignore for the README
|
|
103
|
+
*
|
|
104
|
+
* Ledger devices are returning v with potentially EIP-155 already applied when using legacy transactions.
|
|
105
|
+
* Because that v value is only represented as a single byte, we need to replicate what would be the
|
|
106
|
+
* overflow happening on the device while applying EIP-155 and recover the original parity.
|
|
107
|
+
*
|
|
108
|
+
* @param vFromDevice
|
|
109
|
+
* @param chainIdUint32
|
|
110
|
+
* @returns
|
|
111
|
+
*/
|
|
112
|
+
const getParity = (vFromDevice, chainId, transactionType) => {
|
|
113
|
+
if (transactionType)
|
|
114
|
+
return vFromDevice;
|
|
115
|
+
// The device use a 4 bytes integer to represent the chainId and keeps the highest bytes
|
|
116
|
+
const chainIdUint32 = (0, exports.getChainIdAsUint32)(chainId);
|
|
117
|
+
// Then applies EIP-155 to this chainId
|
|
118
|
+
const chainIdWithEIP155 = chainIdUint32 * 2 + 35;
|
|
119
|
+
// Since it's a single byte, we need to apply the overflow after reaching the max 0xff value and starting again to 0x00
|
|
120
|
+
// for both possible values, the chainId with EIP155 and a 0 or 1 parity included
|
|
121
|
+
const chainIdWithOverflowZero = chainIdWithEIP155 % 256;
|
|
122
|
+
const chainIdWithOverflowOne = (chainIdWithEIP155 + 1) % 256;
|
|
123
|
+
if (chainIdWithOverflowZero === vFromDevice) {
|
|
124
|
+
return 0;
|
|
125
|
+
}
|
|
126
|
+
else if (chainIdWithOverflowOne === vFromDevice) {
|
|
127
|
+
return 1;
|
|
128
|
+
}
|
|
129
|
+
throw new Error("Invalid v value");
|
|
130
|
+
};
|
|
131
|
+
exports.getParity = getParity;
|
|
132
|
+
/**
|
|
133
|
+
* @ignore for the README
|
|
134
|
+
*
|
|
135
|
+
* Helper to convert a chainId from a BigNumber to a 4 bytes integer.
|
|
136
|
+
* ChainIds are uint256, but the device limits them to 4 bytes
|
|
137
|
+
*
|
|
138
|
+
* @param {Number|BigNumber} chainId
|
|
139
|
+
* @returns {Number}
|
|
140
|
+
*/
|
|
141
|
+
const getChainIdAsUint32 = (chainId) => {
|
|
142
|
+
const chainIdBuff = Buffer.from((0, exports.padHexString)(new bignumber_js_1.BigNumber(chainId).toString(16)), "hex");
|
|
143
|
+
const chainIdUint32 = chainIdBuff.subarray(0, 4);
|
|
144
|
+
return parseInt(chainIdUint32.toString("hex"), 16);
|
|
145
|
+
};
|
|
146
|
+
exports.getChainIdAsUint32 = getChainIdAsUint32;
|
|
147
|
+
/**
|
|
148
|
+
* @ignore for the README
|
|
149
|
+
*
|
|
150
|
+
* Depending on the transaction type you're trying to sign with the device, the v value will be different.
|
|
151
|
+
* For legacy transactions, the v value is used to store the chainId, and that chainId can be a uint256,
|
|
152
|
+
* and some math operation should be applied to it in order to comply with EIP-155 for replay attacks.
|
|
153
|
+
*
|
|
154
|
+
* In order to prevent breaking changes at the time, the `v` value has been kept as a single byte
|
|
155
|
+
* which forces us to replicate an overflow happening on the device to get the correct `v` value
|
|
156
|
+
*
|
|
157
|
+
* @param {number} vFromDevice
|
|
158
|
+
* @param {BigNumber} chainId
|
|
159
|
+
* @param {Transaction["type"]} transactionType
|
|
160
|
+
* @returns {string} hexa string of the v value
|
|
161
|
+
*/
|
|
162
|
+
const getV = (vFromDevice, chainId, transactionType) => {
|
|
163
|
+
if (chainId.isZero())
|
|
164
|
+
return vFromDevice.toString(16);
|
|
165
|
+
const parity = (0, exports.getParity)(vFromDevice, chainId, transactionType);
|
|
166
|
+
return !transactionType
|
|
167
|
+
? // Legacy transactions (type 0) should apply EIP-155
|
|
168
|
+
// EIP-155: rlp[(nonce, gasprice, startgas, to, value, data, chainid, 0, 0)]
|
|
169
|
+
(0, exports.padHexString)(chainId.times(2).plus(35).plus(parity).toString(16))
|
|
170
|
+
: // Transactions after type 1 should only use partity (00/01) as their v value
|
|
171
|
+
// EIP-2930: 0x01 || rlp([chainId, nonce, gasPrice, gasLimit, to, value, data, accessList, *signatureYParity*, signatureR, signatureS])
|
|
172
|
+
// EIP-1559: 0x02 || rlp([chain_id, nonce, max_priority_fee_per_gas, max_fee_per_gas, gas_limit, destination, amount, data, access_list, *signature_y_parity*, signature_r, signature_s])
|
|
173
|
+
// EIP-4844: 0x03 || rlp([chain_id, nonce, max_priority_fee_per_gas, max_fee_per_gas, gas_limit, to, value, data, access_list, max_fee_per_blob_gas, blob_versioned_hashes, *y_parity*, r, s])
|
|
174
|
+
// EIP-7702: 0x05 || rlp([chain_id, nonce, max_priority_fee_per_gas, max_fee_per_gas, gas_limit, destination, value, data, access_list, authorization_list, *signature_y_parity*, signature_r, signature_s])
|
|
175
|
+
(0, exports.padHexString)(parity.toString(16));
|
|
176
|
+
};
|
|
177
|
+
exports.getV = getV;
|
|
178
|
+
/**
|
|
179
|
+
* @ignore for the README
|
|
180
|
+
*
|
|
181
|
+
* In order to prevent the device from considering a transaction RLP as complete before it actually is
|
|
182
|
+
* we need to split the RLP into chunks which could not be mistaken for a complete transaction.
|
|
183
|
+
* This is true for legacy transaction, where the `v` value is used to store the chainId
|
|
184
|
+
*
|
|
185
|
+
* @param {Buffer} transactionRlp
|
|
186
|
+
* @param {Buffer }derivationPath
|
|
187
|
+
* @param {Transaction["type"]} transactionType
|
|
188
|
+
*
|
|
189
|
+
* @returns {Buffer[]}
|
|
190
|
+
*/
|
|
191
|
+
const safeChunkTransaction = (transactionRlp, derivationPath, transactionType) => {
|
|
192
|
+
const maxChunkSize = 255;
|
|
193
|
+
// The full payload is the derivation path + the complete RLP of the transaction
|
|
194
|
+
const payload = Buffer.concat([derivationPath, transactionRlp]);
|
|
195
|
+
if (payload.length <= maxChunkSize)
|
|
196
|
+
return [payload];
|
|
197
|
+
if (transactionType) {
|
|
198
|
+
const chunks = Math.ceil(payload.length / maxChunkSize);
|
|
199
|
+
return new Array(chunks)
|
|
200
|
+
.fill(null)
|
|
201
|
+
.map((_, i) => payload.subarray(i * maxChunkSize, (i + 1) * maxChunkSize));
|
|
202
|
+
}
|
|
203
|
+
// Decode the RLP of the full transaction and keep only the last 3 elements (v, r, s)
|
|
204
|
+
const decodedVrs = rlp.decode(transactionRlp).slice(-3);
|
|
205
|
+
// Encode those values back to RLP in order to get the length of this serialized list
|
|
206
|
+
// Result should be something like [0xc0 + list payload length, list.map(rlp)]
|
|
207
|
+
// since only v can be used to store the chainId in legacy transactions
|
|
208
|
+
const encodedVrs = rlp.encode(decodedVrs);
|
|
209
|
+
// Since chainIds are uint256, the list payload length can be 1B (v rlp description) + 32B (v) + 1B (r) + 1B (s) = 35B max (< 55B)
|
|
210
|
+
// Therefore, the RLP of this vrs list should be prefixed by a value between [0xc1, 0xe3] (0xc0 + 35B = 0xe3 max)
|
|
211
|
+
// @see https://ethereum.org/en/developers/docs/data-structures-and-encoding/rlp/
|
|
212
|
+
// `encodedVrs` is then everything but the first byte of this serialization
|
|
213
|
+
const encodedVrsBuff = hexBuffer(encodedVrs).subarray(1);
|
|
214
|
+
// Since we want to avoid chunking just before the v,r,s values,
|
|
215
|
+
// we just check the size of that payload and detect
|
|
216
|
+
// if it would fit perfectly in 255B chunks
|
|
217
|
+
// if it does, we chunk smaller parts
|
|
218
|
+
let chunkSize = 0;
|
|
219
|
+
const lastChunkSize = payload.length % maxChunkSize;
|
|
220
|
+
if (lastChunkSize === 0 || lastChunkSize > encodedVrsBuff.length) {
|
|
221
|
+
chunkSize = maxChunkSize;
|
|
222
|
+
}
|
|
223
|
+
else {
|
|
224
|
+
for (let i = 1; i <= maxChunkSize; i++) {
|
|
225
|
+
const lastChunkSize = payload.length % (maxChunkSize - i);
|
|
226
|
+
if (lastChunkSize === 0 || lastChunkSize > encodedVrsBuff.length) {
|
|
227
|
+
chunkSize = maxChunkSize - i;
|
|
228
|
+
break;
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
const chunks = Math.ceil(payload.length / chunkSize);
|
|
233
|
+
return new Array(chunks)
|
|
234
|
+
.fill(null)
|
|
235
|
+
.map((_, i) => payload.subarray(i * chunkSize, (i + 1) * chunkSize));
|
|
236
|
+
};
|
|
237
|
+
exports.safeChunkTransaction = safeChunkTransaction;
|
|
144
238
|
//# sourceMappingURL=utils.js.map
|
package/lib/utils.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAAyC;AACzC,wDAA0C;AAC1C,+DAK6C;AAK3C,6GATA,oCAA4B,OASA;AAC5B,8GATA,qCAA6B,OASA;AAC7B,+GATA,sCAA8B,OASA;AAC9B,+FATA,sBAAc,OASA;AAGT,MAAM,YAAY,GAAG,CAAC,GAAW,EAAE,EAAE;IAC1C,OAAO,GAAG,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC;AAC1C,CAAC,CAAC;AAFW,QAAA,YAAY,gBAEvB;AAEF,SAAgB,SAAS,CAAC,IAAY;IACpC,MAAM,YAAY,GAAa,EAAE,CAAC;IAElC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,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,oDAAoD;IACpD,2CAA2C;IAC3C,qCAAqC;IACrC,IAAI,SAAS,GAAG,CAAC,CAAC;IAClB,MAAM,aAAa,GAAG,OAAO,CAAC,MAAM,GAAG,YAAY,CAAC;IACpD,IAAI,aAAa,KAAK,CAAC,IAAI,aAAa,GAAG,cAAc,CAAC,MAAM,EAAE,CAAC;QACjE,SAAS,GAAG,YAAY,CAAC;IAC3B,CAAC;SAAM,CAAC;QACN,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,YAAY,EAAE,CAAC,EAAE,EAAE,CAAC;YACvC,MAAM,aAAa,GAAG,OAAO,CAAC,MAAM,GAAG,CAAC,YAAY,GAAG,CAAC,CAAC,CAAC;YAC1D,IAAI,aAAa,KAAK,CAAC,IAAI,aAAa,GAAG,cAAc,CAAC,MAAM,EAAE,CAAC;gBACjE,SAAS,GAAG,YAAY,GAAG,CAAC,CAAC;gBAC7B,MAAM;YACR,CAAC;QACH,CAAC;IACH,CAAC;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IACrD,OAAO,IAAI,KAAK,CAAC,MAAM,CAAC;SACrB,IAAI,CAAC,IAAI,CAAC;SACV,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,GAAG,SAAS,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC;AACzE,CAAC,CAAC;AAlDW,QAAA,oBAAoB,wBAkD/B"}
|
package/lib-es/Eth.d.ts
CHANGED
|
@@ -1,25 +1,10 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
|
|
3
|
-
* Ledger Node JS API
|
|
4
|
-
* (c) 2016-2017 Ledger
|
|
5
|
-
*
|
|
6
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
-
* you may not use this file except in compliance with the License.
|
|
8
|
-
* You may obtain a copy of the License at
|
|
9
|
-
*
|
|
10
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
-
*
|
|
12
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
-
* See the License for the specific language governing permissions and
|
|
16
|
-
* limitations under the License.
|
|
17
|
-
********************************************************************************/
|
|
18
|
-
import type Transport from "@ledgerhq/hw-transport";
|
|
2
|
+
/// <reference types="node" />
|
|
19
3
|
import { BigNumber } from "bignumber.js";
|
|
4
|
+
import type Transport from "@ledgerhq/hw-transport";
|
|
5
|
+
import { EIP712Message } from "@ledgerhq/types-live";
|
|
20
6
|
import { LedgerEthTransactionResolution, LoadConfig, ResolutionConfig } from "./services/types";
|
|
21
7
|
import ledgerService from "./services/ledger";
|
|
22
|
-
import { EIP712Message } from "@ledgerhq/types-live";
|
|
23
8
|
export { ledgerService };
|
|
24
9
|
export * from "./utils";
|
|
25
10
|
export type StarkQuantizationType = "eth" | "erc20" | "erc721" | "erc20mintable" | "erc721mintable";
|
package/lib-es/Eth.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Eth.d.ts","sourceRoot":"","sources":["../src/Eth.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Eth.d.ts","sourceRoot":"","sources":["../src/Eth.ts"],"names":[],"mappings":";;AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,SAAS,MAAM,wBAAwB,CAAC;AACpD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAErD,OAAO,EAAE,8BAA8B,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAQhG,OAAO,aAAa,MAAM,mBAAmB,CAAC;AAW9C,OAAO,EAAE,aAAa,EA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