@private.me/xbind 1.3.0 → 1.3.5

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.
Files changed (68) hide show
  1. package/README.md +2 -2
  2. package/dist-standalone/_deps/crypto/base64.js +183 -170
  3. package/dist-standalone/_deps/crypto/cjs/base64.js +653 -91
  4. package/dist-standalone/_deps/crypto/cjs/errors.js +658 -102
  5. package/dist-standalone/_deps/crypto/cjs/hmac.js +468 -66
  6. package/dist-standalone/_deps/crypto/cjs/index.js +848 -82
  7. package/dist-standalone/_deps/crypto/cjs/package.json +1 -0
  8. package/dist-standalone/_deps/crypto/cjs/padding.js +504 -50
  9. package/dist-standalone/_deps/crypto/cjs/share-header.js +369 -65
  10. package/dist-standalone/_deps/crypto/cjs/shares.js +865 -143
  11. package/dist-standalone/_deps/crypto/cjs/tlv.js +1005 -183
  12. package/dist-standalone/_deps/crypto/cjs/uuid.js +437 -55
  13. package/dist-standalone/_deps/crypto/cjs/verify.js +414 -24
  14. package/dist-standalone/_deps/crypto/cjs/xorida.js +888 -186
  15. package/dist-standalone/_deps/crypto/errors.js +179 -89
  16. package/dist-standalone/_deps/crypto/hmac.js +129 -61
  17. package/dist-standalone/_deps/crypto/index.js +140 -40
  18. package/dist-standalone/_deps/crypto/padding.js +151 -45
  19. package/dist-standalone/_deps/crypto/share-header.js +89 -60
  20. package/dist-standalone/_deps/crypto/shares.js +280 -133
  21. package/dist-standalone/_deps/crypto/tlv.js +348 -179
  22. package/dist-standalone/_deps/crypto/uuid.js +130 -50
  23. package/dist-standalone/_deps/crypto/verify.js +71 -15
  24. package/dist-standalone/_deps/crypto/xorida.js +332 -181
  25. package/dist-standalone/_deps/shared/cjs/errors.js +572 -208
  26. package/dist-standalone/_deps/shared/cjs/index.js +443 -85
  27. package/dist-standalone/_deps/shared/cjs/types.js +284 -57
  28. package/dist-standalone/_deps/shared/errors.js +192 -199
  29. package/dist-standalone/_deps/shared/index.js +48 -51
  30. package/dist-standalone/_deps/shared/types.js +56 -57
  31. package/dist-standalone/_deps/ux-helpers/cjs/errors.js +1 -1
  32. package/dist-standalone/_deps/ux-helpers/cjs/pagination.js +1 -1
  33. package/dist-standalone/_deps/ux-helpers/cjs/progress.js +1 -1
  34. package/dist-standalone/_deps/ux-helpers/cjs/search.js +1 -1
  35. package/dist-standalone/_deps/ux-helpers/errors.js +1 -1
  36. package/dist-standalone/_deps/ux-helpers/pagination.js +1 -1
  37. package/dist-standalone/_deps/ux-helpers/progress.js +1 -1
  38. package/dist-standalone/_deps/ux-helpers/search.js +1 -1
  39. package/dist-standalone/_deps/xchange/auto-accept.js +1 -1
  40. package/dist-standalone/_deps/xchange/cjs/auto-accept.js +1 -1
  41. package/dist-standalone/_deps/xchange/cjs/errors.js +1 -1
  42. package/dist-standalone/_deps/xchange/cjs/index.js +1 -1
  43. package/dist-standalone/_deps/xchange/cjs/invite-client.js +1 -1
  44. package/dist-standalone/_deps/xchange/cjs/lazy-init.js +1 -1
  45. package/dist-standalone/_deps/xchange/cjs/trust-integration.js +1 -1
  46. package/dist-standalone/_deps/xchange/cjs/xchange.js +1 -1
  47. package/dist-standalone/_deps/xchange/errors.js +1 -1
  48. package/dist-standalone/_deps/xchange/index.js +1 -1
  49. package/dist-standalone/_deps/xchange/invite-client.js +1 -1
  50. package/dist-standalone/_deps/xchange/lazy-init.js +1 -1
  51. package/dist-standalone/_deps/xchange/trust-integration.js +1 -1
  52. package/dist-standalone/_deps/xchange/xchange.js +1 -1
  53. package/dist-standalone/_deps/xregistry/cjs/discovery.js +1 -1
  54. package/dist-standalone/_deps/xregistry/cjs/errors.js +1 -1
  55. package/dist-standalone/_deps/xregistry/cjs/index.js +1 -1
  56. package/dist-standalone/_deps/xregistry/cjs/registry.js +1 -1
  57. package/dist-standalone/_deps/xregistry/cjs/schema.js +1 -1
  58. package/dist-standalone/_deps/xregistry/cjs/types.js +1 -1
  59. package/dist-standalone/_deps/xregistry/discovery.js +1 -1
  60. package/dist-standalone/_deps/xregistry/errors.js +1 -1
  61. package/dist-standalone/_deps/xregistry/index.js +1 -1
  62. package/dist-standalone/_deps/xregistry/registry.js +1 -1
  63. package/dist-standalone/_deps/xregistry/schema.js +1 -1
  64. package/dist-standalone/_deps/xregistry/types.js +1 -1
  65. package/dist-standalone/cjs/identity.js +2 -3
  66. package/dist-standalone/identity.js +2 -3
  67. package/package.json +2 -1
  68. package/share1.dat +0 -0
