@onekeyfe/hd-core 1.1.25-alpha.1 → 1.1.25

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.
@@ -0,0 +1,499 @@
1
+ import EVMSignTypedData from '../src/api/evm/EVMSignTypedData';
2
+
3
+ import type { EthereumSignTypedDataMessage, EthereumSignTypedDataTypes } from '../src/types';
4
+
5
+ // Mock the config module to avoid package.json resolution issues
6
+ jest.mock('../src/data/config', () => ({
7
+ getSDKVersion: jest.fn(() => '1.0.0'),
8
+ DEFAULT_DOMAIN: 'https://jssdk.onekey.so/1.0.0/',
9
+ }));
10
+
11
+ jest.mock('../src/data-manager/TransportManager', () => ({
12
+ getMessageVersion: jest.fn(() => 'v2'),
13
+ }));
14
+
15
+ jest.mock('../src/device/Device', () => ({
16
+ Device: jest.fn(),
17
+ }));
18
+
19
+ function createMethod(
20
+ data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes>,
21
+ metamaskV4Compat = true
22
+ ): EVMSignTypedData {
23
+ const method = new EVMSignTypedData({
24
+ id: 1,
25
+ payload: {
26
+ method: 'evmSignTypedData',
27
+ path: "m/44'/60'/0'/0/0",
28
+ metamaskV4Compat,
29
+ data,
30
+ domainHash: '0xabcd',
31
+ messageHash: '0x1234',
32
+ },
33
+ });
34
+ method.device = {
35
+ commands: { typedCall: { bind: jest.fn() } },
36
+ } as any;
37
+ method.init();
38
+ return method;
39
+ }
40
+
41
+ function baseDomain(): { EIP712Domain: { name: string; type: string }[] } {
42
+ return { EIP712Domain: [{ name: 'name', type: 'string' }] };
43
+ }
44
+
45
+ describe('EVMSignTypedData — hasClassicFamilyTypedDataFormatViolations', () => {
46
+ // ─── early return ───
47
+ describe('early return', () => {
48
+ it('returns false when types is missing', () => {
49
+ const method = createMethod({ primaryType: 'Foo', domain: {}, message: {} } as any);
50
+ expect(method.hasClassicFamilyTypedDataFormatViolations({} as any)).toBe(false);
51
+ });
52
+
53
+ it('returns false when primaryType is missing', () => {
54
+ const method = createMethod({
55
+ types: baseDomain(),
56
+ domain: {},
57
+ message: {},
58
+ } as any);
59
+ expect(method.hasClassicFamilyTypedDataFormatViolations({ types: baseDomain() } as any)).toBe(
60
+ false
61
+ );
62
+ });
63
+ });
64
+
65
+ // ─── struct fields ───
66
+ describe('struct fields limit (16)', () => {
67
+ it('returns false with exactly 16 fields', () => {
68
+ const fields = Array.from({ length: 16 }, (_, i) => ({
69
+ name: `f${i}`,
70
+ type: 'uint256',
71
+ }));
72
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
73
+ types: { ...baseDomain(), MyStruct: fields },
74
+ primaryType: 'MyStruct',
75
+ domain: { name: 'test' },
76
+ message: Object.fromEntries(fields.map(f => [f.name, '1'])),
77
+ };
78
+ const method = createMethod(data);
79
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
80
+ });
81
+
82
+ it('returns true with 17 fields', () => {
83
+ const fields = Array.from({ length: 17 }, (_, i) => ({
84
+ name: `f${i}`,
85
+ type: 'uint256',
86
+ }));
87
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
88
+ types: { ...baseDomain(), MyStruct: fields },
89
+ primaryType: 'MyStruct',
90
+ domain: { name: 'test' },
91
+ message: Object.fromEntries(fields.map(f => [f.name, '1'])),
92
+ };
93
+ const method = createMethod(data);
94
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
95
+ });
96
+ });
97
+
98
+ // ─── name length ───
99
+ describe('name length limit (63)', () => {
100
+ it('returns false with 63-char type name', () => {
101
+ const longName = 'A'.repeat(63);
102
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
103
+ types: { ...baseDomain(), [longName]: [{ name: 'x', type: 'uint256' }] },
104
+ primaryType: longName,
105
+ domain: { name: 'test' },
106
+ message: { x: '1' },
107
+ };
108
+ const method = createMethod(data);
109
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
110
+ });
111
+
112
+ it('returns true with 64-char type name', () => {
113
+ const longName = 'A'.repeat(64);
114
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
115
+ types: { ...baseDomain(), [longName]: [{ name: 'x', type: 'uint256' }] },
116
+ primaryType: longName,
117
+ domain: { name: 'test' },
118
+ message: { x: '1' },
119
+ };
120
+ const method = createMethod(data);
121
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
122
+ });
123
+
124
+ it('returns true with 64-char field name', () => {
125
+ const longFieldName = 'f'.repeat(64);
126
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
127
+ types: { ...baseDomain(), Foo: [{ name: longFieldName, type: 'uint256' }] },
128
+ primaryType: 'Foo',
129
+ domain: { name: 'test' },
130
+ message: { [longFieldName]: '1' },
131
+ };
132
+ const method = createMethod(data);
133
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
134
+ });
135
+ });
136
+
137
+ // ─── access path depth ───
138
+ describe('access path depth limit (6)', () => {
139
+ it('returns false for depth exactly 6 (root + domain + 4 nested structs)', () => {
140
+ // depth: root(1) + EIP712Domain or primaryType
141
+ // primaryType path: root(1) + D(1) + C(1) + B(1) + A(1) + uint256(1) = 6
142
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
143
+ types: {
144
+ ...baseDomain(),
145
+ D: [{ name: 'c', type: 'C' }],
146
+ C: [{ name: 'b', type: 'B' }],
147
+ B: [{ name: 'a', type: 'A' }],
148
+ A: [{ name: 'val', type: 'uint256' }],
149
+ },
150
+ primaryType: 'D',
151
+ domain: { name: 'test' },
152
+ message: { c: { b: { a: { val: '1' } } } },
153
+ };
154
+ const method = createMethod(data);
155
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
156
+ });
157
+
158
+ it('returns true when depth exceeds 6', () => {
159
+ // depth: root(1) + E(1) + D(1) + C(1) + B(1) + A(1) + uint256(1) = 7
160
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
161
+ types: {
162
+ ...baseDomain(),
163
+ E: [{ name: 'd', type: 'D' }],
164
+ D: [{ name: 'c', type: 'C' }],
165
+ C: [{ name: 'b', type: 'B' }],
166
+ B: [{ name: 'a', type: 'A' }],
167
+ A: [{ name: 'val', type: 'uint256' }],
168
+ },
169
+ primaryType: 'E',
170
+ domain: { name: 'test' },
171
+ message: { d: { c: { b: { a: { val: '1' } } } } },
172
+ };
173
+ const method = createMethod(data);
174
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
175
+ });
176
+
177
+ it('returns true for cyclic type references', () => {
178
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
179
+ types: {
180
+ ...baseDomain(),
181
+ NodeA: [{ name: 'next', type: 'NodeB' }],
182
+ NodeB: [{ name: 'next', type: 'NodeA' }],
183
+ },
184
+ primaryType: 'NodeA',
185
+ domain: { name: 'test' },
186
+ message: { next: { next: {} } },
187
+ };
188
+ const method = createMethod(data);
189
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
190
+ });
191
+ });
192
+
193
+ // ─── custom dependency structs ───
194
+ describe('custom dependency structs limit (8)', () => {
195
+ it('returns false with exactly 8 dep structs', () => {
196
+ const types: EthereumSignTypedDataTypes = { ...baseDomain() };
197
+ const message: Record<string, string> = {};
198
+ const fields: { name: string; type: string }[] = [];
199
+ for (let i = 1; i <= 8; i++) {
200
+ const depName = `Dep${i}`;
201
+ types[depName] = [{ name: 'v', type: 'uint256' }];
202
+ fields.push({ name: `d${i}`, type: depName });
203
+ message[`d${i}`] = JSON.stringify({ v: '1' });
204
+ }
205
+ types.Root = fields;
206
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
207
+ types,
208
+ primaryType: 'Root',
209
+ domain: { name: 'test' },
210
+ message,
211
+ };
212
+ const method = createMethod(data);
213
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
214
+ });
215
+
216
+ it('returns true with 9 dep structs', () => {
217
+ const types: EthereumSignTypedDataTypes = { ...baseDomain() };
218
+ const message: Record<string, string> = {};
219
+ const fields: { name: string; type: string }[] = [];
220
+ for (let i = 1; i <= 9; i++) {
221
+ const depName = `Dep${i}`;
222
+ types[depName] = [{ name: 'v', type: 'uint256' }];
223
+ fields.push({ name: `d${i}`, type: depName });
224
+ message[`d${i}`] = JSON.stringify({ v: '1' });
225
+ }
226
+ types.Root = fields;
227
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
228
+ types,
229
+ primaryType: 'Root',
230
+ domain: { name: 'test' },
231
+ message,
232
+ };
233
+ const method = createMethod(data);
234
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
235
+ });
236
+ });
237
+
238
+ // ─── dynamic value size (string) ───
239
+ describe('dynamic value size — string (1536 bytes)', () => {
240
+ it('returns false with exactly 1536 bytes', () => {
241
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
242
+ types: { ...baseDomain(), Note: [{ name: 'text', type: 'string' }] },
243
+ primaryType: 'Note',
244
+ domain: { name: 'test' },
245
+ message: { text: 'a'.repeat(1536) },
246
+ };
247
+ const method = createMethod(data);
248
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
249
+ });
250
+
251
+ it('returns true with 1537 bytes', () => {
252
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
253
+ types: { ...baseDomain(), Note: [{ name: 'text', type: 'string' }] },
254
+ primaryType: 'Note',
255
+ domain: { name: 'test' },
256
+ message: { text: 'a'.repeat(1537) },
257
+ };
258
+ const method = createMethod(data);
259
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
260
+ });
261
+ });
262
+
263
+ // ─── dynamic value size (bytes) ───
264
+ describe('dynamic value size — bytes (1536 bytes)', () => {
265
+ it('returns false with exactly 1536 bytes hex', () => {
266
+ // 1536 bytes = 3072 hex chars
267
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
268
+ types: { ...baseDomain(), Blob: [{ name: 'raw', type: 'bytes' }] },
269
+ primaryType: 'Blob',
270
+ domain: { name: 'test' },
271
+ message: { raw: `0x${'ab'.repeat(1536)}` },
272
+ };
273
+ const method = createMethod(data);
274
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
275
+ });
276
+
277
+ it('returns true with 1537 bytes hex', () => {
278
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
279
+ types: { ...baseDomain(), Blob: [{ name: 'raw', type: 'bytes' }] },
280
+ primaryType: 'Blob',
281
+ domain: { name: 'test' },
282
+ message: { raw: `0x${'ab'.repeat(1537)}` },
283
+ };
284
+ const method = createMethod(data);
285
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
286
+ });
287
+
288
+ it('returns false for bytes without 0x prefix at exactly 1536 bytes', () => {
289
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
290
+ types: { ...baseDomain(), Blob: [{ name: 'raw', type: 'bytes' }] },
291
+ primaryType: 'Blob',
292
+ domain: { name: 'test' },
293
+ message: { raw: 'ab'.repeat(1536) },
294
+ };
295
+ const method = createMethod(data);
296
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
297
+ });
298
+ });
299
+
300
+ // ─── array elements ───
301
+ describe('array elements limit (24)', () => {
302
+ it('returns false with 24 primitive elements', () => {
303
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
304
+ types: { ...baseDomain(), List: [{ name: 'items', type: 'uint256[]' }] },
305
+ primaryType: 'List',
306
+ domain: { name: 'test' },
307
+ message: { items: Array.from({ length: 24 }, (_, i) => String(i)) },
308
+ };
309
+ const method = createMethod(data);
310
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
311
+ });
312
+
313
+ it('returns true with 25 primitive elements', () => {
314
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
315
+ types: { ...baseDomain(), List: [{ name: 'items', type: 'uint256[]' }] },
316
+ primaryType: 'List',
317
+ domain: { name: 'test' },
318
+ message: { items: Array.from({ length: 25 }, (_, i) => String(i)) },
319
+ };
320
+ const method = createMethod(data);
321
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
322
+ });
323
+
324
+ it('returns true with 25 struct elements in V4 mode', () => {
325
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
326
+ types: {
327
+ ...baseDomain(),
328
+ Item: [{ name: 'v', type: 'uint256' }],
329
+ List: [{ name: 'items', type: 'Item[]' }],
330
+ },
331
+ primaryType: 'List',
332
+ domain: { name: 'test' },
333
+ message: { items: Array.from({ length: 25 }, () => ({ v: '1' })) },
334
+ };
335
+ const method = createMethod(data, true);
336
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
337
+ });
338
+
339
+ it('returns false with 25 struct elements in non-V4 mode', () => {
340
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
341
+ types: {
342
+ ...baseDomain(),
343
+ Item: [{ name: 'v', type: 'uint256' }],
344
+ List: [{ name: 'items', type: 'Item[]' }],
345
+ },
346
+ primaryType: 'List',
347
+ domain: { name: 'test' },
348
+ message: { items: Array.from({ length: 25 }, () => ({ v: '1' })) },
349
+ };
350
+ const method = createMethod(data, false);
351
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
352
+ });
353
+ });
354
+
355
+ // ─── array type fields ───
356
+ describe('total array type fields limit (24)', () => {
357
+ it('returns false with exactly 24 array type fields across structs', () => {
358
+ const types: EthereumSignTypedDataTypes = { ...baseDomain() };
359
+ // Spread 24 array fields across 2 structs (12 each) to stay under the 16-field limit
360
+ const fieldsA: { name: string; type: string }[] = [];
361
+ const fieldsB: { name: string; type: string }[] = [];
362
+ for (let i = 0; i < 12; i++) {
363
+ fieldsA.push({ name: `a${i}`, type: 'uint256[]' });
364
+ fieldsB.push({ name: `b${i}`, type: 'uint256[]' });
365
+ }
366
+ types.PartA = fieldsA;
367
+ types.PartB = fieldsB;
368
+ types.Root = [
369
+ { name: 'partA', type: 'PartA' },
370
+ { name: 'partB', type: 'PartB' },
371
+ ];
372
+ const messageA: Record<string, string[]> = {};
373
+ const messageB: Record<string, string[]> = {};
374
+ fieldsA.forEach(f => {
375
+ messageA[f.name] = ['1'];
376
+ });
377
+ fieldsB.forEach(f => {
378
+ messageB[f.name] = ['1'];
379
+ });
380
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
381
+ types,
382
+ primaryType: 'Root',
383
+ domain: { name: 'test' },
384
+ message: { partA: messageA, partB: messageB },
385
+ };
386
+ const method = createMethod(data);
387
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
388
+ });
389
+
390
+ it('returns true with 25 array type fields', () => {
391
+ const types: EthereumSignTypedDataTypes = { ...baseDomain() };
392
+ const fieldsA: { name: string; type: string }[] = [];
393
+ const fieldsB: { name: string; type: string }[] = [];
394
+ const message: Record<string, unknown> = {};
395
+ for (let i = 0; i < 13; i++) {
396
+ fieldsA.push({ name: `a${i}`, type: 'uint256[]' });
397
+ message[`a${i}`] = ['1'];
398
+ }
399
+ for (let i = 0; i < 12; i++) {
400
+ fieldsB.push({ name: `b${i}`, type: 'uint256[]' });
401
+ }
402
+ types.PartA = fieldsA;
403
+ types.PartB = fieldsB;
404
+ types.Root = [
405
+ { name: 'partA', type: 'PartA' },
406
+ { name: 'partB', type: 'PartB' },
407
+ ];
408
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
409
+ types,
410
+ primaryType: 'Root',
411
+ domain: { name: 'test' },
412
+ message: { partA: message, partB: {} },
413
+ };
414
+ const method = createMethod(data);
415
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
416
+ });
417
+ });
418
+
419
+ // ─── happy path — no violations ───
420
+ describe('no violations', () => {
421
+ it('returns false for a simple valid message', () => {
422
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
423
+ types: {
424
+ ...baseDomain(),
425
+ Transfer: [
426
+ { name: 'to', type: 'address' },
427
+ { name: 'amount', type: 'uint256' },
428
+ ],
429
+ },
430
+ primaryType: 'Transfer',
431
+ domain: { name: 'MyApp' },
432
+ message: {
433
+ to: '0x1234567890123456789012345678901234567890',
434
+ amount: '1000000',
435
+ },
436
+ };
437
+ const method = createMethod(data);
438
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
439
+ });
440
+ });
441
+
442
+ // ─── dynamic value in nested struct ───
443
+ describe('dynamic value in nested struct', () => {
444
+ it('returns true when a nested struct field exceeds dynamic value limit', () => {
445
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
446
+ types: {
447
+ ...baseDomain(),
448
+ Inner: [{ name: 'memo', type: 'string' }],
449
+ Outer: [{ name: 'inner', type: 'Inner' }],
450
+ },
451
+ primaryType: 'Outer',
452
+ domain: { name: 'test' },
453
+ message: { inner: { memo: 'x'.repeat(1537) } },
454
+ };
455
+ const method = createMethod(data);
456
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
457
+ });
458
+ });
459
+
460
+ // ─── array with nested struct containing large string ───
461
+ describe('array with nested large value', () => {
462
+ it('returns true when array entry struct has oversized string', () => {
463
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
464
+ types: {
465
+ ...baseDomain(),
466
+ Entry: [{ name: 'data', type: 'string' }],
467
+ Root: [{ name: 'entries', type: 'Entry[]' }],
468
+ },
469
+ primaryType: 'Root',
470
+ domain: { name: 'test' },
471
+ message: {
472
+ entries: [{ data: 'ok' }, { data: 'b'.repeat(1537) }],
473
+ },
474
+ };
475
+ const method = createMethod(data);
476
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(true);
477
+ });
478
+ });
479
+
480
+ // ─── depth with array type ───
481
+ describe('depth counting with array types', () => {
482
+ it('counts array as additional depth level', () => {
483
+ // root(1) + Outer(1) + Inner[](1) + Inner(1) + Sub(1) + uint256(1) = 6 ✓ OK
484
+ const data: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes> = {
485
+ types: {
486
+ ...baseDomain(),
487
+ Sub: [{ name: 'val', type: 'uint256' }],
488
+ Inner: [{ name: 'sub', type: 'Sub' }],
489
+ Outer: [{ name: 'inners', type: 'Inner[]' }],
490
+ },
491
+ primaryType: 'Outer',
492
+ domain: { name: 'test' },
493
+ message: { inners: [{ sub: { val: '1' } }] },
494
+ };
495
+ const method = createMethod(data);
496
+ expect(method.hasClassicFamilyTypedDataFormatViolations(data)).toBe(false);
497
+ });
498
+ });
499
+ });
@@ -38,6 +38,7 @@ export default class EVMSignTypedData extends BaseMethod<EVMSignTypedDataParams>
38
38
  };
39
39
  hasBiggerData(item: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes>): boolean;
40
40
  hasNestedArrays(item: any): boolean;
41
+ hasClassicFamilyTypedDataFormatViolations(item: EthereumSignTypedDataMessage<EthereumSignTypedDataTypes>): boolean;
41
42
  supportSignTyped(): boolean;
42
43
  run(): Promise<import("@onekeyfe/hd-transport").EthereumMessageSignature>;
43
44
  }
@@ -1 +1 @@
1
- {"version":3,"file":"EVMSignTypedData.d.ts","sourceRoot":"","sources":["../../../src/api/evm/EVMSignTypedData.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAK3C,OAAO,EAEL,KAAK,4BAA4B,EACjC,KAAK,0BAA0B,EAChC,MAAM,aAAa,CAAC;AAQrB,OAAO,KAAK,EAGV,UAAU,EACV,eAAe,EACf,SAAS,EACV,MAAM,wBAAwB,CAAC;AAEhC,MAAM,MAAM,sBAAsB,GAAG;IACnC,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,IAAI,EAAE,4BAA4B,CAAC,0BAA0B,CAAC,CAAC;IAC/D,UAAU,CAAC,EAAE,MAAM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