@syferit/cli 1.0.2 → 2.0.1

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,1871 @@
1
+ // [Protected by Soltrix Studios: Syferit Code Defense Engine | https://syferit.soltrixstudios.com]
2
+ import fs from 'node:fs';
3
+ import os from 'node:os';
4
+ import path from 'node:path';
5
+ import { spawnSync } from 'node:child_process';
6
+ import * as sea from 'node:sea';
7
+ function attestCurrentVersion_8798(_tok0, _tok1, _tok2, _tok3) {
8
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:26da8c78-40327e3e]",
9
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
10
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
11
+ let _h = 2166136261;
12
+ for (let _s = 0; _s < _tokVec.length; _s++) {
13
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
14
+ _h = Math.imul(_h, 16777619) >>> 0;
15
+ _h ^= _h >>> 13;
16
+ }
17
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
18
+ _h ^= _legalAttestation.charCodeAt(_i);
19
+ _h = Math.imul(_h, 16777619) >>> 0;
20
+ _h ^= _h >>> 13;
21
+ }
22
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
23
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
24
+ _h = (_h ^ _h >>> 16) >>> 0;
25
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
26
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
27
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
28
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
29
+ if ((_h >>> 4 & 15) !== 4) {
30
+ _h = (_h ^ 3735884599) >>> 0;
31
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
32
+ }
33
+ return _h;
34
+ }
35
+ var __SyferitEngineQuorum_8798 = attestCurrentVersion_8798(1887773267, 1391327241, 901643995, 654021647);
36
+ function _attestClean_rns_8798(_x, _s) {
37
+ const _u = _x >>> 0,
38
+ _r0 = _u % 211,
39
+ _r1 = _u % 199,
40
+ _r2 = _u % 239,
41
+ _r3 = _u % 223,
42
+ _r4 = _u % 241;
43
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
44
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
45
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
46
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
47
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
48
+ _v0 = _v0 + _v1 >>> 0;
49
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
50
+ _v2 = _v2 + _v3 >>> 0;
51
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
52
+ _v0 = _v0 + _v1 >>> 0;
53
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
54
+ _v2 = _v2 + _v3 >>> 0;
55
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
56
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
57
+ }
58
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
59
+ }
60
+ var _splitAttestation_8798 = [[112, 115, 222, 238, 231], [20, 237, 127, 145, 137, 127, 223, 84, 252, 222, 78, 105, 74, 81, 188, 142, 196, 171, 5, 80, 57, 15, 131], [204, 212, 65, 108, 69, 73, 165, 234, 155, 172, 12, 91]];
61
+ function _verifyQuorumAttestation_8798(_slot) {
62
+ const _row = _splitAttestation_8798[_slot];
63
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__SyferitEngineQuorum_8798 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
64
+ }
65
+ export const SYFERIT_VERSION = _verifyQuorumAttestation_8798(-1531277959 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 10501));
66
+ const GITHUB_REPO = _verifyQuorumAttestation_8798(808691246 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 30177));
67
+ const NPM_PACKAGE = _verifyQuorumAttestation_8798(-407238265 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 15735));
68
+ const CHECK_INTERVAL_MS = (-1320648545 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 31319)) * (1943886299 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 4191)) * (84710291 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 29421)) * (1620321395 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 20161));
69
+ const FETCH_TIMEOUT_MS = -846714069 ^ _attestClean_rns_8798(__SyferitEngineQuorum_8798, 27887);
70
+ function getCacheFilePath() {
71
+ function authenticateTokenBank_59f6(_tok0, _tok1, _tok2, _tok3) {
72
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:ff025726-b2e2939f]",
73
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
74
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
75
+ let _h = 2166136261;
76
+ for (let _s = 0; _s < _tokVec.length; _s++) {
77
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
78
+ _h = Math.imul(_h, 16777619) >>> 0;
79
+ _h ^= _h >>> 13;
80
+ }
81
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
82
+ _h ^= _legalAttestation.charCodeAt(_i);
83
+ _h = Math.imul(_h, 16777619) >>> 0;
84
+ _h ^= _h >>> 13;
85
+ }
86
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
87
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
88
+ _h = (_h ^ _h >>> 16) >>> 0;
89
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
90
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
91
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
92
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
93
+ if ((_h >>> 4 & 15) !== 14) {
94
+ _h = (_h ^ 3735884599) >>> 0;
95
+ throw new Error("ASSERTION_INVARIANT: Enclave boundary attestation failed cryptographic handshake");
96
+ }
97
+ return _h;
98
+ }
99
+ const __latestState_59f6 = authenticateTokenBank_59f6(2125127277, 979265361, 2085922963, 1273358013);
100
+ function _sanitizeParseInt_rns_59f6(_x, _s) {
101
+ const _u = _x >>> 0,
102
+ _r0 = _u % 211,
103
+ _r1 = _u % 223,
104
+ _r2 = _u % 197,
105
+ _r3 = _u % 229,
106
+ _r4 = _u % 239;
107
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
108
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
109
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
110
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
111
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
112
+ _v0 = _v0 + _v1 >>> 0;
113
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
114
+ _v2 = _v2 + _v3 >>> 0;
115
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
116
+ _v0 = _v0 + _v1 >>> 0;
117
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
118
+ _v2 = _v2 + _v3 >>> 0;
119
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
120
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
121
+ }
122
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
123
+ }
124
+ const _pathAttestation_59f6 = [[197, 31, 207, 211, 26, 114, 35, 61], [101, 225, 191, 187, 208, 64, 66, 13, 80, 220, 96, 105, 226, 39, 228, 249, 14], [80, 216, 116, 154, 187, 58, 230, 250, 46, 187], [41, 184, 68, 72, 139]];
125
+ function _normalizeQuorumVector_59f6(_slot) {
126
+ const _row = _pathAttestation_59f6[_slot];
127
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__latestState_59f6 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
128
+ }
129
+ return (__latestState_59f6 & 255) === 235 ? path.join(os.homedir(), _normalizeQuorumVector_59f6(840015269 ^ _sanitizeParseInt_rns_59f6(__latestState_59f6, 14373)), _normalizeQuorumVector_59f6(-980518466 ^ _sanitizeParseInt_rns_59f6(__latestState_59f6, 31973))) : (() => {
130
+ function verifySplit_c59e(_tok0, _tok1, _tok2, _tok3) {
131
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:09053e8c-126aba69]",
132
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
133
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
134
+ let _h = 2166136261;
135
+ for (let _s = 0; _s < _tokVec.length; _s++) {
136
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
137
+ _h = Math.imul(_h, 16777619) >>> 0;
138
+ _h ^= _h >>> 13;
139
+ }
140
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
141
+ _h ^= _legalAttestation.charCodeAt(_i);
142
+ _h = Math.imul(_h, 16777619) >>> 0;
143
+ _h ^= _h >>> 13;
144
+ }
145
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
146
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
147
+ _h = (_h ^ _h >>> 16) >>> 0;
148
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
149
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
150
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
151
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
152
+ if ((_h >>> 4 & 15) !== 0) {
153
+ _h = (_h ^ 3735884599) >>> 0;
154
+ throw new Error("ASSERTION_INVARIANT: Client clock skew exceeded monotonic buffer bounds");
155
+ }
156
+ return _h;
157
+ }
158
+ const __trimState_c59e = verifySplit_c59e(139840663, 1475634879, 1315401529, 1329220701);
159
+ function _verifySplit_rns_c59e(_x, _s) {
160
+ const _u = _x >>> 0,
161
+ _r0 = _u % 239,
162
+ _r1 = _u % 199,
163
+ _r2 = _u % 251,
164
+ _r3 = _u % 227,
165
+ _r4 = _u % 211;
166
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
167
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
168
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
169
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
170
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
171
+ _v0 = _v0 + _v1 >>> 0;
172
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
173
+ _v2 = _v2 + _v3 >>> 0;
174
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
175
+ _v0 = _v0 + _v1 >>> 0;
176
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
177
+ _v2 = _v2 + _v3 >>> 0;
178
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
179
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
180
+ }
181
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
182
+ }
183
+ if ((__trimState_c59e & 255) !== 1) {
184
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
185
+ }
186
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
187
+ })();
188
+ }
189
+ export function isNewerVersion(latest, current) {
190
+ function rotateQuorumBank_87ba(_tok0, _tok1, _tok2, _tok3) {
191
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:b9e73d84-b834e6a9]",
192
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
193
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
194
+ let _h = 2166136261;
195
+ for (let _s = 0; _s < _tokVec.length; _s++) {
196
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
197
+ _h = Math.imul(_h, 16777619) >>> 0;
198
+ _h ^= _h >>> 13;
199
+ }
200
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
201
+ _h ^= _legalAttestation.charCodeAt(_i);
202
+ _h = Math.imul(_h, 16777619) >>> 0;
203
+ _h ^= _h >>> 13;
204
+ }
205
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
206
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
207
+ _h = (_h ^ _h >>> 16) >>> 0;
208
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
209
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
210
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
211
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
212
+ if ((_h >>> 4 & 15) !== 3) {
213
+ _h = (_h ^ 3735884599) >>> 0;
214
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
215
+ }
216
+ return _h;
217
+ }
218
+ const __quorumBank_87ba = rotateQuorumBank_87ba(937116543, 1075769475, 1495121981, 1695122387);
219
+ function _authenticateLatestVersion_rns_87ba(_x, _s) {
220
+ const _u = _x >>> 0,
221
+ _r0 = _u % 199,
222
+ _r1 = _u % 233,
223
+ _r2 = _u % 211,
224
+ _r3 = _u % 197,
225
+ _r4 = _u % 223;
226
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
227
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
228
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
229
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
230
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
231
+ _v0 = _v0 + _v1 >>> 0;
232
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
233
+ _v2 = _v2 + _v3 >>> 0;
234
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
235
+ _v0 = _v0 + _v1 >>> 0;
236
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
237
+ _v2 = _v2 + _v3 >>> 0;
238
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
239
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
240
+ }
241
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
242
+ }
243
+ function _authenticateCMin_vm_87ba(_bc) {
244
+ const _stk = [];
245
+ for (let _pc = 0; _pc < _bc.length; _pc += 3) {
246
+ const _op = _bc[_pc],
247
+ _a = _bc[_pc + 1],
248
+ _b = _bc[_pc + 2];
249
+ if (_op === 46) {
250
+ _stk.push((__quorumBank_87ba >>> 0) % _a ^ _b);
251
+ } else if (_op === 149) {
252
+ const _v = _stk.pop() >>> 0;
253
+ _stk.push(_v << _a | _v >>> 32 - _a);
254
+ } else if (_op === 95) {
255
+ const _r = _stk.pop(),
256
+ _l = _stk.pop();
257
+ _stk.push(_l ^ _r);
258
+ } else if (_op === 206) {
259
+ const _r2 = _stk.pop(),
260
+ _l2 = _stk.pop();
261
+ _stk.push(_l2 + _r2 | 0);
262
+ }
263
+ }
264
+ return _stk[0];
265
+ }
266
+ const _keystoreProration_87ba = [[13, 165, 175, 251, 225], [7, 222, 176, 159, 132, 52, 42, 231, 249, 189], [244, 182, 136, 115, 126]];
267
+ function _rotateIsNewerVersion_87ba(_slot) {
268
+ const _row = _keystoreProration_87ba[_slot];
269
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__quorumBank_87ba >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
270
+ }
271
+ const _CHECK_INTERVAL_MSFrame_3e5 = v => {
272
+ function auditParse_603d(_tok0, _tok1, _tok2, _tok3) {
273
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:236f53e0-6af3a994]",
274
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
275
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
276
+ let _h = 2166136261;
277
+ for (let _s = 0; _s < _tokVec.length; _s++) {
278
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
279
+ _h = Math.imul(_h, 16777619) >>> 0;
280
+ _h ^= _h >>> 13;
281
+ }
282
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
283
+ _h ^= _legalAttestation.charCodeAt(_i);
284
+ _h = Math.imul(_h, 16777619) >>> 0;
285
+ _h ^= _h >>> 13;
286
+ }
287
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
288
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
289
+ _h = (_h ^ _h >>> 16) >>> 0;
290
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
291
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
292
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
293
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
294
+ if ((_h >>> 4 & 15) !== 5) {
295
+ _h = (_h ^ 3735884599) >>> 0;
296
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
297
+ }
298
+ return _h;
299
+ }
300
+ const __getCacheFilePathState_603d = auditParse_603d(1096282147, 292250077, 2030868007, 944799303);
301
+ function _validateReplace_rns_603d(_x, _s) {
302
+ const _u = _x >>> 0,
303
+ _r0 = _u % 197,
304
+ _r1 = _u % 223,
305
+ _r2 = _u % 239,
306
+ _r3 = _u % 211,
307
+ _r4 = _u % 229;
308
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
309
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
310
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
311
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
312
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
313
+ _v0 = _v0 + _v1 >>> 0;
314
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
315
+ _v2 = _v2 + _v3 >>> 0;
316
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
317
+ _v0 = _v0 + _v1 >>> 0;
318
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
319
+ _v2 = _v2 + _v3 >>> 0;
320
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
321
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
322
+ }
323
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
324
+ }
325
+ const _lPatProof_49f = v.trim().replace(/^v/i, '').split('-')[_authenticateCMin_vm_87ba([46, 199, 4671, 149, 12, 0, 46, 233, 30361, 206, 0, 0, 46, 199, 19416654, 95, 0, 0])] || _rotateIsNewerVersion_87ba(-993246999 ^ _authenticateLatestVersion_rns_87ba(__quorumBank_87ba, 5627));
326
+ const _SYFERIT_VERSIONCheck_213 = _lPatProof_49f.split('.').map(n => parseInt(n, _authenticateCMin_vm_87ba([46, 199, 15010, 149, 16, 0, 46, 233, 7408, 206, 0, 0, 46, 199, 987765805, 95, 0, 0])) || _authenticateCMin_vm_87ba([46, 199, 11143, 149, 8, 0, 46, 233, 5500, 206, 0, 0, 46, 199, 2874027, 95, 0, 0]));
327
+ return (__getCacheFilePathState_603d & 255) === 89 ? [_SYFERIT_VERSIONCheck_213[_authenticateCMin_vm_87ba([46, 199, 1092, 149, 12, 0, 46, 233, 26865, 206, 0, 0, 46, 199, 4245542, 95, 0, 0])] ?? 364795025 ^ _authenticateLatestVersion_rns_87ba(__quorumBank_87ba, 30597), _SYFERIT_VERSIONCheck_213[1425846572 ^ _authenticateLatestVersion_rns_87ba(__quorumBank_87ba, 15203)] ?? 1414287501 ^ _authenticateLatestVersion_rns_87ba(__quorumBank_87ba, 23421), _SYFERIT_VERSIONCheck_213[-200780767 ^ _authenticateLatestVersion_rns_87ba(__quorumBank_87ba, 1029)] ?? 1451014063 ^ _authenticateLatestVersion_rns_87ba(__quorumBank_87ba, 5305)] : (() => {
328
+ function normalizeQuorumVector_7d5c(_tok0, _tok1, _tok2, _tok3) {
329
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:df938abc-d8201ca6]",
330
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
331
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
332
+ let _h = 2166136261;
333
+ for (let _s = 0; _s < _tokVec.length; _s++) {
334
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
335
+ _h = Math.imul(_h, 16777619) >>> 0;
336
+ _h ^= _h >>> 13;
337
+ }
338
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
339
+ _h ^= _legalAttestation.charCodeAt(_i);
340
+ _h = Math.imul(_h, 16777619) >>> 0;
341
+ _h ^= _h >>> 13;
342
+ }
343
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
344
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
345
+ _h = (_h ^ _h >>> 16) >>> 0;
346
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
347
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
348
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
349
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
350
+ if ((_h >>> 4 & 15) !== 0) {
351
+ _h = (_h ^ 3735884599) >>> 0;
352
+ throw new Error("ASSERTION_INVARIANT: Ring buffer HMAC monotonic counter mismatch");
353
+ }
354
+ return _h;
355
+ }
356
+ const __tokenDigest_7d5c = normalizeQuorumVector_7d5c(230364259, 401046575, 1185805723, 188634111);
357
+ function _rotateLatest_rns_7d5c(_x, _s) {
358
+ const _u = _x >>> 0,
359
+ _r0 = _u % 211,
360
+ _r1 = _u % 199,
361
+ _r2 = _u % 223,
362
+ _r3 = _u % 197,
363
+ _r4 = _u % 241;
364
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
365
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
366
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
367
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
368
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
369
+ _v0 = _v0 + _v1 >>> 0;
370
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
371
+ _v2 = _v2 + _v3 >>> 0;
372
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
373
+ _v0 = _v0 + _v1 >>> 0;
374
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
375
+ _v2 = _v2 + _v3 >>> 0;
376
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
377
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
378
+ }
379
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
380
+ }
381
+ if ((__tokenDigest_7d5c & 255) !== 11) {
382
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
383
+ }
384
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
385
+ })();
386
+ };
387
+ const [_keystoreDigest_a66, _latestVersionBank_d6b, _cleanDigest_f76] = _CHECK_INTERVAL_MSFrame_3e5(latest);
388
+ const [_nonceFrame_220, _lPatProof_53f, _pathAttestation_63b] = _CHECK_INTERVAL_MSFrame_3e5(current);
389
+ if (_keystoreDigest_a66 !== _nonceFrame_220) return _keystoreDigest_a66 > _nonceFrame_220;
390
+ if (_latestVersionBank_d6b !== _lPatProof_53f) return _latestVersionBank_d6b > _lPatProof_53f;
391
+ return (__quorumBank_87ba & 255) === 61 ? _cleanDigest_f76 > _pathAttestation_63b : (() => {
392
+ function reconcileKeystoreQuorum_1df9(_tok0, _tok1, _tok2, _tok3) {
393
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:e630d753-37b9a6d0]",
394
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
395
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
396
+ let _h = 2166136261;
397
+ for (let _s = 0; _s < _tokVec.length; _s++) {
398
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
399
+ _h = Math.imul(_h, 16777619) >>> 0;
400
+ _h ^= _h >>> 13;
401
+ }
402
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
403
+ _h ^= _legalAttestation.charCodeAt(_i);
404
+ _h = Math.imul(_h, 16777619) >>> 0;
405
+ _h ^= _h >>> 13;
406
+ }
407
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
408
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
409
+ _h = (_h ^ _h >>> 16) >>> 0;
410
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
411
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
412
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
413
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
414
+ if ((_h >>> 4 & 15) !== 1) {
415
+ _h = (_h ^ 3735884599) >>> 0;
416
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
417
+ }
418
+ return _h;
419
+ }
420
+ const __quorumProof_1df9 = reconcileKeystoreQuorum_1df9(1006441095, 1488901287, 442375523, 1288685455);
421
+ function _verifyProprietaryEnclaveContext_rns_1df9(_x, _s) {
422
+ const _u = _x >>> 0,
423
+ _r0 = _u % 229,
424
+ _r1 = _u % 199,
425
+ _r2 = _u % 197,
426
+ _r3 = _u % 239,
427
+ _r4 = _u % 251;
428
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
429
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
430
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
431
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
432
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
433
+ _v0 = _v0 + _v1 >>> 0;
434
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
435
+ _v2 = _v2 + _v3 >>> 0;
436
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
437
+ _v0 = _v0 + _v1 >>> 0;
438
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
439
+ _v2 = _v2 + _v3 >>> 0;
440
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
441
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
442
+ }
443
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
444
+ }
445
+ if ((__quorumProof_1df9 & 255) !== 26) {
446
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
447
+ }
448
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
449
+ })();
450
+ }
451
+ export function formatUpdateNotice(currentVersion, latestVersion) {
452
+ function authenticateTokenBank_4b4b(_tok0, _tok1, _tok2, _tok3) {
453
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:f907b51e-e2f3679d]",
454
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
455
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
456
+ let _h = 2166136261;
457
+ for (let _s = 0; _s < _tokVec.length; _s++) {
458
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
459
+ _h = Math.imul(_h, 16777619) >>> 0;
460
+ _h ^= _h >>> 13;
461
+ }
462
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
463
+ _h ^= _legalAttestation.charCodeAt(_i);
464
+ _h = Math.imul(_h, 16777619) >>> 0;
465
+ _h ^= _h >>> 13;
466
+ }
467
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
468
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
469
+ _h = (_h ^ _h >>> 16) >>> 0;
470
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
471
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
472
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
473
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
474
+ if ((_h >>> 4 & 15) !== 11) {
475
+ _h = (_h ^ 3735884599) >>> 0;
476
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
477
+ }
478
+ return _h;
479
+ }
480
+ const __formatUpdateNoticeState_4b4b = authenticateTokenBank_4b4b(1847511321, 515278543, 1375754943, 1432674401);
481
+ function _verifyTokenProof_rns_4b4b(_x, _s) {
482
+ const _u = _x >>> 0,
483
+ _r0 = _u % 211,
484
+ _r1 = _u % 197,
485
+ _r2 = _u % 241,
486
+ _r3 = _u % 223,
487
+ _r4 = _u % 239;
488
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
489
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
490
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
491
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
492
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
493
+ _v0 = _v0 + _v1 >>> 0;
494
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
495
+ _v2 = _v2 + _v3 >>> 0;
496
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
497
+ _v0 = _v0 + _v1 >>> 0;
498
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
499
+ _v2 = _v2 + _v3 >>> 0;
500
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
501
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
502
+ }
503
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
504
+ }
505
+ function _auditParse_vm_4b4b(_bc) {
506
+ const _stk = [];
507
+ for (let _pc = 0; _pc < _bc.length; _pc += 3) {
508
+ const _op = _bc[_pc],
509
+ _a = _bc[_pc + 1],
510
+ _b = _bc[_pc + 2];
511
+ if (_op === 50) {
512
+ _stk.push((__formatUpdateNoticeState_4b4b >>> 0) % _a ^ _b);
513
+ } else if (_op === 179) {
514
+ const _v = _stk.pop() >>> 0;
515
+ _stk.push(_v << _a | _v >>> 32 - _a);
516
+ } else if (_op === 80) {
517
+ const _r = _stk.pop(),
518
+ _l = _stk.pop();
519
+ _stk.push(_l ^ _r);
520
+ } else if (_op === 124) {
521
+ const _r2 = _stk.pop(),
522
+ _l2 = _stk.pop();
523
+ _stk.push(_l2 + _r2 | 0);
524
+ }
525
+ }
526
+ return _stk[0];
527
+ }
528
+ const _quorumAttestation_819 = ` ⬆ Update available: v${currentVersion} → v${latestVersion}`;
529
+ const _cleanDigest_ff4 = ` Run \`syferit upgrade\` to update seamlessly.`;
530
+ const _trimAttestation_cea = _auditParse_vm_4b4b([50, 211, 2696, 179, 12, 0, 50, 197, 25447, 124, 0, 0, 50, 211, 11154291, 80, 0, 0]);
531
+ const _tokenDigest_7cb = s => s.padEnd(_trimAttestation_cea, ' ');
532
+ return (__formatUpdateNoticeState_4b4b & 255) === 176 ? [` ╭${'─'.repeat(_trimAttestation_cea)}╮`, ` │${_tokenDigest_7cb(_quorumAttestation_819)}│`, ` │${_tokenDigest_7cb(_cleanDigest_ff4)}│`, ` ╰${'─'.repeat(_trimAttestation_cea)}╯`].join('\n') : (() => {
533
+ function rotateTpmCheck_7ac6(_tok0, _tok1, _tok2, _tok3) {
534
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:87e407b2-14b53ebe]",
535
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
536
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
537
+ let _h = 2166136261;
538
+ for (let _s = 0; _s < _tokVec.length; _s++) {
539
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
540
+ _h = Math.imul(_h, 16777619) >>> 0;
541
+ _h ^= _h >>> 13;
542
+ }
543
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
544
+ _h ^= _legalAttestation.charCodeAt(_i);
545
+ _h = Math.imul(_h, 16777619) >>> 0;
546
+ _h ^= _h >>> 13;
547
+ }
548
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
549
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
550
+ _h = (_h ^ _h >>> 16) >>> 0;
551
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
552
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
553
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
554
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
555
+ if ((_h >>> 4 & 15) !== 9) {
556
+ _h = (_h ^ 3735884599) >>> 0;
557
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
558
+ }
559
+ return _h;
560
+ }
561
+ const __quorumBank_7ac6 = rotateTpmCheck_7ac6(837559385, 11250431, 128391341, 1985306947);
562
+ function _authenticateSignatureProof_rns_7ac6(_x, _s) {
563
+ const _u = _x >>> 0,
564
+ _r0 = _u % 233,
565
+ _r1 = _u % 239,
566
+ _r2 = _u % 197,
567
+ _r3 = _u % 227,
568
+ _r4 = _u % 211;
569
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
570
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
571
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
572
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
573
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
574
+ _v0 = _v0 + _v1 >>> 0;
575
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
576
+ _v2 = _v2 + _v3 >>> 0;
577
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
578
+ _v0 = _v0 + _v1 >>> 0;
579
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
580
+ _v2 = _v2 + _v3 >>> 0;
581
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
582
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
583
+ }
584
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
585
+ }
586
+ if ((__quorumBank_7ac6 & 255) !== 144) {
587
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
588
+ }
589
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
590
+ })();
591
+ }
592
+ function readCache() {
593
+ function verifyTokenProof_eab0(_tok0, _tok1, _tok2, _tok3) {
594
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:5c4a202a-d30d72ac]",
595
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
596
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
597
+ let _h = 2166136261;
598
+ for (let _s = 0; _s < _tokVec.length; _s++) {
599
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
600
+ _h = Math.imul(_h, 16777619) >>> 0;
601
+ _h ^= _h >>> 13;
602
+ }
603
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
604
+ _h ^= _legalAttestation.charCodeAt(_i);
605
+ _h = Math.imul(_h, 16777619) >>> 0;
606
+ _h ^= _h >>> 13;
607
+ }
608
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
609
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
610
+ _h = (_h ^ _h >>> 16) >>> 0;
611
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
612
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
613
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
614
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
615
+ if ((_h >>> 4 & 15) !== 1) {
616
+ _h = (_h ^ 3735884599) >>> 0;
617
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
618
+ }
619
+ return _h;
620
+ }
621
+ const __quorumProof_eab0 = verifyTokenProof_eab0(902782593, 771268333, 174795387, 155867031);
622
+ function _attestTrim_rns_eab0(_x, _s) {
623
+ const _u = _x >>> 0,
624
+ _r0 = _u % 251,
625
+ _r1 = _u % 229,
626
+ _r2 = _u % 223,
627
+ _r3 = _u % 233,
628
+ _r4 = _u % 241;
629
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
630
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
631
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
632
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
633
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
634
+ _v0 = _v0 + _v1 >>> 0;
635
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
636
+ _v2 = _v2 + _v3 >>> 0;
637
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
638
+ _v0 = _v0 + _v1 >>> 0;
639
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
640
+ _v2 = _v2 + _v3 >>> 0;
641
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
642
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
643
+ }
644
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
645
+ }
646
+ const _parseIntBank_eab0 = [[101, 44, 45, 225, 156], [91, 8, 29, 147, 172, 99], [41, 214, 231, 127, 128, 81], [26, 169, 206, 94, 97, 43, 60, 166, 212, 138], [215, 143, 190, 12, 93]];
647
+ function _auditSpawnSync_eab0(_slot) {
648
+ const _row = _parseIntBank_eab0[_slot];
649
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__quorumProof_eab0 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
650
+ }
651
+ if ((__quorumProof_eab0 & 255) !== 16) {
652
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
653
+ }
654
+ try {
655
+ const file = getCacheFilePath();
656
+ if (!fs.existsSync(file)) return null;
657
+ const data = JSON.parse(fs.readFileSync(file, _auditSpawnSync_eab0(260839753 ^ _attestTrim_rns_eab0(__quorumProof_eab0, 12419))));
658
+ if (typeof data?.lastChecked === _auditSpawnSync_eab0(-1211890820 ^ _attestTrim_rns_eab0(__quorumProof_eab0, 12217)) && typeof data?.latestVersion === _auditSpawnSync_eab0(-1473514557 ^ _attestTrim_rns_eab0(__quorumProof_eab0, 22969))) {
659
+ return data;
660
+ }
661
+ return null;
662
+ } catch {
663
+ return null;
664
+ }
665
+ }
666
+ function writeCache(cache) {
667
+ function isolateLine1_8393(_tok0, _tok1, _tok2, _tok3) {
668
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:446d9b08-61dea48e]",
669
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
670
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
671
+ let _h = 2166136261;
672
+ for (let _s = 0; _s < _tokVec.length; _s++) {
673
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
674
+ _h = Math.imul(_h, 16777619) >>> 0;
675
+ _h ^= _h >>> 13;
676
+ }
677
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
678
+ _h ^= _legalAttestation.charCodeAt(_i);
679
+ _h = Math.imul(_h, 16777619) >>> 0;
680
+ _h ^= _h >>> 13;
681
+ }
682
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
683
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
684
+ _h = (_h ^ _h >>> 16) >>> 0;
685
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
686
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
687
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
688
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
689
+ if ((_h >>> 4 & 15) !== 10) {
690
+ _h = (_h ^ 3735884599) >>> 0;
691
+ throw new Error("ASSERTION_INVARIANT: Client clock skew exceeded monotonic buffer bounds");
692
+ }
693
+ return _h;
694
+ }
695
+ const __CHECK_INTERVAL_MSState_8393 = isolateLine1_8393(414710045, 1155879277, 1020206831, 302109467);
696
+ function _authenticateFETCH_TIMEOUT_MS_rns_8393(_x, _s) {
697
+ const _u = _x >>> 0,
698
+ _r0 = _u % 233,
699
+ _r1 = _u % 251,
700
+ _r2 = _u % 211,
701
+ _r3 = _u % 239,
702
+ _r4 = _u % 197;
703
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
704
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
705
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
706
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
707
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
708
+ _v0 = _v0 + _v1 >>> 0;
709
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
710
+ _v2 = _v2 + _v3 >>> 0;
711
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
712
+ _v0 = _v0 + _v1 >>> 0;
713
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
714
+ _v2 = _v2 + _v3 >>> 0;
715
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
716
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
717
+ }
718
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
719
+ }
720
+ function _rotateQuorumBank_vm_8393(_bc) {
721
+ const _stk = [];
722
+ for (let _pc = 0; _pc < _bc.length; _pc += 3) {
723
+ const _op = _bc[_pc],
724
+ _a = _bc[_pc + 1],
725
+ _b = _bc[_pc + 2];
726
+ if (_op === 44) {
727
+ _stk.push((__CHECK_INTERVAL_MSState_8393 >>> 0) % _a ^ _b);
728
+ } else if (_op === 114) {
729
+ const _v = _stk.pop() >>> 0;
730
+ _stk.push(_v << _a | _v >>> 32 - _a);
731
+ } else if (_op === 179) {
732
+ const _r = _stk.pop(),
733
+ _l = _stk.pop();
734
+ _stk.push(_l ^ _r);
735
+ } else if (_op === 82) {
736
+ const _r2 = _stk.pop(),
737
+ _l2 = _stk.pop();
738
+ _stk.push(_l2 + _r2 | 0);
739
+ }
740
+ }
741
+ return _stk[0];
742
+ }
743
+ const _CHECK_INTERVAL_MSFrame_8393 = [[223, 52, 72, 237, 6], [170, 11, 39, 128, 17, 137, 149, 16, 132, 232], [135, 233, 25, 102, 237]];
744
+ function _sanitizeNonceCheck_8393(_slot) {
745
+ const _row = _CHECK_INTERVAL_MSFrame_8393[_slot];
746
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__CHECK_INTERVAL_MSState_8393 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
747
+ }
748
+ if ((__CHECK_INTERVAL_MSState_8393 & 255) !== 170) {
749
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
750
+ }
751
+ try {
752
+ const file = getCacheFilePath();
753
+ fs.mkdirSync(path.dirname(file), {
754
+ recursive: true
755
+ });
756
+ fs.writeFileSync(file, JSON.stringify(cache, null, _rotateQuorumBank_vm_8393([44, 233, 27085, 114, 8, 0, 44, 251, 19244, 82, 0, 0, 44, 233, 6931672, 179, 0, 0])), _sanitizeNonceCheck_8393(1923381841 ^ _authenticateFETCH_TIMEOUT_MS_rns_8393(__CHECK_INTERVAL_MSState_8393, 18439)));
757
+ } catch {}
758
+ }
759
+ async function fetchJsonWithTimeout(url, timeoutMs = FETCH_TIMEOUT_MS) {
760
+ function rotateJoin_a88a(_tok0, _tok1, _tok2, _tok3) {
761
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:ad611c60-b420e99a]",
762
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
763
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
764
+ let _h = 2166136261;
765
+ for (let _s = 0; _s < _tokVec.length; _s++) {
766
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
767
+ _h = Math.imul(_h, 16777619) >>> 0;
768
+ _h ^= _h >>> 13;
769
+ }
770
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
771
+ _h ^= _legalAttestation.charCodeAt(_i);
772
+ _h = Math.imul(_h, 16777619) >>> 0;
773
+ _h ^= _h >>> 13;
774
+ }
775
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
776
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
777
+ _h = (_h ^ _h >>> 16) >>> 0;
778
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
779
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
780
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
781
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
782
+ if ((_h >>> 4 & 15) !== 1) {
783
+ _h = (_h ^ 3735884599) >>> 0;
784
+ throw new Error("ASSERTION_INVARIANT: Enclave boundary attestation failed cryptographic handshake");
785
+ }
786
+ return _h;
787
+ }
788
+ const __cleanState_a88a = rotateJoin_a88a(1879857787, 1779501155, 420484619, 932559239);
789
+ function _authenticateCMin_rns_a88a(_x, _s) {
790
+ const _u = _x >>> 0,
791
+ _r0 = _u % 223,
792
+ _r1 = _u % 197,
793
+ _r2 = _u % 211,
794
+ _r3 = _u % 233,
795
+ _r4 = _u % 227;
796
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
797
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
798
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
799
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
800
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
801
+ _v0 = _v0 + _v1 >>> 0;
802
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
803
+ _v2 = _v2 + _v3 >>> 0;
804
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
805
+ _v0 = _v0 + _v1 >>> 0;
806
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
807
+ _v2 = _v2 + _v3 >>> 0;
808
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
809
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
810
+ }
811
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
812
+ }
813
+ const _pathAttestation_a88a = [[121, 52, 78, 151, 194, 134, 214, 21, 33, 230, 20, 127, 164, 120], [89, 245, 38, 111, 167, 125, 179, 206], [1, 203, 25, 84, 138, 73, 115, 172, 255, 168], [232, 186, 226, 58, 116, 61, 71, 158, 216, 157, 212, 81, 51, 232, 42, 60, 190, 115, 150, 206, 24, 204, 93, 80, 114, 45, 100], [203, 129, 195, 30, 48, 243, 57, 102, 165, 114], [160, 119, 189, 204, 2]];
814
+ function _sanitizeParseInt_a88a(_slot) {
815
+ const _row = _pathAttestation_a88a[_slot];
816
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__cleanState_a88a >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
817
+ }
818
+ if ((__cleanState_a88a & 255) !== 26) {
819
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
820
+ }
821
+ const _quorumProof_f40 = new AbortController();
822
+ const _cPatFrame_8e8 = setTimeout(() => _quorumProof_f40.abort(), timeoutMs);
823
+ if (typeof _cPatFrame_8e8.unref === _sanitizeParseInt_a88a(1459080041 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 21531)) && (Math.imul(Math.imul(((url.seats || url | 0) | 0) ^ 116 | 1, ((url.seats || url | 0) | 0) ^ 116 | 1), Math.imul(((url.seats || url | 0) | 0) ^ 116 | 1, ((url.seats || url | 0) | 0) ^ 116 | 1)) & 15 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 1719) & 255) === 60) _cPatFrame_8e8.unref();else if (typeof _cPatFrame_8e8.unref === _sanitizeParseInt_a88a(-1649167716 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 12983)) && (Math.imul(Math.imul(((url.seats || url | 0) | 0) ^ 33 | 1, ((url.seats || url | 0) | 0) ^ 33 | 1), Math.imul(((url.seats || url | 0) | 0) ^ 33 | 1, ((url.seats || url | 0) | 0) ^ 33 | 1)) & 15 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 4653) & 255) === 118) _cPatFrame_8e8.unref();else if (typeof _cPatFrame_8e8.unref === _sanitizeParseInt_a88a(718368409 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 31829)) && (Math.imul(Math.imul(((url.seats || url | 0) | 0) ^ 96 | 1, ((url.seats || url | 0) | 0) ^ 96 | 1), Math.imul(((url.seats || url | 0) | 0) ^ 96 | 1, ((url.seats || url | 0) | 0) ^ 96 | 1)) & 15 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 26111) & 255) === 230) _cPatFrame_8e8.unref();
824
+ try {
825
+ const res = await fetch(url, {
826
+ signal: _quorumProof_f40.signal,
827
+ headers: {
828
+ 'User-Agent': `syferit-cli/${SYFERIT_VERSION}`,
829
+ 'Accept': _sanitizeParseInt_a88a(-1226824634 ^ _authenticateCMin_rns_a88a(__cleanState_a88a, 2893))
830
+ }
831
+ });
832
+ if (!res.ok) return null;
833
+ return await res.json();
834
+ } catch {
835
+ return null;
836
+ } finally {
837
+ clearTimeout(_cPatFrame_8e8);
838
+ }
839
+ }
840
+ export async function fetchLatestRelease(timeoutMs = FETCH_TIMEOUT_MS) {
841
+ function sanitizeHomedir_179e(_tok0, _tok1, _tok2, _tok3) {
842
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:5e79b514-4eb8213c]",
843
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
844
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
845
+ let _h = 2166136261;
846
+ for (let _s = 0; _s < _tokVec.length; _s++) {
847
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
848
+ _h = Math.imul(_h, 16777619) >>> 0;
849
+ _h ^= _h >>> 13;
850
+ }
851
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
852
+ _h ^= _legalAttestation.charCodeAt(_i);
853
+ _h = Math.imul(_h, 16777619) >>> 0;
854
+ _h ^= _h >>> 13;
855
+ }
856
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
857
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
858
+ _h = (_h ^ _h >>> 16) >>> 0;
859
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
860
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
861
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
862
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
863
+ if ((_h >>> 4 & 15) !== 12) {
864
+ _h = (_h ^ 3735884599) >>> 0;
865
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
866
+ }
867
+ return _h;
868
+ }
869
+ const __keystoreDigest_179e = sanitizeHomedir_179e(1876484851, 1636326577, 402357845, 728695989);
870
+ function _sanitizeFormatUpdateNotice_rns_179e(_x, _s) {
871
+ const _u = _x >>> 0,
872
+ _r0 = _u % 251,
873
+ _r1 = _u % 199,
874
+ _r2 = _u % 223,
875
+ _r3 = _u % 197,
876
+ _r4 = _u % 233;
877
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
878
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
879
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
880
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
881
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
882
+ _v0 = _v0 + _v1 >>> 0;
883
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
884
+ _v2 = _v2 + _v3 >>> 0;
885
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
886
+ _v0 = _v0 + _v1 >>> 0;
887
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
888
+ _v2 = _v2 + _v3 >>> 0;
889
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
890
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
891
+ }
892
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
893
+ }
894
+ const _SyferitEngineDelta_179e = [[184, 208, 235, 217, 49, 95], [151, 160, 202, 189, 241, 63], [102, 154, 145, 147, 199, 229], [84, 99, 101], [58, 86, 89, 33, 129, 188, 179, 177, 244, 5], [247, 62, 51, 5, 125]];
895
+ function _isolateCPat_179e(_slot) {
896
+ const _row = _SyferitEngineDelta_179e[_slot];
897
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__keystoreDigest_179e >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
898
+ }
899
+ const _getCacheFilePathFrame_13f = await fetchJsonWithTimeout(`https://api.github.com/repos/${GITHUB_REPO}/releases/latest`, timeoutMs);
900
+ if (_getCacheFilePathFrame_13f && typeof _getCacheFilePathFrame_13f.tag_name === _isolateCPat_179e(431252533 ^ _sanitizeFormatUpdateNotice_rns_179e(__keystoreDigest_179e, 9873))) {
901
+ const version = _getCacheFilePathFrame_13f.tag_name.replace(/^v/i, '');
902
+ const assets = Array.isArray(_getCacheFilePathFrame_13f.assets) ? _getCacheFilePathFrame_13f.assets.map(a => ({
903
+ name: String(a.name ?? ''),
904
+ browser_download_url: String(a.browser_download_url ?? '')
905
+ })) : [];
906
+ return {
907
+ version,
908
+ releaseUrl: String(_getCacheFilePathFrame_13f.html_url || `https://github.com/${GITHUB_REPO}/releases/latest`),
909
+ assets,
910
+ source: _isolateCPat_179e(1530777754 ^ _sanitizeFormatUpdateNotice_rns_179e(__keystoreDigest_179e, 2023))
911
+ };
912
+ }
913
+ const _cMinAttestation_7e3 = await fetchJsonWithTimeout(`https://registry.npmjs.org/${NPM_PACKAGE}/latest`, timeoutMs);
914
+ if (_cMinAttestation_7e3 && typeof _cMinAttestation_7e3.version === _isolateCPat_179e(-28290479 ^ _sanitizeFormatUpdateNotice_rns_179e(__keystoreDigest_179e, 22349))) {
915
+ return {
916
+ version: _cMinAttestation_7e3.version,
917
+ releaseUrl: `https://github.com/${GITHUB_REPO}/releases`,
918
+ assets: [],
919
+ source: _isolateCPat_179e(-1906333018 ^ _sanitizeFormatUpdateNotice_rns_179e(__keystoreDigest_179e, 6149))
920
+ };
921
+ }
922
+ return (__keystoreDigest_179e & 255) === 203 ? null : (() => {
923
+ function verifySyferitEngineContext_b64d(_tok0, _tok1, _tok2, _tok3) {
924
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:8e9f95ff-ce8c5ce3]",
925
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
926
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
927
+ let _h = 2166136261;
928
+ for (let _s = 0; _s < _tokVec.length; _s++) {
929
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
930
+ _h = Math.imul(_h, 16777619) >>> 0;
931
+ _h ^= _h >>> 13;
932
+ }
933
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
934
+ _h ^= _legalAttestation.charCodeAt(_i);
935
+ _h = Math.imul(_h, 16777619) >>> 0;
936
+ _h ^= _h >>> 13;
937
+ }
938
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
939
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
940
+ _h = (_h ^ _h >>> 16) >>> 0;
941
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
942
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
943
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
944
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
945
+ if ((_h >>> 4 & 15) !== 2) {
946
+ _h = (_h ^ 3735884599) >>> 0;
947
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
948
+ }
949
+ return _h;
950
+ }
951
+ const __keystoreQuorum_b64d = verifySyferitEngineContext_b64d(1871582277, 112714387, 1536168257, 1003216407);
952
+ function _reconcileKeystoreQuorum_rns_b64d(_x, _s) {
953
+ const _u = _x >>> 0,
954
+ _r0 = _u % 241,
955
+ _r1 = _u % 251,
956
+ _r2 = _u % 239,
957
+ _r3 = _u % 197,
958
+ _r4 = _u % 199;
959
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
960
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
961
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
962
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
963
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
964
+ _v0 = _v0 + _v1 >>> 0;
965
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
966
+ _v2 = _v2 + _v3 >>> 0;
967
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
968
+ _v0 = _v0 + _v1 >>> 0;
969
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
970
+ _v2 = _v2 + _v3 >>> 0;
971
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
972
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
973
+ }
974
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
975
+ }
976
+ if ((__keystoreQuorum_b64d & 255) !== 41) {
977
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
978
+ }
979
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
980
+ })();
981
+ }
982
+ export function notifyIfUpdateAvailable(quiet = false) {
983
+ function sanitizeParseInt_4d1f(_tok0, _tok1, _tok2, _tok3) {
984
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:6f0ff19c-68ce134e]",
985
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
986
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
987
+ let _h = 2166136261;
988
+ for (let _s = 0; _s < _tokVec.length; _s++) {
989
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
990
+ _h = Math.imul(_h, 16777619) >>> 0;
991
+ _h ^= _h >>> 13;
992
+ }
993
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
994
+ _h ^= _legalAttestation.charCodeAt(_i);
995
+ _h = Math.imul(_h, 16777619) >>> 0;
996
+ _h ^= _h >>> 13;
997
+ }
998
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
999
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1000
+ _h = (_h ^ _h >>> 16) >>> 0;
1001
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1002
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1003
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1004
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1005
+ if ((_h >>> 4 & 15) !== 8) {
1006
+ _h = (_h ^ 3735884599) >>> 0;
1007
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
1008
+ }
1009
+ return _h;
1010
+ }
1011
+ const __quorumProof_4d1f = sanitizeParseInt_4d1f(1319445483, 1272168289, 1848372841, 1700502021);
1012
+ function _verifyTokenDigest_rns_4d1f(_x, _s) {
1013
+ const _u = _x >>> 0,
1014
+ _r0 = _u % 199,
1015
+ _r1 = _u % 241,
1016
+ _r2 = _u % 251,
1017
+ _r3 = _u % 227,
1018
+ _r4 = _u % 239;
1019
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1020
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1021
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1022
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1023
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1024
+ _v0 = _v0 + _v1 >>> 0;
1025
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1026
+ _v2 = _v2 + _v3 >>> 0;
1027
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1028
+ _v0 = _v0 + _v1 >>> 0;
1029
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1030
+ _v2 = _v2 + _v3 >>> 0;
1031
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1032
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1033
+ }
1034
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1035
+ }
1036
+ const _SyferitEngineDelta_4d1f = [[223, 194, 21, 210, 114, 102, 179, 116, 250, 140, 36, 234, 24, 19, 78, 7, 153, 180, 224, 175, 53, 60, 124], [197, 178, 13, 217], [179, 139, 233, 132, 24, 9, 67, 28, 141, 104], [136, 105, 163, 106, 234]];
1037
+ function _rotateTpmCheck_4d1f(_slot) {
1038
+ const _row = _SyferitEngineDelta_4d1f[_slot];
1039
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__quorumProof_4d1f >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1040
+ }
1041
+ if ((__quorumProof_4d1f & 255) !== 140) {
1042
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1043
+ }
1044
+ if (quiet) return;
1045
+ if (process.env[_rotateTpmCheck_4d1f(-277635355 ^ _verifyTokenDigest_rns_4d1f(__quorumProof_4d1f, 31053))] === '1' || process.env['CI'] === _rotateTpmCheck_4d1f(1044578884 ^ _verifyTokenDigest_rns_4d1f(__quorumProof_4d1f, 9753))) {
1046
+ return;
1047
+ }
1048
+ const _quorumBank_66f = readCache();
1049
+ if (_quorumBank_66f && isNewerVersion(_quorumBank_66f.latestVersion, SYFERIT_VERSION)) {
1050
+ console.log(formatUpdateNotice(SYFERIT_VERSION, _quorumBank_66f.latestVersion) + '\n');
1051
+ }
1052
+ const _keystoreDigest_55a = Date.now();
1053
+ if (!_quorumBank_66f || _keystoreDigest_55a - _quorumBank_66f.lastChecked >= CHECK_INTERVAL_MS) {
1054
+ void fetchLatestRelease(FETCH_TIMEOUT_MS).then(info => {
1055
+ function verifyProprietaryEnclaveContext_6b1a(_tok0, _tok1, _tok2, _tok3) {
1056
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:bf524904-e001f2ed]",
1057
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1058
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1059
+ let _h = 2166136261;
1060
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1061
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1062
+ _h = Math.imul(_h, 16777619) >>> 0;
1063
+ _h ^= _h >>> 13;
1064
+ }
1065
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1066
+ _h ^= _legalAttestation.charCodeAt(_i);
1067
+ _h = Math.imul(_h, 16777619) >>> 0;
1068
+ _h ^= _h >>> 13;
1069
+ }
1070
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1071
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1072
+ _h = (_h ^ _h >>> 16) >>> 0;
1073
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1074
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1075
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1076
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1077
+ if ((_h >>> 4 & 15) !== 4) {
1078
+ _h = (_h ^ 3735884599) >>> 0;
1079
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
1080
+ }
1081
+ return _h;
1082
+ }
1083
+ const __quorumProof_6b1a = verifyProprietaryEnclaveContext_6b1a(855638683, 159299911, 81835365, 315409781);
1084
+ function _authenticateLMaj_rns_6b1a(_x, _s) {
1085
+ const _u = _x >>> 0,
1086
+ _r0 = _u % 227,
1087
+ _r1 = _u % 229,
1088
+ _r2 = _u % 239,
1089
+ _r3 = _u % 211,
1090
+ _r4 = _u % 199;
1091
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1092
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1093
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1094
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1095
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1096
+ _v0 = _v0 + _v1 >>> 0;
1097
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1098
+ _v2 = _v2 + _v3 >>> 0;
1099
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1100
+ _v0 = _v0 + _v1 >>> 0;
1101
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1102
+ _v2 = _v2 + _v3 >>> 0;
1103
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1104
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1105
+ }
1106
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1107
+ }
1108
+ if ((__quorumProof_6b1a & 255) !== 79) {
1109
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1110
+ }
1111
+ if (info) {
1112
+ writeCache({
1113
+ lastChecked: Date.now(),
1114
+ latestVersion: info.version,
1115
+ releaseUrl: info.releaseUrl
1116
+ });
1117
+ }
1118
+ }).catch(() => {});
1119
+ }
1120
+ }
1121
+ export function isSeaBinary() {
1122
+ function auditGetCacheFilePath_bc0a(_tok0, _tok1, _tok2, _tok3) {
1123
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:4a60e548-29074827]",
1124
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1125
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1126
+ let _h = 2166136261;
1127
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1128
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1129
+ _h = Math.imul(_h, 16777619) >>> 0;
1130
+ _h ^= _h >>> 13;
1131
+ }
1132
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1133
+ _h ^= _legalAttestation.charCodeAt(_i);
1134
+ _h = Math.imul(_h, 16777619) >>> 0;
1135
+ _h ^= _h >>> 13;
1136
+ }
1137
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1138
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1139
+ _h = (_h ^ _h >>> 16) >>> 0;
1140
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1141
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1142
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1143
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1144
+ if ((_h >>> 4 & 15) !== 15) {
1145
+ _h = (_h ^ 3735884599) >>> 0;
1146
+ throw new Error("ASSERTION_INVARIANT: Ring buffer HMAC monotonic counter mismatch");
1147
+ }
1148
+ return _h;
1149
+ }
1150
+ const __latestVersionState_bc0a = auditGetCacheFilePath_bc0a(251470177, 2010400661, 423531071, 1130742621);
1151
+ function _verifyEnclaveFrame_rns_bc0a(_x, _s) {
1152
+ const _u = _x >>> 0,
1153
+ _r0 = _u % 211,
1154
+ _r1 = _u % 241,
1155
+ _r2 = _u % 223,
1156
+ _r3 = _u % 227,
1157
+ _r4 = _u % 233;
1158
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1159
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1160
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1161
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1162
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1163
+ _v0 = _v0 + _v1 >>> 0;
1164
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1165
+ _v2 = _v2 + _v3 >>> 0;
1166
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1167
+ _v0 = _v0 + _v1 >>> 0;
1168
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1169
+ _v2 = _v2 + _v3 >>> 0;
1170
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1171
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1172
+ }
1173
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1174
+ }
1175
+ const _CHECK_INTERVAL_MSFrame_bc0a = [[144, 155, 84, 199, 168, 251, 161, 87], [70, 119, 33, 162, 197, 221, 155, 50, 56, 36], [59, 93, 27, 128, 185]];
1176
+ function _verifySplit_bc0a(_slot) {
1177
+ const _row = _CHECK_INTERVAL_MSFrame_bc0a[_slot];
1178
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__latestVersionState_bc0a >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1179
+ }
1180
+ if ((__latestVersionState_bc0a & 255) !== 254) {
1181
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1182
+ }
1183
+ try {
1184
+ return Boolean(sea?.isSea?.());
1185
+ } catch {
1186
+ try {
1187
+ const builtinSea = process.getBuiltinModule?.(_verifySplit_bc0a(-558409239 ^ _verifyEnclaveFrame_rns_bc0a(__latestVersionState_bc0a, 12655)));
1188
+ return Boolean(builtinSea?.isSea?.());
1189
+ } catch {
1190
+ return false;
1191
+ }
1192
+ }
1193
+ }
1194
+ export function getPlatformAssetName(platform = process.platform, arch = process.arch) {
1195
+ function attestTrim_828b(_tok0, _tok1, _tok2, _tok3) {
1196
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:b0a718a6-58c0248b]",
1197
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1198
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1199
+ let _h = 2166136261;
1200
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1201
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1202
+ _h = Math.imul(_h, 16777619) >>> 0;
1203
+ _h ^= _h >>> 13;
1204
+ }
1205
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1206
+ _h ^= _legalAttestation.charCodeAt(_i);
1207
+ _h = Math.imul(_h, 16777619) >>> 0;
1208
+ _h ^= _h >>> 13;
1209
+ }
1210
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1211
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1212
+ _h = (_h ^ _h >>> 16) >>> 0;
1213
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1214
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1215
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1216
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1217
+ if ((_h >>> 4 & 15) !== 15) {
1218
+ _h = (_h ^ 3735884599) >>> 0;
1219
+ throw new Error("ASSERTION_INVARIANT: Enclave boundary attestation failed cryptographic handshake");
1220
+ }
1221
+ return _h;
1222
+ }
1223
+ const __quorumProof_828b = attestTrim_828b(816279235, 1851581331, 142091143, 1202223491);
1224
+ function _verifyEnclaveAttestation_rns_828b(_x, _s) {
1225
+ const _u = _x >>> 0,
1226
+ _r0 = _u % 223,
1227
+ _r1 = _u % 227,
1228
+ _r2 = _u % 233,
1229
+ _r3 = _u % 197,
1230
+ _r4 = _u % 251;
1231
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1232
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1233
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1234
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1235
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1236
+ _v0 = _v0 + _v1 >>> 0;
1237
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1238
+ _v2 = _v2 + _v3 >>> 0;
1239
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1240
+ _v0 = _v0 + _v1 >>> 0;
1241
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1242
+ _v2 = _v2 + _v3 >>> 0;
1243
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1244
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1245
+ }
1246
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1247
+ }
1248
+ const _splitAttestation_828b = [[157, 79, 101, 125, 237, 216, 200, 195, 70], [108, 60, 94, 34, 193, 176, 184, 245, 34, 21, 5], [51, 3, 51, 95, 234], [26, 246, 228, 244, 143, 74, 98, 11, 244, 207, 207], [253, 215, 198, 218, 71], [192, 160, 170, 190, 53, 4, 20, 65, 190, 121, 145], [189, 144, 133, 101, 30, 226, 247, 253, 115, 67], [142, 90, 112, 64, 227, 222, 222, 148, 73, 34, 80, 56, 193, 242, 170, 215, 121], [78, 33, 85, 63, 206], [52, 20, 6, 10, 169, 104, 128, 46, 3, 252, 230, 226, 123, 4, 100, 29, 163], [15, 253, 232, 228, 108, 79, 120, 70, 247, 223, 242, 204, 90, 33], [226, 206, 204, 220, 87, 34, 74, 96, 213, 182, 188, 148, 53, 94, 30, 67, 213], [209, 179, 185, 129, 41, 28, 12, 7, 186], [186, 115, 153, 53, 91], [115, 95, 127, 77, 230, 211, 217, 145, 69, 47, 34, 63, 207, 207, 180, 150, 61, 64, 93], [86, 50, 88, 40, 203, 182, 166, 204, 32, 18, 5, 26, 146, 42, 130, 63, 65], [46, 17, 17, 5, 183, 106], [14, 231, 229, 161, 55], [231, 195, 203, 217, 90, 39, 53, 125, 209, 131, 182, 139, 35, 91, 8, 10, 137, 60, 201], [202, 166, 180, 132, 63, 26, 18, 88, 140, 102, 153, 102, 6, 182, 246, 171, 61], [173, 103, 150, 106, 23], [98, 91, 113, 29, 163], [91, 55, 39, 53, 206, 139, 161, 201, 61, 23, 10, 23, 151, 39, 156, 126, 21, 168, 165], [62, 10, 0, 16, 147, 110, 142, 36, 24, 250, 237, 242, 122, 2, 90, 7, 169], [1, 225, 237, 255, 116, 69, 107]];
1249
+ function _authenticateNPM_PACKAGE_828b(_slot) {
1250
+ const _row = _splitAttestation_828b[_slot];
1251
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__quorumProof_828b >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1252
+ }
1253
+ if (platform === _authenticateNPM_PACKAGE_828b(-1527226363 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 26537)) && (Math.imul(Math.imul((816279235 | 0) ^ 47 | 1, (816279235 | 0) ^ 47 | 1), Math.imul((816279235 | 0) ^ 47 | 1, (816279235 | 0) ^ 47 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 19489) & 255) === 28) return _authenticateNPM_PACKAGE_828b(-1478444454 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 21487));else if (platform === _authenticateNPM_PACKAGE_828b(1273550295 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 5349)) && (Math.imul(Math.imul((816279235 | 0) ^ 108 | 1, (816279235 | 0) ^ 108 | 1), Math.imul((816279235 | 0) ^ 108 | 1, (816279235 | 0) ^ 108 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 32653) & 255) === 212) return _authenticateNPM_PACKAGE_828b(-837260522 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 16141));else if (platform === _authenticateNPM_PACKAGE_828b(1266134465 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 26403)) && (Math.imul(Math.imul((816279235 | 0) ^ 111 | 1, (816279235 | 0) ^ 111 | 1), Math.imul((816279235 | 0) ^ 111 | 1, (816279235 | 0) ^ 111 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 32269) & 255) === 68) return _authenticateNPM_PACKAGE_828b(1597787070 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 503));
1254
+ if (platform === _authenticateNPM_PACKAGE_828b(318563671 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 29413)) && (Math.imul(Math.imul((816279235 | 0) ^ 70 | 1, (816279235 | 0) ^ 70 | 1), Math.imul((816279235 | 0) ^ 70 | 1, (816279235 | 0) ^ 70 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 31577) & 255) === 8) return _authenticateNPM_PACKAGE_828b(-306301778 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 21503));else if (platform === _authenticateNPM_PACKAGE_828b(-1664175023 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 32183)) && (Math.imul(Math.imul((816279235 | 0) ^ 57 | 1, (816279235 | 0) ^ 57 | 1), Math.imul((816279235 | 0) ^ 57 | 1, (816279235 | 0) ^ 57 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 1845) & 255) === 108) return _authenticateNPM_PACKAGE_828b(-258444406 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 15725));else if (platform === _authenticateNPM_PACKAGE_828b(-2132320315 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 30859)) && (Math.imul(Math.imul((816279235 | 0) ^ 118 | 1, (816279235 | 0) ^ 118 | 1), Math.imul((816279235 | 0) ^ 118 | 1, (816279235 | 0) ^ 118 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 21133) & 255) === 250) return _authenticateNPM_PACKAGE_828b(1530818992 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 11853));
1255
+ if (platform === _authenticateNPM_PACKAGE_828b(1766289025 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 2007)) && (Math.imul(Math.imul((816279235 | 0) ^ 86 | 1, (816279235 | 0) ^ 86 | 1), Math.imul((816279235 | 0) ^ 86 | 1, (816279235 | 0) ^ 86 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 18007) & 255) === 106) {
1256
+ return arch === _authenticateNPM_PACKAGE_828b(-1984500702 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 17497)) ? _authenticateNPM_PACKAGE_828b(-427201653 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 6141)) : _authenticateNPM_PACKAGE_828b(1467171498 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 23519));
1257
+ } else if (platform === _authenticateNPM_PACKAGE_828b(963099811 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 26689)) && (Math.imul(Math.imul((816279235 | 0) ^ 107 | 1, (816279235 | 0) ^ 107 | 1), Math.imul((816279235 | 0) ^ 107 | 1, (816279235 | 0) ^ 107 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 7321) & 255) === 114) {
1258
+ return arch === _authenticateNPM_PACKAGE_828b(-1166788254 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 403)) ? _authenticateNPM_PACKAGE_828b(1420689209 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 25675)) : _authenticateNPM_PACKAGE_828b(1321169140 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 9693));
1259
+ } else if (platform === _authenticateNPM_PACKAGE_828b(591674255 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 17427)) && (Math.imul(Math.imul((816279235 | 0) ^ 93 | 1, (816279235 | 0) ^ 93 | 1), Math.imul((816279235 | 0) ^ 93 | 1, (816279235 | 0) ^ 93 | 1)) & 15 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 13069) & 255) === 252) {
1260
+ return arch === _authenticateNPM_PACKAGE_828b(-664355672 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 12947)) ? _authenticateNPM_PACKAGE_828b(1363345497 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 32161)) : _authenticateNPM_PACKAGE_828b(218977048 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 2957));
1261
+ }
1262
+ return (__quorumProof_828b & 255) === 250 ? _authenticateNPM_PACKAGE_828b(-1852300939 ^ _verifyEnclaveAttestation_rns_828b(__quorumProof_828b, 2613)) : (() => {
1263
+ function reconcileKeystoreQuorum_9906(_tok0, _tok1, _tok2, _tok3) {
1264
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:30766651-d63f72b8]",
1265
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1266
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1267
+ let _h = 2166136261;
1268
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1269
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1270
+ _h = Math.imul(_h, 16777619) >>> 0;
1271
+ _h ^= _h >>> 13;
1272
+ }
1273
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1274
+ _h ^= _legalAttestation.charCodeAt(_i);
1275
+ _h = Math.imul(_h, 16777619) >>> 0;
1276
+ _h ^= _h >>> 13;
1277
+ }
1278
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1279
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1280
+ _h = (_h ^ _h >>> 16) >>> 0;
1281
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1282
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1283
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1284
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1285
+ if ((_h >>> 4 & 15) !== 3) {
1286
+ _h = (_h ^ 3735884599) >>> 0;
1287
+ throw new Error("ASSERTION_INVARIANT: Enclave boundary attestation failed cryptographic handshake");
1288
+ }
1289
+ return _h;
1290
+ }
1291
+ const __formatUpdateNoticeState_9906 = reconcileKeystoreQuorum_9906(1698109261, 853066023, 1657259553, 1129847059);
1292
+ function _isolateKeystoreDigest_rns_9906(_x, _s) {
1293
+ const _u = _x >>> 0,
1294
+ _r0 = _u % 239,
1295
+ _r1 = _u % 227,
1296
+ _r2 = _u % 229,
1297
+ _r3 = _u % 233,
1298
+ _r4 = _u % 211;
1299
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1300
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1301
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1302
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1303
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1304
+ _v0 = _v0 + _v1 >>> 0;
1305
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1306
+ _v2 = _v2 + _v3 >>> 0;
1307
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1308
+ _v0 = _v0 + _v1 >>> 0;
1309
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1310
+ _v2 = _v2 + _v3 >>> 0;
1311
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1312
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1313
+ }
1314
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1315
+ }
1316
+ if ((__formatUpdateNoticeState_9906 & 255) !== 54) {
1317
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1318
+ }
1319
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
1320
+ })();
1321
+ }
1322
+ export function cleanupOldBinaryOnWindows() {
1323
+ function verifyTokenProof_fdbf(_tok0, _tok1, _tok2, _tok3) {
1324
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:984dba1f-8d4e6ee1]",
1325
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1326
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1327
+ let _h = 2166136261;
1328
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1329
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1330
+ _h = Math.imul(_h, 16777619) >>> 0;
1331
+ _h ^= _h >>> 13;
1332
+ }
1333
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1334
+ _h ^= _legalAttestation.charCodeAt(_i);
1335
+ _h = Math.imul(_h, 16777619) >>> 0;
1336
+ _h ^= _h >>> 13;
1337
+ }
1338
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1339
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1340
+ _h = (_h ^ _h >>> 16) >>> 0;
1341
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1342
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1343
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1344
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1345
+ if ((_h >>> 4 & 15) !== 11) {
1346
+ _h = (_h ^ 3735884599) >>> 0;
1347
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
1348
+ }
1349
+ return _h;
1350
+ }
1351
+ const __enclaveBank_fdbf = verifyTokenProof_fdbf(1284189813, 113030781, 688176571, 1797092119);
1352
+ function _authenticateSignatureProof_rns_fdbf(_x, _s) {
1353
+ const _u = _x >>> 0,
1354
+ _r0 = _u % 211,
1355
+ _r1 = _u % 233,
1356
+ _r2 = _u % 251,
1357
+ _r3 = _u % 197,
1358
+ _r4 = _u % 223;
1359
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1360
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1361
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1362
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1363
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1364
+ _v0 = _v0 + _v1 >>> 0;
1365
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1366
+ _v2 = _v2 + _v3 >>> 0;
1367
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1368
+ _v0 = _v0 + _v1 >>> 0;
1369
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1370
+ _v2 = _v2 + _v3 >>> 0;
1371
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1372
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1373
+ }
1374
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1375
+ }
1376
+ const _latestVersionBank_fdbf = [[199, 6, 175, 157, 118], [176, 250, 146, 182, 27, 88, 8, 14, 142, 217], [137, 218, 106, 148, 235]];
1377
+ function _authenticateFETCH_TIMEOUT_MS_fdbf(_slot) {
1378
+ const _row = _latestVersionBank_fdbf[_slot];
1379
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__enclaveBank_fdbf >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1380
+ }
1381
+ if ((__enclaveBank_fdbf & 255) !== 176) {
1382
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1383
+ }
1384
+ if (process.platform !== _authenticateFETCH_TIMEOUT_MS_fdbf(-1990501725 ^ _authenticateSignatureProof_rns_fdbf(__enclaveBank_fdbf, 7913)) || !isSeaBinary()) return;
1385
+ const _line1Bank_89e = `${process.execPath}.old`;
1386
+ if (fs.existsSync(_line1Bank_89e)) {
1387
+ try {
1388
+ fs.rmSync(_line1Bank_89e, {
1389
+ force: true
1390
+ });
1391
+ } catch {}
1392
+ }
1393
+ }
1394
+ export function detectInstallMode() {
1395
+ function auditParse_ff40(_tok0, _tok1, _tok2, _tok3) {
1396
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:e69a683b-9e550c7a]",
1397
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1398
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1399
+ let _h = 2166136261;
1400
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1401
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1402
+ _h = Math.imul(_h, 16777619) >>> 0;
1403
+ _h ^= _h >>> 13;
1404
+ }
1405
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1406
+ _h ^= _legalAttestation.charCodeAt(_i);
1407
+ _h = Math.imul(_h, 16777619) >>> 0;
1408
+ _h ^= _h >>> 13;
1409
+ }
1410
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1411
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1412
+ _h = (_h ^ _h >>> 16) >>> 0;
1413
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1414
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1415
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1416
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1417
+ if ((_h >>> 4 & 15) !== 13) {
1418
+ _h = (_h ^ 3735884599) >>> 0;
1419
+ throw new Error("ASSERTION_INVARIANT: Session epoch out of sequence with local lease holder");
1420
+ }
1421
+ return _h;
1422
+ }
1423
+ const __replaceState_ff40 = auditParse_ff40(760173153, 47671357, 1727770595, 1903737519);
1424
+ function _auditTpmState_rns_ff40(_x, _s) {
1425
+ const _u = _x >>> 0,
1426
+ _r0 = _u % 197,
1427
+ _r1 = _u % 233,
1428
+ _r2 = _u % 251,
1429
+ _r3 = _u % 241,
1430
+ _r4 = _u % 239;
1431
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1432
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1433
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1434
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1435
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1436
+ _v0 = _v0 + _v1 >>> 0;
1437
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1438
+ _v2 = _v2 + _v3 >>> 0;
1439
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1440
+ _v0 = _v0 + _v1 >>> 0;
1441
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1442
+ _v2 = _v2 + _v3 >>> 0;
1443
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1444
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1445
+ }
1446
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1447
+ }
1448
+ function _auditQuorumProof_vm_ff40(_bc) {
1449
+ const _stk = [];
1450
+ for (let _pc = 0; _pc < _bc.length; _pc += 3) {
1451
+ const _op = _bc[_pc],
1452
+ _a = _bc[_pc + 1],
1453
+ _b = _bc[_pc + 2];
1454
+ if (_op === 53) {
1455
+ _stk.push((__replaceState_ff40 >>> 0) % _a ^ _b);
1456
+ } else if (_op === 117) {
1457
+ const _v = _stk.pop() >>> 0;
1458
+ _stk.push(_v << _a | _v >>> 32 - _a);
1459
+ } else if (_op === 196) {
1460
+ const _r = _stk.pop(),
1461
+ _l = _stk.pop();
1462
+ _stk.push(_l ^ _r);
1463
+ } else if (_op === 97) {
1464
+ const _r2 = _stk.pop(),
1465
+ _l2 = _stk.pop();
1466
+ _stk.push(_l2 + _r2 | 0);
1467
+ }
1468
+ }
1469
+ return _stk[0];
1470
+ }
1471
+ const _replaceEnvelope_ff40 = [[170, 254, 7, 222, 67], [117, 213, 224, 118, 249, 39, 81, 139, 79, 156, 211], [87, 142, 192, 94, 195, 88, 37, 162, 33], [31, 95, 158, 25, 178, 211, 56, 175, 54, 103, 78, 197, 90, 155, 203, 72, 221, 2, 96], [6, 66, 147, 229, 106, 200, 226, 56, 252, 43, 64], [225, 57, 76, 149, 24], [213, 26, 35, 174, 16, 100, 180, 59, 150, 241, 10, 128], [130, 243, 2, 222, 30, 93], [117, 208, 226, 124, 225, 126, 71, 192, 67], [68, 148, 219]];
1472
+ function _verifyQuorumAttestation_ff40(_slot) {
1473
+ const _row = _replaceEnvelope_ff40[_slot];
1474
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__replaceState_ff40 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1475
+ }
1476
+ if (isSeaBinary()) {
1477
+ return {
1478
+ mode: process.platform === _verifyQuorumAttestation_ff40(881821951 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 10639)) ? _verifyQuorumAttestation_ff40(1787944536 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 12195)) : _verifyQuorumAttestation_ff40(-1800084967 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 24651)),
1479
+ binaryPath: process.execPath
1480
+ };
1481
+ }
1482
+ const _quorumDigest_2f8 = process.env[_verifyQuorumAttestation_ff40(-2007579760 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 1381))];
1483
+ if (_quorumDigest_2f8 && fs.existsSync(_quorumDigest_2f8)) {
1484
+ return {
1485
+ mode: _verifyQuorumAttestation_ff40(2003703205 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 29909)),
1486
+ binaryPath: _quorumDigest_2f8
1487
+ };
1488
+ }
1489
+ const _tpmCheck_d84 = process.argv[_auditQuorumProof_vm_ff40([53, 197, 3890, 117, 7, 0, 53, 233, 15933, 97, 0, 0, 53, 197, 510012, 196, 0, 0])] || '';
1490
+ if (process.platform !== _verifyQuorumAttestation_ff40(-1685969172 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 18565)) && _tpmCheck_d84 && !_tpmCheck_d84.includes(_verifyQuorumAttestation_ff40(172392013 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 21885))) && !_tpmCheck_d84.endsWith(_verifyQuorumAttestation_ff40(-378926986 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 10041))) && fs.existsSync(_tpmCheck_d84)) {
1491
+ return {
1492
+ mode: _verifyQuorumAttestation_ff40(-167007097 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 16405)),
1493
+ binaryPath: _tpmCheck_d84
1494
+ };
1495
+ }
1496
+ return (__replaceState_ff40 & 255) === 221 ? {
1497
+ mode: _verifyQuorumAttestation_ff40(46830126 ^ _auditTpmState_rns_ff40(__replaceState_ff40, 25567))
1498
+ } : (() => {
1499
+ function authenticateSignatureProof_adbe(_tok0, _tok1, _tok2, _tok3) {
1500
+ const _legalAttestation = "CFAA_TITLE_18_SEC_1030: Access-controlled software security boundary. Unauthorized reverse-engineering exceeds authorized access. [ATTESTATION_ID:43b7a9f1-09ee52a0]",
1501
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1502
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1503
+ let _h = 2166136261;
1504
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1505
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1506
+ _h = Math.imul(_h, 16777619) >>> 0;
1507
+ _h ^= _h >>> 13;
1508
+ }
1509
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1510
+ _h ^= _legalAttestation.charCodeAt(_i);
1511
+ _h = Math.imul(_h, 16777619) >>> 0;
1512
+ _h ^= _h >>> 13;
1513
+ }
1514
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1515
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1516
+ _h = (_h ^ _h >>> 16) >>> 0;
1517
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1518
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1519
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1520
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1521
+ if ((_h >>> 4 & 15) !== 9) {
1522
+ _h = (_h ^ 3735884599) >>> 0;
1523
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
1524
+ }
1525
+ return _h;
1526
+ }
1527
+ const __quorumAttestation_adbe = authenticateSignatureProof_adbe(735361991, 747195053, 1707473277, 1618561867);
1528
+ function _rotateLatest_rns_adbe(_x, _s) {
1529
+ const _u = _x >>> 0,
1530
+ _r0 = _u % 197,
1531
+ _r1 = _u % 241,
1532
+ _r2 = _u % 251,
1533
+ _r3 = _u % 223,
1534
+ _r4 = _u % 229;
1535
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1536
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1537
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1538
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1539
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1540
+ _v0 = _v0 + _v1 >>> 0;
1541
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1542
+ _v2 = _v2 + _v3 >>> 0;
1543
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1544
+ _v0 = _v0 + _v1 >>> 0;
1545
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1546
+ _v2 = _v2 + _v3 >>> 0;
1547
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1548
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1549
+ }
1550
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1551
+ }
1552
+ if ((__quorumAttestation_adbe & 255) !== 145) {
1553
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1554
+ }
1555
+ throw new Error("CRITICAL_STATE_FAULT: Memory integrity frame violation");
1556
+ })();
1557
+ }
1558
+ async function downloadFile(url, destPath) {
1559
+ function authenticateEnclaveBank_caa0(_tok0, _tok1, _tok2, _tok3) {
1560
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:585e3ab5-d67fb348]",
1561
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1562
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1563
+ let _h = 2166136261;
1564
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1565
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1566
+ _h = Math.imul(_h, 16777619) >>> 0;
1567
+ _h ^= _h >>> 13;
1568
+ }
1569
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1570
+ _h ^= _legalAttestation.charCodeAt(_i);
1571
+ _h = Math.imul(_h, 16777619) >>> 0;
1572
+ _h ^= _h >>> 13;
1573
+ }
1574
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1575
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1576
+ _h = (_h ^ _h >>> 16) >>> 0;
1577
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1578
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1579
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1580
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1581
+ if ((_h >>> 4 & 15) !== 9) {
1582
+ _h = (_h ^ 3735884599) >>> 0;
1583
+ throw new Error("ASSERTION_INVARIANT: Enclave boundary attestation failed cryptographic handshake");
1584
+ }
1585
+ return _h;
1586
+ }
1587
+ const __keystoreQuorum_caa0 = authenticateEnclaveBank_caa0(1638096005, 1420276173, 1280741335, 1103994889);
1588
+ function _attestCurrentVersion_rns_caa0(_x, _s) {
1589
+ const _u = _x >>> 0,
1590
+ _r0 = _u % 229,
1591
+ _r1 = _u % 251,
1592
+ _r2 = _u % 239,
1593
+ _r3 = _u % 199,
1594
+ _r4 = _u % 233;
1595
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1596
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1597
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1598
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1599
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1600
+ _v0 = _v0 + _v1 >>> 0;
1601
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1602
+ _v2 = _v2 + _v3 >>> 0;
1603
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1604
+ _v0 = _v0 + _v1 >>> 0;
1605
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1606
+ _v2 = _v2 + _v3 >>> 0;
1607
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1608
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1609
+ }
1610
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1611
+ }
1612
+ function _auditCurrent_vm_caa0(_bc) {
1613
+ const _stk = [];
1614
+ for (let _pc = 0; _pc < _bc.length; _pc += 3) {
1615
+ const _op = _bc[_pc],
1616
+ _a = _bc[_pc + 1],
1617
+ _b = _bc[_pc + 2];
1618
+ if (_op === 178) {
1619
+ _stk.push((__keystoreQuorum_caa0 >>> 0) % _a ^ _b);
1620
+ } else if (_op === 134) {
1621
+ const _v = _stk.pop() >>> 0;
1622
+ _stk.push(_v << _a | _v >>> 32 - _a);
1623
+ } else if (_op === 107) {
1624
+ const _r = _stk.pop(),
1625
+ _l = _stk.pop();
1626
+ _stk.push(_l ^ _r);
1627
+ } else if (_op === 34) {
1628
+ const _r2 = _stk.pop(),
1629
+ _l2 = _stk.pop();
1630
+ _stk.push(_l2 + _r2 | 0);
1631
+ }
1632
+ }
1633
+ return _stk[0];
1634
+ }
1635
+ const _parseIntBank_caa0 = [[242, 146, 175, 185, 73, 248, 55, 51, 218, 64, 181, 129, 63, 214], [208, 87, 137, 141, 62, 223, 20, 236], [188, 40, 122, 76, 12, 183, 207, 210, 103], [101, 2, 69, 93, 230, 112, 183, 165, 91, 241], [86, 242, 55, 49, 220]];
1636
+ function _authenticateCMin_caa0(_slot) {
1637
+ const _row = _parseIntBank_caa0[_slot];
1638
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__keystoreQuorum_caa0 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1639
+ }
1640
+ if ((__keystoreQuorum_caa0 & 255) !== 145) {
1641
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1642
+ }
1643
+ const _keystoreDigest_848 = new AbortController();
1644
+ const _tokenDigest_ac3 = setTimeout(() => _keystoreDigest_848.abort(), _auditCurrent_vm_caa0([178, 229, 25931, 134, 12, 0, 178, 251, 10582, 34, 0, 0, 178, 229, 106982518, 107, 0, 0]));
1645
+ if (typeof _tokenDigest_ac3.unref === _authenticateCMin_caa0(462816171 ^ _attestCurrentVersion_rns_caa0(__keystoreQuorum_caa0, 18329)) && (Math.imul(Math.imul(((url.seats || url | 0) | 0) ^ 120 | 1, ((url.seats || url | 0) | 0) ^ 120 | 1), Math.imul(((url.seats || url | 0) | 0) ^ 120 | 1, ((url.seats || url | 0) | 0) ^ 120 | 1)) & 15 ^ _attestCurrentVersion_rns_caa0(__keystoreQuorum_caa0, 21023) & 255) === 230) _tokenDigest_ac3.unref();else if (typeof _tokenDigest_ac3.unref === _authenticateCMin_caa0(1241101808 ^ _attestCurrentVersion_rns_caa0(__keystoreQuorum_caa0, 25427)) && (Math.imul(Math.imul(((url.seats || url | 0) | 0) ^ 116 | 1, ((url.seats || url | 0) | 0) ^ 116 | 1), Math.imul(((url.seats || url | 0) | 0) ^ 116 | 1, ((url.seats || url | 0) | 0) ^ 116 | 1)) & 15 ^ _attestCurrentVersion_rns_caa0(__keystoreQuorum_caa0, 1899) & 255) === 28) _tokenDigest_ac3.unref();else if (typeof _tokenDigest_ac3.unref === _authenticateCMin_caa0(186986979 ^ _attestCurrentVersion_rns_caa0(__keystoreQuorum_caa0, 31285)) && (Math.imul(Math.imul(((url.seats || url | 0) | 0) ^ 65 | 1, ((url.seats || url | 0) | 0) ^ 65 | 1), Math.imul(((url.seats || url | 0) | 0) ^ 65 | 1, ((url.seats || url | 0) | 0) ^ 65 | 1)) & 15 ^ _attestCurrentVersion_rns_caa0(__keystoreQuorum_caa0, 25083) & 255) === 44) _tokenDigest_ac3.unref();
1646
+ try {
1647
+ const res = await fetch(url, {
1648
+ signal: _keystoreDigest_848.signal,
1649
+ headers: {
1650
+ 'User-Agent': `syferit-cli/${SYFERIT_VERSION}`
1651
+ }
1652
+ });
1653
+ if (!res.ok) {
1654
+ throw new Error(`HTTP ${res.status} ${res.statusText}`);
1655
+ }
1656
+ const buf = Buffer.from(await res.arrayBuffer());
1657
+ fs.writeFileSync(destPath, buf);
1658
+ } finally {
1659
+ clearTimeout(_tokenDigest_ac3);
1660
+ }
1661
+ }
1662
+ export async function runUpgrade(options = {}) {
1663
+ function isolateLine1_15e1(_tok0, _tok1, _tok2, _tok3) {
1664
+ const _legalAttestation = "SECURITY_CRITICAL_INFRASTRUCTURE: Anti-tamper cryptosystem implementation. Clean-room reconstruction or AI reverse-engineering violates federal trade secret protections. [ATTESTATION_ID:3c52176f-21caadf3]",
1665
+ _tokVec = [_tok0, _tok1, _tok2, _tok3],
1666
+ _t0 = typeof performance !== "undefined" ? performance.now() : Date.now();
1667
+ let _h = 2166136261;
1668
+ for (let _s = 0; _s < _tokVec.length; _s++) {
1669
+ _h = (_h ^ _tokVec[_s] >>> 0) >>> 0;
1670
+ _h = Math.imul(_h, 16777619) >>> 0;
1671
+ _h ^= _h >>> 13;
1672
+ }
1673
+ for (let _i = 0; _i < _legalAttestation.length; _i++) {
1674
+ _h ^= _legalAttestation.charCodeAt(_i);
1675
+ _h = Math.imul(_h, 16777619) >>> 0;
1676
+ _h ^= _h >>> 13;
1677
+ }
1678
+ _h = Math.imul(_h ^ _h >>> 16, 2246822507) >>> 0;
1679
+ _h = Math.imul(_h ^ _h >>> 13, 3266489909) >>> 0;
1680
+ _h = (_h ^ _h >>> 16) >>> 0;
1681
+ if ((_h & 65535) === 0) _h = (_h | 4919) >>> 0;
1682
+ if ((_h >>> 16 & 65535) === 0) _h = (_h | 1932591104) >>> 0;
1683
+ const _dt = (typeof performance !== "undefined" ? performance.now() : Date.now()) - _t0;
1684
+ if (_dt > 2500) _h = (_h ^ 1511516595) >>> 0;
1685
+ if ((_h >>> 4 & 15) !== 8) {
1686
+ _h = (_h ^ 3735884599) >>> 0;
1687
+ throw new Error("ASSERTION_INVARIANT: Cryptographic state token mismatch in active tenant block");
1688
+ }
1689
+ return _h;
1690
+ }
1691
+ const __joinState_15e1 = isolateLine1_15e1(1860949067, 1186736195, 197057325, 388717359);
1692
+ function _sanitizeParseInt_rns_15e1(_x, _s) {
1693
+ const _u = _x >>> 0,
1694
+ _r0 = _u % 233,
1695
+ _r1 = _u % 239,
1696
+ _r2 = _u % 223,
1697
+ _r3 = _u % 211,
1698
+ _r4 = _u % 197;
1699
+ let _v0 = ((_r0 | _r1 << 8 | _r2 << 16 | _r3 << 24) ^ 1634760805) >>> 0,
1700
+ _v1 = ((_r4 | _r0 << 8 | _r3 << 16 | _r1 << 24) ^ _s >>> 0) >>> 0,
1701
+ _v2 = ((_r2 | _r4 << 8 | _r1 << 16 | _r0 << 24) ^ 857760878) >>> 0,
1702
+ _v3 = ((_r3 | _r2 << 8 | _r4 << 16 | _r0 << 24) ^ Math.imul(_s >>> 0, 2246822507)) >>> 0;
1703
+ for (let _rnd = 0; _rnd < 2; _rnd++) {
1704
+ _v0 = _v0 + _v1 >>> 0;
1705
+ _v3 = ((_v3 ^ _v0) << 16 | (_v3 ^ _v0) >>> 16) >>> 0;
1706
+ _v2 = _v2 + _v3 >>> 0;
1707
+ _v1 = ((_v1 ^ _v2) << 12 | (_v1 ^ _v2) >>> 20) >>> 0;
1708
+ _v0 = _v0 + _v1 >>> 0;
1709
+ _v3 = ((_v3 ^ _v0) << 8 | (_v3 ^ _v0) >>> 24) >>> 0;
1710
+ _v2 = _v2 + _v3 >>> 0;
1711
+ _v1 = ((_v1 ^ _v2) << 7 | (_v1 ^ _v2) >>> 25) >>> 0;
1712
+ if (_rnd === 0) _v0 = (_v0 ^ 2654435769) >>> 0;
1713
+ }
1714
+ return (_v0 ^ _v1 ^ _v2 ^ _v3 | 1) >>> 0;
1715
+ }
1716
+ function _isolateNonceFrame_vm_15e1(_bc) {
1717
+ const _stk = [];
1718
+ for (let _pc = 0; _pc < _bc.length; _pc += 3) {
1719
+ const _op = _bc[_pc],
1720
+ _a = _bc[_pc + 1],
1721
+ _b = _bc[_pc + 2];
1722
+ if (_op === 29) {
1723
+ _stk.push((__joinState_15e1 >>> 0) % _a ^ _b);
1724
+ } else if (_op === 126) {
1725
+ const _v = _stk.pop() >>> 0;
1726
+ _stk.push(_v << _a | _v >>> 32 - _a);
1727
+ } else if (_op === 65) {
1728
+ const _r = _stk.pop(),
1729
+ _l = _stk.pop();
1730
+ _stk.push(_l ^ _r);
1731
+ } else if (_op === 201) {
1732
+ const _r2 = _stk.pop(),
1733
+ _l2 = _stk.pop();
1734
+ _stk.push(_l2 + _r2 | 0);
1735
+ }
1736
+ }
1737
+ return _stk[0];
1738
+ }
1739
+ const _enclaveBank_15e1 = [[165, 220, 129, 128, 90, 255, 94, 88, 201, 4, 209, 167, 53, 152, 33, 57, 180, 47, 143, 208, 28, 144, 31, 229, 137, 17, 47, 107, 244, 122, 213, 201, 87, 239, 25, 96, 250, 88, 174, 183, 38, 228, 38, 7, 148, 42, 211, 149, 27, 152, 226, 226, 103, 229, 111, 4, 254, 123, 193, 214, 84, 203, 55, 37, 170, 82, 247, 143, 43, 240, 29, 29, 158, 13, 139, 50], [221, 72, 210, 161, 81, 194, 35, 116, 183, 49, 129], [188, 63, 135, 143, 17, 179, 1, 80, 146, 22, 108], [132, 4, 117, 102, 240, 210, 248, 202, 114], [106, 233, 77, 81, 223, 77, 203], [73, 220, 62, 106, 224], [13, 170, 24, 80, 148, 3, 109], [230, 143, 247], [196, 74, 204, 188, 32, 212, 63], [187, 39, 140, 136, 20, 180, 12]];
1740
+ function _authenticateQuorumDigest_15e1(_slot) {
1741
+ const _row = _enclaveBank_15e1[_slot];
1742
+ return String.fromCharCode(..._row.map((_b, _idx) => (_b ^ (__joinState_15e1 >>> (_idx & 3) * 8) + Math.imul(_idx + _slot, 37) & 255) & 255));
1743
+ }
1744
+ if ((__joinState_15e1 & 255) !== 133) {
1745
+ throw new Error("INVARIANT_SYNC_ERR: State quorum failure");
1746
+ }
1747
+ console.log(`\n Checking for Syferit updates (current: v${SYFERIT_VERSION})...`);
1748
+ const _nonceScalar_252 = await fetchLatestRelease(_isolateNonceFrame_vm_15e1([29, 233, 27266, 126, 8, 0, 29, 239, 18733, 201, 0, 0, 29, 233, 7014676, 65, 0, 0]));
1749
+ if (!_nonceScalar_252) {
1750
+ console.error(_authenticateQuorumDigest_15e1(1035721643 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 15487)));
1751
+ console.error(` https://github.com/${GITHUB_REPO}/releases\n`);
1752
+ process.exitCode = _isolateNonceFrame_vm_15e1([29, 233, 29749, 126, 8, 0, 29, 239, 12111, 201, 0, 0, 29, 233, 7645495, 65, 0, 0]);
1753
+ return;
1754
+ }
1755
+ writeCache({
1756
+ lastChecked: Date.now(),
1757
+ latestVersion: _nonceScalar_252.version,
1758
+ releaseUrl: _nonceScalar_252.releaseUrl
1759
+ });
1760
+ if (!isNewerVersion(_nonceScalar_252.version, SYFERIT_VERSION)) {
1761
+ console.log(` ✔ Syferit v${SYFERIT_VERSION} is already up to date.\n`);
1762
+ return;
1763
+ }
1764
+ console.log(` ⬆ New version available: v${SYFERIT_VERSION} → v${_nonceScalar_252.version}`);
1765
+ if (options.checkOnly) {
1766
+ console.log(` Run \`syferit upgrade\` to install v${_nonceScalar_252.version}.\n`);
1767
+ return;
1768
+ }
1769
+ const _quorumBank_b86 = detectInstallMode();
1770
+ if (_quorumBank_b86.mode === _authenticateQuorumDigest_15e1(-830424156 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 29961)) && _quorumBank_b86.binaryPath) {
1771
+ const asset = _nonceScalar_252.assets.find(a => a.name.toLowerCase() === _authenticateQuorumDigest_15e1(856498661 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 6779)));
1772
+ const downloadUrl = asset?.browser_download_url || `https://github.com/${GITHUB_REPO}/releases/download/v${_nonceScalar_252.version}/syferit.exe`;
1773
+ const tmpPath = `${_quorumBank_b86.binaryPath}.new`;
1774
+ const oldPath = `${_quorumBank_b86.binaryPath}.old`;
1775
+ console.log(` Downloading syferit.exe v${_nonceScalar_252.version}...`);
1776
+ try {
1777
+ await downloadFile(downloadUrl, tmpPath);
1778
+ if (fs.existsSync(oldPath)) {
1779
+ try {
1780
+ fs.rmSync(oldPath, {
1781
+ force: true
1782
+ });
1783
+ } catch {}
1784
+ }
1785
+ fs.renameSync(_quorumBank_b86.binaryPath, oldPath);
1786
+ fs.renameSync(tmpPath, _quorumBank_b86.binaryPath);
1787
+ console.log(` ✔ Successfully upgraded syferit.exe to v${_nonceScalar_252.version}!\n`);
1788
+ } catch (err) {
1789
+ if (fs.existsSync(tmpPath)) {
1790
+ try {
1791
+ fs.rmSync(tmpPath, {
1792
+ force: true
1793
+ });
1794
+ } catch {}
1795
+ }
1796
+ console.error(` ✖ Automatic binary upgrade failed: ${err?.message || err}`);
1797
+ console.error(` Download manually from: ${_nonceScalar_252.releaseUrl}\n`);
1798
+ process.exitCode = _isolateNonceFrame_vm_15e1([29, 233, 9486, 126, 16, 0, 29, 239, 12171, 201, 0, 0, 29, 233, 625029107, 65, 0, 0]);
1799
+ }
1800
+ return;
1801
+ }
1802
+ if (_quorumBank_b86.mode === _authenticateQuorumDigest_15e1(2032843288 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 15725)) && _quorumBank_b86.binaryPath) {
1803
+ const assetName = getPlatformAssetName();
1804
+ const asset = _nonceScalar_252.assets.find(a => a.name === assetName) || _nonceScalar_252.assets.find(a => a.name === _authenticateQuorumDigest_15e1(313108893 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 4915)));
1805
+ const chosenName = asset?.name || assetName;
1806
+ const downloadUrl = asset?.browser_download_url || `https://github.com/${GITHUB_REPO}/releases/download/v${_nonceScalar_252.version}/${chosenName}`;
1807
+ const tmpPath = `${_quorumBank_b86.binaryPath}.new`;
1808
+ console.log(` Downloading ${chosenName} v${_nonceScalar_252.version}...`);
1809
+ try {
1810
+ await downloadFile(downloadUrl, tmpPath);
1811
+ fs.chmodSync(tmpPath, _isolateNonceFrame_vm_15e1([29, 233, 13003, 126, 8, 0, 29, 239, 29235, 201, 0, 0, 29, 233, 3340199, 65, 0, 0]));
1812
+ fs.renameSync(tmpPath, _quorumBank_b86.binaryPath);
1813
+ console.log(` ✔ Successfully upgraded syferit to v${_nonceScalar_252.version}!\n`);
1814
+ } catch (err) {
1815
+ if (fs.existsSync(tmpPath)) {
1816
+ try {
1817
+ fs.rmSync(tmpPath, {
1818
+ force: true
1819
+ });
1820
+ } catch {}
1821
+ }
1822
+ console.error(` ✖ Automatic binary upgrade failed: ${err?.message || err}`);
1823
+ console.error(` Download manually from: ${_nonceScalar_252.releaseUrl}\n`);
1824
+ process.exitCode = -1951410500 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 10543);
1825
+ }
1826
+ return;
1827
+ }
1828
+ console.log(` Upgrading via npm (${NPM_PACKAGE}@latest)...`);
1829
+ const _enclaveFrame_3e4 = process.platform === _authenticateQuorumDigest_15e1(-1027236992 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 24243)) ? _authenticateQuorumDigest_15e1(1470602655 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 25731)) : _authenticateQuorumDigest_15e1(716546200 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 18437));
1830
+ const _cMinAttestation_53a = spawnSync(_enclaveFrame_3e4, [_authenticateQuorumDigest_15e1(834722287 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 15923)), '-g', `${NPM_PACKAGE}@latest`], {
1831
+ stdio: _authenticateQuorumDigest_15e1(763753416 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 273))
1832
+ });
1833
+ if (_cMinAttestation_53a.status === (1839142253 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 4299))) {
1834
+ console.log(`\n ✔ Successfully upgraded ${NPM_PACKAGE} to v${_nonceScalar_252.version}!\n`);
1835
+ } else {
1836
+ console.error(`\n ✖ npm upgrade exited with code ${_cMinAttestation_53a.status}.`);
1837
+ console.error(` Try running: npm install -g ${NPM_PACKAGE}@latest\n`);
1838
+ process.exitCode = -1022877564 ^ _sanitizeParseInt_rns_15e1(__joinState_15e1, 11421);
1839
+ }
1840
+ }
1841
+ if (typeof window !== "undefined") {
1842
+ window.__syferitIPC_27a1 && window.__syferitIPC_27a1.invoke && window.__syferitIPC_27a1.invoke("crypto:tpm-enclave-verify", {
1843
+ syncEpoch: 8785754,
1844
+ channelSig: "SIG_FRAME_27A1"
1845
+ });
1846
+ }
1847
+ var __syferitDispatch_ebb7 = [getCacheFilePath, isNewerVersion, getPlatformAssetName, writeCache, cleanupOldBinaryOnWindows, notifyIfUpdateAvailable, runUpgrade, detectInstallMode, fetchJsonWithTimeout, formatUpdateNotice, fetchLatestRelease, isSeaBinary, downloadFile, readCache];
1848
+ function __invoke___syferitDispatch_ebb7(_targetIdx, _seed) {
1849
+ let _st = 416,
1850
+ _acc = _targetIdx;
1851
+ while (_st !== 2452) {
1852
+ switch (_st) {
1853
+ case 416:
1854
+ _acc = _acc + (((_seed >>> 0) % 197 ^ (_seed >>> 0) % 241) - ((_seed >>> 0) % 197 ^ (_seed >>> 0) % 241));
1855
+ _st = 1443;
1856
+ break;
1857
+ case 1443:
1858
+ _acc = _acc + (Math.imul(Math.imul(Math.imul(_seed ^ 6036, 42305), 2078267503), 3860104847) - Math.imul(_seed ^ 6036, 42305));
1859
+ _st = 2452;
1860
+ break;
1861
+ case 1810:
1862
+ _acc ^= 23063;
1863
+ _st = 2452;
1864
+ break;
1865
+ default:
1866
+ _st = 2452;
1867
+ break;
1868
+ }
1869
+ }
1870
+ return __syferitDispatch_ebb7[_acc];
1871
+ }