@@ -1,152 +1,874 @@
1
- "use strict";
2
- /**
3
- * High-level share creation and reconstruction API.
4
- *
5
- * Sender pipeline: serialize (TLV) → pad (PKCS#7) → HMAC (sign) → split (XorIDA)
6
- * Receiver pipeline: reconstruct (XorIDA) → verify (HMAC) → unpad (PKCS#7) → deserialize (TLV)
7
- */
8
- Object.defineProperty(exports, "__esModule", { value: true });
9
- exports.createShares = createShares;
10
- exports.reconstructMessage = reconstructMessage;
11
- const shared_1 = require("../../shared/index.js");
12
- const tlv_js_1 = require("./tlv.js");
13
- const padding_js_1 = require("./padding.js");
14
- const hmac_js_1 = require("./hmac.js");
15
- const xorida_js_1 = require("./xorida.js");
16
- const uuid_js_1 = require("./uuid.js");
17
- /**
18
- * Create shares from a XailMessage.
19
- *
20
- * Pipeline: serialize → pad → HMAC → split → package as XailShare[]
21
- *
22
- * @param message - The message to split into shares
23
- * @param n - Total number of shares to produce
24
- * @param k - Threshold: minimum shares needed for reconstruction
25
- * @returns Array of n XailShare objects ready for transport
26
- */
27
- async function createShares(message, n, k) {
28
- // Ensure UUID is set before serialization so TLV and share headers match.
29
- const uuid = message.uuid || (0, uuid_js_1.generateUUID)();
30
- const messageWithUuid = uuid !== message.uuid ? { ...message, uuid } : message;
31
- // Step 1: Serialize to TLV
32
- const tlvPayload = (0, tlv_js_1.serializeMessage)(messageWithUuid);
33
- // Step 2: Pad to XorIDA block boundary
34
- const p = (0, xorida_js_1.nextOddPrime)(n);
35
- const blockSize = p - 1;
36
- const padded = (0, padding_js_1.pkcs7Pad)(tlvPayload, blockSize);
37
- // Step 3: HMAC the padded payload
38
- const { key: hmacKey, signature: hmacSignature } = await (0, hmac_js_1.generateHMAC)(padded);
39
- // Step 4: Split via XorIDA
40
- const shareDataArrays = (0, xorida_js_1.splitXorIDA)(padded, n, k);
41
- const shares = shareDataArrays.map((data, index) => ({
42
- uuid,
43
- index,
44
- totalShares: n,
45
- threshold: k,
46
- data,
47
- hmacKey: hmacKey.slice(), // each share carries a copy
48
- hmacSignature: hmacSignature.slice(),
49
- }));
50
- return shares;
51
- }
52
- /**
53
- * Reconstruct a XailMessage from k shares.
54
- *
55
- * Pipeline: validate → reconstruct → verify HMAC → unpad → deserialize
56
- *
57
- * @param shares - Array of k XailShare objects (must share the same UUID)
58
- * @returns Reconstructed message, or ReconstructionError
59
- */
60
- async function reconstructMessage(shares) {
61
- // Validation: need at least k shares
62
- if (shares.length === 0) {
63
- return (0, shared_1.err)({ code: 'INSUFFICIENT_SHARES', message: 'No shares provided' });
1
+ 'use strict';
2
+ const a6_0x3bd392 = a6_0x4a9d;
3
+ (function (_0x1fc867, _0x209236) {
4
+ const a6_0x247d83 = {
5
+ _0x135f9c: 0x14a,
6
+ _0x58cd1: 0xa1,
7
+ _0xfc3f07: 0x131,
8
+ _0x2e1a36: 0x9d,
9
+ _0x5911d9: 0x93
10
+ }, _0x3a6e1c = a6_0x4a9d, _0x4d071e = _0x1fc867();
11
+ while (!![]) {
12
+ try {
13
+ const _0x361e3f = -parseInt(_0x3a6e1c(0xce)) / 0x1 + parseInt(_0x3a6e1c(0xdd)) / 0x2 * (parseInt(_0x3a6e1c(a6_0x247d83._0x135f9c)) / 0x3) + -parseInt(_0x3a6e1c(0x105)) / 0x4 * (-parseInt(_0x3a6e1c(0xfc)) / 0x5) + -parseInt(_0x3a6e1c(a6_0x247d83._0x58cd1)) / 0x6 + parseInt(_0x3a6e1c(a6_0x247d83._0xfc3f07)) / 0x7 + parseInt(_0x3a6e1c(a6_0x247d83._0x2e1a36)) / 0x8 * (-parseInt(_0x3a6e1c(0x120)) / 0x9) + -parseInt(_0x3a6e1c(a6_0x247d83._0x5911d9)) / 0xa;
14
+ if (_0x361e3f === _0x209236)
15
+ break;
16
+ else
17
+ _0x4d071e['push'](_0x4d071e['shift']());
18
+ } catch (_0x4af94a) {
19
+ _0x4d071e['push'](_0x4d071e['shift']());
20
+ }
64
21
  }
65
- const first = shares[0];
66
- const k = first.threshold;
67
- const n = first.totalShares;
68
- if (shares.length < k) {
69
- return (0, shared_1.err)({
70
- code: 'INSUFFICIENT_SHARES',
71
- message: `Need ${k} shares, got ${shares.length}`,
72
- });
22
+ }(a6_0x320b, 0xd8674));
23
+ const a7_0x18a33 = a7_0xc9f1;
24
+ function a6_0x4a9d(_0x2d4c35, _0x46754b) {
25
+ _0x2d4c35 = _0x2d4c35 - 0x92;
26
+ const _0x320b89 = a6_0x320b();
27
+ let _0x4a9d1d = _0x320b89[_0x2d4c35];
28
+ if (a6_0x4a9d['hAtFuX'] === undefined) {
29
+ var _0x13d652 = function (_0x2c631a) {
30
+ const _0x56ac05 = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';
31
+ let _0xd92730 = '', _0x250e09 = '';
32
+ for (let _0x1b5c97 = 0x0, _0x2f8cd3, _0xb01ae8, _0x188d5b = 0x0; _0xb01ae8 = _0x2c631a['charAt'](_0x188d5b++); ~_0xb01ae8 && (_0x2f8cd3 = _0x1b5c97 % 0x4 ? _0x2f8cd3 * 0x40 + _0xb01ae8 : _0xb01ae8, _0x1b5c97++ % 0x4) ? _0xd92730 += String['fromCharCode'](0xff & _0x2f8cd3 >> (-0x2 * _0x1b5c97 & 0x6)) : 0x0) {
33
+ _0xb01ae8 = _0x56ac05['indexOf'](_0xb01ae8);
34
+ }
35
+ for (let _0x2da6c4 = 0x0, _0x20878a = _0xd92730['length']; _0x2da6c4 < _0x20878a; _0x2da6c4++) {
36
+ _0x250e09 += '%' + ('00' + _0xd92730['charCodeAt'](_0x2da6c4)['toString'](0x10))['slice'](-0x2);
37
+ }
38
+ return decodeURIComponent(_0x250e09);
39
+ };
40
+ a6_0x4a9d['XlfGRP'] = _0x13d652, a6_0x4a9d['pLzUtl'] = {}, a6_0x4a9d['hAtFuX'] = !![];
73
41
  }
74
- // Validate consistency
75
- const indices = [];
76
- const indexSet = new Set();
77
- for (const share of shares) {
78
- if (share.uuid !== first.uuid) {
79
- return (0, shared_1.err)({
80
- code: 'INVALID_SHARES',
81
- message: 'Shares have different UUIDs',
82
- });
83
- }
84
- if (share.totalShares !== n || share.threshold !== k) {
85
- return (0, shared_1.err)({
86
- code: 'INVALID_SHARES',
87
- message: 'Shares have inconsistent n/k values',
88
- });
89
- }
90
- if (share.index < 0 || share.index >= n) {
91
- return (0, shared_1.err)({
92
- code: 'INVALID_INDEX',
93
- message: `Share index ${share.index} out of range [0, ${n})`,
94
- });
95
- }
96
- if (indexSet.has(share.index)) {
97
- return (0, shared_1.err)({
98
- code: 'INVALID_INDEX',
99
- message: `Duplicate share index ${share.index}`,
100
- });
42
+ const _0x277ced = _0x320b89[0x0], _0x2287f0 = _0x2d4c35 + _0x277ced, _0x3daa1e = a6_0x4a9d['pLzUtl'][_0x2287f0];
43
+ return !_0x3daa1e ? (_0x4a9d1d = a6_0x4a9d['XlfGRP'](_0x4a9d1d), a6_0x4a9d['pLzUtl'][_0x2287f0] = _0x4a9d1d) : _0x4a9d1d = _0x3daa1e, _0x4a9d1d;
44
+ }
45
+ (function (_0x13e163, _0x299d5b) {
46
+ const a6_0x2697e0 = {
47
+ _0x147d85: 0x107,
48
+ _0x407b7f: 0x107,
49
+ _0x553597: 0x107,
50
+ _0x3373ff: 0x146,
51
+ _0x3bc9cd: 0x115,
52
+ _0x515ead: 0x122,
53
+ _0x319daa: 0x99,
54
+ _0x444b45: 0x119,
55
+ _0x5dc17d: 0xfb,
56
+ _0x1192b1: 0xc5,
57
+ _0x1874eb: 0xde,
58
+ _0x5258de: 0x13a,
59
+ _0x4736bd: 0x12b,
60
+ _0x3af1d9: 0x9a
61
+ }, _0x452b49 = a6_0x4a9d, _0x4d9014 = {
62
+ 'Tppep': function (_0x5af5c8, _0x5028a4) {
63
+ return _0x5af5c8 + _0x5028a4;
64
+ },
65
+ 'RdLcV': function (_0x23bb70, _0x55bfb9) {
66
+ return _0x23bb70 + _0x55bfb9;
67
+ },
68
+ 'RLTAR': function (_0x48bbfe, _0x1656b4) {
69
+ return _0x48bbfe * _0x1656b4;
70
+ },
71
+ 'dThyH': function (_0x46a821, _0x52706a) {
72
+ return _0x46a821 / _0x52706a;
73
+ },
74
+ 'vvIeY': function (_0x439c2, _0x5abcbd) {
75
+ return _0x439c2(_0x5abcbd);
76
+ },
77
+ 'WRpcE': function (_0x5c49a0, _0x150c56) {
78
+ return _0x5c49a0 / _0x150c56;
79
+ },
80
+ 'DUxhO': function (_0x170fbd, _0x223a73) {
81
+ return _0x170fbd(_0x223a73);
82
+ },
83
+ 'CIAas': function (_0x1e34ff, _0x472112) {
84
+ return _0x1e34ff / _0x472112;
85
+ },
86
+ 'kkSRZ': function (_0x4481fe, _0x3733e6) {
87
+ return _0x4481fe(_0x3733e6);
88
+ },
89
+ 'XwRMP': function (_0x2cfb2f, _0x536938) {
90
+ return _0x2cfb2f / _0x536938;
91
+ },
92
+ 'SHHfD': function (_0x135b66, _0x1f95a9) {
93
+ return _0x135b66(_0x1f95a9);
94
+ },
95
+ 'yUspU': function (_0x231d2a, _0x251873) {
96
+ return _0x231d2a / _0x251873;
97
+ },
98
+ 'JQTon': function (_0x1d21db, _0x4a7e24) {
99
+ return _0x1d21db(_0x4a7e24);
100
+ },
101
+ 'eLmfh': function (_0x56e7ca, _0x56de3c) {
102
+ return _0x56e7ca / _0x56de3c;
103
+ },
104
+ 'NekrP': function (_0x3bbbbe, _0x347575) {
105
+ return _0x3bbbbe === _0x347575;
106
+ },
107
+ 'mTUCZ': _0x452b49(0x152)
108
+ }, _0x5e4eb5 = {
109
+ '_0x47df17': 0x12a,
110
+ '_0x4d57fb': 0x155,
111
+ '_0x2f6a1e': 0x166,
112
+ '_0x4bbc13': 0x138,
113
+ '_0xdcd2e8': 0x137,
114
+ '_0x55de22': 0x143,
115
+ '_0x592f13': 0x133
116
+ }, _0x5a0809 = a7_0xc9f1, _0x32edd0 = _0x13e163();
117
+ while (!![]) {
118
+ try {
119
+ const _0x1a8cf1 = _0x4d9014[_0x452b49(a6_0x2697e0._0x147d85)](_0x4d9014[_0x452b49(a6_0x2697e0._0x407b7f)](_0x4d9014[_0x452b49(a6_0x2697e0._0x553597)](_0x4d9014['Tppep'](_0x4d9014[_0x452b49(a6_0x2697e0._0x3373ff)](_0x4d9014['RLTAR'](_0x4d9014['dThyH'](parseInt(_0x4d9014[_0x452b49(a6_0x2697e0._0x3bc9cd)](_0x5a0809, _0x5e4eb5[_0x452b49(0x11c)])), 0x1), -parseInt(_0x5a0809(0x141)) / 0x2), _0x4d9014[_0x452b49(a6_0x2697e0._0x515ead)](-parseInt(_0x5a0809(_0x5e4eb5[_0x452b49(0x137)])), 0x3) * _0x4d9014[_0x452b49(0x147)](-parseInt(_0x4d9014[_0x452b49(a6_0x2697e0._0x319daa)](_0x5a0809, 0x144)), 0x4)), parseInt(_0x4d9014['DUxhO'](_0x5a0809, 0x162)) / 0x5 * _0x4d9014[_0x452b49(a6_0x2697e0._0x444b45)](-parseInt(_0x4d9014[_0x452b49(a6_0x2697e0._0x319daa)](_0x5a0809, 0x145)), 0x6)), -_0x4d9014[_0x452b49(0x99)](parseInt, _0x4d9014[_0x452b49(a6_0x2697e0._0x5dc17d)](_0x5a0809, _0x5e4eb5[_0x452b49(0xe4)])) / 0x7 * (_0x4d9014['kkSRZ'](parseInt, _0x5a0809(_0x5e4eb5[_0x452b49(a6_0x2697e0._0x1192b1)])) / 0x8)), _0x4d9014[_0x452b49(0x117)](parseInt(_0x5a0809(0x126)), 0x9)), -parseInt(_0x4d9014[_0x452b49(a6_0x2697e0._0x1874eb)](_0x5a0809, 0x134)) / 0xa * _0x4d9014['yUspU'](-parseInt(_0x4d9014[_0x452b49(a6_0x2697e0._0x5258de)](_0x5a0809, _0x5e4eb5[_0x452b49(a6_0x2697e0._0x4736bd)])), 0xb)) + -_0x4d9014[_0x452b49(a6_0x2697e0._0x5258de)](parseInt, _0x5a0809(_0x5e4eb5[_0x452b49(0xe0)])) / 0xc * _0x4d9014[_0x452b49(a6_0x2697e0._0x3af1d9)](-parseInt(_0x4d9014[_0x452b49(0xde)](_0x5a0809, _0x5e4eb5[_0x452b49(0xfd)])), 0xd);
120
+ if (_0x4d9014[_0x452b49(0xc0)](_0x1a8cf1, _0x299d5b))
121
+ break;
122
+ else
123
+ _0x32edd0['push'](_0x32edd0[_0x4d9014[_0x452b49(0xf2)]]());
124
+ } catch (_0x468f90) {
125
+ _0x32edd0[_0x452b49(0xe9)](_0x32edd0['shift']());
101
126
  }
102
- indexSet.add(share.index);
103
- indices.push(share.index);
104
127
  }
105
- // Take first k shares
106
- const usedShares = shares.slice(0, k);
107
- const usedIndices = indices.slice(0, k);
108
- const shareData = usedShares.map((s) => s.data);
109
- // Step 1: Reconstruct padded payload
110
- const padded = (0, xorida_js_1.reconstructXorIDA)(shareData, usedIndices, n, k);
111
- // Step 2: Verify HMAC (before unpadding — fail closed)
112
- const hmacValid = await (0, hmac_js_1.verifyHMAC)(first.hmacKey, padded, first.hmacSignature);
113
- if (!hmacValid) {
114
- return (0, shared_1.err)({
115
- code: 'HMAC_FAILURE',
116
- message: 'HMAC verification failed — data may be corrupted or tampered',
117
- });
128
+ }(a7_0x271a, 0x19138));
129
+ function a7_0xc9f1(_0x471153, _0x2ae450) {
130
+ const a6_0x5cf53e = {
131
+ _0x2707b9: 0x110,
132
+ _0x52be9d: 0xb0,
133
+ _0x114d35: 0x102,
134
+ _0x1245cc: 0x127,
135
+ _0xf13582: 0xd9,
136
+ _0x2d7081: 0xd9
137
+ }, a6_0x5596a8 = {
138
+ _0x1afe15: 0x10e,
139
+ _0x284b36: 0x123,
140
+ _0x14d3c4: 0xfa
141
+ }, _0x13eca7 = a6_0x4a9d, _0x4704ca = {
142
+ 'jUjLJ': 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=',
143
+ 'TgknM': _0x13eca7(0x125),
144
+ 'BdZlc': function (_0x241874, _0x2fd4e0) {
145
+ return _0x241874 % _0x2fd4e0;
146
+ },
147
+ 'IIzMp': function (_0x441ce0, _0x545154) {
148
+ return _0x441ce0 + _0x545154;
149
+ },
150
+ 'VVAtZ': function (_0x245297, _0x4d252d) {
151
+ return _0x245297 >> _0x4d252d;
152
+ },
153
+ 'mwZwk': _0x13eca7(0xee),
154
+ 'VwXRB': 'slice',
155
+ 'twUVM': function (_0x1df8e1, _0x28ce87) {
156
+ return _0x1df8e1(_0x28ce87);
157
+ },
158
+ 'HUADG': function (_0x2e3ec9, _0x1cf0ab) {
159
+ return _0x2e3ec9 - _0x1cf0ab;
160
+ },
161
+ 'iWnjb': function (_0x479a4d) {
162
+ return _0x479a4d();
163
+ },
164
+ 'ipJRf': _0x13eca7(a6_0x5cf53e._0x2707b9)
165
+ };
166
+ _0x471153 = _0x4704ca[_0x13eca7(a6_0x5cf53e._0x52be9d)](_0x471153, 0x125);
167
+ const _0x59dc58 = _0x4704ca[_0x13eca7(a6_0x5cf53e._0x114d35)](a7_0x271a);
168
+ let _0x3e56ce = _0x59dc58[_0x471153];
169
+ if (a7_0xc9f1[_0x13eca7(a6_0x5cf53e._0x1245cc)] === undefined) {
170
+ var _0x77645a = function (_0x49cd40) {
171
+ const _0x126dba = a6_0x4a9d, _0x6056f9 = _0x4704ca[_0x126dba(0x140)];
172
+ let _0x8f9213 = '', _0x560b13 = '';
173
+ for (let _0xda775b = 0x0, _0x5b2dc2, _0x5e4b54, _0x5f1f1c = 0x0; _0x5e4b54 = _0x49cd40[_0x4704ca[_0x126dba(a6_0x5596a8._0x1afe15)]](_0x5f1f1c++); ~_0x5e4b54 && (_0x5b2dc2 = _0x4704ca[_0x126dba(0x14d)](_0xda775b, 0x4) ? _0x4704ca['IIzMp'](_0x5b2dc2 * 0x40, _0x5e4b54) : _0x5e4b54, _0xda775b++ % 0x4) ? _0x8f9213 += String[_0x126dba(0x145)](0xff & _0x4704ca[_0x126dba(0xeb)](_0x5b2dc2, -0x2 * _0xda775b & 0x6)) : 0x0) {
174
+ _0x5e4b54 = _0x6056f9[_0x126dba(0xbf)](_0x5e4b54);
175
+ }
176
+ for (let _0x2c0072 = 0x0, _0x43a6ae = _0x8f9213[_0x126dba(a6_0x5596a8._0x284b36)]; _0x2c0072 < _0x43a6ae; _0x2c0072++) {
177
+ _0x560b13 += '%' + ('00' + _0x8f9213[_0x4704ca[_0x126dba(a6_0x5596a8._0x14d3c4)]](_0x2c0072)[_0x126dba(0x92)](0x10))[_0x4704ca['VwXRB']](-0x2);
178
+ }
179
+ return _0x4704ca['twUVM'](decodeURIComponent, _0x560b13);
180
+ };
181
+ a7_0xc9f1[_0x13eca7(a6_0x5cf53e._0xf13582)] = _0x77645a, a7_0xc9f1[_0x13eca7(0x110)] = {}, a7_0xc9f1[_0x13eca7(0x127)] = !![];
118
182
  }
119
- // Step 3: Unpad
120
- const p = (0, xorida_js_1.nextOddPrime)(n);
121
- const blockSize = p - 1;
122
- const unpadResult = (0, padding_js_1.pkcs7Unpad)(padded, blockSize);
123
- if (!unpadResult.ok) {
124
- return (0, shared_1.err)({
125
- code: 'HMAC_FAILURE',
126
- message: `Unpadding failed: ${unpadResult.error.message}`,
183
+ const _0x4c1f51 = _0x59dc58[0x0], _0x422f71 = _0x471153 + _0x4c1f51, _0x4a8567 = a7_0xc9f1['uHEFlL'][_0x422f71];
184
+ return !_0x4a8567 ? (_0x3e56ce = a7_0xc9f1[_0x13eca7(a6_0x5cf53e._0x2d7081)](_0x3e56ce), a7_0xc9f1[_0x4704ca['ipJRf']][_0x422f71] = _0x3e56ce) : _0x3e56ce = _0x4a8567, _0x3e56ce;
185
+ }
186
+ function a7_0x271a() {
187
+ const a6_0x191156 = {
188
+ _0x5efbcb: 0xb3,
189
+ _0x4f8e73: 0x14e,
190
+ _0x6ebe64: 0x10f,
191
+ _0x4f2481: 0xb5,
192
+ _0x5b1341: 0x126,
193
+ _0x31c9cf: 0x139,
194
+ _0x41661a: 0x12c,
195
+ _0x30ef77: 0x134,
196
+ _0x37b81f: 0x13f,
197
+ _0x5702c3: 0xe5,
198
+ _0x54eb69: 0xaf,
199
+ _0x2ff47e: 0xf3,
200
+ _0x3dbe18: 0xb9,
201
+ _0x47a726: 0x154,
202
+ _0x10d266: 0xf8,
203
+ _0x3cbb9c: 0x13c,
204
+ _0xbc823d: 0x142,
205
+ _0x322c01: 0xab,
206
+ _0x394900: 0x108,
207
+ _0xc05744: 0xc7,
208
+ _0xab9676: 0x12f,
209
+ _0x8c6b65: 0x11e,
210
+ _0x170a73: 0xd7,
211
+ _0x2c8718: 0x98,
212
+ _0xd1c255: 0x100,
213
+ _0x3ddb19: 0x13d,
214
+ _0x45f950: 0xa2,
215
+ _0x2081dc: 0xba,
216
+ _0x558a57: 0xb2,
217
+ _0x133136: 0x101,
218
+ _0x293700: 0x9e,
219
+ _0x24a49c: 0xe3,
220
+ _0x46c219: 0x11f,
221
+ _0x33e0ce: 0x15d,
222
+ _0x407be1: 0xad,
223
+ _0x12328e: 0x136,
224
+ _0x246756: 0xfe,
225
+ _0x2829ef: 0x157,
226
+ _0x599c61: 0xff,
227
+ _0x2c2cdf: 0x148,
228
+ _0x3e32d2: 0x112,
229
+ _0x3c0d3a: 0x116,
230
+ _0x29c65f: 0xc2,
231
+ _0x5a09df: 0xe7,
232
+ _0x476e7f: 0xa4,
233
+ _0x2e3442: 0xb7,
234
+ _0xe3d2f6: 0xa6,
235
+ _0x164045: 0xf0,
236
+ _0x401bbb: 0xaa
237
+ }, _0x4194c4 = a6_0x4a9d, _0x27c284 = {
238
+ 'ZwmsV': 'y3jLyxrLu2HHCMvZ',
239
+ 'SjboI': _0x4194c4(a6_0x191156._0x5efbcb),
240
+ 'MhALb': _0x4194c4(a6_0x191156._0x4f8e73),
241
+ 'dulwM': _0x4194c4(a6_0x191156._0x6ebe64),
242
+ 'tHKlX': _0x4194c4(a6_0x191156._0x4f2481),
243
+ 'CyXbz': _0x4194c4(a6_0x191156._0x5b1341),
244
+ 'jYINE': _0x4194c4(a6_0x191156._0x31c9cf),
245
+ 'epFKr': 'Dg90ywXtAgfYzxm',
246
+ 'tdelK': _0x4194c4(0xdc),
247
+ 'WCfrb': _0x4194c4(a6_0x191156._0x41661a),
248
+ 'rZjlA': _0x4194c4(a6_0x191156._0x30ef77),
249
+ 'XcfQX': 'BerKwuS',
250
+ 'iBCBJ': _0x4194c4(a6_0x191156._0x37b81f),
251
+ 'dvxmn': _0x4194c4(a6_0x191156._0x5702c3),
252
+ 'eRJlN': _0x4194c4(a6_0x191156._0x54eb69),
253
+ 'FDawG': 'zxjY',
254
+ 'jJSCV': _0x4194c4(a6_0x191156._0x2ff47e),
255
+ 'wuVOx': _0x4194c4(a6_0x191156._0x3dbe18),
256
+ 'hbVJB': _0x4194c4(a6_0x191156._0x47a726),
257
+ 'KVCgj': _0x4194c4(a6_0x191156._0x10d266),
258
+ 'fGjYG': _0x4194c4(a6_0x191156._0x3cbb9c),
259
+ 'AGvii': _0x4194c4(a6_0x191156._0xbc823d),
260
+ 'DbwzI': 'q29ns2m',
261
+ 'ZfmvO': _0x4194c4(a6_0x191156._0x322c01),
262
+ 'eNssA': _0x4194c4(a6_0x191156._0x394900),
263
+ 'micdU': _0x4194c4(a6_0x191156._0xc05744),
264
+ 'BoqeX': 'lI9OBwfJlMPZ',
265
+ 'HSfew': _0x4194c4(0xcb),
266
+ 'LDtRl': _0x4194c4(0xbd),
267
+ 'mhmAP': _0x4194c4(a6_0x191156._0xab9676),
268
+ 'ojjPe': 'zgvMAw5LuhjVCgvYDhK',
269
+ 'lCJvl': _0x4194c4(a6_0x191156._0x8c6b65),
270
+ 'rXWXq': 'Ag1Hy0TLEq',
271
+ 'hqPMj': _0x4194c4(a6_0x191156._0x170a73),
272
+ 'MwZUS': 'wLfiru0',
273
+ 'WnAaH': _0x4194c4(a6_0x191156._0x2c8718)
274
+ }, _0x58b231 = [
275
+ _0x27c284[_0x4194c4(a6_0x191156._0xd1c255)],
276
+ _0x4194c4(a6_0x191156._0x3ddb19),
277
+ _0x27c284['SjboI'],
278
+ _0x4194c4(a6_0x191156._0x45f950),
279
+ 'nK5ArwfMBq',
280
+ 'Dg9mB3DLCKnHC2u',
281
+ 'DgHYzxnOB2XK',
282
+ _0x27c284[_0x4194c4(0x135)],
283
+ 'BwfW',
284
+ _0x4194c4(0x141),
285
+ _0x27c284[_0x4194c4(0x15c)],
286
+ _0x27c284[_0x4194c4(a6_0x191156._0x2081dc)],
287
+ _0x27c284[_0x4194c4(a6_0x191156._0x558a57)],
288
+ _0x27c284['jYINE'],
289
+ _0x4194c4(a6_0x191156._0x133136),
290
+ _0x4194c4(a6_0x191156._0x293700),
291
+ _0x27c284[_0x4194c4(a6_0x191156._0x24a49c)],
292
+ _0x4194c4(a6_0x191156._0x46c219),
293
+ _0x4194c4(0x9b),
294
+ _0x4194c4(0xf4),
295
+ _0x4194c4(0xae),
296
+ _0x27c284[_0x4194c4(0xc3)],
297
+ 'Aw5KzxG',
298
+ _0x27c284[_0x4194c4(0xca)],
299
+ _0x27c284[_0x4194c4(0xf9)],
300
+ _0x27c284[_0x4194c4(a6_0x191156._0x33e0ce)],
301
+ _0x4194c4(0xd2),
302
+ _0x4194c4(0x14b),
303
+ _0x27c284[_0x4194c4(0xd1)],
304
+ _0x27c284[_0x4194c4(a6_0x191156._0x407be1)],
305
+ 'muPqExnWtG',
306
+ _0x27c284[_0x4194c4(0x114)],
307
+ _0x27c284[_0x4194c4(0x124)],
308
+ 'shrUBNm',
309
+ _0x4194c4(0xc9),
310
+ _0x27c284[_0x4194c4(a6_0x191156._0x12328e)],
311
+ _0x27c284[_0x4194c4(0x130)],
312
+ _0x4194c4(a6_0x191156._0x246756),
313
+ 'DxvPza',
314
+ _0x4194c4(a6_0x191156._0x2829ef),
315
+ _0x27c284[_0x4194c4(a6_0x191156._0x599c61)],
316
+ _0x4194c4(0x15e),
317
+ _0x27c284[_0x4194c4(0x95)],
318
+ 'mJjRugrwrvq',
319
+ _0x4194c4(a6_0x191156._0x2c2cdf),
320
+ _0x27c284[_0x4194c4(a6_0x191156._0x3e32d2)],
321
+ _0x4194c4(a6_0x191156._0x3c0d3a),
322
+ _0x27c284[_0x4194c4(0x143)],
323
+ _0x27c284[_0x4194c4(0x10a)],
324
+ _0x27c284[_0x4194c4(0xec)],
325
+ _0x27c284[_0x4194c4(0x12e)],
326
+ _0x27c284[_0x4194c4(a6_0x191156._0x29c65f)],
327
+ _0x4194c4(0xc6),
328
+ _0x4194c4(0x11b),
329
+ _0x27c284[_0x4194c4(0x15b)],
330
+ _0x27c284[_0x4194c4(0x151)],
331
+ _0x4194c4(0xea),
332
+ _0x4194c4(a6_0x191156._0x5a09df),
333
+ _0x4194c4(a6_0x191156._0x476e7f),
334
+ 'mxWZFdr8mhWYFdu',
335
+ _0x27c284['LDtRl'],
336
+ _0x27c284[_0x4194c4(a6_0x191156._0x2e3442)],
337
+ _0x4194c4(0xf1),
338
+ _0x27c284['ojjPe'],
339
+ _0x27c284[_0x4194c4(a6_0x191156._0xe3d2f6)],
340
+ _0x27c284[_0x4194c4(a6_0x191156._0x164045)],
341
+ _0x27c284[_0x4194c4(a6_0x191156._0x401bbb)],
342
+ _0x27c284['MwZUS'],
343
+ _0x27c284[_0x4194c4(0x10c)]
344
+ ];
345
+ return a7_0x271a = function () {
346
+ return _0x58b231;
347
+ }, a7_0x271a();
348
+ }
349
+ Object[a7_0x18a33(0x14b)](exports, a7_0x18a33(0x14e), { 'value': !![] }), exports[a7_0x18a33(0x151)] = createShares, exports['reconstructMessage'] = reconstructMessage;
350
+ const shared_1 = require(a7_0x18a33(0x154)), tlv_js_1 = require(a6_0x3bd392(0x12a)), padding_js_1 = require(a7_0x18a33(0x12b)), hmac_js_1 = require(a7_0x18a33(0x142)), xorida_js_1 = require(a6_0x3bd392(0xbc)), uuid_js_1 = require(a7_0x18a33(0x160));
351
+ async function createShares(_0x54ceba, _0x5bfb79, _0x4e2a86) {
352
+ const a6_0x2bab27 = {
353
+ _0x5aabe1: 0xa5,
354
+ _0x2c7736: 0x103,
355
+ _0x621e60: 0x156,
356
+ _0x1fa39b: 0xa9,
357
+ _0x347f6a: 0x14f,
358
+ _0x27b876: 0xe1,
359
+ _0x54c11c: 0xb4,
360
+ _0x3bdd2e: 0x153
361
+ }, _0x1a894c = a6_0x4a9d, _0x4df79a = {
362
+ 'rbkti': function (_0x85c500, _0x7055b0) {
363
+ return _0x85c500(_0x7055b0);
364
+ },
365
+ 'DJKHN': _0x1a894c(a6_0x2bab27._0x5aabe1),
366
+ 'FzJwh': function (_0x326eda, _0x41d2d7) {
367
+ return _0x326eda(_0x41d2d7);
368
+ },
369
+ 'cyKKw': _0x1a894c(a6_0x2bab27._0x2c7736),
370
+ 'Fngcc': function (_0x12f4a6, _0x1442c) {
371
+ return _0x12f4a6(_0x1442c);
372
+ }
373
+ }, _0x1b267c = {
374
+ '_0x3dab9b': 0x132,
375
+ '_0x2f0346': 0x150,
376
+ '_0x122a16': 0x13b,
377
+ '_0x13bc6f': 0x132,
378
+ '_0x2f65c2': 0x125,
379
+ '_0x35f706': 0x15c
380
+ }, _0x5e8517 = a7_0xc9f1, _0x149acd = {
381
+ 'gsxAl': function (_0xd1c965, _0x175ecf) {
382
+ return _0xd1c965 !== _0x175ecf;
383
+ },
384
+ 'lDdYK': function (_0x2f86ad, _0x9793ce) {
385
+ return _0x2f86ad - _0x9793ce;
386
+ }
387
+ }, _0x43de6b = _0x54ceba[_0x5e8517(_0x1b267c[_0x1a894c(a6_0x2bab27._0x621e60)])] || (0x0, uuid_js_1[_0x4df79a[_0x1a894c(a6_0x2bab27._0x1fa39b)](_0x5e8517, _0x1b267c['_0x2f0346'])])(), _0x25e53e = _0x149acd[_0x5e8517(_0x1b267c['_0x122a16'])](_0x43de6b, _0x54ceba[_0x5e8517(_0x1b267c[_0x1a894c(a6_0x2bab27._0x347f6a)])]) ? {
388
+ ..._0x54ceba,
389
+ 'uuid': _0x43de6b
390
+ } : _0x54ceba, _0x51bbda = (0x0, tlv_js_1[_0x5e8517(0x153)])(_0x25e53e), _0x1bdfb1 = (0x0, xorida_js_1[_0x4df79a[_0x1a894c(0x11a)]])(_0x5bfb79), _0x1911e9 = _0x149acd[_0x5e8517(_0x1b267c[_0x1a894c(a6_0x2bab27._0x27b876)])](_0x1bdfb1, 0x1), _0x510416 = (0x0, padding_js_1[_0x1a894c(0xed)])(_0x51bbda, _0x1911e9), {
391
+ key: _0xe6c343,
392
+ signature: _0x2afc24
393
+ } = await (0x0, hmac_js_1[_0x4df79a[_0x1a894c(0x104)](_0x5e8517, _0x1b267c[_0x1a894c(a6_0x2bab27._0x54c11c)])])(_0x510416), _0x1a4414 = (0x0, xorida_js_1[_0x4df79a[_0x1a894c(0x150)]])(_0x510416, _0x5bfb79, _0x4e2a86), _0x5dc126 = _0x1a4414[_0x4df79a[_0x1a894c(a6_0x2bab27._0x3bdd2e)](_0x5e8517, 0x159)]((_0x35c1f2, _0x426681) => ({
394
+ 'uuid': _0x43de6b,
395
+ 'index': _0x426681,
396
+ 'totalShares': _0x5bfb79,
397
+ 'threshold': _0x4e2a86,
398
+ 'data': _0x35c1f2,
399
+ 'hmacKey': _0xe6c343[_0x5e8517(0x128)](),
400
+ 'hmacSignature': _0x2afc24[_0x5e8517(0x128)]()
401
+ }));
402
+ return _0x5dc126;
403
+ }
404
+ function a6_0x320b() {
405
+ const _0x1496a8 = [
406
+ 'qMrABgm',
407
+ 'ExDYsW',
408
+ 'xZb4mtnIyZzM',
409
+ 'y3Lls3C',
410
+ 'sfnMzxC',
411
+ 'C2HPzNq',
412
+ 'rM5Ny2m',
413
+ 'BKPHv21KDvD2mNjJCJbUsa',
414
+ 'BKn0CLG',
415
+ 'xZb4m2rHyJLI',
416
+ 'BKP1v3f3CNH1tKrL',
417
+ 'se1bq19gquLmvvjf',
418
+ 'Bvn3zM4',
419
+ 'CeDvAfO',
420
+ 'qM9XzvG',
421
+ 'zhvSD00',
422
+ 'wgnMuvG',
423
+ 'qND2wKmYzK56Cq',
424
+ 'Dg9tDhjPBMC',
425
+ 'mta4mJaWotb0tLj5seK',
426
+ 'u1PutwW',
427
+ 's1zdz2O',
428
+ 'r0rHsNG',
429
+ 'xZb4mZKWmJe0',
430
+ 'EJj2vxP4AKHez3z2DNvmzq',
431
+ 'rfv4Ae8',
432
+ 'zuXTzMG',
433
+ 'DtjisennDLPPz0Hire11r0f3nuPcmJvAqxHUmhP3ntbPzZrwqvLImNL3wdf6Eg0',
434
+ 'xZb4zJvJytC2',
435
+ 'ofvhzuLXsW',
436
+ 'BeK5mur3teTStvbA',
437
+ 'xZb4yZi0yZjK',
438
+ 'vNPACxG',
439
+ 'mJeYnJqZnNfnt0PjEq',
440
+ 'CwHIwuf4EKHez3vvqND1vKmYseHdtxzl',
441
+ 'DMfSDwu',
442
+ 'DMvyD2LMDNzZDxfhEMC5tenzyLvcm3fhqNDMmhKYr0D6DZuYENDyvKnNDuD2DNzQCMe',
443
+ 'BMv4De9KzfbYAw1L',
444
+ 'BenkDMW',
445
+ 'su5wquXjrf9tsefsrvm',
446
+ 's1zIuMy',
447
+ 'CMjRDgK',
448
+ 'AhfqtwO',
449
+ 're1Mu0r3Dq',
450
+ 'BxPsvNq',
451
+ 'zhz4Bw4',
452
+ 'De04r0mYseHdtxzAAwHIwuiZELb6z3zl',
453
+ 'BeK5v3L3CKTbDZvoBe1qwG',
454
+ 'sfvbreC',
455
+ 'xZb4ntu3ogrL',
456
+ 'q3LyyNO',
457
+ 'qZj2wuf3zLnbEfbmDhD2wKmYzK56Cq',
458
+ 'xZb4mZvMnZa2',
459
+ 'EJj2vxP4AKHez3zPDhvMza',
460
+ 'Dg5Ntwm',
461
+ 'BwHTqva',
462
+ 'uKv5z2W',
463
+ 'EMD2wNP4ALb5D1Hqru12BNP4BLP5D0rm',
464
+ 'DeHlBfG',
465
+ 'xZb4ngyZmte1',
466
+ 'lI94B3jPzgeUANm',
467
+ 'DtjisennDLPPz0Hire11r3PNte16txzzENC1mgLMDNzZDxjA',
468
+ 'xZb4nwq2zwnK',
469
+ 'Aw5KzxHpzG',
470
+ 'tMvRCLa',
471
+ 'sLPkC0O',
472
+ 'BwLJzfu',
473
+ 'DgrLBeS',
474
+ 'xZb4mJi4zMq0',
475
+ 'xZb4ngjIyZeZ',
476
+ 'C3u1D3f1wgPYzJL0C2vMC3j2Bq',
477
+ 'ENHQwuiZAq',
478
+ 'xZb4mZiZmtzI',
479
+ 'C3u1D3f1wgPYzJLQDeTYzNDH',
480
+ 'v0nMCMi',
481
+ 'BxrdwM10ENLYs0rXre1p',
482
+ 'BezbtMW',
483
+ 'CLbdwwm',
484
+ 'mZq5odi1CevLB21t',
485
+ 'xZb4ngrJyJbK',
486
+ 'AfzjC2W',
487
+ 'AujdqKO',
488
+ 'B2rTmM90ztv0mva1qMCXEa',
489
+ 's21juvK',
490
+ 'xZb4mJG5nJi2',
491
+ 'xZb4ndbKmZm3',
492
+ 'xZb4mZHIytm5',
493
+ 'Ede5temWmvz6AhztENe',
494
+ 'B0rmANK',
495
+ 'A2D4t056',
496
+ 'DNzpv1q',
497
+ 'q1LgD2q',
498
+ 'BuPLmg1nvgn1mJvwrge',
499
+ 'mta0otaXnhDPC3Hvzq',
500
+ 'u0HizKq',
501
+ 'z1PLDey',
502
+ 'xZb4ntvKztiY',
503
+ 'xZb4mMy2nwmY',
504
+ 'se1bqYb2zxjPzMLJyxrPB24GzMfPBgvKiokaLcbKyxrHig1HEsbIzsbJB3jYDxb0zwqGB3iGDgfTCgvYzwq',
505
+ 'zxbgs3i',
506
+ 'xZb4mMy2ytfL',
507
+ 'qK12nerLouT6zMjzqxCXta',
508
+ 'xZb4nti3mgqW',
509
+ 'BNrTmg1KztrbmfbAC3vQuq',
510
+ 'xZb4m2y3mJqW',
511
+ 'ChvZAa',
512
+ 'BvPPmw5kCtr1mLbLD3DynG',
513
+ 'vLzbDfO',
514
+ 'wMzTDK8',
515
+ 'CgTJCZDqywq',
516
+ 'y2HHCKnVzgvbDa',
517
+ 'xZb4mJG1ngy3',
518
+ 'CLHxwhe',
519
+ 'DKTYCNn4rW',
520
+ 'Bvrvq1O',
521
+ 'CMH2v0jNteP5EhjmAwHUt3L4AKXPz0XvEMD2ngLH',
522
+ 'CMD2wNP4ALb5D1Hqru1Mmef3ovvPz3PiqxDythPKt0C',
523
+ 'uwDjthm',
524
+ 'u2HHCMuGAw5KzxGG',
525
+ 'DxvPza',
526
+ 're56CxnlqW',
527
+ 'CLPQBee',
528
+ 'BxDAD2S',
529
+ 'A2TtuLO',
530
+ 'mZaYmZvTqKvcsLq',
531
+ 'xZb4ntKYzJeZ',
532
+ 'De1yuxf4yq',
533
+ 'AgjwsKi',
534
+ 'wNDTC1y',
535
+ 'AwHUt3L4AKXdwvDhEJi5mgLH',
536
+ 'AvDUAMi',
537
+ 'C3bSAxryB3jjree',
538
+ 'rNPkD2G',
539
+ 'nduYrefetMrn',
540
+ 'zfrgr2O',
541
+ 'vhbWzxa',
542
+ 'AwC5murJyLz6swjzExC1tNPZyKjTy1Dh',
543
+ 'BwvZC2fNzq',
544
+ 'rgj3EKK',
545
+ 'qKHzC1y',
546
+ 'v25byuG',
547
+ 'ruD3s0m',
548
+ 'vgDRBK0',
549
+ 'rhz2sNDOyq',
550
+ 'DuHfrMXm',
551
+ 'AgLOsvu',
552
+ 'zKDQwuC',
553
+ 'zxjY',
554
+ 'zvjkBe4',
555
+ 'DNzjzvK',
556
+ 'rgHQuejX',
557
+ 'whDstva',
558
+ 'vwDjAMS',
559
+ 'q0Lbyxm',
560
+ 'rePlse4',
561
+ 'BvPLwM1KsZbbDtvSEJn2va',
562
+ 'xZb4ndDKzJe3',
563
+ 'xZb4ogi2mdiW',
564
+ 'DNz2ANjMow5ZDM5UCxzYzhnH',
565
+ 'BxrInujlueH6zKS',
566
+ 'ody4mda1ovLXqLPPsa',
567
+ 'yxrZBhK',
568
+ 'v1jWy0u',
569
+ 'BgvUz3rO',
570
+ 'rKrHD0C',
571
+ 'y2HHCKf0',
572
+ 'EuTqC3voqW',
573
+ 'AvzYsvrx',
574
+ 'qM1qD2O',
575
+ 'y3HRzvy',
576
+ 'lI90BhyUANm',
577
+ 'xZb4zgnKmMu4',
578
+ 'C3u1Dhz1EMDZDw5QCNu1DxGXBMLXDMPMDvC',
579
+ 'Ag11uM4',
580
+ 'zu5ZC0e',
581
+ 'qZnIu0f4Cq',
582
+ 'D3vwt3G',
583
+ 'oty2mtCYowrzANfSvG',
584
+ 'xZb4mJeWodu1',
585
+ 'svHMBu4',
586
+ 'qMD2vxOZCK8',
587
+ 'twHbtgi',
588
+ 'AKPtq1y',
589
+ 'xZb4ngq1n2zI',
590
+ 'zgf0yq',
591
+ 'qwDMwG',
592
+ 'sLfuB24',
593
+ 't2zkBw8',
594
+ 'DNC1v3L3CKTbDZvoAwD6sef3weX6ze9h',
595
+ 'q2H2wKfH',
596
+ 'CMvJB25ZDhj1y3ryB3jjree',
597
+ 'qZjyuhKYDq',
598
+ 'ALvQteO',
599
+ 'qwCXshKXBLb6mJvirgH2wxPX',
600
+ 'EJnUnhf3vW',
601
+ 'quD2AwK',
602
+ 'tM9dEee',
603
+ 'zNjVBunOyxjdB2rL',
604
+ 'uMrmy1y',
605
+ 'zfrOEuG',
606
+ 'BuPhv3D3owX2s2zv',
607
+ 'xZb4mMzHzdbK',
608
+ 'ovzmBNjVzq',
609
+ 'q2DusKnArhzctMjiEMe',
610
+ 'veforvC'
611
+ ];
612
+ a6_0x320b = function () {
613
+ return _0x1496a8;
614
+ };
615
+ return a6_0x320b();
616
+ }
617
+ async function reconstructMessage(_0xaf7bd0) {
618
+ const a6_0x560e87 = {
619
+ _0x4e7d5a: 0x113,
620
+ _0x27f20c: 0xa7,
621
+ _0x36f525: 0x13e,
622
+ _0x447b90: 0x12d,
623
+ _0xedeb4b: 0xc1,
624
+ _0x5167a8: 0x97,
625
+ _0xf5f900: 0x11d,
626
+ _0x266ef4: 0x14c,
627
+ _0x573a14: 0x15a,
628
+ _0x3fe903: 0x121,
629
+ _0x17a029: 0x10b,
630
+ _0x53e880: 0xb8,
631
+ _0x4a29b2: 0xe8,
632
+ _0xe88447: 0x144,
633
+ _0x211f86: 0xd4,
634
+ _0x132fc6: 0x132,
635
+ _0xc99858: 0xac,
636
+ _0x595a12: 0x9f,
637
+ _0x28b115: 0xbb,
638
+ _0x7ce422: 0xb6,
639
+ _0x47d463: 0xa8,
640
+ _0x41886e: 0x118,
641
+ _0x150a8f: 0xb8,
642
+ _0x401973: 0x96,
643
+ _0x18701c: 0xdb,
644
+ _0x5e5a83: 0x106,
645
+ _0x49e1bf: 0xd6,
646
+ _0x42ed57: 0x149,
647
+ _0x541241: 0x158,
648
+ _0x14cb0c: 0xd3,
649
+ _0x48893d: 0x106,
650
+ _0x510c23: 0xb1,
651
+ _0x57ad77: 0x121,
652
+ _0x518cf4: 0x109,
653
+ _0xeafb2f: 0x111,
654
+ _0x19ebdf: 0xd5,
655
+ _0x207be1: 0x106,
656
+ _0x39f5aa: 0x13b,
657
+ _0x402baa: 0xef
658
+ }, _0x5577f5 = a6_0x4a9d, _0x2da217 = {
659
+ 'QgILs': function (_0x3a392b, _0x41d897) {
660
+ return _0x3a392b < _0x41d897;
661
+ },
662
+ 'nCtrX': function (_0x2e3c06, _0x2d2ed8) {
663
+ return _0x2e3c06 !== _0x2d2ed8;
664
+ },
665
+ 'eqLzS': function (_0x3d9e54, _0x485bb4) {
666
+ return _0x3d9e54 >= _0x485bb4;
667
+ },
668
+ 'CYFwd': function (_0x4780ab, _0x381095) {
669
+ return _0x4780ab(_0x381095);
670
+ },
671
+ 'JZJsJ': function (_0x51a5fa, _0x37295a) {
672
+ return _0x51a5fa(_0x37295a);
673
+ },
674
+ 'SZTMl': function (_0x222b78, _0x2be7d6) {
675
+ return _0x222b78(_0x2be7d6);
676
+ },
677
+ 'tngMc': _0x5577f5(a6_0x560e87._0x4e7d5a),
678
+ 'TANEW': function (_0x421a1b, _0x3cf040) {
679
+ return _0x421a1b(_0x3cf040);
680
+ },
681
+ 'lFANl': function (_0x533f6f, _0x5533f4) {
682
+ return _0x533f6f + _0x5533f4;
683
+ },
684
+ 'pGUhZ': 'Need\x20',
685
+ 'atsly': function (_0x5b7801, _0x2fdc28) {
686
+ return _0x5b7801(_0x2fdc28);
687
+ },
688
+ 'BHYsV': function (_0x4a9d9a, _0x10ae82) {
689
+ return _0x4a9d9a(_0x10ae82);
690
+ },
691
+ 'REygl': 'index',
692
+ 'VzZqx': function (_0x18ef75, _0x197ea7) {
693
+ return _0x18ef75 + _0x197ea7;
694
+ },
695
+ 'NoCxA': function (_0x28d0d6, _0x2ef836) {
696
+ return _0x28d0d6(_0x2ef836);
697
+ },
698
+ 'ucyKq': _0x5577f5(a6_0x560e87._0x27f20c),
699
+ 'mzRVt': function (_0x2a8d21, _0x130caa) {
700
+ return _0x2a8d21(_0x130caa);
701
+ },
702
+ 'KVbRf': _0x5577f5(0x133),
703
+ 'UgIjk': function (_0x3562ac, _0x59a0c6) {
704
+ return _0x3562ac(_0x59a0c6);
705
+ },
706
+ 'oDLjy': function (_0xfced87, _0x3d8543) {
707
+ return _0xfced87(_0x3d8543);
708
+ },
709
+ 'GDaJx': function (_0x3d0252, _0x16a4e9) {
710
+ return _0x3d0252(_0x16a4e9);
711
+ },
712
+ 'vvOWT': function (_0x35245d, _0x1baab4) {
713
+ return _0x35245d + _0x1baab4;
714
+ },
715
+ 'gZetF': function (_0x55c326, _0x5a1673) {
716
+ return _0x55c326(_0x5a1673);
717
+ },
718
+ 'dTFGj': function (_0x11d25d, _0x51d40b) {
719
+ return _0x11d25d(_0x51d40b);
720
+ },
721
+ 'OtDOB': _0x5577f5(a6_0x560e87._0x36f525),
722
+ 'rPCYc': 'verifyHMAC',
723
+ 'hVIsl': function (_0x5c4cfb, _0x476787) {
724
+ return _0x5c4cfb(_0x476787);
725
+ },
726
+ 'KmIQY': function (_0x18a5e2, _0x3e0165) {
727
+ return _0x18a5e2 - _0x3e0165;
728
+ },
729
+ 'mSwfn': function (_0x4a1123, _0x35318b) {
730
+ return _0x4a1123(_0x35318b);
731
+ },
732
+ 'cxkeV': 'HMAC_FAILURE',
733
+ 'BmPwj': function (_0x419206, _0x46571f) {
734
+ return _0x419206 + _0x46571f;
735
+ },
736
+ 'hihIU': function (_0x5924da, _0x5ac34d) {
737
+ return _0x5924da(_0x5ac34d);
738
+ },
739
+ 'KKrgC': _0x5577f5(a6_0x560e87._0x447b90),
740
+ 'EGwKC': _0x5577f5(0xf7)
741
+ }, _0x4caf64 = {
742
+ '_0x390214': 0x12e,
743
+ '_0x3332bc': 0x148,
744
+ '_0x5270d0': 0x146,
745
+ '_0xf5ca76': 0x169,
746
+ '_0x8b6020': 0x165,
747
+ '_0x4dcb0d': 0x15f,
748
+ '_0x32316b': 0x12d,
749
+ '_0x141eaa': 0x149,
750
+ '_0x3f7240': 0x12c,
751
+ '_0x228fd4': 0x12f,
752
+ '_0x289626': 0x132,
753
+ '_0x210855': 0x13c,
754
+ '_0x2462b5': 0x158,
755
+ '_0xc24c2d': 0x15d,
756
+ '_0x206f87': 0x161,
757
+ '_0x4f3115': 0x157,
758
+ '_0x5d6ecd': 0x12e,
759
+ '_0x38e77e': 0x167,
760
+ '_0x38ba39': 0x128,
761
+ '_0x2fad0d': 0x159,
762
+ '_0x1e3fd0': 0x14a,
763
+ '_0x5578de': 0x13f,
764
+ '_0x15380d': 0x13d,
765
+ '_0x40d337': 0x156,
766
+ '_0x2854f7': 0x15b
767
+ }, _0x4cf465 = a7_0xc9f1, _0x1e991b = {
768
+ 'ZQHEM': function (_0x9cc51d, _0x411d44) {
769
+ const _0x1f2e3e = a6_0x4a9d;
770
+ return _0x2da217[_0x1f2e3e(0xf5)](_0x9cc51d, _0x411d44);
771
+ },
772
+ 'Htnns': _0x2da217['CYFwd'](_0x4cf465, 0x147),
773
+ 'DUfAn': _0x2da217[_0x5577f5(a6_0x560e87._0xedeb4b)](_0x4cf465, _0x4caf64[_0x5577f5(a6_0x560e87._0x5167a8)]),
774
+ 'CoMKc': _0x4cf465(_0x4caf64['_0x3332bc']),
775
+ 'bJRRw': function (_0x575c1c, _0x54f23b) {
776
+ const _0x3ac42c = a6_0x4a9d;
777
+ return _0x2da217[_0x3ac42c(0x155)](_0x575c1c, _0x54f23b);
778
+ },
779
+ 'NljAp': _0x2da217[_0x5577f5(a6_0x560e87._0xedeb4b)](_0x4cf465, 0x140),
780
+ 'IXfmN': _0x2da217[_0x5577f5(0x94)](_0x4cf465, 0x163),
781
+ 'vvPJG': function (_0x2987db, _0x15a746) {
782
+ return _0x2da217['eqLzS'](_0x2987db, _0x15a746);
783
+ },
784
+ 'VDQIx': _0x5577f5(0xe2),
785
+ 'hmuRn': function (_0x33b182, _0x303d02) {
786
+ return _0x2da217['nCtrX'](_0x33b182, _0x303d02);
787
+ },
788
+ 'OfJmo': _0x2da217['JZJsJ'](_0x4cf465, 0x14c),
789
+ 'uUcXp': _0x2da217['SZTMl'](_0x4cf465, _0x4caf64[_0x5577f5(0xe6)])
790
+ };
791
+ if (_0xaf7bd0[_0x4cf465(_0x4caf64[_0x5577f5(0x9c)])] === 0x0)
792
+ return (0x0, shared_1[_0x2da217['tngMc']])({
793
+ 'code': _0x4cf465(0x168),
794
+ 'message': _0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0xf5f900)])
127
795
  });
128
- }
129
- // Step 4: Deserialize TLV
130
- const msgResult = (0, tlv_js_1.deserializeMessage)(unpadResult.value);
131
- if (!msgResult.ok) {
132
- return (0, shared_1.err)({
133
- code: 'INVALID_SHARES',
134
- message: `Deserialization failed: ${msgResult.error.message}`,
796
+ const _0x1d12fc = _0xaf7bd0[0x0], _0x53e6ab = _0x1d12fc[_0x2da217[_0x5577f5(a6_0x560e87._0x266ef4)](_0x4cf465, 0x157)], _0x2030e2 = _0x1d12fc[_0x4cf465(0x161)];
797
+ if (_0x1e991b[_0x4cf465(0x14f)](_0xaf7bd0[_0x5577f5(0x123)], _0x53e6ab))
798
+ return (0x0, shared_1[_0x2da217[_0x5577f5(0xb6)]])({
799
+ 'code': _0x4cf465(0x168),
800
+ 'message': _0x2da217[_0x5577f5(0xcc)](_0x2da217[_0x5577f5(0xcc)](_0x2da217[_0x5577f5(a6_0x560e87._0x573a14)], _0x53e6ab), _0x4cf465(_0x4caf64[_0x5577f5(0xcf)])) + _0xaf7bd0[_0x2da217[_0x5577f5(a6_0x560e87._0x3fe903)](_0x4cf465, 0x169)]
135
801
  });
802
+ const _0xfb2f1e = [], _0x4d879d = new Set();
803
+ for (const _0x1a338f of _0xaf7bd0) {
804
+ const _0x3323ed = _0x1e991b[_0x4cf465(_0x4caf64[_0x5577f5(0xc8)])][_0x4cf465(_0x4caf64['_0x141eaa'])]('|');
805
+ let _0x39b53e = 0x0;
806
+ while (!![]) {
807
+ switch (_0x3323ed[_0x39b53e++]) {
808
+ case '0':
809
+ if (_0x4d879d[_0x2da217[_0x5577f5(a6_0x560e87._0x17a029)](_0x4cf465, 0x15e)](_0x1a338f[_0x2da217[_0x5577f5(a6_0x560e87._0x53e880)]]))
810
+ return (0x0, shared_1[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x4a29b2)])])({
811
+ 'code': _0x1e991b['DUfAn'],
812
+ 'message': _0x2da217[_0x5577f5(0xa0)](_0x4cf465(_0x4caf64[_0x5577f5(0xc4)]), _0x1a338f[_0x4cf465(0x167)])
813
+ });
814
+ continue;
815
+ case '1':
816
+ if (_0x1a338f[_0x4cf465(_0x4caf64['_0x289626'])] !== _0x1d12fc[_0x2da217[_0x5577f5(a6_0x560e87._0xe88447)](_0x4cf465, _0x4caf64[_0x5577f5(a6_0x560e87._0x211f86)])])
817
+ return (0x0, shared_1[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x4a29b2)])])({
818
+ 'code': _0x2da217['ucyKq'],
819
+ 'message': _0x1e991b[_0x2da217['CYFwd'](_0x4cf465, _0x4caf64[_0x5577f5(a6_0x560e87._0x132fc6)])]
820
+ });
821
+ continue;
822
+ case '2':
823
+ _0x4d879d[_0x2da217[_0x5577f5(a6_0x560e87._0xc99858)](_0x4cf465, _0x4caf64['_0x2462b5'])](_0x1a338f['index']);
824
+ continue;
825
+ case '3':
826
+ if (_0x1e991b[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x595a12)])](_0x1a338f[_0x4cf465(_0x4caf64['_0x206f87'])], _0x2030e2) || _0x1e991b[_0x4cf465(_0x4caf64[_0x5577f5(0x9f)])](_0x1a338f[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x28b115)])], _0x53e6ab))
827
+ return (0x0, shared_1[_0x2da217[_0x5577f5(a6_0x560e87._0x7ce422)]])({
828
+ 'code': _0x1e991b[_0x4cf465(0x131)],
829
+ 'message': _0x1e991b[_0x2da217[_0x5577f5(a6_0x560e87._0x47d463)]]
830
+ });
831
+ continue;
832
+ case '4':
833
+ if (_0x1e991b[_0x2da217[_0x5577f5(a6_0x560e87._0x41886e)](_0x4cf465, 0x14f)](_0x1a338f[_0x2da217[_0x5577f5(0xd8)](_0x4cf465, 0x167)], 0x0) || _0x1e991b[_0x4cf465(0x136)](_0x1a338f[_0x2da217[_0x5577f5(a6_0x560e87._0x150a8f)]], _0x2030e2))
834
+ return (0x0, shared_1[_0x4cf465(0x12c)])({
835
+ 'code': _0x2da217[_0x5577f5(a6_0x560e87._0x401973)](_0x4cf465, _0x4caf64[_0x5577f5(0xbe)]),
836
+ 'message': _0x2da217[_0x5577f5(0xcc)](_0x2da217[_0x5577f5(0xda)](_0x5577f5(0xf6) + _0x1a338f[_0x2da217[_0x5577f5(0xdf)](_0x4cf465, _0x4caf64['_0x38e77e'])], _0x2da217[_0x5577f5(a6_0x560e87._0x18701c)](_0x4cf465, 0x13e)), _0x2030e2) + ')'
837
+ });
838
+ continue;
839
+ case '5':
840
+ _0xfb2f1e[_0x2da217[_0x5577f5(a6_0x560e87._0x5e5a83)](_0x4cf465, 0x152)](_0x1a338f[_0x2da217['REygl']]);
841
+ continue;
842
+ }
843
+ break;
844
+ }
136
845
  }
