@onekeyfe/hd-core 1.2.8-alpha.100 → 1.2.8-alpha.101
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/__tests__/core-dispose.test.ts +114 -1
- package/__tests__/core-error-output.test.ts +21 -0
- package/__tests__/device-connector-protocol.test.ts +5 -2
- package/__tests__/device-lifecycle-events.test.ts +22 -3
- package/__tests__/logBlockEvent.test.ts +1 -1
- package/__tests__/usb-identity-probe.test.ts +358 -0
- package/__tests__/zcash-protobuf.test.ts +141 -0
- package/__tests__/zcash-sign-pczt.test.ts +180 -5
- package/dist/api/FirmwareUpdateV4.d.ts.map +1 -1
- package/dist/api/SearchDevices.d.ts +21 -1
- package/dist/api/SearchDevices.d.ts.map +1 -1
- package/dist/api/zcash/ZcashSignPczt.d.ts +0 -1
- package/dist/api/zcash/ZcashSignPczt.d.ts.map +1 -1
- package/dist/core/index.d.ts +3 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/device/DeviceCommands.d.ts +4 -4
- package/dist/events/logBlockEvent.d.ts.map +1 -1
- package/dist/index.d.ts +36 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2702 -2544
- package/dist/types/device.d.ts +9 -0
- package/dist/types/device.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/api/FirmwareUpdateV4.ts +4 -7
- package/src/api/SearchDevices.ts +172 -7
- package/src/api/zcash/ZcashSignPczt.ts +12 -10
- package/src/core/index.ts +45 -14
- package/src/device/DeviceConnector.ts +4 -4
- package/src/events/logBlockEvent.ts +0 -1
- package/src/index.ts +1 -0
- package/src/types/device.ts +12 -0
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
import * as protobuf from 'protobufjs/light';
|
|
2
|
+
import transport from '@onekeyfe/hd-transport';
|
|
3
|
+
|
|
4
|
+
import messagesJson from '../src/data/messages/messages-protocol-v2.json';
|
|
5
|
+
|
|
6
|
+
// Round-trips the Zcash messages through the SDK's real protobuf encoder and
|
|
7
|
+
// decoder against the shipped protocol V2 schema, pinning wire ids and defaults.
|
|
8
|
+
const {
|
|
9
|
+
createMessageFromName,
|
|
10
|
+
decodeProtobuf: decode,
|
|
11
|
+
encodeProtobuf: encode,
|
|
12
|
+
parseConfigure,
|
|
13
|
+
} = transport;
|
|
14
|
+
const messages = parseConfigure(messagesJson as protobuf.INamespace);
|
|
15
|
+
|
|
16
|
+
const wireFieldIds = (buf: Uint8Array) => {
|
|
17
|
+
const reader = protobuf.Reader.create(buf);
|
|
18
|
+
const ids: number[] = [];
|
|
19
|
+
while (reader.pos < reader.len) {
|
|
20
|
+
const tag = reader.uint32();
|
|
21
|
+
// eslint-disable-next-line no-bitwise
|
|
22
|
+
ids.push(tag >>> 3);
|
|
23
|
+
// eslint-disable-next-line no-bitwise
|
|
24
|
+
reader.skipType(tag & 7);
|
|
25
|
+
}
|
|
26
|
+
return ids;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
const roundTrip = (name: string, data: Record<string, unknown>) => {
|
|
30
|
+
const { Message, messageTypeId } = createMessageFromName(messages, name);
|
|
31
|
+
const encoded = encode(Message, data);
|
|
32
|
+
const bytes = new Uint8Array(encoded.toBuffer());
|
|
33
|
+
return { messageTypeId, ids: wireFieldIds(bytes), decoded: decode(Message, encoded) };
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
describe('Zcash protobuf messages (protocol V2)', () => {
|
|
37
|
+
test.each([
|
|
38
|
+
['ZcashGetAddress', 12400],
|
|
39
|
+
['ZcashAddress', 12401],
|
|
40
|
+
['ZcashSignPczt', 12402],
|
|
41
|
+
['ZcashSignedPczt', 12403],
|
|
42
|
+
['ZcashPcztChunkRequest', 12404],
|
|
43
|
+
['ZcashPcztChunkAck', 12405],
|
|
44
|
+
['ZcashSignedPcztChunkRequest', 12406],
|
|
45
|
+
])('%s has wire type %d', (name, typeId) => {
|
|
46
|
+
expect(createMessageFromName(messages, name).messageTypeId).toBe(typeId);
|
|
47
|
+
});
|
|
48
|
+
|
|
49
|
+
test.each(['ZcashSignPczt', 'ZcashSignedPczt'])('%s round trips length and bytes', name => {
|
|
50
|
+
const chunk = 'ab'.repeat(1024);
|
|
51
|
+
const { ids, decoded } = roundTrip(name, { pczt_length: 4096, pczt_initial_chunk: chunk });
|
|
52
|
+
expect(ids).toEqual([1, 2]);
|
|
53
|
+
expect(decoded).toEqual({ pczt_length: 4096, pczt_initial_chunk: chunk });
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
test('ZcashPcztChunkAck round trips the data chunk', () => {
|
|
57
|
+
const { ids, decoded } = roundTrip('ZcashPcztChunkAck', { data_chunk: '00ff10' });
|
|
58
|
+
expect(ids).toEqual([1]);
|
|
59
|
+
expect(decoded).toEqual({ data_chunk: '00ff10' });
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
test.each(['ZcashPcztChunkRequest', 'ZcashSignedPcztChunkRequest'])(
|
|
63
|
+
'%s round trips the chunk length',
|
|
64
|
+
name => {
|
|
65
|
+
const { ids, decoded } = roundTrip(name, { chunk_length: 1024 });
|
|
66
|
+
expect(ids).toEqual([1]);
|
|
67
|
+
expect(decoded).toEqual({ chunk_length: 1024 });
|
|
68
|
+
}
|
|
69
|
+
);
|
|
70
|
+
|
|
71
|
+
test('ZcashGetAddress encodes every field with its schema id', () => {
|
|
72
|
+
const { ids, decoded } = roundTrip('ZcashGetAddress', {
|
|
73
|
+
address_n: [2147483680, 2147483781, 2147483648],
|
|
74
|
+
show_display: true,
|
|
75
|
+
include_seed_fingerprint: true,
|
|
76
|
+
include_ufvk: true,
|
|
77
|
+
diversifier_index: 0xffffffff,
|
|
78
|
+
address_type: 2,
|
|
79
|
+
scope: 1,
|
|
80
|
+
});
|
|
81
|
+
// address_n is unpacked: one tag per element.
|
|
82
|
+
expect(ids).toEqual([1, 1, 1, 2, 3, 4, 5, 6, 7]);
|
|
83
|
+
expect(decoded).toEqual({
|
|
84
|
+
address_n: [2147483680, 2147483781, 2147483648],
|
|
85
|
+
show_display: true,
|
|
86
|
+
include_seed_fingerprint: true,
|
|
87
|
+
include_ufvk: true,
|
|
88
|
+
diversifier_index: 0xffffffff,
|
|
89
|
+
address_type: 'UNIFIED_ORCHARD',
|
|
90
|
+
scope: 'INTERNAL',
|
|
91
|
+
});
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
test('ZcashGetAddress enum values match the schema', () => {
|
|
95
|
+
const addressType = messages.lookupEnum('ZcashAddressType').values;
|
|
96
|
+
const scope = messages.lookupEnum('ZcashAddressScope').values;
|
|
97
|
+
expect(addressType).toEqual({
|
|
98
|
+
UNIFIED_ORCHARD_P2PKH: 0,
|
|
99
|
+
TRANSPARENT_P2PKH: 1,
|
|
100
|
+
UNIFIED_ORCHARD: 2,
|
|
101
|
+
});
|
|
102
|
+
expect(scope).toEqual({ EXTERNAL: 0, INTERNAL: 1 });
|
|
103
|
+
});
|
|
104
|
+
|
|
105
|
+
test('ZcashGetAddress omits unset optional fields and keeps schema defaults', () => {
|
|
106
|
+
const { Message } = createMessageFromName(messages, 'ZcashGetAddress');
|
|
107
|
+
const { ids } = roundTrip('ZcashGetAddress', { address_n: [2147483680] });
|
|
108
|
+
expect(ids).toEqual([1]);
|
|
109
|
+
expect(Message.fields.diversifier_index.defaultValue).toBe(0);
|
|
110
|
+
expect(Message.fields.address_type.defaultValue).toBe(0);
|
|
111
|
+
expect(Message.fields.scope.defaultValue).toBe(0);
|
|
112
|
+
const empty = Message.decode(new Uint8Array(0)) as unknown as Record<string, unknown>;
|
|
113
|
+
expect(empty.diversifier_index).toBe(0);
|
|
114
|
+
expect(empty.address_type).toBe(0);
|
|
115
|
+
expect(empty.scope).toBe(0);
|
|
116
|
+
});
|
|
117
|
+
|
|
118
|
+
test('ZcashAddress decodes optional ufvk and seed fingerprint', () => {
|
|
119
|
+
const fingerprint = '0f'.repeat(32);
|
|
120
|
+
const full = roundTrip('ZcashAddress', {
|
|
121
|
+
address: 'u1abc',
|
|
122
|
+
ufvk: 'uview1abc',
|
|
123
|
+
seed_fingerprint: fingerprint,
|
|
124
|
+
});
|
|
125
|
+
expect(full.ids).toEqual([1, 2, 3]);
|
|
126
|
+
expect(full.decoded).toEqual({
|
|
127
|
+
address: 'u1abc',
|
|
128
|
+
ufvk: 'uview1abc',
|
|
129
|
+
seed_fingerprint: fingerprint,
|
|
130
|
+
});
|
|
131
|
+
|
|
132
|
+
const minimal = roundTrip('ZcashAddress', { address: 't1abc' });
|
|
133
|
+
expect(minimal.ids).toEqual([1]);
|
|
134
|
+
expect(minimal.decoded).toEqual({ address: 't1abc', ufvk: null, seed_fingerprint: null });
|
|
135
|
+
});
|
|
136
|
+
|
|
137
|
+
test('required fields are enforced on decode', () => {
|
|
138
|
+
const { Message } = createMessageFromName(messages, 'ZcashSignedPczt');
|
|
139
|
+
expect(() => Message.decode(new Uint8Array(0))).toThrow(/missing required/);
|
|
140
|
+
});
|
|
141
|
+
});
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ERRORS, HardwareErrorCode } from '@onekeyfe/hd-shared';
|
|
2
|
+
|
|
3
|
+
import ZcashSignPczt from '../src/api/zcash/ZcashSignPczt';
|
|
2
4
|
import ZcashGetAddress from '../src/api/zcash/ZcashGetAddress';
|
|
3
5
|
|
|
4
6
|
import type { Device } from '../src/device/Device';
|
|
@@ -117,10 +119,183 @@ describe('ZcashSignPczt', () => {
|
|
|
117
119
|
expect(typedCall).toHaveBeenCalledTimes(1);
|
|
118
120
|
});
|
|
119
121
|
|
|
120
|
-
test('rejects
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
122
|
+
test('rejects an announced signed length that is not a sane positive size', async () => {
|
|
123
|
+
for (const total of [0, 1.5, 16 * 1024 * 1024 + 1]) {
|
|
124
|
+
const method = createSignMethod(hex(0x01, 100));
|
|
125
|
+
method.init();
|
|
126
|
+
const typedCall = jest.fn().mockResolvedValueOnce({
|
|
127
|
+
type: 'ZcashSignedPczt',
|
|
128
|
+
message: { pczt_length: total, pczt_initial_chunk: '' },
|
|
129
|
+
});
|
|
130
|
+
attachDevice(method, typedCall);
|
|
131
|
+
await expect(method.run()).rejects.toThrow('invalid signed pczt length');
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
|
|
135
|
+
test('rejects empty input and leaves size limits to the device', () => {
|
|
136
|
+
expect(() => createSignMethod('').init()).toThrow('pczt is empty');
|
|
137
|
+
const method = createSignMethod(hex(0x00, 64 * 1024));
|
|
138
|
+
expect(() => method.init()).not.toThrow();
|
|
139
|
+
expect(method.params.pczt_length).toBe(64 * 1024);
|
|
140
|
+
});
|
|
141
|
+
});
|
|
142
|
+
|
|
143
|
+
describe('ZcashSignPczt protocol edge cases', () => {
|
|
144
|
+
const signedMessage = (signed: Buffer, initialLength = 1024) => ({
|
|
145
|
+
type: 'ZcashSignedPczt',
|
|
146
|
+
message: {
|
|
147
|
+
pczt_length: signed.length,
|
|
148
|
+
pczt_initial_chunk: signed.subarray(0, initialLength).toString('hex'),
|
|
149
|
+
},
|
|
150
|
+
});
|
|
151
|
+
|
|
152
|
+
const runWith = (pczt: string, typedCall: jest.Mock) => {
|
|
153
|
+
const method = createSignMethod(pczt);
|
|
154
|
+
method.init();
|
|
155
|
+
attachDevice(method, typedCall);
|
|
156
|
+
return method.run();
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
test.each([
|
|
160
|
+
{ name: 'short', data: hex(0xcd, 100) },
|
|
161
|
+
{ name: 'empty', data: '' },
|
|
162
|
+
{ name: 'missing', data: undefined },
|
|
163
|
+
])('rejects a $name download chunk', async ({ data }) => {
|
|
164
|
+
const signed = Buffer.alloc(1500, 0xcd);
|
|
165
|
+
const typedCall = jest
|
|
166
|
+
.fn()
|
|
167
|
+
.mockResolvedValueOnce(signedMessage(signed))
|
|
168
|
+
.mockResolvedValueOnce({ type: 'ZcashPcztChunkAck', message: { data_chunk: data } });
|
|
169
|
+
|
|
170
|
+
await expect(runWith(hex(0x01, 100), typedCall)).rejects.toThrow(
|
|
171
|
+
'requested bytes at offset 1024 of 1500'
|
|
172
|
+
);
|
|
173
|
+
expect(typedCall).toHaveBeenCalledTimes(2);
|
|
174
|
+
});
|
|
175
|
+
|
|
176
|
+
test('rejects a download chunk longer than requested', async () => {
|
|
177
|
+
const signed = Buffer.alloc(1500, 0xcd);
|
|
178
|
+
const typedCall = jest
|
|
179
|
+
.fn()
|
|
180
|
+
.mockResolvedValueOnce(signedMessage(signed))
|
|
181
|
+
.mockResolvedValueOnce({
|
|
182
|
+
type: 'ZcashPcztChunkAck',
|
|
183
|
+
message: { data_chunk: hex(0xcd, 477) },
|
|
184
|
+
});
|
|
185
|
+
|
|
186
|
+
await expect(runWith(hex(0x01, 100), typedCall)).rejects.toThrow(
|
|
187
|
+
'device returned 477 of 476 requested bytes'
|
|
188
|
+
);
|
|
189
|
+
});
|
|
190
|
+
|
|
191
|
+
test.each([0, -1, 1.5, Number.NaN])(
|
|
192
|
+
'rejects a device upload request for chunk length %s',
|
|
193
|
+
async chunkLength => {
|
|
194
|
+
const typedCall = jest.fn().mockResolvedValueOnce({
|
|
195
|
+
type: 'ZcashPcztChunkRequest',
|
|
196
|
+
message: { chunk_length: chunkLength },
|
|
197
|
+
});
|
|
198
|
+
|
|
199
|
+
await expect(runWith(hex(0x01, 2000), typedCall)).rejects.toThrow(
|
|
200
|
+
`device requested ${chunkLength} bytes at offset 1024`
|
|
201
|
+
);
|
|
202
|
+
expect(typedCall).toHaveBeenCalledTimes(1);
|
|
203
|
+
}
|
|
204
|
+
);
|
|
205
|
+
|
|
206
|
+
test('propagates a device Failure in the middle of upload', async () => {
|
|
207
|
+
const failure = ERRORS.TypedError(
|
|
208
|
+
HardwareErrorCode.ActionCancelled,
|
|
209
|
+
'Action cancelled by user'
|
|
210
|
+
);
|
|
211
|
+
const typedCall = jest
|
|
212
|
+
.fn()
|
|
213
|
+
.mockResolvedValueOnce({ type: 'ZcashPcztChunkRequest', message: { chunk_length: 500 } })
|
|
214
|
+
.mockRejectedValueOnce(failure);
|
|
215
|
+
|
|
216
|
+
await expect(runWith(hex(0x01, 2000), typedCall)).rejects.toBe(failure);
|
|
217
|
+
expect(typedCall).toHaveBeenCalledTimes(2);
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
test('propagates a device Failure in the middle of download', async () => {
|
|
221
|
+
const failure = ERRORS.TypedError(HardwareErrorCode.RuntimeError, 'Firmware error');
|
|
222
|
+
const signed = Buffer.alloc(3000, 0xcd);
|
|
223
|
+
const typedCall = jest
|
|
224
|
+
.fn()
|
|
225
|
+
.mockResolvedValueOnce(signedMessage(signed))
|
|
226
|
+
.mockResolvedValueOnce({
|
|
227
|
+
type: 'ZcashPcztChunkAck',
|
|
228
|
+
message: { data_chunk: signed.subarray(1024, 2048).toString('hex') },
|
|
229
|
+
})
|
|
230
|
+
.mockRejectedValueOnce(failure);
|
|
231
|
+
|
|
232
|
+
await expect(runWith(hex(0x01, 100), typedCall)).rejects.toBe(failure);
|
|
233
|
+
expect(typedCall).toHaveBeenCalledTimes(3);
|
|
234
|
+
});
|
|
235
|
+
|
|
236
|
+
test('exactly 1024 bytes in both directions needs no extra chunks', async () => {
|
|
237
|
+
const signed = Buffer.alloc(1024, 0xcd);
|
|
238
|
+
const typedCall = jest.fn().mockResolvedValueOnce(signedMessage(signed));
|
|
239
|
+
|
|
240
|
+
await expect(runWith(hex(0xab, 1024), typedCall)).resolves.toEqual({
|
|
241
|
+
pczt: signed.toString('hex'),
|
|
242
|
+
});
|
|
243
|
+
expect(typedCall).toHaveBeenCalledTimes(1);
|
|
244
|
+
expect(typedCall.mock.calls[0][2]).toEqual({
|
|
245
|
+
pczt_length: 1024,
|
|
246
|
+
pczt_initial_chunk: hex(0xab, 1024),
|
|
247
|
+
});
|
|
248
|
+
});
|
|
249
|
+
|
|
250
|
+
test('1025 bytes in both directions splits into 1024 + 1', async () => {
|
|
251
|
+
const pczt = `${hex(0xab, 1024)}ef`;
|
|
252
|
+
const signed = Buffer.concat([Buffer.alloc(1024, 0xcd), Buffer.from([0x99])]);
|
|
253
|
+
const typedCall = jest
|
|
254
|
+
.fn()
|
|
255
|
+
.mockResolvedValueOnce({ type: 'ZcashPcztChunkRequest', message: { chunk_length: 1 } })
|
|
256
|
+
.mockResolvedValueOnce(signedMessage(signed))
|
|
257
|
+
.mockResolvedValueOnce({ type: 'ZcashPcztChunkAck', message: { data_chunk: '99' } });
|
|
258
|
+
|
|
259
|
+
await expect(runWith(pczt, typedCall)).resolves.toEqual({ pczt: signed.toString('hex') });
|
|
260
|
+
expect(typedCall.mock.calls[0][2]).toEqual({
|
|
261
|
+
pczt_length: 1025,
|
|
262
|
+
pczt_initial_chunk: hex(0xab, 1024),
|
|
263
|
+
});
|
|
264
|
+
expect(typedCall.mock.calls[1][2]).toEqual({ data_chunk: 'ef' });
|
|
265
|
+
expect(typedCall.mock.calls[2][2]).toEqual({ chunk_length: 1 });
|
|
266
|
+
});
|
|
267
|
+
|
|
268
|
+
test('2048 bytes in both directions uses one full 1024-byte chunk each way', async () => {
|
|
269
|
+
const signed = Buffer.alloc(2048, 0xcd);
|
|
270
|
+
const typedCall = jest
|
|
271
|
+
.fn()
|
|
272
|
+
.mockResolvedValueOnce({ type: 'ZcashPcztChunkRequest', message: { chunk_length: 1024 } })
|
|
273
|
+
.mockResolvedValueOnce(signedMessage(signed))
|
|
274
|
+
.mockResolvedValueOnce({
|
|
275
|
+
type: 'ZcashPcztChunkAck',
|
|
276
|
+
message: { data_chunk: signed.subarray(1024).toString('hex') },
|
|
277
|
+
});
|
|
278
|
+
|
|
279
|
+
await expect(runWith(hex(0xab, 2048), typedCall)).resolves.toEqual({
|
|
280
|
+
pczt: signed.toString('hex'),
|
|
281
|
+
});
|
|
282
|
+
expect(typedCall.mock.calls[1][2]).toEqual({ data_chunk: hex(0xab, 1024) });
|
|
283
|
+
expect(typedCall.mock.calls[2][2]).toEqual({ chunk_length: 1024 });
|
|
284
|
+
expect(typedCall).toHaveBeenCalledTimes(3);
|
|
285
|
+
});
|
|
286
|
+
|
|
287
|
+
test.each(['abc', '0xabc', 'a'])('rejects odd-length hex %s', pczt => {
|
|
288
|
+
expect(() => createSignMethod(pczt).init()).toThrow('pczt hex must have an even length');
|
|
289
|
+
});
|
|
290
|
+
|
|
291
|
+
test.each(['zz', '0xgg', 'ab cd'])('rejects non-hex input %s', pczt => {
|
|
292
|
+
expect(() => createSignMethod(pczt).init()).toThrow('should be [hexString]');
|
|
293
|
+
});
|
|
294
|
+
|
|
295
|
+
test('accepts a 0x-prefixed even-length hex string', () => {
|
|
296
|
+
const method = createSignMethod('0xABcd');
|
|
297
|
+
method.init();
|
|
298
|
+
expect(method.params).toEqual({ pczt_length: 2, pczt_initial_chunk: 'abcd' });
|
|
124
299
|
});
|
|
125
300
|
});
|
|
126
301
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FirmwareUpdateV4.d.ts","sourceRoot":"","sources":["../../src/api/FirmwareUpdateV4.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAkD,MAAM,qBAAqB,CAAC;AA0BlG,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAiC/E,OAAO,KAAK,EAEV,sBAAsB,EAEvB,MAAM,6BAA6B,CAAC;AAuErC,wBAAgB,wCAAwC,CACtD,UAAU,EAAE,WAAW,GAAG,MAAM,GAAG,SAAS,EAC5C,MAAM,EAAE,sBAAsB,EAC9B,0BAA0B,UAAQ,QAiCnC;
|
|
1
|
+
{"version":3,"file":"FirmwareUpdateV4.d.ts","sourceRoot":"","sources":["../../src/api/FirmwareUpdateV4.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAkD,MAAM,qBAAqB,CAAC;AA0BlG,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAiC/E,OAAO,KAAK,EAEV,sBAAsB,EAEvB,MAAM,6BAA6B,CAAC;AAuErC,wBAAgB,wCAAwC,CACtD,UAAU,EAAE,WAAW,GAAG,MAAM,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B;YAgGzB,8BAA8B;IAU5C,OAAO,CAAC,kCAAkC;YAQ5B,cAAc;YAyCd,6BAA6B;YAW7B,0BAA0B;YAoB1B,6BAA6B;YAwD7B,gBAAgB;IA0B9B,OAAO,CAAC,qBAAqB;CAM9B"}
|
|
@@ -1,9 +1,29 @@
|
|
|
1
1
|
import { BaseMethod } from './BaseMethod';
|
|
2
|
-
import type { SearchDevice } from '../types/device';
|
|
2
|
+
import type { SearchDevice, UsbDeviceIdentity } from '../types/device';
|
|
3
3
|
import type DeviceConnector from '../device/DeviceConnector';
|
|
4
|
+
import type { AcquireInput, OneKeyDeviceInfo as DeviceDescriptor, Transport } from '@onekeyfe/hd-transport';
|
|
5
|
+
import type { Device } from '../device/Device';
|
|
6
|
+
type RequestQueueLookup = {
|
|
7
|
+
getRequestTasksIdByConnectId: (connectId: string) => number[];
|
|
8
|
+
getTask: (requestId: number) => {
|
|
9
|
+
method: {
|
|
10
|
+
device?: Device;
|
|
11
|
+
};
|
|
12
|
+
} | undefined;
|
|
13
|
+
};
|
|
14
|
+
export type UsbIdentityProbeDescriptor = Pick<DeviceDescriptor, 'path' | 'commType'> & Partial<Pick<DeviceDescriptor, 'id' | 'session'>>;
|
|
15
|
+
export declare const getOwnedUsbDeviceIdentity: (descriptor: UsbIdentityProbeDescriptor, requestQueue: RequestQueueLookup) => UsbDeviceIdentity | undefined;
|
|
16
|
+
export type UsbIdentityProbeTransport = Pick<Transport, 'release' | 'call' | 'getProtocolType' | 'configureProtocolV2'> & {
|
|
17
|
+
init: (logger: object) => unknown;
|
|
18
|
+
enumerate: () => Promise<UsbIdentityProbeDescriptor[]>;
|
|
19
|
+
acquire: (input: AcquireInput) => Promise<string | undefined>;
|
|
20
|
+
configure: (signedData: string) => void | Promise<void>;
|
|
21
|
+
};
|
|
22
|
+
export declare const probeUsbDeviceIdentitiesWithTransport: (transport: UsbIdentityProbeTransport, commType: UsbDeviceIdentity['commType'], getOwnedIdentity?: ((descriptor: UsbIdentityProbeDescriptor) => UsbDeviceIdentity | undefined) | undefined) => Promise<UsbDeviceIdentity[]>;
|
|
4
23
|
export default class SearchDevices extends BaseMethod {
|
|
5
24
|
connector?: DeviceConnector;
|
|
6
25
|
init(): void;
|
|
7
26
|
run(): Promise<SearchDevice[]>;
|
|
8
27
|
}
|
|
28
|
+
export {};
|
|
9
29
|
//# sourceMappingURL=SearchDevices.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SearchDevices.d.ts","sourceRoot":"","sources":["../../src/api/SearchDevices.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"SearchDevices.d.ts","sourceRoot":"","sources":["../../src/api/SearchDevices.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAU1C,OAAO,KAAK,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAEvE,OAAO,KAAK,eAAe,MAAM,2BAA2B,CAAC;AAC7D,OAAO,KAAK,EACV,YAAY,EACZ,gBAAgB,IAAI,gBAAgB,EAEpC,SAAS,EACV,MAAM,wBAAwB,CAAC;AAChC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAI/C,KAAK,kBAAkB,GAAG;IACxB,4BAA4B,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,MAAM,EAAE,CAAC;IAC9D,OAAO,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK;QAAE,MAAM,EAAE;YAAE,MAAM,CAAC,EAAE,MAAM,CAAA;SAAE,CAAA;KAAE,GAAG,SAAS,CAAC;CAC7E,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG,IAAI,CAAC,gBAAgB,EAAE,MAAM,GAAG,UAAU,CAAC,GAClF,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,IAAI,GAAG,SAAS,CAAC,CAAC,CAAC;AA4CpD,eAAO,MAAM,yBAAyB,eACxB,0BAA0B,gBACxB,kBAAkB,KAC/B,iBAAiB,GAAG,SAatB,CAAC;AAEF,MAAM,MAAM,yBAAyB,GAAG,IAAI,CAC1C,SAAS,EACT,SAAS,GAAG,MAAM,GAAG,iBAAiB,GAAG,qBAAqB,CAC/D,GAAG;IACF,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC;IAClC,SAAS,EAAE,MAAM,OAAO,CAAC,0BAA0B,EAAE,CAAC,CAAC;IACvD,OAAO,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IAC9D,SAAS,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACzD,CAAC;AAYF,eAAO,MAAM,qCAAqC,cACrC,yBAAyB,YAC1B,iBAAiB,CAAC,UAAU,CAAC,mCACP,0BAA0B,KAAK,iBAAiB,GAAG,SAAS,kBAC3F,QAAQ,iBAAiB,EAAE,CA4G7B,CAAC;AAsBF,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,UAAU;IACnD,SAAS,CAAC,EAAE,eAAe,CAAa;IAExC,IAAI;IAME,GAAG,IAAI,OAAO,CAAC,YAAY,EAAE,CAAC;CAuFrC"}
|
|
@@ -4,7 +4,6 @@ import type { ZcashSignPczt as HardwareZcashSignPczt } from '@onekeyfe/hd-transp
|
|
|
4
4
|
import type { TypedCall, TypedResponseMessage } from '../../device/DeviceCommands';
|
|
5
5
|
import type { ZcashSignedPczt } from '../../types/api/zcashSignPczt';
|
|
6
6
|
import type { DeviceFirmwareRange } from '../../types';
|
|
7
|
-
export declare const ZCASH_PCZT_MAX_BYTES: number;
|
|
8
7
|
export default class ZcashSignPczt extends BaseMethod<HardwareZcashSignPczt> {
|
|
9
8
|
pczt: Buffer;
|
|
10
9
|
getSupportedProtocols(): readonly ["V2"];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ZcashSignPczt.d.ts","sourceRoot":"","sources":["../../../src/api/zcash/ZcashSignPczt.ts"],"names":[],"mappings":";AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAK3C,OAAO,KAAK,EAAE,aAAa,IAAI,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,KAAK,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AACnF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"ZcashSignPczt.d.ts","sourceRoot":"","sources":["../../../src/api/zcash/ZcashSignPczt.ts"],"names":[],"mappings":";AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAK3C,OAAO,KAAK,EAAE,aAAa,IAAI,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,KAAK,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AACnF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAMvD,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,UAAU,CAAC,qBAAqB,CAAC;IAC1E,IAAI,EAAE,MAAM,CAAmB;IAE/B,qBAAqB;IAIrB,IAAI;IAuBJ,eAAe,IAAI,mBAAmB;IAUtC,UAAU,cACG,SAAS,OACf,qBAAqB,iBAAiB,CAAC,GAAG,qBAAqB,uBAAuB,CAAC,UACpF,MAAM,KACb,QAAQ,qBAAqB,iBAAiB,CAAC,CAAC,CAiCjD;IAIF,kBAAkB,cACL,SAAS,OACf,qBAAqB,iBAAiB,CAAC,KAC3C,QAAQ,MAAM,CAAC,CAmChB;IAEI,GAAG,IAAI,OAAO,CAAC,eAAe,CAAC;CAgBtC"}
|
package/dist/core/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
+
import { getOwnedUsbDeviceIdentity } from '../api/SearchDevices';
|
|
2
3
|
import EventEmitter from 'events';
|
|
3
4
|
import { type LowlevelTransportSharedPlugin, type ProtocolType } from '@onekeyfe/hd-transport';
|
|
4
5
|
import { Device } from '../device/Device';
|
|
@@ -20,6 +21,7 @@ export default class Core extends EventEmitter {
|
|
|
20
21
|
private tracingContext;
|
|
21
22
|
readonly sdkInstanceId: string;
|
|
22
23
|
private requestQueue;
|
|
24
|
+
getOwnedUsbDeviceIdentity(descriptor: Parameters<typeof getOwnedUsbDeviceIdentity>[0]): import("../types").UsbDeviceIdentity | undefined;
|
|
23
25
|
private disposePromise?;
|
|
24
26
|
private prePendingCallPromises;
|
|
25
27
|
private methodSynchronize;
|
|
@@ -36,5 +38,5 @@ export declare const switchTransport: ({ env, Transport, plugin, }: {
|
|
|
36
38
|
env: ConnectSettings['env'];
|
|
37
39
|
Transport: any;
|
|
38
40
|
plugin?: LowlevelTransportSharedPlugin | undefined;
|
|
39
|
-
}) => void
|
|
41
|
+
}) => Promise<void>;
|
|
40
42
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/core/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":";AACA,OAAO,YAAY,MAAM,QAAQ,CAAC;AAClC,OAAO,EAEL,KAAK,6BAA6B,EAElC,KAAK,YAAY,EAIlB,MAAM,wBAAwB,CAAC;AAgChC,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAsB1C,OAAO,eAAe,MAAM,2BAA2B,CAAC;AAYxD,OAAO,KAAK,EAAE,eAAe,EAAyB,MAAM,UAAU,CAAC;AACvE,OAAO,KAAK,EAAE,WAAW,EAAmD,MAAM,WAAW,C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,EAAE,UAAU,GAAG,YAAY,GAAG,SAAS,CAMtF;AAgND,eAAO,MAAM,MAAM,YAAa,WAAW,cAAc,MAAM,SA4G9D,CAAC;AA8GF,eAAO,MAAM,qBAAqB,gFAejC,CAAC;AAiLF,MAAM,CAAC,OAAO,OAAO,IAAK,SAAQ,YAAY;IAC5C,OAAO,CAAC,cAAc,CAAoB;IAE1C,SAAgB,aAAa,EAAE,MAAM,CAAC;IAEtC,OAAO,CAAC,YAAY,CAAsB;IAE1C,yBAAyB,CAAC,UAAU,EAAE,UAAU,CAAC,OAAO,yBAAyB,CAAC,CAAC,CAAC,CAAC;IAIrF,OAAO,CAAC,cAAc,CAAC,CAAgB;IAGvC,OAAO,CAAC,sBAAsB,CAAoC;IAElE,OAAO,CAAC,iBAAiB,CAAoB;;IAS7C,OAAO,CAAC,cAAc;IAuChB,aAAa,CAAC,OAAO,EAAE,WAAW;IAuExC,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC;YAOV,gBAAgB;CAmC/B;AAED,eAAO,MAAM,QAAQ,YAMpB,CAAC;AAEF,eAAO,MAAM,aAAa,uBAYzB,CAAC;AAMF,eAAO,MAAM,IAAI,aACL,eAAe,aACd,GAAG,WACL,6BAA6B,8BAmBvC,CAAC;AAEF,eAAO,MAAM,eAAe;SAKrB,eAAe,CAAC,KAAK,CAAC;eAChB,GAAG;;mBAyBf,CAAC"}
|
|
@@ -31,7 +31,7 @@ export declare const cancelDeviceInPrompt: (device: Device, expectResponse?: boo
|
|
|
31
31
|
};
|
|
32
32
|
} | {
|
|
33
33
|
success: boolean;
|
|
34
|
-
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
34
|
+
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 604 | 605 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
35
35
|
payload: {
|
|
36
36
|
message: string;
|
|
37
37
|
};
|
|
@@ -50,7 +50,7 @@ export declare const cancelDeviceWithInitialize: (device: Device) => Promise<{
|
|
|
50
50
|
};
|
|
51
51
|
} | {
|
|
52
52
|
success: boolean;
|
|
53
|
-
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
53
|
+
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 604 | 605 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
54
54
|
payload: {
|
|
55
55
|
message: string;
|
|
56
56
|
};
|
|
@@ -81,7 +81,7 @@ export declare class DeviceCommands {
|
|
|
81
81
|
};
|
|
82
82
|
} | {
|
|
83
83
|
success: boolean;
|
|
84
|
-
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
84
|
+
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 604 | 605 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
85
85
|
payload: {
|
|
86
86
|
message: string;
|
|
87
87
|
};
|
|
@@ -100,7 +100,7 @@ export declare class DeviceCommands {
|
|
|
100
100
|
};
|
|
101
101
|
} | {
|
|
102
102
|
success: boolean;
|
|
103
|
-
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
103
|
+
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 604 | 605 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
104
104
|
payload: {
|
|
105
105
|
message: string;
|
|
106
106
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"logBlockEvent.d.ts","sourceRoot":"","sources":["../../src/events/logBlockEvent.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,aAAa,EAAE,GAAG,CAAC,MAAM,CAKpC,CAAC;
|
|
1
|
+
{"version":3,"file":"logBlockEvent.d.ts","sourceRoot":"","sources":["../../src/events/logBlockEvent.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,aAAa,EAAE,GAAG,CAAC,MAAM,CAKpC,CAAC;AAeH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAmBrE;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAK9E;AAED,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAE/E"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import EventEmitter, { EventEmitter as EventEmitter$1 } from 'events';
|
|
2
2
|
import * as _onekeyfe_hd_transport from '@onekeyfe/hd-transport';
|
|
3
|
-
import { DeviceRebootType, Messages, Transport, TransportCallOptions, OneKeyDeviceCommType, ProtocolInfo, ProtocolV2DeviceInfo, DeviceStatus as DeviceStatus$1, Enum_SafetyCheckLevel, OneKeyDeviceInfo, Success as Success$1, DeviceSessionPinType, LowlevelTransportSharedPlugin, OnboardingStatus, RecoveryDeviceType, ResourceType, NextU2FCounter, SetU2FCounter, CipheredKeyValue as CipheredKeyValue$1, UintType, EthereumPublicKey, EthereumMessageSignature, Address, MultisigRedeemScriptType, InputScriptType, PublicKey, BabylonDerivedContextHash, MessageSignature, SignedPsbt, PrevInput, TxOutputBinType, TxInput, TxOutputType, TxInputType, StarcoinAddress as StarcoinAddress$1, StarcoinPublicKey as StarcoinPublicKey$1, StarcoinMessageSignature, StarcoinSignedTx, NEMAddress as NEMAddress$1, NEMSignedTx, SolanaAddress as SolanaAddress$1, SolanaSignedTx as SolanaSignedTx$1, SolanaTxExtraInfo, SolanaOffChainMessageVersion, SolanaOffChainMessageFormat, StellarAddress as StellarAddress$1, StellarSignedTx, TronAddress as TronAddress$1, TronResourceCode, TronSignedTx, TronMessageSignature, ConfluxAddress as ConfluxAddress$1, ConfluxMessageSignature, NearAddress as NearAddress$1, NearSignedTx, AptosAddress as AptosAddress$1, AptosMessageSignature as AptosMessageSignature$1, AptosSignedTx as AptosSignedTx$1, AlgorandAddress, AlgorandSignedTx, CosmosAddress as CosmosAddress$1, CosmosSignedTx as CosmosSignedTx$1, SuiAddress as SuiAddress$1, SuiMessageSignature, CardanoAddressParametersType, CardanoMessageSignature, FilecoinAddress as FilecoinAddress$1, FilecoinSignedTx as FilecoinSignedTx$1, PolkadotAddress as PolkadotAddress$1, PolkadotSignedTx as PolkadotSignedTx$1, KaspaAddress as KaspaAddress$1, NervosAddress as NervosAddress$1, NervosSignedTx as NervosSignedTx$1, DnxAddress as DnxAddress$1, TonWalletVersion, TonWorkChain, TonSignedMessage, TonSignedProof, TonSignDataType, TonSignedData, ScdoAddress as ScdoAddress$1, ScdoSignedMessage, ScdoSignedTx as ScdoSignedTx$1, AlephiumMessageSignature, AlephiumSignedTx as AlephiumSignedTx$1, BenfenAddress as BenfenAddress$1, BenfenMessageSignature, ZcashAddressType, ZcashAddressScope, SafetyCheckLevel, ChangeOutputScriptType, ProtocolType } from '@onekeyfe/hd-transport';
|
|
3
|
+
import { DeviceRebootType, Messages, Transport, TransportCallOptions, OneKeyDeviceCommType, ProtocolInfo, ProtocolV2DeviceInfo, DeviceStatus as DeviceStatus$1, Enum_SafetyCheckLevel, OneKeyDeviceInfo, Success as Success$1, DeviceSessionPinType, AcquireInput, LowlevelTransportSharedPlugin, OnboardingStatus, RecoveryDeviceType, ResourceType, NextU2FCounter, SetU2FCounter, CipheredKeyValue as CipheredKeyValue$1, UintType, EthereumPublicKey, EthereumMessageSignature, Address, MultisigRedeemScriptType, InputScriptType, PublicKey, BabylonDerivedContextHash, MessageSignature, SignedPsbt, PrevInput, TxOutputBinType, TxInput, TxOutputType, TxInputType, StarcoinAddress as StarcoinAddress$1, StarcoinPublicKey as StarcoinPublicKey$1, StarcoinMessageSignature, StarcoinSignedTx, NEMAddress as NEMAddress$1, NEMSignedTx, SolanaAddress as SolanaAddress$1, SolanaSignedTx as SolanaSignedTx$1, SolanaTxExtraInfo, SolanaOffChainMessageVersion, SolanaOffChainMessageFormat, StellarAddress as StellarAddress$1, StellarSignedTx, TronAddress as TronAddress$1, TronResourceCode, TronSignedTx, TronMessageSignature, ConfluxAddress as ConfluxAddress$1, ConfluxMessageSignature, NearAddress as NearAddress$1, NearSignedTx, AptosAddress as AptosAddress$1, AptosMessageSignature as AptosMessageSignature$1, AptosSignedTx as AptosSignedTx$1, AlgorandAddress, AlgorandSignedTx, CosmosAddress as CosmosAddress$1, CosmosSignedTx as CosmosSignedTx$1, SuiAddress as SuiAddress$1, SuiMessageSignature, CardanoAddressParametersType, CardanoMessageSignature, FilecoinAddress as FilecoinAddress$1, FilecoinSignedTx as FilecoinSignedTx$1, PolkadotAddress as PolkadotAddress$1, PolkadotSignedTx as PolkadotSignedTx$1, KaspaAddress as KaspaAddress$1, NervosAddress as NervosAddress$1, NervosSignedTx as NervosSignedTx$1, DnxAddress as DnxAddress$1, TonWalletVersion, TonWorkChain, TonSignedMessage, TonSignedProof, TonSignDataType, TonSignedData, ScdoAddress as ScdoAddress$1, ScdoSignedMessage, ScdoSignedTx as ScdoSignedTx$1, AlephiumMessageSignature, AlephiumSignedTx as AlephiumSignedTx$1, BenfenAddress as BenfenAddress$1, BenfenMessageSignature, ZcashAddressType, ZcashAddressScope, SafetyCheckLevel, ChangeOutputScriptType, ProtocolType } from '@onekeyfe/hd-transport';
|
|
4
4
|
export { Success as DeviceSuccess, HDNodeType, Messages as PROTO, ResourceType, TonSignDataType, TonWalletVersion } from '@onekeyfe/hd-transport';
|
|
5
5
|
import * as _onekeyfe_hd_shared from '@onekeyfe/hd-shared';
|
|
6
6
|
import { HardwareConnectProtocol, EFirmwareType, EDeviceType, Deferred } from '@onekeyfe/hd-shared';
|
|
@@ -145,7 +145,7 @@ declare class DeviceCommands {
|
|
|
145
145
|
};
|
|
146
146
|
} | {
|
|
147
147
|
success: boolean;
|
|
148
|
-
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
148
|
+
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 604 | 605 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
149
149
|
payload: {
|
|
150
150
|
message: string;
|
|
151
151
|
};
|
|
@@ -164,7 +164,7 @@ declare class DeviceCommands {
|
|
|
164
164
|
};
|
|
165
165
|
} | {
|
|
166
166
|
success: boolean;
|
|
167
|
-
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
167
|
+
error: 0 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 200 | 300 | 301 | 302 | 303 | 304 | 305 | 400 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 500 | 600 | 601 | 602 | 603 | 604 | 605 | 700 | 701 | 702 | 703 | 704 | 705 | 706 | 707 | 708 | 709 | 710 | 711 | 712 | 713 | 714 | 715 | 716 | 717 | 718 | 719 | 720 | 721 | 722 | 723 | 724 | 800 | 801 | 802 | 803 | 804 | 805 | 806 | 807 | 808 | 809 | 810 | 811 | 812 | 813 | 814 | 815 | 816 | 817 | 818 | 819 | 820 | 821 | 822 | 823 | 824 | 825 | 826 | 827 | 828 | 830 | 831 | 832 | 900 | 901 | 902 | 903;
|
|
168
168
|
payload: {
|
|
169
169
|
message: string;
|
|
170
170
|
};
|
|
@@ -384,6 +384,17 @@ type SearchDevice = {
|
|
|
384
384
|
name: string;
|
|
385
385
|
commType: OneKeyDeviceCommType;
|
|
386
386
|
};
|
|
387
|
+
/** Identity confirmed over USB. The descriptor path is only a transport address. */
|
|
388
|
+
type UsbDeviceIdentity = {
|
|
389
|
+
path: string;
|
|
390
|
+
serialNo: string | null;
|
|
391
|
+
deviceId: string | null;
|
|
392
|
+
deviceType: IDeviceType;
|
|
393
|
+
connectProtocol: HardwareConnectProtocol;
|
|
394
|
+
commType: 'webusb' | 'bridge';
|
|
395
|
+
/** Mode confirmed by the device response; absent when discovery cannot establish it. */
|
|
396
|
+
mode?: DeviceStateMode;
|
|
397
|
+
};
|
|
387
398
|
type Device$1 = KnownDevice;
|
|
388
399
|
type DeviceFeaturesProtocol = 'V1' | 'V2' | 'unknown';
|
|
389
400
|
type DeviceFeaturesMode = 'normal' | 'bootloader' | 'romloader' | 'notInitialized' | 'backupMode' | 'unknown';
|
|
@@ -1107,10 +1118,30 @@ declare function formatRequestContext(context: RequestContext): string;
|
|
|
1107
1118
|
*/
|
|
1108
1119
|
declare function cleanupSdkInstance(sdkInstanceId: string): void;
|
|
1109
1120
|
|
|
1121
|
+
type RequestQueueLookup = {
|
|
1122
|
+
getRequestTasksIdByConnectId: (connectId: string) => number[];
|
|
1123
|
+
getTask: (requestId: number) => {
|
|
1124
|
+
method: {
|
|
1125
|
+
device?: Device;
|
|
1126
|
+
};
|
|
1127
|
+
} | undefined;
|
|
1128
|
+
};
|
|
1129
|
+
type UsbIdentityProbeDescriptor = Pick<OneKeyDeviceInfo, 'path' | 'commType'> & Partial<Pick<OneKeyDeviceInfo, 'id' | 'session'>>;
|
|
1130
|
+
declare const getOwnedUsbDeviceIdentity: (descriptor: UsbIdentityProbeDescriptor, requestQueue: RequestQueueLookup) => UsbDeviceIdentity | undefined;
|
|
1131
|
+
type UsbIdentityProbeTransport = Pick<Transport, 'release' | 'call' | 'getProtocolType' | 'configureProtocolV2'> & {
|
|
1132
|
+
init: (logger: object) => unknown;
|
|
1133
|
+
enumerate: () => Promise<UsbIdentityProbeDescriptor[]>;
|
|
1134
|
+
acquire: (input: AcquireInput) => Promise<string | undefined>;
|
|
1135
|
+
configure: (signedData: string) => void | Promise<void>;
|
|
1136
|
+
};
|
|
1137
|
+
/** Runs on a separate transport; never initializes or switches the current Core. */
|
|
1138
|
+
declare const probeUsbDeviceIdentitiesWithTransport: (transport: UsbIdentityProbeTransport, commType: UsbDeviceIdentity['commType'], getOwnedIdentity?: ((descriptor: UsbIdentityProbeDescriptor) => UsbDeviceIdentity | undefined) | undefined) => Promise<UsbDeviceIdentity[]>;
|
|
1139
|
+
|
|
1110
1140
|
declare class Core extends EventEmitter {
|
|
1111
1141
|
private tracingContext;
|
|
1112
1142
|
readonly sdkInstanceId: string;
|
|
1113
1143
|
private requestQueue;
|
|
1144
|
+
getOwnedUsbDeviceIdentity(descriptor: Parameters<typeof getOwnedUsbDeviceIdentity>[0]): UsbDeviceIdentity | undefined;
|
|
1114
1145
|
private disposePromise?;
|
|
1115
1146
|
private prePendingCallPromises;
|
|
1116
1147
|
private methodSynchronize;
|
|
@@ -1125,7 +1156,7 @@ declare const switchTransport: ({ env, Transport, plugin, }: {
|
|
|
1125
1156
|
env: ConnectSettings['env'];
|
|
1126
1157
|
Transport: any;
|
|
1127
1158
|
plugin?: LowlevelTransportSharedPlugin | undefined;
|
|
1128
|
-
}) => void
|
|
1159
|
+
}) => Promise<void>;
|
|
1129
1160
|
|
|
1130
1161
|
type UploadPortfolioParams = {
|
|
1131
1162
|
packageBase64: string;
|
|
@@ -4938,4 +4969,4 @@ declare const HardwareSdk: ({ init, call, dispose, eventEmitter, uiResponse, can
|
|
|
4938
4969
|
declare const HardwareSDKLowLevel: ({ init, call, dispose, eventEmitter, addHardwareGlobalEventListener, uiResponse, cancel, updateSettings, switchTransport, }: LowLevelInjectApi) => LowLevelCoreApi;
|
|
4939
4970
|
declare const HardwareTopLevelSdk: () => CoreApi;
|
|
4940
4971
|
|
|
4941
|
-
export { AccountAddress, AccountAddresses, AlephiumAddress, AlephiumGetAddressParams, AlephiumSignMessageParams, AlephiumSignTransactionParams, AlephiumSignedTx, AlgoAddress, AlgoGetAddressParams, AlgoSignTransactionParams, AlgoSignedTx, AllFirmwareRelease, AllNetworkAddressParams, AllNetworkGetAddressParams, AptosAddress, AptosGetAddressParams, AptosGetPublicKeyParams, AptosMessageSignature, AptosPublicKey, AptosSignInMessageParams, AptosSignInMessageSignature, AptosSignMessageParams, AptosSignTransactionParams, AptosSignedTx, AssetsMap, BTCAddress, BTCDeriveContextHashParams, BTCGetAddressParams, BTCGetPublicKeyParams, BTCPublicKey, BTCSignMessageParams, BTCSignTransactionParams, BTCVerifyMessageParams, BenfenAddress, BenfenGetAddressParams, BenfenGetPublicKeyParams, BenfenPublicKey, BenfenSignMessageParams, BenfenSignTransactionParams, BenfenSignedTx, BleReleaseInfoEvent, BleReleaseInfoPayload, BridgeReleaseCheckResult, CORE_EVENT, CallMethod, CallMethodAnyResponse, CallMethodKeys, CallMethodPayload, CallMethodResponse, CallMethodUnion, CardanoAddress, CardanoGetAddressMethodParams, CardanoGetAddressParams, CardanoSignMessageMethodParams, CardanoSignMessageParams, CardanoSignTransaction, CardanoSignedTxData, CipheredKeyValue, CipheredKeyValueParams, ClearSessionCacheParams, ClearSessionCachePayload, CommonParams, ConfluxAddress, ConfluxGetAddressParams, ConfluxSignMessageCIP23Params, ConfluxSignMessageParams, ConfluxSignTransactionParams, ConfluxSignedTx, ConfluxTransaction, ConnectSettings, Core, CoreApi, CoreMessage, CosmosAddress, CosmosGetAddressParams, CosmosGetPublicKeyParams, CosmosPublicKey, CosmosSignTransactionParams, CosmosSignedTx, DEFAULT_PRIORITY, DEVICE, DEVICE_EVENT, DEVICE_SETTINGS_NEVER_TIMEOUT_MS, DEVICE_SETTINGS_SHARED_FIELDS, DEVICE_SETTINGS_V1_ONLY_FIELDS, DEVICE_SETTINGS_V2_ONLY_FIELDS, DataManager, Device$1 as Device, DeviceButtonRequest, DeviceButtonRequestPayload, DeviceChangePinParams, DeviceConnnectRequest, DeviceDisconnnectRequest, DeviceEvent, DeviceEventListenerFn, DeviceEventMessage, DeviceFeaturesMode, DeviceFeaturesPayload, DeviceFeaturesProtocol, DeviceFeaturesRaw, DeviceFeaturesRawPatch, DeviceFeaturesVerify, DeviceFirmwareRange, DeviceFlagsParams, DeviceModelToTypes, DeviceProgress, DeviceRecoveryParams, DeviceResetParams, DeviceSendFeatures, DeviceSendState, DeviceSendSupportFeatures, DeviceSettingsCapabilities, DeviceSettingsDurationOption, DeviceSettingsField, DeviceSettingsParams, DeviceSettingsProtocol, DeviceSettingsValueOption, DeviceState, DeviceStateEvent, DeviceStateIdentity, DeviceStateMode, DeviceStatePatch, DeviceStateProtocol, DeviceStateScope, DeviceStateSection, DeviceStateSecurityElement, DeviceStateSecurityElements, DeviceStateSecurityElementsPatch, DeviceStateSettings, DeviceStateStatus, DeviceStateUpdateSource, DeviceStateVersions, DeviceStatus, DeviceSupportFeatures, DeviceSupportFeaturesPayload, DeviceTypeMap, DeviceTypeToModels, DeviceUnlockParams, DeviceUploadResourceParams, DeviceUploadResourceResponse, DeviceVerifyParams, DeviceVerifySignature, DnxAddress, DnxGetAddressParams, DnxSignTransactionParams, DnxSignature, DnxTxKey, EOneKeyDeviceMode, EVMAccessList, EVMAddress, EVMAuthorization, EVMAuthorizationSignature, EVMGetAddressParams, EVMGetPublicKeyParams, EVMPublicKey, EVMSignMessageEIP712Params, EVMSignMessageParams, EVMSignTransactionParams, EVMSignTypedDataParams, EVMSignedTx, EVMTransaction, EVMTransactionEIP1559, EVMTransactionEIP7702, EVMVerifyMessageParams, EthereumSignTypedDataMessage, EthereumSignTypedDataTypeProperty, EthereumSignTypedDataTypes, FIRMWARE, FIRMWARE_EVENT, Features, FilecoinAddress, FilecoinGetAddressParams, FilecoinSignTransactionParams, FilecoinSignedTx, FirmwareArtifactReader, FirmwareArtifactReference, FirmwareEvent, FirmwareMessage, FirmwareProcessing, FirmwareProgress, FirmwareRange, FirmwareRelease, FirmwareReleaseCheckResult, FirmwareTip, FirmwareUpdateArtifactParams, FirmwareUpdateBinaryParams, FirmwareUpdateCapabilities, FirmwareUpdateHostBinding, FirmwareUpdateParams, FirmwareUpdatePlan, FirmwareUpdatePlanArtifact, FirmwareUpdatePlanArtifactRole, FirmwareUpdatePlanForceTarget, FirmwareUpdatePlanTarget, FirmwareUpdatePreparedArtifact, FirmwareUpdatePreparedArtifactInput, FirmwareUpdatePreparedEntry, FirmwareUpdatePreparedPlan, FirmwareUpdateTipMessage, FirmwareUpdateV3Params, FirmwareUpdateV4Params, FirmwareUpdateV4Target, GetDeviceStateParams, GetPassphraseStateParams, HardwareSDKLowLevel, HardwareTopLevelSdk, HardwareUiInteractionMeta, IBLEFirmwareReleaseInfo, IDeviceBLEFirmwareStatus, IDeviceFirmwareStatus, IDeviceModel, IDeviceType, IFRAME, IFirmwareField, IFirmwareReleaseInfo, IFirmwareUpdateProgressType, IFirmwareUpdateTipMessage, IFrameBridge, IFrameCallMessage, IFrameCallback, IFrameCallbackMessage, IFrameCancelMessage, IFrameEvent, IFrameEventMessage, IFrameInit, IFrameSwitchTransport, IFrameSwitchTransportMessage, ILocale, IProtocolV2FirmwareComponent, IProtocolV2FirmwareComponentTarget, IProtocolV2ResourceSource, IProtocolV2Resources, ITransportStatus, IVersionArray, IVersionRange, KaspaAddress, KaspaGetAddressParams, KaspaSignInputParams, KaspaSignOutputParams, KaspaSignTransactionParams, KaspaSignature, KaspaStreamingSignInputParams, KaspaStreamingSignOutputParams, KnownDevice, LOG, LOG_EVENT, LogBlockEvent, LogEvent, LogEventMessage, LogOutput, LoggerNames, LowLevelCoreApi, LowLevelInjectApi, MajorVersion, MethodResponseMessage, NEMAddress, NEMAggregateModificationTransaction, NEMGetAddressParams, NEMImportanceTransaction, NEMMosaic, NEMMosaicCreationTransaction, NEMMultisigTransaction, NEMProvisionNamespaceTransaction, NEMSignTransactionParams, NEMSupplyChangeTransaction, NEMTransaction, NEMTransferTransaction, NearAddress, NearGetAddressParams, NearSignTransactionParams, NervosAddress, NervosGetAddressParams, NervosSignTransactionParams, NervosSignedTx, NexaAddress, NexaGetAddressParams, NexaSignInputParams, NexaSignOutputParams, NexaSignTransactionParams, NexaSignature, NormalizedFeatures, OnekeyFeatures, OpenWalletSessionMode, OpenWalletSessionModeValue, OpenWalletSessionParams, OpenWalletSessionPayload, PRO2_WALLPAPER_HEIGHT, PRO2_WALLPAPER_WIDTH, PROTOCOL_V2_NEVER_TIMEOUT_MS, Params, PassphraseRequestPayload, PolkadotAddress, PolkadotGetAddressParams, PolkadotSignTransactionParams, PolkadotSignedTx, PostMessageEvent, PreviousAddressResult, Pro2WallpaperColorFormat, ProtocolV2ComponentReleaseInfo, ProtocolV2FirmwareComponentRelease, ProtocolV2FirmwareComponentReleaseStatus, ProtocolV2FirmwareReleaseStatus, ProtocolV2UiCompletion, ProtocolV2UiEventMetadata, ProtocolV2UiEventSource, RESPONSE_EVENT, RefTransaction, ReleaseInfo, ReleaseInfoEvent, ReleaseInfoPayload, RemoteConfigResponse, RequestContext, Response, ScdoAddress, ScdoGetAddressParams, ScdoSignMessageParams, ScdoSignTransactionParams, ScdoSignedTx, SdkTracingContext, SearchDevice, SignedTransaction, SolSignMessageParams, SolSignMessageResponse, SolSignOffchainMessageParams, SolSignOffchainMessageResponse, SolanaAddress, SolanaGetAddressParams, SolanaSignTransactionParams, SolanaSignedTx, StarcoinAddress, StarcoinGetAddressParams, StarcoinGetPublicKeyParams, StarcoinPublicKey, StarcoinSignMessageParams, StarcoinSignTransactionParams, StarcoinVerifyMessageParams, StellarAddress, StellarAsset, StellarGetAddressParams, StellarOperation, StellarSignTransactionParams, StellarTransaction, StrictFeatures, Success, SuiAddress, SuiGetAddressParams, SuiGetPublicKeyParams, SuiPublicKey, SuiSignMessageParams, SuiSignTransactionParams, SuiSignedTx, SupportFeatureType, SupportFeatures, TestProtocolV2PingParams, TonAddress, TonGetAddressParams, TonSignDataParams, TonSignMessageParams, TonSignProofParams, TopLevelInjectApi, TransactionOptions, TransportReleaseStatus, TronAddress, TronDelegateResourceContract, TronFreezeBalanceV2Contract, TronGetAddressParams, TronSignMessageParams, TronSignTransactionParams, TronTransaction, TronTransactionContract, TronTransferContract, TronTriggerSmartContract, TronUnDelegateResourceContract, TronUnfreezeBalanceV2Contract, TronWithdrawBalanceContract, TronWithdrawExpireUnfreezeContract, UI_EVENT, UI_REQUEST, UI_RESPONSE, UiEvent, UiEventMessage, UiPromise, UiPromiseResponse, UiRequestButton, UiRequestDeviceAction, UiRequestFirmwareProgressing, UiRequestPassphrase, UiRequestPassphraseOnDevice, UiRequestSelectDeviceForSwitchFirmwareWebDevice, UiRequestSelectDeviceInBootloaderForWebDevice, UiRequestWindowClose, UiRequestWithoutPayload, UiResponseCorrelation, UiResponseCorrelationFields, UiResponseEvent, UiResponseMessage, UiResponsePassphrase, UiResponsePin, UiResponseSelectDeviceForSwitchFirmwareWebDevice, UiResponseSelectDeviceInBootloaderForWebDevice, UnavailableCapabilities, UnavailableCapability, Unsuccessful, VersionArray, ZcashAddress, ZcashGetAddressParams, ZcashSignPcztParams, ZcashSignedPczt, checkNeedUpdateBootForClassicAndMini, checkNeedUpdateBootForTouch, cleanupCallback, cleanupSdkInstance, completeRequestContext, corsValidator, createDeviceMessage, createErrorMessage, createFirmwareMessage, createIFrameMessage, createLogMessage, createRequestContext, createResponseMessage, createSdkTracingContext, createUiMessage, createUiResponse, HardwareSdk as default, enableLog, encodePro2Wallpaper, executeCallback, formatLogMethodLabel, formatRequestContext, generateInstanceId, generateSdkInstanceId, getActiveRequestsByDeviceInstance, getAutoLockOptions, getAutoShutDownOptions, getDeviceBLEFirmwareVersion, getDeviceBleName, getDeviceBoardloaderVersion, getDeviceBootloaderVersion, getDeviceFirmwareVersion, getDeviceLabel, getDeviceSerialNo, getDeviceSettingsCapabilities, getDeviceType, getDeviceTypeByBleName, getDeviceUUID, getEnv, getFirmwareType, getFirmwareUpdateField, getFirmwareUpdateFieldArray, getFirmwareUpdateHostBindingGeneration, getHDPath, getHomeScreenDefaultList, getHomeScreenHex, getHomeScreenSize, getLanguageConfig, getLog, getLogBlockLabel, getLogger, getMethodSupportedProtocols, getMethodVersionRange, getNftSize, getOutputScriptType, getSDKVersion, getSafeLogPayload, getScriptType, getTimeStamp, httpRequest, init$1 as initCore, isBleConnect, isValidVersionArray, isValidVersionString, normalizeSafetyCheckLevel, normalizeVersionArray, parseConnectSettings, parseMessage, patchFeatures, preloadSessionCache, projectFeatures as projectDeviceStateFeatures, registerFirmwareUpdateHostBinding, safeThrowError, setLoggerPostMessage, supportInputPinOnSoftware, switchTransport, transportEnv, unregisterFirmwareUpdateHostBinding, updateRequestContext, versionCompare, versionSplit, wait, whitelist, whitelistExtension };
|
|
4972
|
+
export { AccountAddress, AccountAddresses, AlephiumAddress, AlephiumGetAddressParams, AlephiumSignMessageParams, AlephiumSignTransactionParams, AlephiumSignedTx, AlgoAddress, AlgoGetAddressParams, AlgoSignTransactionParams, AlgoSignedTx, AllFirmwareRelease, AllNetworkAddressParams, AllNetworkGetAddressParams, AptosAddress, AptosGetAddressParams, AptosGetPublicKeyParams, AptosMessageSignature, AptosPublicKey, AptosSignInMessageParams, AptosSignInMessageSignature, AptosSignMessageParams, AptosSignTransactionParams, AptosSignedTx, AssetsMap, BTCAddress, BTCDeriveContextHashParams, BTCGetAddressParams, BTCGetPublicKeyParams, BTCPublicKey, BTCSignMessageParams, BTCSignTransactionParams, BTCVerifyMessageParams, BenfenAddress, BenfenGetAddressParams, BenfenGetPublicKeyParams, BenfenPublicKey, BenfenSignMessageParams, BenfenSignTransactionParams, BenfenSignedTx, BleReleaseInfoEvent, BleReleaseInfoPayload, BridgeReleaseCheckResult, CORE_EVENT, CallMethod, CallMethodAnyResponse, CallMethodKeys, CallMethodPayload, CallMethodResponse, CallMethodUnion, CardanoAddress, CardanoGetAddressMethodParams, CardanoGetAddressParams, CardanoSignMessageMethodParams, CardanoSignMessageParams, CardanoSignTransaction, CardanoSignedTxData, CipheredKeyValue, CipheredKeyValueParams, ClearSessionCacheParams, ClearSessionCachePayload, CommonParams, ConfluxAddress, ConfluxGetAddressParams, ConfluxSignMessageCIP23Params, ConfluxSignMessageParams, ConfluxSignTransactionParams, ConfluxSignedTx, ConfluxTransaction, ConnectSettings, Core, CoreApi, CoreMessage, CosmosAddress, CosmosGetAddressParams, CosmosGetPublicKeyParams, CosmosPublicKey, CosmosSignTransactionParams, CosmosSignedTx, DEFAULT_PRIORITY, DEVICE, DEVICE_EVENT, DEVICE_SETTINGS_NEVER_TIMEOUT_MS, DEVICE_SETTINGS_SHARED_FIELDS, DEVICE_SETTINGS_V1_ONLY_FIELDS, DEVICE_SETTINGS_V2_ONLY_FIELDS, DataManager, Device$1 as Device, DeviceButtonRequest, DeviceButtonRequestPayload, DeviceChangePinParams, DeviceConnnectRequest, DeviceDisconnnectRequest, DeviceEvent, DeviceEventListenerFn, DeviceEventMessage, DeviceFeaturesMode, DeviceFeaturesPayload, DeviceFeaturesProtocol, DeviceFeaturesRaw, DeviceFeaturesRawPatch, DeviceFeaturesVerify, DeviceFirmwareRange, DeviceFlagsParams, DeviceModelToTypes, DeviceProgress, DeviceRecoveryParams, DeviceResetParams, DeviceSendFeatures, DeviceSendState, DeviceSendSupportFeatures, DeviceSettingsCapabilities, DeviceSettingsDurationOption, DeviceSettingsField, DeviceSettingsParams, DeviceSettingsProtocol, DeviceSettingsValueOption, DeviceState, DeviceStateEvent, DeviceStateIdentity, DeviceStateMode, DeviceStatePatch, DeviceStateProtocol, DeviceStateScope, DeviceStateSection, DeviceStateSecurityElement, DeviceStateSecurityElements, DeviceStateSecurityElementsPatch, DeviceStateSettings, DeviceStateStatus, DeviceStateUpdateSource, DeviceStateVersions, DeviceStatus, DeviceSupportFeatures, DeviceSupportFeaturesPayload, DeviceTypeMap, DeviceTypeToModels, DeviceUnlockParams, DeviceUploadResourceParams, DeviceUploadResourceResponse, DeviceVerifyParams, DeviceVerifySignature, DnxAddress, DnxGetAddressParams, DnxSignTransactionParams, DnxSignature, DnxTxKey, EOneKeyDeviceMode, EVMAccessList, EVMAddress, EVMAuthorization, EVMAuthorizationSignature, EVMGetAddressParams, EVMGetPublicKeyParams, EVMPublicKey, EVMSignMessageEIP712Params, EVMSignMessageParams, EVMSignTransactionParams, EVMSignTypedDataParams, EVMSignedTx, EVMTransaction, EVMTransactionEIP1559, EVMTransactionEIP7702, EVMVerifyMessageParams, EthereumSignTypedDataMessage, EthereumSignTypedDataTypeProperty, EthereumSignTypedDataTypes, FIRMWARE, FIRMWARE_EVENT, Features, FilecoinAddress, FilecoinGetAddressParams, FilecoinSignTransactionParams, FilecoinSignedTx, FirmwareArtifactReader, FirmwareArtifactReference, FirmwareEvent, FirmwareMessage, FirmwareProcessing, FirmwareProgress, FirmwareRange, FirmwareRelease, FirmwareReleaseCheckResult, FirmwareTip, FirmwareUpdateArtifactParams, FirmwareUpdateBinaryParams, FirmwareUpdateCapabilities, FirmwareUpdateHostBinding, FirmwareUpdateParams, FirmwareUpdatePlan, FirmwareUpdatePlanArtifact, FirmwareUpdatePlanArtifactRole, FirmwareUpdatePlanForceTarget, FirmwareUpdatePlanTarget, FirmwareUpdatePreparedArtifact, FirmwareUpdatePreparedArtifactInput, FirmwareUpdatePreparedEntry, FirmwareUpdatePreparedPlan, FirmwareUpdateTipMessage, FirmwareUpdateV3Params, FirmwareUpdateV4Params, FirmwareUpdateV4Target, GetDeviceStateParams, GetPassphraseStateParams, HardwareSDKLowLevel, HardwareTopLevelSdk, HardwareUiInteractionMeta, IBLEFirmwareReleaseInfo, IDeviceBLEFirmwareStatus, IDeviceFirmwareStatus, IDeviceModel, IDeviceType, IFRAME, IFirmwareField, IFirmwareReleaseInfo, IFirmwareUpdateProgressType, IFirmwareUpdateTipMessage, IFrameBridge, IFrameCallMessage, IFrameCallback, IFrameCallbackMessage, IFrameCancelMessage, IFrameEvent, IFrameEventMessage, IFrameInit, IFrameSwitchTransport, IFrameSwitchTransportMessage, ILocale, IProtocolV2FirmwareComponent, IProtocolV2FirmwareComponentTarget, IProtocolV2ResourceSource, IProtocolV2Resources, ITransportStatus, IVersionArray, IVersionRange, KaspaAddress, KaspaGetAddressParams, KaspaSignInputParams, KaspaSignOutputParams, KaspaSignTransactionParams, KaspaSignature, KaspaStreamingSignInputParams, KaspaStreamingSignOutputParams, KnownDevice, LOG, LOG_EVENT, LogBlockEvent, LogEvent, LogEventMessage, LogOutput, LoggerNames, LowLevelCoreApi, LowLevelInjectApi, MajorVersion, MethodResponseMessage, NEMAddress, NEMAggregateModificationTransaction, NEMGetAddressParams, NEMImportanceTransaction, NEMMosaic, NEMMosaicCreationTransaction, NEMMultisigTransaction, NEMProvisionNamespaceTransaction, NEMSignTransactionParams, NEMSupplyChangeTransaction, NEMTransaction, NEMTransferTransaction, NearAddress, NearGetAddressParams, NearSignTransactionParams, NervosAddress, NervosGetAddressParams, NervosSignTransactionParams, NervosSignedTx, NexaAddress, NexaGetAddressParams, NexaSignInputParams, NexaSignOutputParams, NexaSignTransactionParams, NexaSignature, NormalizedFeatures, OnekeyFeatures, OpenWalletSessionMode, OpenWalletSessionModeValue, OpenWalletSessionParams, OpenWalletSessionPayload, PRO2_WALLPAPER_HEIGHT, PRO2_WALLPAPER_WIDTH, PROTOCOL_V2_NEVER_TIMEOUT_MS, Params, PassphraseRequestPayload, PolkadotAddress, PolkadotGetAddressParams, PolkadotSignTransactionParams, PolkadotSignedTx, PostMessageEvent, PreviousAddressResult, Pro2WallpaperColorFormat, ProtocolV2ComponentReleaseInfo, ProtocolV2FirmwareComponentRelease, ProtocolV2FirmwareComponentReleaseStatus, ProtocolV2FirmwareReleaseStatus, ProtocolV2UiCompletion, ProtocolV2UiEventMetadata, ProtocolV2UiEventSource, RESPONSE_EVENT, RefTransaction, ReleaseInfo, ReleaseInfoEvent, ReleaseInfoPayload, RemoteConfigResponse, RequestContext, Response, ScdoAddress, ScdoGetAddressParams, ScdoSignMessageParams, ScdoSignTransactionParams, ScdoSignedTx, SdkTracingContext, SearchDevice, SignedTransaction, SolSignMessageParams, SolSignMessageResponse, SolSignOffchainMessageParams, SolSignOffchainMessageResponse, SolanaAddress, SolanaGetAddressParams, SolanaSignTransactionParams, SolanaSignedTx, StarcoinAddress, StarcoinGetAddressParams, StarcoinGetPublicKeyParams, StarcoinPublicKey, StarcoinSignMessageParams, StarcoinSignTransactionParams, StarcoinVerifyMessageParams, StellarAddress, StellarAsset, StellarGetAddressParams, StellarOperation, StellarSignTransactionParams, StellarTransaction, StrictFeatures, Success, SuiAddress, SuiGetAddressParams, SuiGetPublicKeyParams, SuiPublicKey, SuiSignMessageParams, SuiSignTransactionParams, SuiSignedTx, SupportFeatureType, SupportFeatures, TestProtocolV2PingParams, TonAddress, TonGetAddressParams, TonSignDataParams, TonSignMessageParams, TonSignProofParams, TopLevelInjectApi, TransactionOptions, TransportReleaseStatus, TronAddress, TronDelegateResourceContract, TronFreezeBalanceV2Contract, TronGetAddressParams, TronSignMessageParams, TronSignTransactionParams, TronTransaction, TronTransactionContract, TronTransferContract, TronTriggerSmartContract, TronUnDelegateResourceContract, TronUnfreezeBalanceV2Contract, TronWithdrawBalanceContract, TronWithdrawExpireUnfreezeContract, UI_EVENT, UI_REQUEST, UI_RESPONSE, UiEvent, UiEventMessage, UiPromise, UiPromiseResponse, UiRequestButton, UiRequestDeviceAction, UiRequestFirmwareProgressing, UiRequestPassphrase, UiRequestPassphraseOnDevice, UiRequestSelectDeviceForSwitchFirmwareWebDevice, UiRequestSelectDeviceInBootloaderForWebDevice, UiRequestWindowClose, UiRequestWithoutPayload, UiResponseCorrelation, UiResponseCorrelationFields, UiResponseEvent, UiResponseMessage, UiResponsePassphrase, UiResponsePin, UiResponseSelectDeviceForSwitchFirmwareWebDevice, UiResponseSelectDeviceInBootloaderForWebDevice, UnavailableCapabilities, UnavailableCapability, Unsuccessful, UsbDeviceIdentity, VersionArray, ZcashAddress, ZcashGetAddressParams, ZcashSignPcztParams, ZcashSignedPczt, checkNeedUpdateBootForClassicAndMini, checkNeedUpdateBootForTouch, cleanupCallback, cleanupSdkInstance, completeRequestContext, corsValidator, createDeviceMessage, createErrorMessage, createFirmwareMessage, createIFrameMessage, createLogMessage, createRequestContext, createResponseMessage, createSdkTracingContext, createUiMessage, createUiResponse, HardwareSdk as default, enableLog, encodePro2Wallpaper, executeCallback, formatLogMethodLabel, formatRequestContext, generateInstanceId, generateSdkInstanceId, getActiveRequestsByDeviceInstance, getAutoLockOptions, getAutoShutDownOptions, getDeviceBLEFirmwareVersion, getDeviceBleName, getDeviceBoardloaderVersion, getDeviceBootloaderVersion, getDeviceFirmwareVersion, getDeviceLabel, getDeviceSerialNo, getDeviceSettingsCapabilities, getDeviceType, getDeviceTypeByBleName, getDeviceUUID, getEnv, getFirmwareType, getFirmwareUpdateField, getFirmwareUpdateFieldArray, getFirmwareUpdateHostBindingGeneration, getHDPath, getHomeScreenDefaultList, getHomeScreenHex, getHomeScreenSize, getLanguageConfig, getLog, getLogBlockLabel, getLogger, getMethodSupportedProtocols, getMethodVersionRange, getNftSize, getOutputScriptType, getSDKVersion, getSafeLogPayload, getScriptType, getTimeStamp, httpRequest, init$1 as initCore, isBleConnect, isValidVersionArray, isValidVersionString, normalizeSafetyCheckLevel, normalizeVersionArray, parseConnectSettings, parseMessage, patchFeatures, preloadSessionCache, probeUsbDeviceIdentitiesWithTransport, projectFeatures as projectDeviceStateFeatures, registerFirmwareUpdateHostBinding, safeThrowError, setLoggerPostMessage, supportInputPinOnSoftware, switchTransport, transportEnv, unregisterFirmwareUpdateHostBinding, updateRequestContext, versionCompare, versionSplit, wait, whitelist, whitelistExtension };
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,eAAe,EAAU,MAAM,UAAU,CAAC;AAIpE,OAAO,KAAK,EAAE,eAAe,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAC3E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAE3C,YAAY,EAAE,eAAe,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAC3E,YAAY,EAAE,iBAAiB,EAA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