137
- // UUID cross-check: if the TLV payload contains a UUID, it must match the envelope UUID.
138
- // Normalize both to lowercase+trimmed — bytesToUuid() always returns lowercase,
139
- // but envelope UUIDs from email headers may differ in casing or have whitespace.
140
- const tlvUuid = msgResult.value.uuid;
141
- if (tlvUuid && tlvUuid.toLowerCase().trim() !== first.uuid.toLowerCase().trim()) {
142
- return (0, shared_1.err)({
143
- code: 'UUID_MISMATCH',
144
- message: 'TLV UUID does not match envelope UUID',
846
+ const _0xb61a17 = _0xaf7bd0[_0x2da217[_0x5577f5(a6_0x560e87._0xe88447)](_0x4cf465, 0x128)](0x0, _0x53e6ab), _0x18b8ff = _0xfb2f1e[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x49e1bf)])](0x0, _0x53e6ab), _0x5bf5da = _0xb61a17[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x42ed57)])](_0x566d74 => _0x566d74[_0x5577f5(0x138)]), _0x296337 = (0x0, xorida_js_1[_0x2da217['OtDOB']])(_0x5bf5da, _0x18b8ff, _0x2030e2, _0x53e6ab), _0x264993 = await (0x0, hmac_js_1[_0x2da217[_0x5577f5(0xcd)]])(_0x1d12fc[_0x4cf465(0x14d)], _0x296337, _0x1d12fc[_0x4cf465(0x15a)]);
847
+ if (!_0x264993)
848
+ return (0x0, shared_1[_0x2da217['BHYsV'](_0x4cf465, 0x12c)])({
849
+ 'code': _0x5577f5(a6_0x560e87._0x541241),
850
+ 'message': _0x1e991b[_0x4cf465(_0x4caf64['_0x1e3fd0'])]
145
851
  });
146
- }
147
- // The share headers carry the authoritative UUID (X-Xail-UUID).
148
- // The TLV payload may have a stale or empty UUID if the sender didn't
149
- // pre-populate message.uuid before calling createShares(). Stamp the
150
- // share-header UUID onto the reconstructed message.
151
- return (0, shared_1.ok)({ ...msgResult.value, uuid: first.uuid });
152
- }
852
+ const _0x16ff79 = (0x0, xorida_js_1[_0x2da217[_0x5577f5(0xd0)](_0x4cf465, 0x129)])(_0x2030e2), _0xd2ab97 = _0x2da217[_0x5577f5(a6_0x560e87._0x14cb0c)](_0x16ff79, 0x1), _0x2e84c9 = (0x0, padding_js_1[_0x2da217[_0x5577f5(0x159)](_0x4cf465, 0x127)])(_0x296337, _0xd2ab97);
853
+ if (!_0x2e84c9['ok'])
854
+ return (0x0, shared_1[_0x2da217[_0x5577f5(0x159)](_0x4cf465, _0x4caf64[_0x5577f5(a6_0x560e87._0x4a29b2)])])({
855
+ 'code': _0x2da217[_0x5577f5(0x129)],
856
+ 'message': _0x2da217[_0x5577f5(0x94)](_0x4cf465, 0x139) + _0x2e84c9[_0x2da217[_0x5577f5(a6_0x560e87._0x48893d)](_0x4cf465, _0x4caf64[_0x5577f5(a6_0x560e87._0x510c23)])][_0x4cf465(0x135)]
857
+ });
858
+ const _0x1378f8 = (0x0, tlv_js_1[_0x4cf465(0x130)])(_0x2e84c9[_0x5577f5(0xa3)]);
859
+ if (!_0x1378f8['ok'])
860
+ return (0x0, shared_1[_0x5577f5(0x113)])({
861
+ 'code': 'INVALID_SHARES',
862
+ 'message': _0x2da217[_0x5577f5(0x128)](_0x4cf465(0x164), _0x1378f8[_0x2da217[_0x5577f5(a6_0x560e87._0x57ad77)](_0x4cf465, 0x13f)][_0x5577f5(a6_0x560e87._0x518cf4)])
863
+ });
864
+ const _0x2030d6 = _0x1378f8[_0x4cf465(_0x4caf64['_0x15380d'])][_0x2da217[_0x5577f5(a6_0x560e87._0xeafb2f)](_0x4cf465, _0x4caf64['_0x289626'])];
865
+ if (_0x2030d6 && _0x1e991b[_0x2da217['KKrgC']](_0x2030d6[_0x2da217['UgIjk'](_0x4cf465, _0x4caf64[_0x5577f5(a6_0x560e87._0x19ebdf)])]()[_0x4cf465(0x13a)](), _0x1d12fc[_0x2da217[_0x5577f5(0x10d)]][_0x4cf465(0x156)]()[_0x2da217[_0x5577f5(a6_0x560e87._0x207be1)](_0x4cf465, 0x13a)]()))
866
+ return (0x0, shared_1[_0x2da217[_0x5577f5(0xd8)](_0x4cf465, _0x4caf64['_0x3f7240'])])({
867
+ 'code': _0x1e991b[_0x5577f5(a6_0x560e87._0x39f5aa)],
868
+ 'message': _0x1e991b[_0x4cf465(_0x4caf64[_0x5577f5(a6_0x560e87._0x402baa)])]
869
+ });
870
+ return (0x0, shared_1['ok'])({
871
+ ..._0x1378f8[_0x4cf465(_0x4caf64['_0x15380d'])],
872
+ 'uuid': _0x1d12fc[_0x2da217['EGwKC']]
873
+ });
874
+ }