zigap-utils 0.0.39 → 0.0.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/components/AddressProvideQR/AddressProvideQR.types.d.ts +0 -1
- package/dist/components/LoginQR/LoginQR.types.d.ts +3 -7
- package/dist/index.cjs.js +11 -11
- package/dist/index.es.js +391 -499
- package/dist/util/addressProvide.d.ts +3 -3
- package/dist/util/index.d.ts +2 -2
- package/dist/util/socketService.d.ts +11 -0
- package/dist/util/types.d.ts +1 -4
- package/dist/validation/hashing.d.ts +2 -0
- package/dist/validation/token.d.ts +5 -0
- package/package.json +15 -1
- package/dist/util/test/index.d.ts +0 -1
- package/dist/util/test/test.d.ts +0 -2
- package/dist/util/test2.d.ts +0 -2
- package/dist/xphere/validation.d.ts +0 -10
package/dist/index.es.js
CHANGED
|
@@ -1,24 +1,22 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
var da = Object.defineProperty;
|
|
3
3
|
var ha = (f, e, t) => e in f ? da(f, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : f[e] = t;
|
|
4
|
-
var wt = (f, e, t) =>
|
|
4
|
+
var wt = (f, e, t) => ha(f, typeof e != "symbol" ? e + "" : e, t);
|
|
5
5
|
import * as ua from "react";
|
|
6
|
-
import nr, { useRef as ei, useState as
|
|
6
|
+
import nr, { useRef as ei, useState as qf, useEffect as zt } from "react";
|
|
7
7
|
var Pe = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
8
8
|
function sn(f) {
|
|
9
9
|
return f && f.__esModule && Object.prototype.hasOwnProperty.call(f, "default") ? f.default : f;
|
|
10
10
|
}
|
|
11
11
|
function on(f) {
|
|
12
|
-
if (f.__esModule)
|
|
13
|
-
return f;
|
|
12
|
+
if (f.__esModule) return f;
|
|
14
13
|
var e = f.default;
|
|
15
14
|
if (typeof e == "function") {
|
|
16
15
|
var t = function r() {
|
|
17
16
|
return this instanceof r ? Reflect.construct(e, arguments, this.constructor) : e.apply(this, arguments);
|
|
18
17
|
};
|
|
19
18
|
t.prototype = e.prototype;
|
|
20
|
-
} else
|
|
21
|
-
t = {};
|
|
19
|
+
} else t = {};
|
|
22
20
|
return Object.defineProperty(t, "__esModule", { value: !0 }), Object.keys(f).forEach(function(r) {
|
|
23
21
|
var a = Object.getOwnPropertyDescriptor(f, r);
|
|
24
22
|
Object.defineProperty(t, r, a.get ? a : {
|
|
@@ -42,18 +40,14 @@ const cn = /* @__PURE__ */ on(ua);
|
|
|
42
40
|
*/
|
|
43
41
|
var ti;
|
|
44
42
|
function la() {
|
|
45
|
-
if (ti)
|
|
46
|
-
return Xt;
|
|
43
|
+
if (ti) return Xt;
|
|
47
44
|
ti = 1;
|
|
48
45
|
var f = cn, e = Symbol.for("react.element"), t = Symbol.for("react.fragment"), r = Object.prototype.hasOwnProperty, a = f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
49
46
|
function y(x, u, o) {
|
|
50
47
|
var c, v = {}, b = null, B = null;
|
|
51
48
|
o !== void 0 && (b = "" + o), u.key !== void 0 && (b = "" + u.key), u.ref !== void 0 && (B = u.ref);
|
|
52
|
-
for (c in u)
|
|
53
|
-
|
|
54
|
-
if (x && x.defaultProps)
|
|
55
|
-
for (c in u = x.defaultProps, u)
|
|
56
|
-
v[c] === void 0 && (v[c] = u[c]);
|
|
49
|
+
for (c in u) r.call(u, c) && !i.hasOwnProperty(c) && (v[c] = u[c]);
|
|
50
|
+
if (x && x.defaultProps) for (c in u = x.defaultProps, u) v[c] === void 0 && (v[c] = u[c]);
|
|
57
51
|
return { $$typeof: e, type: x, key: b, ref: B, props: v, _owner: a.current };
|
|
58
52
|
}
|
|
59
53
|
return Xt.Fragment = t, Xt.jsx = y, Xt.jsxs = y, Xt;
|
|
@@ -160,14 +154,14 @@ function xa() {
|
|
|
160
154
|
}
|
|
161
155
|
return null;
|
|
162
156
|
}
|
|
163
|
-
var g = Object.assign, C = 0, F,
|
|
157
|
+
var g = Object.assign, C = 0, F, q, N, D, h, E, j;
|
|
164
158
|
function Y() {
|
|
165
159
|
}
|
|
166
160
|
Y.__reactDisabledLog = !0;
|
|
167
161
|
function W() {
|
|
168
162
|
{
|
|
169
163
|
if (C === 0) {
|
|
170
|
-
F = console.log,
|
|
164
|
+
F = console.log, q = console.info, N = console.warn, D = console.error, h = console.group, E = console.groupCollapsed, j = console.groupEnd;
|
|
171
165
|
var p = {
|
|
172
166
|
configurable: !0,
|
|
173
167
|
enumerable: !0,
|
|
@@ -200,10 +194,10 @@ function xa() {
|
|
|
200
194
|
value: F
|
|
201
195
|
}),
|
|
202
196
|
info: g({}, p, {
|
|
203
|
-
value:
|
|
197
|
+
value: q
|
|
204
198
|
}),
|
|
205
199
|
warn: g({}, p, {
|
|
206
|
-
value:
|
|
200
|
+
value: N
|
|
207
201
|
}),
|
|
208
202
|
error: g({}, p, {
|
|
209
203
|
value: D
|
|
@@ -375,9 +369,9 @@ function xa() {
|
|
|
375
369
|
}
|
|
376
370
|
}
|
|
377
371
|
}
|
|
378
|
-
var
|
|
372
|
+
var qe = Array.isArray;
|
|
379
373
|
function Se(p) {
|
|
380
|
-
return
|
|
374
|
+
return qe(p);
|
|
381
375
|
}
|
|
382
376
|
function F0(p) {
|
|
383
377
|
{
|
|
@@ -399,7 +393,7 @@ function xa() {
|
|
|
399
393
|
if (Je(p))
|
|
400
394
|
return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", F0(p)), f0(p);
|
|
401
395
|
}
|
|
402
|
-
var
|
|
396
|
+
var Ne = z.ReactCurrentOwner, u0 = {
|
|
403
397
|
key: !0,
|
|
404
398
|
ref: !0,
|
|
405
399
|
__self: !0,
|
|
@@ -423,12 +417,12 @@ function xa() {
|
|
|
423
417
|
return p.key !== void 0;
|
|
424
418
|
}
|
|
425
419
|
function r0(p, I) {
|
|
426
|
-
if (typeof p.ref == "string" &&
|
|
427
|
-
var L = d(
|
|
428
|
-
He[L] || (S('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', d(
|
|
420
|
+
if (typeof p.ref == "string" && Ne.current && I && Ne.current.stateNode !== I) {
|
|
421
|
+
var L = d(Ne.current.type);
|
|
422
|
+
He[L] || (S('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', d(Ne.current.type), p.ref), He[L] = !0);
|
|
429
423
|
}
|
|
430
424
|
}
|
|
431
|
-
function
|
|
425
|
+
function q0(p, I) {
|
|
432
426
|
{
|
|
433
427
|
var L = function() {
|
|
434
428
|
G0 || (G0 = !0, S("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", I));
|
|
@@ -492,13 +486,13 @@ function xa() {
|
|
|
492
486
|
}
|
|
493
487
|
if (te || xe) {
|
|
494
488
|
var ve = typeof p == "function" ? p.displayName || p.name || "Unknown" : p;
|
|
495
|
-
te &&
|
|
489
|
+
te && q0(he, ve), xe && i0(he, ve);
|
|
496
490
|
}
|
|
497
|
-
return s0(p, te, xe, ne, V,
|
|
491
|
+
return s0(p, te, xe, ne, V, Ne.current, he);
|
|
498
492
|
}
|
|
499
493
|
}
|
|
500
494
|
var e0 = z.ReactCurrentOwner, n0 = z.ReactDebugCurrentFrame;
|
|
501
|
-
function
|
|
495
|
+
function N0(p) {
|
|
502
496
|
if (p) {
|
|
503
497
|
var I = p._owner, L = Ge(p.type, p._source, I ? I.type : null);
|
|
504
498
|
n0.setExtraStackFrame(L);
|
|
@@ -548,7 +542,7 @@ Check the top-level render call using <` + L + ">.");
|
|
|
548
542
|
return;
|
|
549
543
|
Ve[L] = !0;
|
|
550
544
|
var V = "";
|
|
551
|
-
p && p._owner && p._owner !== e0.current && (V = " It was passed a child from " + d(p._owner.type) + "."),
|
|
545
|
+
p && p._owner && p._owner !== e0.current && (V = " It was passed a child from " + d(p._owner.type) + "."), N0(p), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', L, V), N0(null);
|
|
552
546
|
}
|
|
553
547
|
}
|
|
554
548
|
function d0(p, I) {
|
|
@@ -600,11 +594,11 @@ Check the top-level render call using <` + L + ">.");
|
|
|
600
594
|
for (var I = Object.keys(p.props), L = 0; L < I.length; L++) {
|
|
601
595
|
var V = I[L];
|
|
602
596
|
if (V !== "children" && V !== "key") {
|
|
603
|
-
|
|
597
|
+
N0(p), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", V), N0(null);
|
|
604
598
|
break;
|
|
605
599
|
}
|
|
606
600
|
}
|
|
607
|
-
p.ref !== null && (
|
|
601
|
+
p.ref !== null && (N0(p), S("Invalid attribute `ref` supplied to `React.Fragment`."), N0(null));
|
|
608
602
|
}
|
|
609
603
|
}
|
|
610
604
|
var Re = {};
|
|
@@ -1176,7 +1170,7 @@ function ln(f) {
|
|
|
1176
1170
|
"includeMargin",
|
|
1177
1171
|
"style",
|
|
1178
1172
|
"imageSettings"
|
|
1179
|
-
]), v = o == null ? void 0 : o.src, b = ei(null), B = ei(null), [w, R] =
|
|
1173
|
+
]), v = o == null ? void 0 : o.src, b = ei(null), B = ei(null), [w, R] = qf(!1);
|
|
1180
1174
|
zt(() => {
|
|
1181
1175
|
if (b.current != null) {
|
|
1182
1176
|
const S = b.current, P = S.getContext("2d");
|
|
@@ -2070,7 +2064,7 @@ function Ra() {
|
|
|
2070
2064
|
});
|
|
2071
2065
|
}(zr)), zr.exports;
|
|
2072
2066
|
}
|
|
2073
|
-
var
|
|
2067
|
+
var qr = { exports: {} }, ci;
|
|
2074
2068
|
function Rt() {
|
|
2075
2069
|
return ci || (ci = 1, function(f, e) {
|
|
2076
2070
|
(function(t, r) {
|
|
@@ -2143,9 +2137,9 @@ function Rt() {
|
|
|
2143
2137
|
}
|
|
2144
2138
|
}(), t.enc.Base64;
|
|
2145
2139
|
});
|
|
2146
|
-
}(
|
|
2140
|
+
}(qr)), qr.exports;
|
|
2147
2141
|
}
|
|
2148
|
-
var
|
|
2142
|
+
var Nr = { exports: {} }, di;
|
|
2149
2143
|
function ka() {
|
|
2150
2144
|
return di || (di = 1, function(f, e) {
|
|
2151
2145
|
(function(t, r) {
|
|
@@ -2225,7 +2219,7 @@ function ka() {
|
|
|
2225
2219
|
}
|
|
2226
2220
|
}(), t.enc.Base64url;
|
|
2227
2221
|
});
|
|
2228
|
-
}(
|
|
2222
|
+
}(Nr)), Nr.exports;
|
|
2229
2223
|
}
|
|
2230
2224
|
var Lr = { exports: {} }, hi;
|
|
2231
2225
|
function kt() {
|
|
@@ -2253,8 +2247,8 @@ function kt() {
|
|
|
2253
2247
|
var S = k + z, P = R[S];
|
|
2254
2248
|
R[S] = (P << 8 | P >>> 24) & 16711935 | (P << 24 | P >>> 8) & 4278255360;
|
|
2255
2249
|
}
|
|
2256
|
-
var T = this._hash.words, H = R[k + 0], $ = R[k + 1], K = R[k + 2], X = R[k + 3], Q = R[k + 4], U = R[k + 5], A = R[k + 6], n = R[k + 7], d = R[k + 8], g = R[k + 9], C = R[k + 10], F = R[k + 11],
|
|
2257
|
-
E = v(E, j, Y, W, H, 7, o[0]), W = v(W, E, j, Y, $, 12, o[1]), Y = v(Y, W, E, j, K, 17, o[2]), j = v(j, Y, W, E, X, 22, o[3]), E = v(E, j, Y, W, Q, 7, o[4]), W = v(W, E, j, Y, U, 12, o[5]), Y = v(Y, W, E, j, A, 17, o[6]), j = v(j, Y, W, E, n, 22, o[7]), E = v(E, j, Y, W, d, 7, o[8]), W = v(W, E, j, Y, g, 12, o[9]), Y = v(Y, W, E, j, C, 17, o[10]), j = v(j, Y, W, E, F, 22, o[11]), E = v(E, j, Y, W,
|
|
2250
|
+
var T = this._hash.words, H = R[k + 0], $ = R[k + 1], K = R[k + 2], X = R[k + 3], Q = R[k + 4], U = R[k + 5], A = R[k + 6], n = R[k + 7], d = R[k + 8], g = R[k + 9], C = R[k + 10], F = R[k + 11], q = R[k + 12], N = R[k + 13], D = R[k + 14], h = R[k + 15], E = T[0], j = T[1], Y = T[2], W = T[3];
|
|
2251
|
+
E = v(E, j, Y, W, H, 7, o[0]), W = v(W, E, j, Y, $, 12, o[1]), Y = v(Y, W, E, j, K, 17, o[2]), j = v(j, Y, W, E, X, 22, o[3]), E = v(E, j, Y, W, Q, 7, o[4]), W = v(W, E, j, Y, U, 12, o[5]), Y = v(Y, W, E, j, A, 17, o[6]), j = v(j, Y, W, E, n, 22, o[7]), E = v(E, j, Y, W, d, 7, o[8]), W = v(W, E, j, Y, g, 12, o[9]), Y = v(Y, W, E, j, C, 17, o[10]), j = v(j, Y, W, E, F, 22, o[11]), E = v(E, j, Y, W, q, 7, o[12]), W = v(W, E, j, Y, N, 12, o[13]), Y = v(Y, W, E, j, D, 17, o[14]), j = v(j, Y, W, E, h, 22, o[15]), E = b(E, j, Y, W, $, 5, o[16]), W = b(W, E, j, Y, A, 9, o[17]), Y = b(Y, W, E, j, F, 14, o[18]), j = b(j, Y, W, E, H, 20, o[19]), E = b(E, j, Y, W, U, 5, o[20]), W = b(W, E, j, Y, C, 9, o[21]), Y = b(Y, W, E, j, h, 14, o[22]), j = b(j, Y, W, E, Q, 20, o[23]), E = b(E, j, Y, W, g, 5, o[24]), W = b(W, E, j, Y, D, 9, o[25]), Y = b(Y, W, E, j, X, 14, o[26]), j = b(j, Y, W, E, d, 20, o[27]), E = b(E, j, Y, W, N, 5, o[28]), W = b(W, E, j, Y, K, 9, o[29]), Y = b(Y, W, E, j, n, 14, o[30]), j = b(j, Y, W, E, q, 20, o[31]), E = B(E, j, Y, W, U, 4, o[32]), W = B(W, E, j, Y, d, 11, o[33]), Y = B(Y, W, E, j, F, 16, o[34]), j = B(j, Y, W, E, D, 23, o[35]), E = B(E, j, Y, W, $, 4, o[36]), W = B(W, E, j, Y, Q, 11, o[37]), Y = B(Y, W, E, j, n, 16, o[38]), j = B(j, Y, W, E, C, 23, o[39]), E = B(E, j, Y, W, N, 4, o[40]), W = B(W, E, j, Y, H, 11, o[41]), Y = B(Y, W, E, j, X, 16, o[42]), j = B(j, Y, W, E, A, 23, o[43]), E = B(E, j, Y, W, g, 4, o[44]), W = B(W, E, j, Y, q, 11, o[45]), Y = B(Y, W, E, j, h, 16, o[46]), j = B(j, Y, W, E, K, 23, o[47]), E = w(E, j, Y, W, H, 6, o[48]), W = w(W, E, j, Y, n, 10, o[49]), Y = w(Y, W, E, j, D, 15, o[50]), j = w(j, Y, W, E, U, 21, o[51]), E = w(E, j, Y, W, q, 6, o[52]), W = w(W, E, j, Y, X, 10, o[53]), Y = w(Y, W, E, j, C, 15, o[54]), j = w(j, Y, W, E, $, 21, o[55]), E = w(E, j, Y, W, d, 6, o[56]), W = w(W, E, j, Y, h, 10, o[57]), Y = w(Y, W, E, j, A, 15, o[58]), j = w(j, Y, W, E, N, 21, o[59]), E = w(E, j, Y, W, Q, 6, o[60]), W = w(W, E, j, Y, F, 10, o[61]), Y = w(Y, W, E, j, K, 15, o[62]), j = w(j, Y, W, E, g, 21, o[63]), T[0] = T[0] + E | 0, T[1] = T[1] + j | 0, T[2] = T[2] + Y | 0, T[3] = T[3] + W | 0;
|
|
2258
2252
|
},
|
|
2259
2253
|
_doFinalize: function() {
|
|
2260
2254
|
var R = this._data, k = R.words, z = this._nDataBytes * 8, S = R.sigBytes * 8;
|
|
@@ -2338,7 +2332,7 @@ function bn() {
|
|
|
2338
2332
|
}(Hr)), Hr.exports;
|
|
2339
2333
|
}
|
|
2340
2334
|
var Ur = { exports: {} }, li;
|
|
2341
|
-
function
|
|
2335
|
+
function Nf() {
|
|
2342
2336
|
return li || (li = 1, function(f, e) {
|
|
2343
2337
|
(function(t, r) {
|
|
2344
2338
|
f.exports = r($e());
|
|
@@ -2370,8 +2364,8 @@ function qf() {
|
|
|
2370
2364
|
var Q = v[X - 15], U = (Q << 25 | Q >>> 7) ^ (Q << 14 | Q >>> 18) ^ Q >>> 3, A = v[X - 2], n = (A << 15 | A >>> 17) ^ (A << 13 | A >>> 19) ^ A >>> 10;
|
|
2371
2365
|
v[X] = U + v[X - 7] + n + v[X - 16];
|
|
2372
2366
|
}
|
|
2373
|
-
var d = T & H ^ ~T & $, g = k & z ^ k & S ^ z & S, C = (k << 30 | k >>> 2) ^ (k << 19 | k >>> 13) ^ (k << 10 | k >>> 22), F = (T << 26 | T >>> 6) ^ (T << 21 | T >>> 11) ^ (T << 7 | T >>> 25),
|
|
2374
|
-
K = $, $ = H, H = T, T = P +
|
|
2367
|
+
var d = T & H ^ ~T & $, g = k & z ^ k & S ^ z & S, C = (k << 30 | k >>> 2) ^ (k << 19 | k >>> 13) ^ (k << 10 | k >>> 22), F = (T << 26 | T >>> 6) ^ (T << 21 | T >>> 11) ^ (T << 7 | T >>> 25), q = K + F + d + c[X] + v[X], N = C + g;
|
|
2368
|
+
K = $, $ = H, H = T, T = P + q | 0, P = S, S = z, z = k, k = q + N | 0;
|
|
2375
2369
|
}
|
|
2376
2370
|
R[0] = R[0] + k | 0, R[1] = R[1] + z | 0, R[2] = R[2] + S | 0, R[3] = R[3] + P | 0, R[4] = R[4] + T | 0, R[5] = R[5] + H | 0, R[6] = R[6] + $ | 0, R[7] = R[7] + K | 0;
|
|
2377
2371
|
},
|
|
@@ -2393,7 +2387,7 @@ var $r = { exports: {} }, xi;
|
|
|
2393
2387
|
function Pa() {
|
|
2394
2388
|
return xi || (xi = 1, function(f, e) {
|
|
2395
2389
|
(function(t, r, a) {
|
|
2396
|
-
f.exports = r($e(),
|
|
2390
|
+
f.exports = r($e(), Nf());
|
|
2397
2391
|
})(Pe, function(t) {
|
|
2398
2392
|
return function() {
|
|
2399
2393
|
var r = t, a = r.lib, i = a.WordArray, y = r.algo, x = y.SHA256, u = y.SHA224 = x.extend({
|
|
@@ -2530,18 +2524,18 @@ function pn() {
|
|
|
2530
2524
|
]);
|
|
2531
2525
|
},
|
|
2532
2526
|
_doProcessBlock: function(w, R) {
|
|
2533
|
-
for (var k = this._hash.words, z = k[0], S = k[1], P = k[2], T = k[3], H = k[4], $ = k[5], K = k[6], X = k[7], Q = z.high, U = z.low, A = S.high, n = S.low, d = P.high, g = P.low, C = T.high, F = T.low,
|
|
2534
|
-
var Se, F0, Je = b[
|
|
2535
|
-
if (
|
|
2536
|
-
F0 = Je.high = w[R +
|
|
2527
|
+
for (var k = this._hash.words, z = k[0], S = k[1], P = k[2], T = k[3], H = k[4], $ = k[5], K = k[6], X = k[7], Q = z.high, U = z.low, A = S.high, n = S.low, d = P.high, g = P.low, C = T.high, F = T.low, q = H.high, N = H.low, D = $.high, h = $.low, E = K.high, j = K.low, Y = X.high, W = X.low, re = Q, ce = U, we = A, Ae = n, Me = d, Fe = g, Z0 = C, We = F, Oe = q, _0 = N, Ge = D, Ye = h, $0 = E, Qe = j, ze = Y, O0 = W, qe = 0; qe < 80; qe++) {
|
|
2528
|
+
var Se, F0, Je = b[qe];
|
|
2529
|
+
if (qe < 16)
|
|
2530
|
+
F0 = Je.high = w[R + qe * 2] | 0, Se = Je.low = w[R + qe * 2 + 1] | 0;
|
|
2537
2531
|
else {
|
|
2538
|
-
var f0 = b[
|
|
2532
|
+
var f0 = b[qe - 15], S0 = f0.high, Ne = f0.low, u0 = (S0 >>> 1 | Ne << 31) ^ (S0 >>> 8 | Ne << 24) ^ S0 >>> 7, G0 = (Ne >>> 1 | S0 << 31) ^ (Ne >>> 8 | S0 << 24) ^ (Ne >>> 7 | S0 << 25), l0 = b[qe - 2], He = l0.high, z0 = l0.low, a0 = (He >>> 19 | z0 << 13) ^ (He << 3 | z0 >>> 29) ^ He >>> 6, r0 = (z0 >>> 19 | He << 13) ^ (z0 << 3 | He >>> 29) ^ (z0 >>> 6 | He << 26), q0 = b[qe - 7], i0 = q0.high, s0 = q0.low, W0 = b[qe - 16], e0 = W0.high, n0 = W0.low;
|
|
2539
2533
|
Se = G0 + s0, F0 = u0 + i0 + (Se >>> 0 < G0 >>> 0 ? 1 : 0), Se = Se + r0, F0 = F0 + a0 + (Se >>> 0 < r0 >>> 0 ? 1 : 0), Se = Se + n0, F0 = F0 + e0 + (Se >>> 0 < n0 >>> 0 ? 1 : 0), Je.high = F0, Je.low = Se;
|
|
2540
2534
|
}
|
|
2541
|
-
var
|
|
2535
|
+
var N0 = Oe & Ge ^ ~Oe & $0, o0 = _0 & Ye ^ ~_0 & Qe, x0 = re & we ^ re & Me ^ we & Me, D0 = ce & Ae ^ ce & Fe ^ Ae & Fe, t0 = (re >>> 28 | ce << 4) ^ (re << 30 | ce >>> 2) ^ (re << 25 | ce >>> 7), Ve = (ce >>> 28 | re << 4) ^ (ce << 30 | re >>> 2) ^ (ce << 25 | re >>> 7), tt = (Oe >>> 14 | _0 << 18) ^ (Oe >>> 18 | _0 << 14) ^ (Oe << 23 | _0 >>> 9), c0 = (_0 >>> 14 | Oe << 18) ^ (_0 >>> 18 | Oe << 14) ^ (_0 << 23 | Oe >>> 9), d0 = v[qe], yt = d0.high, Ie = d0.low, Re = O0 + c0, l = ze + tt + (Re >>> 0 < O0 >>> 0 ? 1 : 0), Re = Re + o0, l = l + N0 + (Re >>> 0 < o0 >>> 0 ? 1 : 0), Re = Re + Ie, l = l + yt + (Re >>> 0 < Ie >>> 0 ? 1 : 0), Re = Re + Se, l = l + F0 + (Re >>> 0 < Se >>> 0 ? 1 : 0), _ = Ve + D0, m = t0 + x0 + (_ >>> 0 < Ve >>> 0 ? 1 : 0);
|
|
2542
2536
|
ze = $0, O0 = Qe, $0 = Ge, Qe = Ye, Ge = Oe, Ye = _0, _0 = We + Re | 0, Oe = Z0 + l + (_0 >>> 0 < We >>> 0 ? 1 : 0) | 0, Z0 = Me, We = Fe, Me = we, Fe = Ae, we = re, Ae = ce, ce = Re + _ | 0, re = l + m + (ce >>> 0 < Re >>> 0 ? 1 : 0) | 0;
|
|
2543
2537
|
}
|
|
2544
|
-
U = z.low = U + ce, z.high = Q + re + (U >>> 0 < ce >>> 0 ? 1 : 0), n = S.low = n + Ae, S.high = A + we + (n >>> 0 < Ae >>> 0 ? 1 : 0), g = P.low = g + Fe, P.high = d + Me + (g >>> 0 < Fe >>> 0 ? 1 : 0), F = T.low = F + We, T.high = C + Z0 + (F >>> 0 < We >>> 0 ? 1 : 0),
|
|
2538
|
+
U = z.low = U + ce, z.high = Q + re + (U >>> 0 < ce >>> 0 ? 1 : 0), n = S.low = n + Ae, S.high = A + we + (n >>> 0 < Ae >>> 0 ? 1 : 0), g = P.low = g + Fe, P.high = d + Me + (g >>> 0 < Fe >>> 0 ? 1 : 0), F = T.low = F + We, T.high = C + Z0 + (F >>> 0 < We >>> 0 ? 1 : 0), N = H.low = N + _0, H.high = q + Oe + (N >>> 0 < _0 >>> 0 ? 1 : 0), h = $.low = h + Ye, $.high = D + Ge + (h >>> 0 < Ye >>> 0 ? 1 : 0), j = K.low = j + Qe, K.high = E + $0 + (j >>> 0 < Qe >>> 0 ? 1 : 0), W = X.low = W + O0, X.high = Y + ze + (W >>> 0 < O0 >>> 0 ? 1 : 0);
|
|
2545
2539
|
},
|
|
2546
2540
|
_doFinalize: function() {
|
|
2547
2541
|
var w = this._data, R = w.words, k = this._nDataBytes * 8, z = w.sigBytes * 8;
|
|
@@ -2657,21 +2651,21 @@ function Ta() {
|
|
|
2657
2651
|
d.high = U, d.low = A;
|
|
2658
2652
|
}
|
|
2659
2653
|
for (var Q = 0; Q < 5; Q++)
|
|
2660
|
-
for (var g = w[(Q + 4) % 5], C = w[(Q + 1) % 5], F = C.high,
|
|
2654
|
+
for (var g = w[(Q + 4) % 5], C = w[(Q + 1) % 5], F = C.high, q = C.low, U = g.high ^ (F << 1 | q >>> 31), A = g.low ^ (q << 1 | F >>> 31), n = 0; n < 5; n++) {
|
|
2661
2655
|
var K = S[Q + 5 * n];
|
|
2662
2656
|
K.high ^= U, K.low ^= A;
|
|
2663
2657
|
}
|
|
2664
|
-
for (var
|
|
2665
|
-
var U, A, K = S[
|
|
2658
|
+
for (var N = 1; N < 25; N++) {
|
|
2659
|
+
var U, A, K = S[N], D = K.high, h = K.low, E = v[N];
|
|
2666
2660
|
E < 32 ? (U = D << E | h >>> 32 - E, A = h << E | D >>> 32 - E) : (U = h << E - 32 | D >>> 64 - E, A = D << E - 32 | h >>> 64 - E);
|
|
2667
|
-
var j = w[b[
|
|
2661
|
+
var j = w[b[N]];
|
|
2668
2662
|
j.high = U, j.low = A;
|
|
2669
2663
|
}
|
|
2670
2664
|
var Y = w[0], W = S[0];
|
|
2671
2665
|
Y.high = W.high, Y.low = W.low;
|
|
2672
2666
|
for (var Q = 0; Q < 5; Q++)
|
|
2673
2667
|
for (var n = 0; n < 5; n++) {
|
|
2674
|
-
var
|
|
2668
|
+
var N = Q + 5 * n, K = S[N], re = w[N], ce = w[(Q + 1) % 5 + 5 * n], we = w[(Q + 2) % 5 + 5 * n];
|
|
2675
2669
|
K.high = re.high ^ ~ce.high & we.high, K.low = re.low ^ ~ce.low & we.low;
|
|
2676
2670
|
}
|
|
2677
2671
|
var K = S[0], Ae = B[X];
|
|
@@ -3050,11 +3044,11 @@ function Oa() {
|
|
|
3050
3044
|
var Q = K + X, U = $[Q];
|
|
3051
3045
|
$[Q] = (U << 8 | U >>> 24) & 16711935 | (U << 24 | U >>> 8) & 4278255360;
|
|
3052
3046
|
}
|
|
3053
|
-
var A = this._hash.words, n = B.words, d = w.words, g = o.words, C = c.words, F = v.words,
|
|
3054
|
-
Y =
|
|
3047
|
+
var A = this._hash.words, n = B.words, d = w.words, g = o.words, C = c.words, F = v.words, q = b.words, N, D, h, E, j, Y, W, re, ce, we;
|
|
3048
|
+
Y = N = A[0], W = D = A[1], re = h = A[2], ce = E = A[3], we = j = A[4];
|
|
3055
3049
|
for (var Ae, X = 0; X < 80; X += 1)
|
|
3056
|
-
Ae =
|
|
3057
|
-
Ae = A[1] + h + ce | 0, A[1] = A[2] + E + we | 0, A[2] = A[3] + j + Y | 0, A[3] = A[4] +
|
|
3050
|
+
Ae = N + $[K + g[X]] | 0, X < 16 ? Ae += k(D, h, E) + n[0] : X < 32 ? Ae += z(D, h, E) + n[1] : X < 48 ? Ae += S(D, h, E) + n[2] : X < 64 ? Ae += P(D, h, E) + n[3] : Ae += T(D, h, E) + n[4], Ae = Ae | 0, Ae = H(Ae, F[X]), Ae = Ae + j | 0, N = j, j = E, E = H(h, 10), h = D, D = Ae, Ae = Y + $[K + C[X]] | 0, X < 16 ? Ae += T(W, re, ce) + d[0] : X < 32 ? Ae += P(W, re, ce) + d[1] : X < 48 ? Ae += S(W, re, ce) + d[2] : X < 64 ? Ae += z(W, re, ce) + d[3] : Ae += k(W, re, ce) + d[4], Ae = Ae | 0, Ae = H(Ae, q[X]), Ae = Ae + we | 0, Y = we, we = ce, ce = H(re, 10), re = W, W = Ae;
|
|
3051
|
+
Ae = A[1] + h + ce | 0, A[1] = A[2] + E + we | 0, A[2] = A[3] + j + Y | 0, A[3] = A[4] + N + W | 0, A[4] = A[0] + D + re | 0, A[0] = Ae;
|
|
3058
3052
|
},
|
|
3059
3053
|
_doFinalize: function() {
|
|
3060
3054
|
var $ = this._data, K = $.words, X = this._nDataBytes * 8, Q = $.sigBytes * 8;
|
|
@@ -3175,7 +3169,7 @@ var Xr = { exports: {} }, mi;
|
|
|
3175
3169
|
function za() {
|
|
3176
3170
|
return mi || (mi = 1, function(f, e) {
|
|
3177
3171
|
(function(t, r, a) {
|
|
3178
|
-
f.exports = r($e(),
|
|
3172
|
+
f.exports = r($e(), Nf(), Lf());
|
|
3179
3173
|
})(Pe, function(t) {
|
|
3180
3174
|
return function() {
|
|
3181
3175
|
var r = t, a = r.lib, i = a.Base, y = a.WordArray, x = r.algo, u = x.SHA256, o = x.HMAC, c = x.PBKDF2 = i.extend({
|
|
@@ -3529,8 +3523,8 @@ function C0() {
|
|
|
3529
3523
|
function A(n, d, g) {
|
|
3530
3524
|
var C, F = this._iv;
|
|
3531
3525
|
F ? (C = F, this._iv = r) : C = this._prevBlock;
|
|
3532
|
-
for (var
|
|
3533
|
-
n[d +
|
|
3526
|
+
for (var q = 0; q < g; q++)
|
|
3527
|
+
n[d + q] ^= C[q];
|
|
3534
3528
|
}
|
|
3535
3529
|
return U;
|
|
3536
3530
|
}(), z = a.pad = {}, S = z.Pkcs7 = {
|
|
@@ -3549,8 +3543,8 @@ function C0() {
|
|
|
3549
3543
|
pad: function(U, A) {
|
|
3550
3544
|
for (var n = A * 4, d = n - U.sigBytes % n, g = d << 24 | d << 16 | d << 8 | d, C = [], F = 0; F < d; F += 4)
|
|
3551
3545
|
C.push(g);
|
|
3552
|
-
var
|
|
3553
|
-
U.concat(
|
|
3546
|
+
var q = x.create(C, d);
|
|
3547
|
+
U.concat(q);
|
|
3554
3548
|
},
|
|
3555
3549
|
/**
|
|
3556
3550
|
* Unpads data that had been padded using the algorithm defined in PKCS #5/7.
|
|
@@ -3840,7 +3834,7 @@ function C0() {
|
|
|
3840
3834
|
}(Gr)), Gr.exports;
|
|
3841
3835
|
}
|
|
3842
3836
|
var Qr = { exports: {} }, Ei;
|
|
3843
|
-
function
|
|
3837
|
+
function qa() {
|
|
3844
3838
|
return Ei || (Ei = 1, function(f, e) {
|
|
3845
3839
|
(function(t, r, a) {
|
|
3846
3840
|
f.exports = r($e(), C0());
|
|
@@ -3870,7 +3864,7 @@ function Na() {
|
|
|
3870
3864
|
}(Qr)), Qr.exports;
|
|
3871
3865
|
}
|
|
3872
3866
|
var Jr = { exports: {} }, wi;
|
|
3873
|
-
function
|
|
3867
|
+
function Na() {
|
|
3874
3868
|
return wi || (wi = 1, function(f, e) {
|
|
3875
3869
|
(function(t, r, a) {
|
|
3876
3870
|
f.exports = r($e(), C0());
|
|
@@ -4156,12 +4150,12 @@ function Xa() {
|
|
|
4156
4150
|
P[T + 1] = P[T + 3], P[T + 3] = H;
|
|
4157
4151
|
},
|
|
4158
4152
|
_doCryptBlock: function(P, T, H, $, K, X, Q, U) {
|
|
4159
|
-
for (var A = this._nRounds, n = P[T] ^ H[0], d = P[T + 1] ^ H[1], g = P[T + 2] ^ H[2], C = P[T + 3] ^ H[3], F = 4,
|
|
4160
|
-
var
|
|
4161
|
-
n =
|
|
4153
|
+
for (var A = this._nRounds, n = P[T] ^ H[0], d = P[T + 1] ^ H[1], g = P[T + 2] ^ H[2], C = P[T + 3] ^ H[3], F = 4, q = 1; q < A; q++) {
|
|
4154
|
+
var N = $[n >>> 24] ^ K[d >>> 16 & 255] ^ X[g >>> 8 & 255] ^ Q[C & 255] ^ H[F++], D = $[d >>> 24] ^ K[g >>> 16 & 255] ^ X[C >>> 8 & 255] ^ Q[n & 255] ^ H[F++], h = $[g >>> 24] ^ K[C >>> 16 & 255] ^ X[n >>> 8 & 255] ^ Q[d & 255] ^ H[F++], E = $[C >>> 24] ^ K[n >>> 16 & 255] ^ X[d >>> 8 & 255] ^ Q[g & 255] ^ H[F++];
|
|
4155
|
+
n = N, d = D, g = h, C = E;
|
|
4162
4156
|
}
|
|
4163
|
-
var
|
|
4164
|
-
P[T] =
|
|
4157
|
+
var N = (U[n >>> 24] << 24 | U[d >>> 16 & 255] << 16 | U[g >>> 8 & 255] << 8 | U[C & 255]) ^ H[F++], D = (U[d >>> 24] << 24 | U[g >>> 16 & 255] << 16 | U[C >>> 8 & 255] << 8 | U[n & 255]) ^ H[F++], h = (U[g >>> 24] << 24 | U[C >>> 16 & 255] << 16 | U[n >>> 8 & 255] << 8 | U[d & 255]) ^ H[F++], E = (U[C >>> 24] << 24 | U[n >>> 16 & 255] << 16 | U[d >>> 8 & 255] << 8 | U[g & 255]) ^ H[F++];
|
|
4158
|
+
P[T] = N, P[T + 1] = D, P[T + 2] = h, P[T + 3] = E;
|
|
4165
4159
|
},
|
|
4166
4160
|
keySize: 256 / 32
|
|
4167
4161
|
});
|
|
@@ -5010,9 +5004,9 @@ function Qa() {
|
|
|
5010
5004
|
});
|
|
5011
5005
|
}(lf)), lf.exports;
|
|
5012
5006
|
}
|
|
5013
|
-
var xf = { exports: {} },
|
|
5007
|
+
var xf = { exports: {} }, qi;
|
|
5014
5008
|
function Ja() {
|
|
5015
|
-
return
|
|
5009
|
+
return qi || (qi = 1, function(f, e) {
|
|
5016
5010
|
(function(t, r, a) {
|
|
5017
5011
|
f.exports = r($e(), Rt(), kt(), At(), C0());
|
|
5018
5012
|
})(Pe, function(t) {
|
|
@@ -5074,9 +5068,9 @@ function Ja() {
|
|
|
5074
5068
|
});
|
|
5075
5069
|
}(xf)), xf.exports;
|
|
5076
5070
|
}
|
|
5077
|
-
var vf = { exports: {} },
|
|
5071
|
+
var vf = { exports: {} }, Ni;
|
|
5078
5072
|
function es() {
|
|
5079
|
-
return
|
|
5073
|
+
return Ni || (Ni = 1, function(f, e) {
|
|
5080
5074
|
(function(t, r, a) {
|
|
5081
5075
|
f.exports = r($e(), Rt(), kt(), At(), C0());
|
|
5082
5076
|
})(Pe, function(t) {
|
|
@@ -6198,7 +6192,7 @@ function es() {
|
|
|
6198
6192
|
}
|
|
6199
6193
|
(function(f, e) {
|
|
6200
6194
|
(function(t, r, a) {
|
|
6201
|
-
f.exports = r($e(), _r(), Da(), Ra(), Rt(), ka(), kt(), bn(),
|
|
6195
|
+
f.exports = r($e(), _r(), Da(), Ra(), Rt(), ka(), kt(), bn(), Nf(), Pa(), pn(), Ia(), Ta(), Oa(), Lf(), za(), At(), C0(), qa(), Na(), La(), Ha(), Ua(), $a(), Wa(), Ya(), Ka(), ja(), Va(), Xa(), Za(), Ga(), Qa(), Ja(), es());
|
|
6202
6196
|
})(Pe, function(t) {
|
|
6203
6197
|
return t;
|
|
6204
6198
|
});
|
|
@@ -6267,8 +6261,7 @@ Hf.exports;
|
|
|
6267
6261
|
(function(f) {
|
|
6268
6262
|
(function(e, t) {
|
|
6269
6263
|
function r(A, n) {
|
|
6270
|
-
if (!A)
|
|
6271
|
-
throw new Error(n || "Assertion failed");
|
|
6264
|
+
if (!A) throw new Error(n || "Assertion failed");
|
|
6272
6265
|
}
|
|
6273
6266
|
function a(A, n) {
|
|
6274
6267
|
A.super_ = n;
|
|
@@ -6316,13 +6309,13 @@ Hf.exports;
|
|
|
6316
6309
|
this.length = Math.ceil(n.length / 3), this.words = new Array(this.length);
|
|
6317
6310
|
for (var C = 0; C < this.length; C++)
|
|
6318
6311
|
this.words[C] = 0;
|
|
6319
|
-
var F,
|
|
6312
|
+
var F, q, N = 0;
|
|
6320
6313
|
if (g === "be")
|
|
6321
6314
|
for (C = n.length - 1, F = 0; C >= 0; C -= 3)
|
|
6322
|
-
|
|
6315
|
+
q = n[C] | n[C - 1] << 8 | n[C - 2] << 16, this.words[F] |= q << N & 67108863, this.words[F + 1] = q >>> 26 - N & 67108863, N += 24, N >= 26 && (N -= 26, F++);
|
|
6323
6316
|
else if (g === "le")
|
|
6324
6317
|
for (C = 0, F = 0; C < n.length; C += 3)
|
|
6325
|
-
|
|
6318
|
+
q = n[C] | n[C + 1] << 8 | n[C + 2] << 16, this.words[F] |= q << N & 67108863, this.words[F + 1] = q >>> 26 - N & 67108863, N += 24, N >= 26 && (N -= 26, F++);
|
|
6326
6319
|
return this.strip();
|
|
6327
6320
|
};
|
|
6328
6321
|
function x(A, n) {
|
|
@@ -6337,21 +6330,21 @@ Hf.exports;
|
|
|
6337
6330
|
this.length = Math.ceil((n.length - d) / 6), this.words = new Array(this.length);
|
|
6338
6331
|
for (var C = 0; C < this.length; C++)
|
|
6339
6332
|
this.words[C] = 0;
|
|
6340
|
-
var F = 0,
|
|
6333
|
+
var F = 0, q = 0, N;
|
|
6341
6334
|
if (g === "be")
|
|
6342
6335
|
for (C = n.length - 1; C >= d; C -= 2)
|
|
6343
|
-
|
|
6336
|
+
N = u(n, d, C) << F, this.words[q] |= N & 67108863, F >= 18 ? (F -= 18, q += 1, this.words[q] |= N >>> 26) : F += 8;
|
|
6344
6337
|
else {
|
|
6345
6338
|
var D = n.length - d;
|
|
6346
6339
|
for (C = D % 2 === 0 ? d + 1 : d; C < n.length; C += 2)
|
|
6347
|
-
|
|
6340
|
+
N = u(n, d, C) << F, this.words[q] |= N & 67108863, F >= 18 ? (F -= 18, q += 1, this.words[q] |= N >>> 26) : F += 8;
|
|
6348
6341
|
}
|
|
6349
6342
|
this.strip();
|
|
6350
6343
|
};
|
|
6351
6344
|
function o(A, n, d, g) {
|
|
6352
|
-
for (var C = 0, F = Math.min(A.length, d),
|
|
6353
|
-
var
|
|
6354
|
-
C *= g,
|
|
6345
|
+
for (var C = 0, F = Math.min(A.length, d), q = n; q < F; q++) {
|
|
6346
|
+
var N = A.charCodeAt(q) - 48;
|
|
6347
|
+
C *= g, N >= 49 ? C += N - 49 + 10 : N >= 17 ? C += N - 17 + 10 : C += N;
|
|
6355
6348
|
}
|
|
6356
6349
|
return C;
|
|
6357
6350
|
}
|
|
@@ -6360,11 +6353,11 @@ Hf.exports;
|
|
|
6360
6353
|
for (var C = 0, F = 1; F <= 67108863; F *= d)
|
|
6361
6354
|
C++;
|
|
6362
6355
|
C--, F = F / d | 0;
|
|
6363
|
-
for (var
|
|
6356
|
+
for (var q = n.length - g, N = q % C, D = Math.min(q, q - N) + g, h = 0, E = g; E < D; E += C)
|
|
6364
6357
|
h = o(n, E, E + C, d), this.imuln(F), this.words[0] + h < 67108864 ? this.words[0] += h : this._iaddn(h);
|
|
6365
|
-
if (
|
|
6358
|
+
if (N !== 0) {
|
|
6366
6359
|
var j = 1;
|
|
6367
|
-
for (h = o(n, E, n.length, d), E = 0; E <
|
|
6360
|
+
for (h = o(n, E, n.length, d), E = 0; E < N; E++)
|
|
6368
6361
|
j *= d;
|
|
6369
6362
|
this.imuln(j), this.words[0] + h < 67108864 ? this.words[0] += h : this._iaddn(h);
|
|
6370
6363
|
}
|
|
@@ -6499,9 +6492,9 @@ Hf.exports;
|
|
|
6499
6492
|
var g;
|
|
6500
6493
|
if (n === 16 || n === "hex") {
|
|
6501
6494
|
g = "";
|
|
6502
|
-
for (var C = 0, F = 0,
|
|
6503
|
-
var
|
|
6504
|
-
F =
|
|
6495
|
+
for (var C = 0, F = 0, q = 0; q < this.length; q++) {
|
|
6496
|
+
var N = this.words[q], D = ((N << C | F) & 16777215).toString(16);
|
|
6497
|
+
F = N >>> 24 - C & 16777215, F !== 0 || q !== this.length - 1 ? g = c[6 - D.length] + D + g : g = D + g, C += 2, C >= 26 && (C -= 26, q--);
|
|
6505
6498
|
}
|
|
6506
6499
|
for (F !== 0 && (g = F.toString(16) + g); g.length % d !== 0; )
|
|
6507
6500
|
g = "0" + g;
|
|
@@ -6532,27 +6525,26 @@ Hf.exports;
|
|
|
6532
6525
|
}, i.prototype.toArrayLike = function(n, d, g) {
|
|
6533
6526
|
var C = this.byteLength(), F = g || Math.max(1, C);
|
|
6534
6527
|
r(C <= F, "byte array longer than desired length"), r(F > 0, "Requested array length <= 0"), this.strip();
|
|
6535
|
-
var
|
|
6536
|
-
if (
|
|
6528
|
+
var q = d === "le", N = new n(F), D, h, E = this.clone();
|
|
6529
|
+
if (q) {
|
|
6537
6530
|
for (h = 0; !E.isZero(); h++)
|
|
6538
|
-
D = E.andln(255), E.iushrn(8),
|
|
6531
|
+
D = E.andln(255), E.iushrn(8), N[h] = D;
|
|
6539
6532
|
for (; h < F; h++)
|
|
6540
|
-
|
|
6533
|
+
N[h] = 0;
|
|
6541
6534
|
} else {
|
|
6542
6535
|
for (h = 0; h < F - C; h++)
|
|
6543
|
-
|
|
6536
|
+
N[h] = 0;
|
|
6544
6537
|
for (h = 0; !E.isZero(); h++)
|
|
6545
|
-
D = E.andln(255), E.iushrn(8),
|
|
6538
|
+
D = E.andln(255), E.iushrn(8), N[F - h - 1] = D;
|
|
6546
6539
|
}
|
|
6547
|
-
return
|
|
6540
|
+
return N;
|
|
6548
6541
|
}, Math.clz32 ? i.prototype._countBits = function(n) {
|
|
6549
6542
|
return 32 - Math.clz32(n);
|
|
6550
6543
|
} : i.prototype._countBits = function(n) {
|
|
6551
6544
|
var d = n, g = 0;
|
|
6552
6545
|
return d >= 4096 && (g += 13, d >>>= 13), d >= 64 && (g += 7, d >>>= 7), d >= 8 && (g += 4, d >>>= 4), d >= 2 && (g += 2, d >>>= 2), g + d;
|
|
6553
6546
|
}, i.prototype._zeroBits = function(n) {
|
|
6554
|
-
if (n === 0)
|
|
6555
|
-
return 26;
|
|
6547
|
+
if (n === 0) return 26;
|
|
6556
6548
|
var d = n, g = 0;
|
|
6557
6549
|
return d & 8191 || (g += 13, d >>>= 13), d & 127 || (g += 7, d >>>= 7), d & 15 || (g += 4, d >>>= 4), d & 3 || (g += 2, d >>>= 2), d & 1 || g++, g;
|
|
6558
6550
|
}, i.prototype.bitLength = function() {
|
|
@@ -6567,12 +6559,10 @@ Hf.exports;
|
|
|
6567
6559
|
return n;
|
|
6568
6560
|
}
|
|
6569
6561
|
i.prototype.zeroBits = function() {
|
|
6570
|
-
if (this.isZero())
|
|
6571
|
-
return 0;
|
|
6562
|
+
if (this.isZero()) return 0;
|
|
6572
6563
|
for (var n = 0, d = 0; d < this.length; d++) {
|
|
6573
6564
|
var g = this._zeroBits(this.words[d]);
|
|
6574
|
-
if (n += g, g !== 26)
|
|
6575
|
-
break;
|
|
6565
|
+
if (n += g, g !== 26) break;
|
|
6576
6566
|
}
|
|
6577
6567
|
return n;
|
|
6578
6568
|
}, i.prototype.byteLength = function() {
|
|
@@ -6647,15 +6637,15 @@ Hf.exports;
|
|
|
6647
6637
|
return n.negative = 0, d = this.isub(n), n.negative = 1, d._normSign();
|
|
6648
6638
|
var g, C;
|
|
6649
6639
|
this.length > n.length ? (g = this, C = n) : (g = n, C = this);
|
|
6650
|
-
for (var F = 0,
|
|
6651
|
-
d = (g.words[
|
|
6652
|
-
for (; F !== 0 &&
|
|
6653
|
-
d = (g.words[
|
|
6640
|
+
for (var F = 0, q = 0; q < C.length; q++)
|
|
6641
|
+
d = (g.words[q] | 0) + (C.words[q] | 0) + F, this.words[q] = d & 67108863, F = d >>> 26;
|
|
6642
|
+
for (; F !== 0 && q < g.length; q++)
|
|
6643
|
+
d = (g.words[q] | 0) + F, this.words[q] = d & 67108863, F = d >>> 26;
|
|
6654
6644
|
if (this.length = g.length, F !== 0)
|
|
6655
6645
|
this.words[this.length] = F, this.length++;
|
|
6656
6646
|
else if (g !== this)
|
|
6657
|
-
for (;
|
|
6658
|
-
this.words[
|
|
6647
|
+
for (; q < g.length; q++)
|
|
6648
|
+
this.words[q] = g.words[q];
|
|
6659
6649
|
return this;
|
|
6660
6650
|
}, i.prototype.add = function(n) {
|
|
6661
6651
|
var d;
|
|
@@ -6672,14 +6662,14 @@ Hf.exports;
|
|
|
6672
6662
|
return this.negative = 0, this.length = 1, this.words[0] = 0, this;
|
|
6673
6663
|
var C, F;
|
|
6674
6664
|
g > 0 ? (C = this, F = n) : (C = n, F = this);
|
|
6675
|
-
for (var
|
|
6676
|
-
d = (C.words[
|
|
6677
|
-
for (;
|
|
6678
|
-
d = (C.words[
|
|
6679
|
-
if (
|
|
6680
|
-
for (;
|
|
6681
|
-
this.words[
|
|
6682
|
-
return this.length = Math.max(this.length,
|
|
6665
|
+
for (var q = 0, N = 0; N < F.length; N++)
|
|
6666
|
+
d = (C.words[N] | 0) - (F.words[N] | 0) + q, q = d >> 26, this.words[N] = d & 67108863;
|
|
6667
|
+
for (; q !== 0 && N < C.length; N++)
|
|
6668
|
+
d = (C.words[N] | 0) + q, q = d >> 26, this.words[N] = d & 67108863;
|
|
6669
|
+
if (q === 0 && N < C.length && C !== this)
|
|
6670
|
+
for (; N < C.length; N++)
|
|
6671
|
+
this.words[N] = C.words[N];
|
|
6672
|
+
return this.length = Math.max(this.length, N), C !== this && (this.negative = 1), this.strip();
|
|
6683
6673
|
}, i.prototype.sub = function(n) {
|
|
6684
6674
|
return this.clone().isub(n);
|
|
6685
6675
|
};
|
|
@@ -6687,70 +6677,70 @@ Hf.exports;
|
|
|
6687
6677
|
d.negative = n.negative ^ A.negative;
|
|
6688
6678
|
var g = A.length + n.length | 0;
|
|
6689
6679
|
d.length = g, g = g - 1 | 0;
|
|
6690
|
-
var C = A.words[0] | 0, F = n.words[0] | 0,
|
|
6691
|
-
d.words[0] =
|
|
6680
|
+
var C = A.words[0] | 0, F = n.words[0] | 0, q = C * F, N = q & 67108863, D = q / 67108864 | 0;
|
|
6681
|
+
d.words[0] = N;
|
|
6692
6682
|
for (var h = 1; h < g; h++) {
|
|
6693
6683
|
for (var E = D >>> 26, j = D & 67108863, Y = Math.min(h, n.length - 1), W = Math.max(0, h - A.length + 1); W <= Y; W++) {
|
|
6694
6684
|
var re = h - W | 0;
|
|
6695
|
-
C = A.words[re] | 0, F = n.words[W] | 0,
|
|
6685
|
+
C = A.words[re] | 0, F = n.words[W] | 0, q = C * F + j, E += q / 67108864 | 0, j = q & 67108863;
|
|
6696
6686
|
}
|
|
6697
6687
|
d.words[h] = j | 0, D = E | 0;
|
|
6698
6688
|
}
|
|
6699
6689
|
return D !== 0 ? d.words[h] = D | 0 : d.length--, d.strip();
|
|
6700
6690
|
}
|
|
6701
6691
|
var R = function(n, d, g) {
|
|
6702
|
-
var C = n.words, F = d.words,
|
|
6692
|
+
var C = n.words, F = d.words, q = g.words, N = 0, D, h, E, j = C[0] | 0, Y = j & 8191, W = j >>> 13, re = C[1] | 0, ce = re & 8191, we = re >>> 13, Ae = C[2] | 0, Me = Ae & 8191, Fe = Ae >>> 13, Z0 = C[3] | 0, We = Z0 & 8191, Oe = Z0 >>> 13, _0 = C[4] | 0, Ge = _0 & 8191, Ye = _0 >>> 13, $0 = C[5] | 0, Qe = $0 & 8191, ze = $0 >>> 13, O0 = C[6] | 0, qe = O0 & 8191, Se = O0 >>> 13, F0 = C[7] | 0, Je = F0 & 8191, f0 = F0 >>> 13, S0 = C[8] | 0, Ne = S0 & 8191, u0 = S0 >>> 13, G0 = C[9] | 0, l0 = G0 & 8191, He = G0 >>> 13, z0 = F[0] | 0, a0 = z0 & 8191, r0 = z0 >>> 13, q0 = F[1] | 0, i0 = q0 & 8191, s0 = q0 >>> 13, W0 = F[2] | 0, e0 = W0 & 8191, n0 = W0 >>> 13, N0 = F[3] | 0, o0 = N0 & 8191, x0 = N0 >>> 13, D0 = F[4] | 0, t0 = D0 & 8191, Ve = D0 >>> 13, tt = F[5] | 0, c0 = tt & 8191, d0 = tt >>> 13, yt = F[6] | 0, Ie = yt & 8191, Re = yt >>> 13, l = F[7] | 0, _ = l & 8191, m = l >>> 13, s = F[8] | 0, M = s & 8191, p = s >>> 13, I = F[9] | 0, L = I & 8191, V = I >>> 13;
|
|
6703
6693
|
g.negative = n.negative ^ d.negative, g.length = 19, D = Math.imul(Y, a0), h = Math.imul(Y, r0), h = h + Math.imul(W, a0) | 0, E = Math.imul(W, r0);
|
|
6704
|
-
var ne = (
|
|
6705
|
-
|
|
6706
|
-
var fe = (
|
|
6707
|
-
|
|
6708
|
-
var he = (
|
|
6709
|
-
|
|
6710
|
-
var te = (
|
|
6711
|
-
|
|
6712
|
-
var xe = (
|
|
6713
|
-
|
|
6714
|
-
var ue = (
|
|
6715
|
-
|
|
6716
|
-
var ve = (
|
|
6717
|
-
|
|
6718
|
-
var ge = (
|
|
6719
|
-
|
|
6720
|
-
var me = (
|
|
6721
|
-
|
|
6722
|
-
var _e = (
|
|
6723
|
-
|
|
6724
|
-
var pe = (
|
|
6725
|
-
|
|
6726
|
-
var de = (
|
|
6727
|
-
|
|
6728
|
-
var ye = (
|
|
6729
|
-
|
|
6730
|
-
var oe = (
|
|
6731
|
-
|
|
6732
|
-
var le = (
|
|
6733
|
-
|
|
6734
|
-
var be = (
|
|
6735
|
-
|
|
6736
|
-
var se = (
|
|
6737
|
-
|
|
6738
|
-
var Z = (
|
|
6739
|
-
|
|
6740
|
-
var G = (
|
|
6741
|
-
return
|
|
6694
|
+
var ne = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6695
|
+
N = (E + (h >>> 13) | 0) + (ne >>> 26) | 0, ne &= 67108863, D = Math.imul(ce, a0), h = Math.imul(ce, r0), h = h + Math.imul(we, a0) | 0, E = Math.imul(we, r0), D = D + Math.imul(Y, i0) | 0, h = h + Math.imul(Y, s0) | 0, h = h + Math.imul(W, i0) | 0, E = E + Math.imul(W, s0) | 0;
|
|
6696
|
+
var fe = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6697
|
+
N = (E + (h >>> 13) | 0) + (fe >>> 26) | 0, fe &= 67108863, D = Math.imul(Me, a0), h = Math.imul(Me, r0), h = h + Math.imul(Fe, a0) | 0, E = Math.imul(Fe, r0), D = D + Math.imul(ce, i0) | 0, h = h + Math.imul(ce, s0) | 0, h = h + Math.imul(we, i0) | 0, E = E + Math.imul(we, s0) | 0, D = D + Math.imul(Y, e0) | 0, h = h + Math.imul(Y, n0) | 0, h = h + Math.imul(W, e0) | 0, E = E + Math.imul(W, n0) | 0;
|
|
6698
|
+
var he = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6699
|
+
N = (E + (h >>> 13) | 0) + (he >>> 26) | 0, he &= 67108863, D = Math.imul(We, a0), h = Math.imul(We, r0), h = h + Math.imul(Oe, a0) | 0, E = Math.imul(Oe, r0), D = D + Math.imul(Me, i0) | 0, h = h + Math.imul(Me, s0) | 0, h = h + Math.imul(Fe, i0) | 0, E = E + Math.imul(Fe, s0) | 0, D = D + Math.imul(ce, e0) | 0, h = h + Math.imul(ce, n0) | 0, h = h + Math.imul(we, e0) | 0, E = E + Math.imul(we, n0) | 0, D = D + Math.imul(Y, o0) | 0, h = h + Math.imul(Y, x0) | 0, h = h + Math.imul(W, o0) | 0, E = E + Math.imul(W, x0) | 0;
|
|
6700
|
+
var te = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6701
|
+
N = (E + (h >>> 13) | 0) + (te >>> 26) | 0, te &= 67108863, D = Math.imul(Ge, a0), h = Math.imul(Ge, r0), h = h + Math.imul(Ye, a0) | 0, E = Math.imul(Ye, r0), D = D + Math.imul(We, i0) | 0, h = h + Math.imul(We, s0) | 0, h = h + Math.imul(Oe, i0) | 0, E = E + Math.imul(Oe, s0) | 0, D = D + Math.imul(Me, e0) | 0, h = h + Math.imul(Me, n0) | 0, h = h + Math.imul(Fe, e0) | 0, E = E + Math.imul(Fe, n0) | 0, D = D + Math.imul(ce, o0) | 0, h = h + Math.imul(ce, x0) | 0, h = h + Math.imul(we, o0) | 0, E = E + Math.imul(we, x0) | 0, D = D + Math.imul(Y, t0) | 0, h = h + Math.imul(Y, Ve) | 0, h = h + Math.imul(W, t0) | 0, E = E + Math.imul(W, Ve) | 0;
|
|
6702
|
+
var xe = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6703
|
+
N = (E + (h >>> 13) | 0) + (xe >>> 26) | 0, xe &= 67108863, D = Math.imul(Qe, a0), h = Math.imul(Qe, r0), h = h + Math.imul(ze, a0) | 0, E = Math.imul(ze, r0), D = D + Math.imul(Ge, i0) | 0, h = h + Math.imul(Ge, s0) | 0, h = h + Math.imul(Ye, i0) | 0, E = E + Math.imul(Ye, s0) | 0, D = D + Math.imul(We, e0) | 0, h = h + Math.imul(We, n0) | 0, h = h + Math.imul(Oe, e0) | 0, E = E + Math.imul(Oe, n0) | 0, D = D + Math.imul(Me, o0) | 0, h = h + Math.imul(Me, x0) | 0, h = h + Math.imul(Fe, o0) | 0, E = E + Math.imul(Fe, x0) | 0, D = D + Math.imul(ce, t0) | 0, h = h + Math.imul(ce, Ve) | 0, h = h + Math.imul(we, t0) | 0, E = E + Math.imul(we, Ve) | 0, D = D + Math.imul(Y, c0) | 0, h = h + Math.imul(Y, d0) | 0, h = h + Math.imul(W, c0) | 0, E = E + Math.imul(W, d0) | 0;
|
|
6704
|
+
var ue = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6705
|
+
N = (E + (h >>> 13) | 0) + (ue >>> 26) | 0, ue &= 67108863, D = Math.imul(qe, a0), h = Math.imul(qe, r0), h = h + Math.imul(Se, a0) | 0, E = Math.imul(Se, r0), D = D + Math.imul(Qe, i0) | 0, h = h + Math.imul(Qe, s0) | 0, h = h + Math.imul(ze, i0) | 0, E = E + Math.imul(ze, s0) | 0, D = D + Math.imul(Ge, e0) | 0, h = h + Math.imul(Ge, n0) | 0, h = h + Math.imul(Ye, e0) | 0, E = E + Math.imul(Ye, n0) | 0, D = D + Math.imul(We, o0) | 0, h = h + Math.imul(We, x0) | 0, h = h + Math.imul(Oe, o0) | 0, E = E + Math.imul(Oe, x0) | 0, D = D + Math.imul(Me, t0) | 0, h = h + Math.imul(Me, Ve) | 0, h = h + Math.imul(Fe, t0) | 0, E = E + Math.imul(Fe, Ve) | 0, D = D + Math.imul(ce, c0) | 0, h = h + Math.imul(ce, d0) | 0, h = h + Math.imul(we, c0) | 0, E = E + Math.imul(we, d0) | 0, D = D + Math.imul(Y, Ie) | 0, h = h + Math.imul(Y, Re) | 0, h = h + Math.imul(W, Ie) | 0, E = E + Math.imul(W, Re) | 0;
|
|
6706
|
+
var ve = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6707
|
+
N = (E + (h >>> 13) | 0) + (ve >>> 26) | 0, ve &= 67108863, D = Math.imul(Je, a0), h = Math.imul(Je, r0), h = h + Math.imul(f0, a0) | 0, E = Math.imul(f0, r0), D = D + Math.imul(qe, i0) | 0, h = h + Math.imul(qe, s0) | 0, h = h + Math.imul(Se, i0) | 0, E = E + Math.imul(Se, s0) | 0, D = D + Math.imul(Qe, e0) | 0, h = h + Math.imul(Qe, n0) | 0, h = h + Math.imul(ze, e0) | 0, E = E + Math.imul(ze, n0) | 0, D = D + Math.imul(Ge, o0) | 0, h = h + Math.imul(Ge, x0) | 0, h = h + Math.imul(Ye, o0) | 0, E = E + Math.imul(Ye, x0) | 0, D = D + Math.imul(We, t0) | 0, h = h + Math.imul(We, Ve) | 0, h = h + Math.imul(Oe, t0) | 0, E = E + Math.imul(Oe, Ve) | 0, D = D + Math.imul(Me, c0) | 0, h = h + Math.imul(Me, d0) | 0, h = h + Math.imul(Fe, c0) | 0, E = E + Math.imul(Fe, d0) | 0, D = D + Math.imul(ce, Ie) | 0, h = h + Math.imul(ce, Re) | 0, h = h + Math.imul(we, Ie) | 0, E = E + Math.imul(we, Re) | 0, D = D + Math.imul(Y, _) | 0, h = h + Math.imul(Y, m) | 0, h = h + Math.imul(W, _) | 0, E = E + Math.imul(W, m) | 0;
|
|
6708
|
+
var ge = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6709
|
+
N = (E + (h >>> 13) | 0) + (ge >>> 26) | 0, ge &= 67108863, D = Math.imul(Ne, a0), h = Math.imul(Ne, r0), h = h + Math.imul(u0, a0) | 0, E = Math.imul(u0, r0), D = D + Math.imul(Je, i0) | 0, h = h + Math.imul(Je, s0) | 0, h = h + Math.imul(f0, i0) | 0, E = E + Math.imul(f0, s0) | 0, D = D + Math.imul(qe, e0) | 0, h = h + Math.imul(qe, n0) | 0, h = h + Math.imul(Se, e0) | 0, E = E + Math.imul(Se, n0) | 0, D = D + Math.imul(Qe, o0) | 0, h = h + Math.imul(Qe, x0) | 0, h = h + Math.imul(ze, o0) | 0, E = E + Math.imul(ze, x0) | 0, D = D + Math.imul(Ge, t0) | 0, h = h + Math.imul(Ge, Ve) | 0, h = h + Math.imul(Ye, t0) | 0, E = E + Math.imul(Ye, Ve) | 0, D = D + Math.imul(We, c0) | 0, h = h + Math.imul(We, d0) | 0, h = h + Math.imul(Oe, c0) | 0, E = E + Math.imul(Oe, d0) | 0, D = D + Math.imul(Me, Ie) | 0, h = h + Math.imul(Me, Re) | 0, h = h + Math.imul(Fe, Ie) | 0, E = E + Math.imul(Fe, Re) | 0, D = D + Math.imul(ce, _) | 0, h = h + Math.imul(ce, m) | 0, h = h + Math.imul(we, _) | 0, E = E + Math.imul(we, m) | 0, D = D + Math.imul(Y, M) | 0, h = h + Math.imul(Y, p) | 0, h = h + Math.imul(W, M) | 0, E = E + Math.imul(W, p) | 0;
|
|
6710
|
+
var me = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6711
|
+
N = (E + (h >>> 13) | 0) + (me >>> 26) | 0, me &= 67108863, D = Math.imul(l0, a0), h = Math.imul(l0, r0), h = h + Math.imul(He, a0) | 0, E = Math.imul(He, r0), D = D + Math.imul(Ne, i0) | 0, h = h + Math.imul(Ne, s0) | 0, h = h + Math.imul(u0, i0) | 0, E = E + Math.imul(u0, s0) | 0, D = D + Math.imul(Je, e0) | 0, h = h + Math.imul(Je, n0) | 0, h = h + Math.imul(f0, e0) | 0, E = E + Math.imul(f0, n0) | 0, D = D + Math.imul(qe, o0) | 0, h = h + Math.imul(qe, x0) | 0, h = h + Math.imul(Se, o0) | 0, E = E + Math.imul(Se, x0) | 0, D = D + Math.imul(Qe, t0) | 0, h = h + Math.imul(Qe, Ve) | 0, h = h + Math.imul(ze, t0) | 0, E = E + Math.imul(ze, Ve) | 0, D = D + Math.imul(Ge, c0) | 0, h = h + Math.imul(Ge, d0) | 0, h = h + Math.imul(Ye, c0) | 0, E = E + Math.imul(Ye, d0) | 0, D = D + Math.imul(We, Ie) | 0, h = h + Math.imul(We, Re) | 0, h = h + Math.imul(Oe, Ie) | 0, E = E + Math.imul(Oe, Re) | 0, D = D + Math.imul(Me, _) | 0, h = h + Math.imul(Me, m) | 0, h = h + Math.imul(Fe, _) | 0, E = E + Math.imul(Fe, m) | 0, D = D + Math.imul(ce, M) | 0, h = h + Math.imul(ce, p) | 0, h = h + Math.imul(we, M) | 0, E = E + Math.imul(we, p) | 0, D = D + Math.imul(Y, L) | 0, h = h + Math.imul(Y, V) | 0, h = h + Math.imul(W, L) | 0, E = E + Math.imul(W, V) | 0;
|
|
6712
|
+
var _e = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6713
|
+
N = (E + (h >>> 13) | 0) + (_e >>> 26) | 0, _e &= 67108863, D = Math.imul(l0, i0), h = Math.imul(l0, s0), h = h + Math.imul(He, i0) | 0, E = Math.imul(He, s0), D = D + Math.imul(Ne, e0) | 0, h = h + Math.imul(Ne, n0) | 0, h = h + Math.imul(u0, e0) | 0, E = E + Math.imul(u0, n0) | 0, D = D + Math.imul(Je, o0) | 0, h = h + Math.imul(Je, x0) | 0, h = h + Math.imul(f0, o0) | 0, E = E + Math.imul(f0, x0) | 0, D = D + Math.imul(qe, t0) | 0, h = h + Math.imul(qe, Ve) | 0, h = h + Math.imul(Se, t0) | 0, E = E + Math.imul(Se, Ve) | 0, D = D + Math.imul(Qe, c0) | 0, h = h + Math.imul(Qe, d0) | 0, h = h + Math.imul(ze, c0) | 0, E = E + Math.imul(ze, d0) | 0, D = D + Math.imul(Ge, Ie) | 0, h = h + Math.imul(Ge, Re) | 0, h = h + Math.imul(Ye, Ie) | 0, E = E + Math.imul(Ye, Re) | 0, D = D + Math.imul(We, _) | 0, h = h + Math.imul(We, m) | 0, h = h + Math.imul(Oe, _) | 0, E = E + Math.imul(Oe, m) | 0, D = D + Math.imul(Me, M) | 0, h = h + Math.imul(Me, p) | 0, h = h + Math.imul(Fe, M) | 0, E = E + Math.imul(Fe, p) | 0, D = D + Math.imul(ce, L) | 0, h = h + Math.imul(ce, V) | 0, h = h + Math.imul(we, L) | 0, E = E + Math.imul(we, V) | 0;
|
|
6714
|
+
var pe = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6715
|
+
N = (E + (h >>> 13) | 0) + (pe >>> 26) | 0, pe &= 67108863, D = Math.imul(l0, e0), h = Math.imul(l0, n0), h = h + Math.imul(He, e0) | 0, E = Math.imul(He, n0), D = D + Math.imul(Ne, o0) | 0, h = h + Math.imul(Ne, x0) | 0, h = h + Math.imul(u0, o0) | 0, E = E + Math.imul(u0, x0) | 0, D = D + Math.imul(Je, t0) | 0, h = h + Math.imul(Je, Ve) | 0, h = h + Math.imul(f0, t0) | 0, E = E + Math.imul(f0, Ve) | 0, D = D + Math.imul(qe, c0) | 0, h = h + Math.imul(qe, d0) | 0, h = h + Math.imul(Se, c0) | 0, E = E + Math.imul(Se, d0) | 0, D = D + Math.imul(Qe, Ie) | 0, h = h + Math.imul(Qe, Re) | 0, h = h + Math.imul(ze, Ie) | 0, E = E + Math.imul(ze, Re) | 0, D = D + Math.imul(Ge, _) | 0, h = h + Math.imul(Ge, m) | 0, h = h + Math.imul(Ye, _) | 0, E = E + Math.imul(Ye, m) | 0, D = D + Math.imul(We, M) | 0, h = h + Math.imul(We, p) | 0, h = h + Math.imul(Oe, M) | 0, E = E + Math.imul(Oe, p) | 0, D = D + Math.imul(Me, L) | 0, h = h + Math.imul(Me, V) | 0, h = h + Math.imul(Fe, L) | 0, E = E + Math.imul(Fe, V) | 0;
|
|
6716
|
+
var de = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6717
|
+
N = (E + (h >>> 13) | 0) + (de >>> 26) | 0, de &= 67108863, D = Math.imul(l0, o0), h = Math.imul(l0, x0), h = h + Math.imul(He, o0) | 0, E = Math.imul(He, x0), D = D + Math.imul(Ne, t0) | 0, h = h + Math.imul(Ne, Ve) | 0, h = h + Math.imul(u0, t0) | 0, E = E + Math.imul(u0, Ve) | 0, D = D + Math.imul(Je, c0) | 0, h = h + Math.imul(Je, d0) | 0, h = h + Math.imul(f0, c0) | 0, E = E + Math.imul(f0, d0) | 0, D = D + Math.imul(qe, Ie) | 0, h = h + Math.imul(qe, Re) | 0, h = h + Math.imul(Se, Ie) | 0, E = E + Math.imul(Se, Re) | 0, D = D + Math.imul(Qe, _) | 0, h = h + Math.imul(Qe, m) | 0, h = h + Math.imul(ze, _) | 0, E = E + Math.imul(ze, m) | 0, D = D + Math.imul(Ge, M) | 0, h = h + Math.imul(Ge, p) | 0, h = h + Math.imul(Ye, M) | 0, E = E + Math.imul(Ye, p) | 0, D = D + Math.imul(We, L) | 0, h = h + Math.imul(We, V) | 0, h = h + Math.imul(Oe, L) | 0, E = E + Math.imul(Oe, V) | 0;
|
|
6718
|
+
var ye = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6719
|
+
N = (E + (h >>> 13) | 0) + (ye >>> 26) | 0, ye &= 67108863, D = Math.imul(l0, t0), h = Math.imul(l0, Ve), h = h + Math.imul(He, t0) | 0, E = Math.imul(He, Ve), D = D + Math.imul(Ne, c0) | 0, h = h + Math.imul(Ne, d0) | 0, h = h + Math.imul(u0, c0) | 0, E = E + Math.imul(u0, d0) | 0, D = D + Math.imul(Je, Ie) | 0, h = h + Math.imul(Je, Re) | 0, h = h + Math.imul(f0, Ie) | 0, E = E + Math.imul(f0, Re) | 0, D = D + Math.imul(qe, _) | 0, h = h + Math.imul(qe, m) | 0, h = h + Math.imul(Se, _) | 0, E = E + Math.imul(Se, m) | 0, D = D + Math.imul(Qe, M) | 0, h = h + Math.imul(Qe, p) | 0, h = h + Math.imul(ze, M) | 0, E = E + Math.imul(ze, p) | 0, D = D + Math.imul(Ge, L) | 0, h = h + Math.imul(Ge, V) | 0, h = h + Math.imul(Ye, L) | 0, E = E + Math.imul(Ye, V) | 0;
|
|
6720
|
+
var oe = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6721
|
+
N = (E + (h >>> 13) | 0) + (oe >>> 26) | 0, oe &= 67108863, D = Math.imul(l0, c0), h = Math.imul(l0, d0), h = h + Math.imul(He, c0) | 0, E = Math.imul(He, d0), D = D + Math.imul(Ne, Ie) | 0, h = h + Math.imul(Ne, Re) | 0, h = h + Math.imul(u0, Ie) | 0, E = E + Math.imul(u0, Re) | 0, D = D + Math.imul(Je, _) | 0, h = h + Math.imul(Je, m) | 0, h = h + Math.imul(f0, _) | 0, E = E + Math.imul(f0, m) | 0, D = D + Math.imul(qe, M) | 0, h = h + Math.imul(qe, p) | 0, h = h + Math.imul(Se, M) | 0, E = E + Math.imul(Se, p) | 0, D = D + Math.imul(Qe, L) | 0, h = h + Math.imul(Qe, V) | 0, h = h + Math.imul(ze, L) | 0, E = E + Math.imul(ze, V) | 0;
|
|
6722
|
+
var le = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6723
|
+
N = (E + (h >>> 13) | 0) + (le >>> 26) | 0, le &= 67108863, D = Math.imul(l0, Ie), h = Math.imul(l0, Re), h = h + Math.imul(He, Ie) | 0, E = Math.imul(He, Re), D = D + Math.imul(Ne, _) | 0, h = h + Math.imul(Ne, m) | 0, h = h + Math.imul(u0, _) | 0, E = E + Math.imul(u0, m) | 0, D = D + Math.imul(Je, M) | 0, h = h + Math.imul(Je, p) | 0, h = h + Math.imul(f0, M) | 0, E = E + Math.imul(f0, p) | 0, D = D + Math.imul(qe, L) | 0, h = h + Math.imul(qe, V) | 0, h = h + Math.imul(Se, L) | 0, E = E + Math.imul(Se, V) | 0;
|
|
6724
|
+
var be = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6725
|
+
N = (E + (h >>> 13) | 0) + (be >>> 26) | 0, be &= 67108863, D = Math.imul(l0, _), h = Math.imul(l0, m), h = h + Math.imul(He, _) | 0, E = Math.imul(He, m), D = D + Math.imul(Ne, M) | 0, h = h + Math.imul(Ne, p) | 0, h = h + Math.imul(u0, M) | 0, E = E + Math.imul(u0, p) | 0, D = D + Math.imul(Je, L) | 0, h = h + Math.imul(Je, V) | 0, h = h + Math.imul(f0, L) | 0, E = E + Math.imul(f0, V) | 0;
|
|
6726
|
+
var se = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6727
|
+
N = (E + (h >>> 13) | 0) + (se >>> 26) | 0, se &= 67108863, D = Math.imul(l0, M), h = Math.imul(l0, p), h = h + Math.imul(He, M) | 0, E = Math.imul(He, p), D = D + Math.imul(Ne, L) | 0, h = h + Math.imul(Ne, V) | 0, h = h + Math.imul(u0, L) | 0, E = E + Math.imul(u0, V) | 0;
|
|
6728
|
+
var Z = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6729
|
+
N = (E + (h >>> 13) | 0) + (Z >>> 26) | 0, Z &= 67108863, D = Math.imul(l0, L), h = Math.imul(l0, V), h = h + Math.imul(He, L) | 0, E = Math.imul(He, V);
|
|
6730
|
+
var G = (N + D | 0) + ((h & 8191) << 13) | 0;
|
|
6731
|
+
return N = (E + (h >>> 13) | 0) + (G >>> 26) | 0, G &= 67108863, q[0] = ne, q[1] = fe, q[2] = he, q[3] = te, q[4] = xe, q[5] = ue, q[6] = ve, q[7] = ge, q[8] = me, q[9] = _e, q[10] = pe, q[11] = de, q[12] = ye, q[13] = oe, q[14] = le, q[15] = be, q[16] = se, q[17] = Z, q[18] = G, N !== 0 && (q[19] = N, g.length++), g;
|
|
6742
6732
|
};
|
|
6743
6733
|
Math.imul || (R = w);
|
|
6744
6734
|
function k(A, n, d) {
|
|
6745
6735
|
d.negative = n.negative ^ A.negative, d.length = A.length + n.length;
|
|
6746
6736
|
for (var g = 0, C = 0, F = 0; F < d.length - 1; F++) {
|
|
6747
|
-
var
|
|
6737
|
+
var q = C;
|
|
6748
6738
|
C = 0;
|
|
6749
|
-
for (var
|
|
6739
|
+
for (var N = g & 67108863, D = Math.min(F, n.length - 1), h = Math.max(0, F - A.length + 1); h <= D; h++) {
|
|
6750
6740
|
var E = F - h, j = A.words[E] | 0, Y = n.words[h] | 0, W = j * Y, re = W & 67108863;
|
|
6751
|
-
|
|
6741
|
+
q = q + (W / 67108864 | 0) | 0, re = re + N | 0, N = re & 67108863, q = q + (re >>> 26) | 0, C += q >>> 26, q &= 67108863;
|
|
6752
6742
|
}
|
|
6753
|
-
d.words[F] =
|
|
6743
|
+
d.words[F] = N, g = q, q = C;
|
|
6754
6744
|
}
|
|
6755
6745
|
return g !== 0 ? d.words[F] = g : d.length--, d.strip();
|
|
6756
6746
|
}
|
|
@@ -6770,21 +6760,20 @@ Hf.exports;
|
|
|
6770
6760
|
d[C] = this.revBin(C, g, n);
|
|
6771
6761
|
return d;
|
|
6772
6762
|
}, S.prototype.revBin = function(n, d, g) {
|
|
6773
|
-
if (n === 0 || n === g - 1)
|
|
6774
|
-
return n;
|
|
6763
|
+
if (n === 0 || n === g - 1) return n;
|
|
6775
6764
|
for (var C = 0, F = 0; F < d; F++)
|
|
6776
6765
|
C |= (n & 1) << d - F - 1, n >>= 1;
|
|
6777
6766
|
return C;
|
|
6778
|
-
}, S.prototype.permute = function(n, d, g, C, F,
|
|
6779
|
-
for (var
|
|
6780
|
-
C[
|
|
6781
|
-
}, S.prototype.transform = function(n, d, g, C, F,
|
|
6782
|
-
this.permute(
|
|
6783
|
-
for (var
|
|
6784
|
-
for (var D =
|
|
6785
|
-
for (var Y = h, W = E, re = 0; re <
|
|
6786
|
-
var ce = g[j + re], we = C[j + re], Ae = g[j + re +
|
|
6787
|
-
Me = Y * Me + W * Ae, Ae = Fe, g[j + re] = ce + Ae, C[j + re] = we + Me, g[j + re +
|
|
6767
|
+
}, S.prototype.permute = function(n, d, g, C, F, q) {
|
|
6768
|
+
for (var N = 0; N < q; N++)
|
|
6769
|
+
C[N] = d[n[N]], F[N] = g[n[N]];
|
|
6770
|
+
}, S.prototype.transform = function(n, d, g, C, F, q) {
|
|
6771
|
+
this.permute(q, n, d, g, C, F);
|
|
6772
|
+
for (var N = 1; N < F; N <<= 1)
|
|
6773
|
+
for (var D = N << 1, h = Math.cos(2 * Math.PI / D), E = Math.sin(2 * Math.PI / D), j = 0; j < F; j += D)
|
|
6774
|
+
for (var Y = h, W = E, re = 0; re < N; re++) {
|
|
6775
|
+
var ce = g[j + re], we = C[j + re], Ae = g[j + re + N], Me = C[j + re + N], Fe = Y * Ae - W * Me;
|
|
6776
|
+
Me = Y * Me + W * Ae, Ae = Fe, g[j + re] = ce + Ae, C[j + re] = we + Me, g[j + re + N] = ce - Ae, C[j + re + N] = we - Me, re !== D && (Fe = h * Y - E * W, W = h * W + E * Y, Y = Fe);
|
|
6788
6777
|
}
|
|
6789
6778
|
}, S.prototype.guessLen13b = function(n, d) {
|
|
6790
6779
|
var g = Math.max(d, n) | 1, C = g & 1, F = 0;
|
|
@@ -6804,23 +6793,23 @@ Hf.exports;
|
|
|
6804
6793
|
}
|
|
6805
6794
|
return n;
|
|
6806
6795
|
}, S.prototype.convert13b = function(n, d, g, C) {
|
|
6807
|
-
for (var F = 0,
|
|
6808
|
-
F = F + (n[
|
|
6809
|
-
for (
|
|
6810
|
-
g[
|
|
6796
|
+
for (var F = 0, q = 0; q < d; q++)
|
|
6797
|
+
F = F + (n[q] | 0), g[2 * q] = F & 8191, F = F >>> 13, g[2 * q + 1] = F & 8191, F = F >>> 13;
|
|
6798
|
+
for (q = 2 * d; q < C; ++q)
|
|
6799
|
+
g[q] = 0;
|
|
6811
6800
|
r(F === 0), r((F & -8192) === 0);
|
|
6812
6801
|
}, S.prototype.stub = function(n) {
|
|
6813
6802
|
for (var d = new Array(n), g = 0; g < n; g++)
|
|
6814
6803
|
d[g] = 0;
|
|
6815
6804
|
return d;
|
|
6816
6805
|
}, S.prototype.mulp = function(n, d, g) {
|
|
6817
|
-
var C = 2 * this.guessLen13b(n.length, d.length), F = this.makeRBT(C),
|
|
6818
|
-
W.length = C, this.convert13b(n.words, n.length,
|
|
6806
|
+
var C = 2 * this.guessLen13b(n.length, d.length), F = this.makeRBT(C), q = this.stub(C), N = new Array(C), D = new Array(C), h = new Array(C), E = new Array(C), j = new Array(C), Y = new Array(C), W = g.words;
|
|
6807
|
+
W.length = C, this.convert13b(n.words, n.length, N, C), this.convert13b(d.words, d.length, E, C), this.transform(N, q, D, h, C, F), this.transform(E, q, j, Y, C, F);
|
|
6819
6808
|
for (var re = 0; re < C; re++) {
|
|
6820
6809
|
var ce = D[re] * j[re] - h[re] * Y[re];
|
|
6821
6810
|
h[re] = D[re] * Y[re] + h[re] * j[re], D[re] = ce;
|
|
6822
6811
|
}
|
|
6823
|
-
return this.conjugate(D, h, C), this.transform(D, h, W,
|
|
6812
|
+
return this.conjugate(D, h, C), this.transform(D, h, W, q, C, F), this.conjugate(W, q, C), this.normalize13b(W, C), g.negative = n.negative ^ d.negative, g.length = n.length + d.length, g.strip();
|
|
6824
6813
|
}, i.prototype.mul = function(n) {
|
|
6825
6814
|
var d = new i(null);
|
|
6826
6815
|
return d.words = new Array(this.length + n.length), this.mulTo(n, d);
|
|
@@ -6844,8 +6833,7 @@ Hf.exports;
|
|
|
6844
6833
|
return this.imul(this.clone());
|
|
6845
6834
|
}, i.prototype.pow = function(n) {
|
|
6846
6835
|
var d = B(n);
|
|
6847
|
-
if (d.length === 0)
|
|
6848
|
-
return new i(1);
|
|
6836
|
+
if (d.length === 0) return new i(1);
|
|
6849
6837
|
for (var g = this, C = 0; C < d.length && d[C] === 0; C++, g = g.sqr())
|
|
6850
6838
|
;
|
|
6851
6839
|
if (++C < d.length)
|
|
@@ -6856,12 +6844,12 @@ Hf.exports;
|
|
|
6856
6844
|
r(typeof n == "number" && n >= 0);
|
|
6857
6845
|
var d = n % 26, g = (n - d) / 26, C = 67108863 >>> 26 - d << 26 - d, F;
|
|
6858
6846
|
if (d !== 0) {
|
|
6859
|
-
var
|
|
6847
|
+
var q = 0;
|
|
6860
6848
|
for (F = 0; F < this.length; F++) {
|
|
6861
|
-
var
|
|
6862
|
-
this.words[F] = D |
|
|
6849
|
+
var N = this.words[F] & C, D = (this.words[F] | 0) - N << d;
|
|
6850
|
+
this.words[F] = D | q, q = N >>> 26 - d;
|
|
6863
6851
|
}
|
|
6864
|
-
|
|
6852
|
+
q && (this.words[F] = q, this.length++);
|
|
6865
6853
|
}
|
|
6866
6854
|
if (g !== 0) {
|
|
6867
6855
|
for (F = this.length - 1; F >= 0; F--)
|
|
@@ -6877,22 +6865,21 @@ Hf.exports;
|
|
|
6877
6865
|
r(typeof n == "number" && n >= 0);
|
|
6878
6866
|
var C;
|
|
6879
6867
|
d ? C = (d - d % 26) / 26 : C = 0;
|
|
6880
|
-
var F = n % 26,
|
|
6881
|
-
if (C -=
|
|
6882
|
-
for (var h = 0; h <
|
|
6868
|
+
var F = n % 26, q = Math.min((n - F) / 26, this.length), N = 67108863 ^ 67108863 >>> F << F, D = g;
|
|
6869
|
+
if (C -= q, C = Math.max(0, C), D) {
|
|
6870
|
+
for (var h = 0; h < q; h++)
|
|
6883
6871
|
D.words[h] = this.words[h];
|
|
6884
|
-
D.length =
|
|
6872
|
+
D.length = q;
|
|
6885
6873
|
}
|
|
6886
|
-
if (
|
|
6887
|
-
|
|
6888
|
-
|
|
6889
|
-
|
|
6890
|
-
|
|
6891
|
-
this.words[0] = 0, this.length = 1;
|
|
6874
|
+
if (q !== 0) if (this.length > q)
|
|
6875
|
+
for (this.length -= q, h = 0; h < this.length; h++)
|
|
6876
|
+
this.words[h] = this.words[h + q];
|
|
6877
|
+
else
|
|
6878
|
+
this.words[0] = 0, this.length = 1;
|
|
6892
6879
|
var E = 0;
|
|
6893
6880
|
for (h = this.length - 1; h >= 0 && (E !== 0 || h >= C); h--) {
|
|
6894
6881
|
var j = this.words[h] | 0;
|
|
6895
|
-
this.words[h] = E << 26 - F | j >>> F, E = j &
|
|
6882
|
+
this.words[h] = E << 26 - F | j >>> F, E = j & N;
|
|
6896
6883
|
}
|
|
6897
6884
|
return D && E !== 0 && (D.words[D.length++] = E), this.length === 0 && (this.words[0] = 0, this.length = 1), this.strip();
|
|
6898
6885
|
}, i.prototype.ishrn = function(n, d, g) {
|
|
@@ -6908,8 +6895,7 @@ Hf.exports;
|
|
|
6908
6895
|
}, i.prototype.testn = function(n) {
|
|
6909
6896
|
r(typeof n == "number" && n >= 0);
|
|
6910
6897
|
var d = n % 26, g = (n - d) / 26, C = 1 << d;
|
|
6911
|
-
if (this.length <= g)
|
|
6912
|
-
return !1;
|
|
6898
|
+
if (this.length <= g) return !1;
|
|
6913
6899
|
var F = this.words[g];
|
|
6914
6900
|
return !!(F & C);
|
|
6915
6901
|
}, i.prototype.imaskn = function(n) {
|
|
@@ -6932,8 +6918,7 @@ Hf.exports;
|
|
|
6932
6918
|
this.words[d] -= 67108864, d === this.length - 1 ? this.words[d + 1] = 1 : this.words[d + 1]++;
|
|
6933
6919
|
return this.length = Math.max(this.length, d + 1), this;
|
|
6934
6920
|
}, i.prototype.isubn = function(n) {
|
|
6935
|
-
if (r(typeof n == "number"), r(n < 67108864), n < 0)
|
|
6936
|
-
return this.iaddn(-n);
|
|
6921
|
+
if (r(typeof n == "number"), r(n < 67108864), n < 0) return this.iaddn(-n);
|
|
6937
6922
|
if (this.negative !== 0)
|
|
6938
6923
|
return this.negative = 0, this.iaddn(n), this.negative = 1, this;
|
|
6939
6924
|
if (this.words[0] -= n, this.length === 1 && this.words[0] < 0)
|
|
@@ -6953,22 +6938,21 @@ Hf.exports;
|
|
|
6953
6938
|
}, i.prototype._ishlnsubmul = function(n, d, g) {
|
|
6954
6939
|
var C = n.length + g, F;
|
|
6955
6940
|
this._expand(C);
|
|
6956
|
-
var
|
|
6941
|
+
var q, N = 0;
|
|
6957
6942
|
for (F = 0; F < n.length; F++) {
|
|
6958
|
-
|
|
6943
|
+
q = (this.words[F + g] | 0) + N;
|
|
6959
6944
|
var D = (n.words[F] | 0) * d;
|
|
6960
|
-
|
|
6945
|
+
q -= D & 67108863, N = (q >> 26) - (D / 67108864 | 0), this.words[F + g] = q & 67108863;
|
|
6961
6946
|
}
|
|
6962
6947
|
for (; F < this.length - g; F++)
|
|
6963
|
-
|
|
6964
|
-
if (
|
|
6965
|
-
|
|
6966
|
-
|
|
6967
|
-
N = -(this.words[F] | 0) + q, q = N >> 26, this.words[F] = N & 67108863;
|
|
6948
|
+
q = (this.words[F + g] | 0) + N, N = q >> 26, this.words[F + g] = q & 67108863;
|
|
6949
|
+
if (N === 0) return this.strip();
|
|
6950
|
+
for (r(N === -1), N = 0, F = 0; F < this.length; F++)
|
|
6951
|
+
q = -(this.words[F] | 0) + N, N = q >> 26, this.words[F] = q & 67108863;
|
|
6968
6952
|
return this.negative = 1, this.strip();
|
|
6969
6953
|
}, i.prototype._wordDiv = function(n, d) {
|
|
6970
|
-
var g = this.length - n.length, C = this.clone(), F = n,
|
|
6971
|
-
g = 26 -
|
|
6954
|
+
var g = this.length - n.length, C = this.clone(), F = n, q = F.words[F.length - 1] | 0, N = this._countBits(q);
|
|
6955
|
+
g = 26 - N, g !== 0 && (F = F.ushln(g), C.iushln(g), q = F.words[F.length - 1] | 0);
|
|
6972
6956
|
var D = C.length - F.length, h;
|
|
6973
6957
|
if (d !== "mod") {
|
|
6974
6958
|
h = new i(null), h.length = D + 1, h.words = new Array(h.length);
|
|
@@ -6979,7 +6963,7 @@ Hf.exports;
|
|
|
6979
6963
|
j.negative === 0 && (C = j, h && (h.words[D] = 1));
|
|
6980
6964
|
for (var Y = D - 1; Y >= 0; Y--) {
|
|
6981
6965
|
var W = (C.words[F.length + Y] | 0) * 67108864 + (C.words[F.length + Y - 1] | 0);
|
|
6982
|
-
for (W = Math.min(W /
|
|
6966
|
+
for (W = Math.min(W / q | 0, 67108863), C._ishlnsubmul(F, W, Y); C.negative !== 0; )
|
|
6983
6967
|
W--, C.negative = 0, C._ishlnsubmul(F, 1, Y), C.isZero() || (C.negative ^= 1);
|
|
6984
6968
|
h && (h.words[Y] = W);
|
|
6985
6969
|
}
|
|
@@ -6993,15 +6977,15 @@ Hf.exports;
|
|
|
6993
6977
|
div: new i(0),
|
|
6994
6978
|
mod: new i(0)
|
|
6995
6979
|
};
|
|
6996
|
-
var C, F,
|
|
6997
|
-
return this.negative !== 0 && n.negative === 0 ? (
|
|
6980
|
+
var C, F, q;
|
|
6981
|
+
return this.negative !== 0 && n.negative === 0 ? (q = this.neg().divmod(n, d), d !== "mod" && (C = q.div.neg()), d !== "div" && (F = q.mod.neg(), g && F.negative !== 0 && F.iadd(n)), {
|
|
6998
6982
|
div: C,
|
|
6999
6983
|
mod: F
|
|
7000
|
-
}) : this.negative === 0 && n.negative !== 0 ? (
|
|
6984
|
+
}) : this.negative === 0 && n.negative !== 0 ? (q = this.divmod(n.neg(), d), d !== "mod" && (C = q.div.neg()), {
|
|
7001
6985
|
div: C,
|
|
7002
|
-
mod:
|
|
7003
|
-
}) : this.negative & n.negative ? (
|
|
7004
|
-
div:
|
|
6986
|
+
mod: q.mod
|
|
6987
|
+
}) : this.negative & n.negative ? (q = this.neg().divmod(n.neg(), d), d !== "div" && (F = q.mod.neg(), g && F.negative !== 0 && F.isub(n)), {
|
|
6988
|
+
div: q.div,
|
|
7005
6989
|
mod: F
|
|
7006
6990
|
}) : n.length > this.length || this.cmp(n) < 0 ? {
|
|
7007
6991
|
div: new i(0),
|
|
@@ -7024,10 +7008,9 @@ Hf.exports;
|
|
|
7024
7008
|
return this.divmod(n, "mod", !0).mod;
|
|
7025
7009
|
}, i.prototype.divRound = function(n) {
|
|
7026
7010
|
var d = this.divmod(n);
|
|
7027
|
-
if (d.mod.isZero())
|
|
7028
|
-
|
|
7029
|
-
|
|
7030
|
-
return N < 0 || F === 1 && N === 0 ? d.div : d.div.negative !== 0 ? d.div.isubn(1) : d.div.iaddn(1);
|
|
7011
|
+
if (d.mod.isZero()) return d.div;
|
|
7012
|
+
var g = d.div.negative !== 0 ? d.mod.isub(n) : d.mod, C = n.ushrn(1), F = n.andln(1), q = g.cmp(C);
|
|
7013
|
+
return q < 0 || F === 1 && q === 0 ? d.div : d.div.negative !== 0 ? d.div.isubn(1) : d.div.iaddn(1);
|
|
7031
7014
|
}, i.prototype.modn = function(n) {
|
|
7032
7015
|
r(n <= 67108863);
|
|
7033
7016
|
for (var d = (1 << 26) % n, g = 0, C = this.length - 1; C >= 0; C--)
|
|
@@ -7046,50 +7029,44 @@ Hf.exports;
|
|
|
7046
7029
|
r(n.negative === 0), r(!n.isZero());
|
|
7047
7030
|
var d = this, g = n.clone();
|
|
7048
7031
|
d.negative !== 0 ? d = d.umod(n) : d = d.clone();
|
|
7049
|
-
for (var C = new i(1), F = new i(0),
|
|
7032
|
+
for (var C = new i(1), F = new i(0), q = new i(0), N = new i(1), D = 0; d.isEven() && g.isEven(); )
|
|
7050
7033
|
d.iushrn(1), g.iushrn(1), ++D;
|
|
7051
7034
|
for (var h = g.clone(), E = d.clone(); !d.isZero(); ) {
|
|
7052
|
-
for (var j = 0, Y = 1; !(d.words[0] & Y) && j < 26; ++j, Y <<= 1)
|
|
7053
|
-
;
|
|
7035
|
+
for (var j = 0, Y = 1; !(d.words[0] & Y) && j < 26; ++j, Y <<= 1) ;
|
|
7054
7036
|
if (j > 0)
|
|
7055
7037
|
for (d.iushrn(j); j-- > 0; )
|
|
7056
7038
|
(C.isOdd() || F.isOdd()) && (C.iadd(h), F.isub(E)), C.iushrn(1), F.iushrn(1);
|
|
7057
|
-
for (var W = 0, re = 1; !(g.words[0] & re) && W < 26; ++W, re <<= 1)
|
|
7058
|
-
;
|
|
7039
|
+
for (var W = 0, re = 1; !(g.words[0] & re) && W < 26; ++W, re <<= 1) ;
|
|
7059
7040
|
if (W > 0)
|
|
7060
7041
|
for (g.iushrn(W); W-- > 0; )
|
|
7061
|
-
(
|
|
7062
|
-
d.cmp(g) >= 0 ? (d.isub(g), C.isub(
|
|
7042
|
+
(q.isOdd() || N.isOdd()) && (q.iadd(h), N.isub(E)), q.iushrn(1), N.iushrn(1);
|
|
7043
|
+
d.cmp(g) >= 0 ? (d.isub(g), C.isub(q), F.isub(N)) : (g.isub(d), q.isub(C), N.isub(F));
|
|
7063
7044
|
}
|
|
7064
7045
|
return {
|
|
7065
|
-
a:
|
|
7066
|
-
b:
|
|
7046
|
+
a: q,
|
|
7047
|
+
b: N,
|
|
7067
7048
|
gcd: g.iushln(D)
|
|
7068
7049
|
};
|
|
7069
7050
|
}, i.prototype._invmp = function(n) {
|
|
7070
7051
|
r(n.negative === 0), r(!n.isZero());
|
|
7071
7052
|
var d = this, g = n.clone();
|
|
7072
7053
|
d.negative !== 0 ? d = d.umod(n) : d = d.clone();
|
|
7073
|
-
for (var C = new i(1), F = new i(0),
|
|
7074
|
-
for (var
|
|
7075
|
-
|
|
7076
|
-
|
|
7077
|
-
|
|
7078
|
-
|
|
7079
|
-
for (var h = 0, E = 1; !(g.words[0] & E) && h < 26; ++h, E <<= 1)
|
|
7080
|
-
;
|
|
7054
|
+
for (var C = new i(1), F = new i(0), q = g.clone(); d.cmpn(1) > 0 && g.cmpn(1) > 0; ) {
|
|
7055
|
+
for (var N = 0, D = 1; !(d.words[0] & D) && N < 26; ++N, D <<= 1) ;
|
|
7056
|
+
if (N > 0)
|
|
7057
|
+
for (d.iushrn(N); N-- > 0; )
|
|
7058
|
+
C.isOdd() && C.iadd(q), C.iushrn(1);
|
|
7059
|
+
for (var h = 0, E = 1; !(g.words[0] & E) && h < 26; ++h, E <<= 1) ;
|
|
7081
7060
|
if (h > 0)
|
|
7082
7061
|
for (g.iushrn(h); h-- > 0; )
|
|
7083
|
-
F.isOdd() && F.iadd(
|
|
7062
|
+
F.isOdd() && F.iadd(q), F.iushrn(1);
|
|
7084
7063
|
d.cmp(g) >= 0 ? (d.isub(g), C.isub(F)) : (g.isub(d), F.isub(C));
|
|
7085
7064
|
}
|
|
7086
7065
|
var j;
|
|
7087
7066
|
return d.cmpn(1) === 0 ? j = C : j = F, j.cmpn(0) < 0 && j.iadd(n), j;
|
|
7088
7067
|
}, i.prototype.gcd = function(n) {
|
|
7089
|
-
if (this.isZero())
|
|
7090
|
-
|
|
7091
|
-
if (n.isZero())
|
|
7092
|
-
return this.abs();
|
|
7068
|
+
if (this.isZero()) return n.abs();
|
|
7069
|
+
if (n.isZero()) return this.abs();
|
|
7093
7070
|
var d = this.clone(), g = n.clone();
|
|
7094
7071
|
d.negative = 0, g.negative = 0;
|
|
7095
7072
|
for (var C = 0; d.isEven() && g.isEven(); C++)
|
|
@@ -7101,8 +7078,8 @@ Hf.exports;
|
|
|
7101
7078
|
g.iushrn(1);
|
|
7102
7079
|
var F = d.cmp(g);
|
|
7103
7080
|
if (F < 0) {
|
|
7104
|
-
var
|
|
7105
|
-
d = g, g =
|
|
7081
|
+
var q = d;
|
|
7082
|
+
d = g, g = q;
|
|
7106
7083
|
} else if (F === 0 || g.cmpn(1) === 0)
|
|
7107
7084
|
break;
|
|
7108
7085
|
d.isub(g);
|
|
@@ -7121,19 +7098,17 @@ Hf.exports;
|
|
|
7121
7098
|
var d = n % 26, g = (n - d) / 26, C = 1 << d;
|
|
7122
7099
|
if (this.length <= g)
|
|
7123
7100
|
return this._expand(g + 1), this.words[g] |= C, this;
|
|
7124
|
-
for (var F = C,
|
|
7125
|
-
var
|
|
7126
|
-
|
|
7101
|
+
for (var F = C, q = g; F !== 0 && q < this.length; q++) {
|
|
7102
|
+
var N = this.words[q] | 0;
|
|
7103
|
+
N += F, F = N >>> 26, N &= 67108863, this.words[q] = N;
|
|
7127
7104
|
}
|
|
7128
|
-
return F !== 0 && (this.words[
|
|
7105
|
+
return F !== 0 && (this.words[q] = F, this.length++), this;
|
|
7129
7106
|
}, i.prototype.isZero = function() {
|
|
7130
7107
|
return this.length === 1 && this.words[0] === 0;
|
|
7131
7108
|
}, i.prototype.cmpn = function(n) {
|
|
7132
7109
|
var d = n < 0;
|
|
7133
|
-
if (this.negative !== 0 && !d)
|
|
7134
|
-
|
|
7135
|
-
if (this.negative === 0 && d)
|
|
7136
|
-
return 1;
|
|
7110
|
+
if (this.negative !== 0 && !d) return -1;
|
|
7111
|
+
if (this.negative === 0 && d) return 1;
|
|
7137
7112
|
this.strip();
|
|
7138
7113
|
var g;
|
|
7139
7114
|
if (this.length > 1)
|
|
@@ -7145,17 +7120,13 @@ Hf.exports;
|
|
|
7145
7120
|
}
|
|
7146
7121
|
return this.negative !== 0 ? -g | 0 : g;
|
|
7147
7122
|
}, i.prototype.cmp = function(n) {
|
|
7148
|
-
if (this.negative !== 0 && n.negative === 0)
|
|
7149
|
-
|
|
7150
|
-
if (this.negative === 0 && n.negative !== 0)
|
|
7151
|
-
return 1;
|
|
7123
|
+
if (this.negative !== 0 && n.negative === 0) return -1;
|
|
7124
|
+
if (this.negative === 0 && n.negative !== 0) return 1;
|
|
7152
7125
|
var d = this.ucmp(n);
|
|
7153
7126
|
return this.negative !== 0 ? -d | 0 : d;
|
|
7154
7127
|
}, i.prototype.ucmp = function(n) {
|
|
7155
|
-
if (this.length > n.length)
|
|
7156
|
-
|
|
7157
|
-
if (this.length < n.length)
|
|
7158
|
-
return -1;
|
|
7128
|
+
if (this.length > n.length) return 1;
|
|
7129
|
+
if (this.length < n.length) return -1;
|
|
7159
7130
|
for (var d = 0, g = this.length - 1; g >= 0; g--) {
|
|
7160
7131
|
var C = this.words[g] | 0, F = n.words[g] | 0;
|
|
7161
7132
|
if (C !== F) {
|
|
@@ -7259,12 +7230,12 @@ Hf.exports;
|
|
|
7259
7230
|
n.words[0] = 0, n.length = 1;
|
|
7260
7231
|
return;
|
|
7261
7232
|
}
|
|
7262
|
-
var
|
|
7263
|
-
for (d.words[d.length++] =
|
|
7264
|
-
var
|
|
7265
|
-
n.words[F - 10] = (
|
|
7233
|
+
var q = n.words[9];
|
|
7234
|
+
for (d.words[d.length++] = q & g, F = 10; F < n.length; F++) {
|
|
7235
|
+
var N = n.words[F] | 0;
|
|
7236
|
+
n.words[F - 10] = (N & g) << 4 | q >>> 22, q = N;
|
|
7266
7237
|
}
|
|
7267
|
-
|
|
7238
|
+
q >>>= 22, n.words[F - 10] = q, q === 0 && n.length > 10 ? n.length -= 10 : n.length -= 9;
|
|
7268
7239
|
}, H.prototype.imulK = function(n) {
|
|
7269
7240
|
n.words[n.length] = 0, n.words[n.length + 1] = 0, n.length += 2;
|
|
7270
7241
|
for (var d = 0, g = 0; g < n.length; g++) {
|
|
@@ -7303,8 +7274,7 @@ Hf.exports;
|
|
|
7303
7274
|
}
|
|
7304
7275
|
return d !== 0 && (n.words[n.length++] = d), n;
|
|
7305
7276
|
}, i._prime = function(n) {
|
|
7306
|
-
if (P[n])
|
|
7307
|
-
return P[n];
|
|
7277
|
+
if (P[n]) return P[n];
|
|
7308
7278
|
var d;
|
|
7309
7279
|
if (n === "k256")
|
|
7310
7280
|
d = new H();
|
|
@@ -7363,8 +7333,7 @@ Hf.exports;
|
|
|
7363
7333
|
}, Q.prototype.sqr = function(n) {
|
|
7364
7334
|
return this.mul(n, n);
|
|
7365
7335
|
}, Q.prototype.sqrt = function(n) {
|
|
7366
|
-
if (n.isZero())
|
|
7367
|
-
return n.clone();
|
|
7336
|
+
if (n.isZero()) return n.clone();
|
|
7368
7337
|
var d = this.m.andln(3);
|
|
7369
7338
|
if (r(d % 2 === 1), d === 3) {
|
|
7370
7339
|
var g = this.m.add(new i(1)).iushrn(2);
|
|
@@ -7373,11 +7342,11 @@ Hf.exports;
|
|
|
7373
7342
|
for (var C = this.m.subn(1), F = 0; !C.isZero() && C.andln(1) === 0; )
|
|
7374
7343
|
F++, C.iushrn(1);
|
|
7375
7344
|
r(!C.isZero());
|
|
7376
|
-
var
|
|
7377
|
-
for (h = new i(2 * h * h).toRed(this); this.pow(h, D).cmp(
|
|
7378
|
-
h.redIAdd(
|
|
7379
|
-
for (var E = this.pow(h, C), j = this.pow(n, C.addn(1).iushrn(1)), Y = this.pow(n, C), W = F; Y.cmp(
|
|
7380
|
-
for (var re = Y, ce = 0; re.cmp(
|
|
7345
|
+
var q = new i(1).toRed(this), N = q.redNeg(), D = this.m.subn(1).iushrn(1), h = this.m.bitLength();
|
|
7346
|
+
for (h = new i(2 * h * h).toRed(this); this.pow(h, D).cmp(N) !== 0; )
|
|
7347
|
+
h.redIAdd(N);
|
|
7348
|
+
for (var E = this.pow(h, C), j = this.pow(n, C.addn(1).iushrn(1)), Y = this.pow(n, C), W = F; Y.cmp(q) !== 0; ) {
|
|
7349
|
+
for (var re = Y, ce = 0; re.cmp(q) !== 0; ce++)
|
|
7381
7350
|
re = re.redSqr();
|
|
7382
7351
|
r(ce < W);
|
|
7383
7352
|
var we = this.pow(E, new i(1).iushln(W - ce - 1));
|
|
@@ -7388,27 +7357,25 @@ Hf.exports;
|
|
|
7388
7357
|
var d = n._invmp(this.m);
|
|
7389
7358
|
return d.negative !== 0 ? (d.negative = 0, this.imod(d).redNeg()) : this.imod(d);
|
|
7390
7359
|
}, Q.prototype.pow = function(n, d) {
|
|
7391
|
-
if (d.isZero())
|
|
7392
|
-
|
|
7393
|
-
if (d.cmpn(1) === 0)
|
|
7394
|
-
return n.clone();
|
|
7360
|
+
if (d.isZero()) return new i(1).toRed(this);
|
|
7361
|
+
if (d.cmpn(1) === 0) return n.clone();
|
|
7395
7362
|
var g = 4, C = new Array(1 << g);
|
|
7396
7363
|
C[0] = new i(1).toRed(this), C[1] = n;
|
|
7397
7364
|
for (var F = 2; F < C.length; F++)
|
|
7398
7365
|
C[F] = this.mul(C[F - 1], n);
|
|
7399
|
-
var
|
|
7366
|
+
var q = C[0], N = 0, D = 0, h = d.bitLength() % 26;
|
|
7400
7367
|
for (h === 0 && (h = 26), F = d.length - 1; F >= 0; F--) {
|
|
7401
7368
|
for (var E = d.words[F], j = h - 1; j >= 0; j--) {
|
|
7402
7369
|
var Y = E >> j & 1;
|
|
7403
|
-
if (
|
|
7370
|
+
if (q !== C[0] && (q = this.sqr(q)), Y === 0 && N === 0) {
|
|
7404
7371
|
D = 0;
|
|
7405
7372
|
continue;
|
|
7406
7373
|
}
|
|
7407
|
-
|
|
7374
|
+
N <<= 1, N |= Y, D++, !(D !== g && (F !== 0 || j !== 0)) && (q = this.mul(q, C[N]), D = 0, N = 0);
|
|
7408
7375
|
}
|
|
7409
7376
|
h = 26;
|
|
7410
7377
|
}
|
|
7411
|
-
return
|
|
7378
|
+
return q;
|
|
7412
7379
|
}, Q.prototype.convertTo = function(n) {
|
|
7413
7380
|
var d = n.umod(this.m);
|
|
7414
7381
|
return d === n ? d.clone() : d;
|
|
@@ -7429,13 +7396,12 @@ Hf.exports;
|
|
|
7429
7396
|
}, U.prototype.imul = function(n, d) {
|
|
7430
7397
|
if (n.isZero() || d.isZero())
|
|
7431
7398
|
return n.words[0] = 0, n.length = 1, n;
|
|
7432
|
-
var g = n.imul(d), C = g.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), F = g.isub(C).iushrn(this.shift),
|
|
7433
|
-
return F.cmp(this.m) >= 0 ?
|
|
7399
|
+
var g = n.imul(d), C = g.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), F = g.isub(C).iushrn(this.shift), q = F;
|
|
7400
|
+
return F.cmp(this.m) >= 0 ? q = F.isub(this.m) : F.cmpn(0) < 0 && (q = F.iadd(this.m)), q._forceRed(this);
|
|
7434
7401
|
}, U.prototype.mul = function(n, d) {
|
|
7435
|
-
if (n.isZero() || d.isZero())
|
|
7436
|
-
|
|
7437
|
-
|
|
7438
|
-
return F.cmp(this.m) >= 0 ? N = F.isub(this.m) : F.cmpn(0) < 0 && (N = F.iadd(this.m)), N._forceRed(this);
|
|
7402
|
+
if (n.isZero() || d.isZero()) return new i(0)._forceRed(this);
|
|
7403
|
+
var g = n.mul(d), C = g.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m), F = g.isub(C).iushrn(this.shift), q = F;
|
|
7404
|
+
return F.cmp(this.m) >= 0 ? q = F.isub(this.m) : F.cmpn(0) < 0 && (q = F.iadd(this.m)), q._forceRed(this);
|
|
7439
7405
|
}, U.prototype.invm = function(n) {
|
|
7440
7406
|
var d = this.imod(n._invmp(this.m).mul(this.r2));
|
|
7441
7407
|
return d._forceRed(this);
|
|
@@ -8400,11 +8366,10 @@ function Ss(f, e) {
|
|
|
8400
8366
|
if (e === "hex")
|
|
8401
8367
|
for (f = f.replace(/[^a-z0-9]+/ig, ""), f.length % 2 !== 0 && (f = "0" + f), a = 0; a < f.length; a += 2)
|
|
8402
8368
|
t.push(parseInt(f[a] + f[a + 1], 16));
|
|
8403
|
-
} else
|
|
8404
|
-
|
|
8405
|
-
|
|
8406
|
-
|
|
8407
|
-
}
|
|
8369
|
+
} else for (var r = 0, a = 0; a < f.length; a++) {
|
|
8370
|
+
var i = f.charCodeAt(a);
|
|
8371
|
+
i < 128 ? t[r++] = i : i < 2048 ? (t[r++] = i >> 6 | 192, t[r++] = i & 63 | 128) : Fs(f, a) ? (i = 65536 + ((i & 1023) << 10) + (f.charCodeAt(++a) & 1023), t[r++] = i >> 18 | 240, t[r++] = i >> 12 & 63 | 128, t[r++] = i >> 6 & 63 | 128, t[r++] = i & 63 | 128) : (t[r++] = i >> 12 | 224, t[r++] = i >> 6 & 63 | 128, t[r++] = i & 63 | 128);
|
|
8372
|
+
}
|
|
8408
8373
|
else
|
|
8409
8374
|
for (a = 0; a < f.length; a++)
|
|
8410
8375
|
t[a] = f[a] | 0;
|
|
@@ -8472,14 +8437,14 @@ function zs(f, e, t) {
|
|
|
8472
8437
|
return f + e + t >>> 0;
|
|
8473
8438
|
}
|
|
8474
8439
|
Le.sum32_3 = zs;
|
|
8475
|
-
function
|
|
8440
|
+
function qs(f, e, t, r) {
|
|
8476
8441
|
return f + e + t + r >>> 0;
|
|
8477
8442
|
}
|
|
8478
|
-
Le.sum32_4 =
|
|
8479
|
-
function
|
|
8443
|
+
Le.sum32_4 = qs;
|
|
8444
|
+
function Ns(f, e, t, r, a) {
|
|
8480
8445
|
return f + e + t + r + a >>> 0;
|
|
8481
8446
|
}
|
|
8482
|
-
Le.sum32_5 =
|
|
8447
|
+
Le.sum32_5 = Ns;
|
|
8483
8448
|
function Ls(f, e, t, r) {
|
|
8484
8449
|
var a = f[e], i = f[e + 1], y = r + i >>> 0, x = (y < r ? 1 : 0) + t + a;
|
|
8485
8450
|
f[e] = x >>> 0, f[e + 1] = y;
|
|
@@ -8608,7 +8573,7 @@ function fo(f) {
|
|
|
8608
8573
|
return rt(f, 17) ^ rt(f, 19) ^ f >>> 10;
|
|
8609
8574
|
}
|
|
8610
8575
|
ht.g1_256 = fo;
|
|
8611
|
-
var
|
|
8576
|
+
var qt = Le, io = Wt, no = ht, pf = qt.rotl32, Gt = qt.sum32, ao = qt.sum32_5, so = no.ft_1, Sn = io.BlockHash, oo = [
|
|
8612
8577
|
1518500249,
|
|
8613
8578
|
1859775393,
|
|
8614
8579
|
2400959708,
|
|
@@ -8625,7 +8590,7 @@ function at() {
|
|
|
8625
8590
|
3285377520
|
|
8626
8591
|
], this.W = new Array(80);
|
|
8627
8592
|
}
|
|
8628
|
-
|
|
8593
|
+
qt.inherits(at, Sn);
|
|
8629
8594
|
var co = at;
|
|
8630
8595
|
at.blockSize = 512;
|
|
8631
8596
|
at.outSize = 160;
|
|
@@ -8644,9 +8609,9 @@ at.prototype._update = function(e, t) {
|
|
|
8644
8609
|
this.h[0] = Gt(this.h[0], i), this.h[1] = Gt(this.h[1], y), this.h[2] = Gt(this.h[2], x), this.h[3] = Gt(this.h[3], u), this.h[4] = Gt(this.h[4], o);
|
|
8645
8610
|
};
|
|
8646
8611
|
at.prototype._digest = function(e) {
|
|
8647
|
-
return e === "hex" ?
|
|
8612
|
+
return e === "hex" ? qt.toHex32(this.h, "big") : qt.split32(this.h, "big");
|
|
8648
8613
|
};
|
|
8649
|
-
var
|
|
8614
|
+
var Nt = Le, ho = Wt, Kt = ht, uo = Pt, Q0 = Nt.sum32, lo = Nt.sum32_4, xo = Nt.sum32_5, vo = Kt.ch32, bo = Kt.maj32, po = Kt.s0_256, yo = Kt.s1_256, go = Kt.g0_256, mo = Kt.g1_256, Dn = ho.BlockHash, _o = [
|
|
8650
8615
|
1116352408,
|
|
8651
8616
|
1899447441,
|
|
8652
8617
|
3049323471,
|
|
@@ -8726,7 +8691,7 @@ function st() {
|
|
|
8726
8691
|
1541459225
|
|
8727
8692
|
], this.k = _o, this.W = new Array(64);
|
|
8728
8693
|
}
|
|
8729
|
-
|
|
8694
|
+
Nt.inherits(st, Dn);
|
|
8730
8695
|
var Rn = st;
|
|
8731
8696
|
st.blockSize = 512;
|
|
8732
8697
|
st.outSize = 256;
|
|
@@ -8745,7 +8710,7 @@ st.prototype._update = function(e, t) {
|
|
|
8745
8710
|
this.h[0] = Q0(this.h[0], i), this.h[1] = Q0(this.h[1], y), this.h[2] = Q0(this.h[2], x), this.h[3] = Q0(this.h[3], u), this.h[4] = Q0(this.h[4], o), this.h[5] = Q0(this.h[5], c), this.h[6] = Q0(this.h[6], v), this.h[7] = Q0(this.h[7], b);
|
|
8746
8711
|
};
|
|
8747
8712
|
st.prototype._digest = function(e) {
|
|
8748
|
-
return e === "hex" ?
|
|
8713
|
+
return e === "hex" ? Nt.toHex32(this.h, "big") : Nt.split32(this.h, "big");
|
|
8749
8714
|
};
|
|
8750
8715
|
var Ff = Le, kn = Rn;
|
|
8751
8716
|
function vt() {
|
|
@@ -8965,7 +8930,7 @@ et.prototype._prepareBlock = function(e, t) {
|
|
|
8965
8930
|
for (var r = this.W, a = 0; a < 32; a++)
|
|
8966
8931
|
r[a] = e[t + a];
|
|
8967
8932
|
for (; a < r.length; a += 2) {
|
|
8968
|
-
var i = Lo(r[a - 4], r[a - 3]), y = Ho(r[a - 4], r[a - 3]), x = r[a - 14], u = r[a - 13], o =
|
|
8933
|
+
var i = Lo(r[a - 4], r[a - 3]), y = Ho(r[a - 4], r[a - 3]), x = r[a - 14], u = r[a - 13], o = qo(r[a - 30], r[a - 29]), c = No(r[a - 30], r[a - 29]), v = r[a - 32], b = r[a - 31];
|
|
8969
8934
|
r[a] = Bo(
|
|
8970
8935
|
i,
|
|
8971
8936
|
y,
|
|
@@ -9016,8 +8981,8 @@ et.prototype._update = function(e, t) {
|
|
|
9016
8981
|
g
|
|
9017
8982
|
);
|
|
9018
8983
|
H = Io(a, i), $ = To(a, i), K = ko(a, i, y, x, u), X = Po(a, i, y, x, u, o);
|
|
9019
|
-
var
|
|
9020
|
-
S = k, P = z, k = w, z = R, w = b, R = B, b = yf(c, v, C, F), B = gf(v, v, C, F), c = u, v = o, u = y, o = x, y = a, x = i, a = yf(C, F,
|
|
8984
|
+
var q = yf(H, $, K, X), N = gf(H, $, K, X);
|
|
8985
|
+
S = k, P = z, k = w, z = R, w = b, R = B, b = yf(c, v, C, F), B = gf(v, v, C, F), c = u, v = o, u = y, o = x, y = a, x = i, a = yf(C, F, q, N), i = gf(C, F, q, N);
|
|
9021
8986
|
}
|
|
9022
8987
|
gt(this.h, 0, a, i), gt(this.h, 2, y, x), gt(this.h, 4, u, o), gt(this.h, 6, c, v), gt(this.h, 8, b, B), gt(this.h, 10, w, R), gt(this.h, 12, k, z), gt(this.h, 14, S, P);
|
|
9023
8988
|
};
|
|
@@ -9056,11 +9021,11 @@ function zo(f, e) {
|
|
|
9056
9021
|
var t = it(f, e, 14), r = it(f, e, 18), a = it(e, f, 9), i = t ^ r ^ a;
|
|
9057
9022
|
return i < 0 && (i += 4294967296), i;
|
|
9058
9023
|
}
|
|
9059
|
-
function
|
|
9024
|
+
function qo(f, e) {
|
|
9060
9025
|
var t = ft(f, e, 1), r = ft(f, e, 8), a = Pn(f, e, 7), i = t ^ r ^ a;
|
|
9061
9026
|
return i < 0 && (i += 4294967296), i;
|
|
9062
9027
|
}
|
|
9063
|
-
function
|
|
9028
|
+
function No(f, e) {
|
|
9064
9029
|
var t = it(f, e, 1), r = it(f, e, 8), a = In(f, e, 7), i = t ^ r ^ a;
|
|
9065
9030
|
return i < 0 && (i += 4294967296), i;
|
|
9066
9031
|
}
|
|
@@ -9109,14 +9074,14 @@ Yt.sha224 = Ao;
|
|
|
9109
9074
|
Yt.sha256 = Rn;
|
|
9110
9075
|
Yt.sha384 = Uo;
|
|
9111
9076
|
Yt.sha512 = On;
|
|
9112
|
-
var
|
|
9077
|
+
var qn = {}, Dt = Le, $o = Wt, ar = Dt.rotl32, Ui = Dt.sum32, Qt = Dt.sum32_3, $i = Dt.sum32_4, Nn = $o.BlockHash;
|
|
9113
9078
|
function ot() {
|
|
9114
9079
|
if (!(this instanceof ot))
|
|
9115
9080
|
return new ot();
|
|
9116
|
-
|
|
9081
|
+
Nn.call(this), this.h = [1732584193, 4023233417, 2562383102, 271733878, 3285377520], this.endian = "little";
|
|
9117
9082
|
}
|
|
9118
|
-
Dt.inherits(ot,
|
|
9119
|
-
|
|
9083
|
+
Dt.inherits(ot, Nn);
|
|
9084
|
+
qn.ripemd160 = ot;
|
|
9120
9085
|
ot.blockSize = 512;
|
|
9121
9086
|
ot.outSize = 160;
|
|
9122
9087
|
ot.hmacStrength = 192;
|
|
@@ -9501,7 +9466,7 @@ Lt.prototype.digest = function(e) {
|
|
|
9501
9466
|
};
|
|
9502
9467
|
(function(f) {
|
|
9503
9468
|
var e = f;
|
|
9504
|
-
e.utils = Le, e.common = Wt, e.sha = Yt, e.ripemd =
|
|
9469
|
+
e.utils = Le, e.common = Wt, e.sha = Yt, e.ripemd = qn, e.hmac = Qo, e.sha1 = e.sha.sha1, e.sha256 = e.sha.sha256, e.sha224 = e.sha.sha224, e.sha384 = e.sha.sha384, e.sha512 = e.sha.sha512, e.ripemd160 = e.ripemd.ripemd160;
|
|
9505
9470
|
})(Mr);
|
|
9506
9471
|
var mf, Yi;
|
|
9507
9472
|
function Jo() {
|
|
@@ -10823,9 +10788,7 @@ var Kn = { exports: {} };
|
|
|
10823
10788
|
(function(e) {
|
|
10824
10789
|
var t = function(l) {
|
|
10825
10790
|
var _, m = new Float64Array(16);
|
|
10826
|
-
if (l)
|
|
10827
|
-
for (_ = 0; _ < l.length; _++)
|
|
10828
|
-
m[_] = l[_];
|
|
10791
|
+
if (l) for (_ = 0; _ < l.length; _++) m[_] = l[_];
|
|
10829
10792
|
return m;
|
|
10830
10793
|
}, r = function() {
|
|
10831
10794
|
throw new Error("no PRNG");
|
|
@@ -10837,8 +10800,7 @@ var Kn = { exports: {} };
|
|
|
10837
10800
|
}
|
|
10838
10801
|
function R(l, _, m, s, M) {
|
|
10839
10802
|
var p, I = 0;
|
|
10840
|
-
for (p = 0; p < M; p++)
|
|
10841
|
-
I |= l[_ + p] ^ m[s + p];
|
|
10803
|
+
for (p = 0; p < M; p++) I |= l[_ + p] ^ m[s + p];
|
|
10842
10804
|
return (1 & I - 1 >>> 8) - 1;
|
|
10843
10805
|
}
|
|
10844
10806
|
function k(l, _, m, s) {
|
|
@@ -10866,52 +10828,42 @@ var Kn = { exports: {} };
|
|
|
10866
10828
|
var $ = new Uint8Array([101, 120, 112, 97, 110, 100, 32, 51, 50, 45, 98, 121, 116, 101, 32, 107]);
|
|
10867
10829
|
function K(l, _, m, s, M, p, I) {
|
|
10868
10830
|
var L = new Uint8Array(16), V = new Uint8Array(64), ne, fe;
|
|
10869
|
-
for (fe = 0; fe < 16; fe++)
|
|
10870
|
-
|
|
10871
|
-
for (fe = 0; fe < 8; fe++)
|
|
10872
|
-
L[fe] = p[fe];
|
|
10831
|
+
for (fe = 0; fe < 16; fe++) L[fe] = 0;
|
|
10832
|
+
for (fe = 0; fe < 8; fe++) L[fe] = p[fe];
|
|
10873
10833
|
for (; M >= 64; ) {
|
|
10874
|
-
for (T(V, L, I, $), fe = 0; fe < 64; fe++)
|
|
10875
|
-
l[_ + fe] = m[s + fe] ^ V[fe];
|
|
10834
|
+
for (T(V, L, I, $), fe = 0; fe < 64; fe++) l[_ + fe] = m[s + fe] ^ V[fe];
|
|
10876
10835
|
for (ne = 1, fe = 8; fe < 16; fe++)
|
|
10877
10836
|
ne = ne + (L[fe] & 255) | 0, L[fe] = ne & 255, ne >>>= 8;
|
|
10878
10837
|
M -= 64, _ += 64, s += 64;
|
|
10879
10838
|
}
|
|
10880
10839
|
if (M > 0)
|
|
10881
|
-
for (T(V, L, I, $), fe = 0; fe < M; fe++)
|
|
10882
|
-
l[_ + fe] = m[s + fe] ^ V[fe];
|
|
10840
|
+
for (T(V, L, I, $), fe = 0; fe < M; fe++) l[_ + fe] = m[s + fe] ^ V[fe];
|
|
10883
10841
|
return 0;
|
|
10884
10842
|
}
|
|
10885
10843
|
function X(l, _, m, s, M) {
|
|
10886
10844
|
var p = new Uint8Array(16), I = new Uint8Array(64), L, V;
|
|
10887
|
-
for (V = 0; V < 16; V++)
|
|
10888
|
-
|
|
10889
|
-
for (V = 0; V < 8; V++)
|
|
10890
|
-
p[V] = s[V];
|
|
10845
|
+
for (V = 0; V < 16; V++) p[V] = 0;
|
|
10846
|
+
for (V = 0; V < 8; V++) p[V] = s[V];
|
|
10891
10847
|
for (; m >= 64; ) {
|
|
10892
|
-
for (T(I, p, M, $), V = 0; V < 64; V++)
|
|
10893
|
-
l[_ + V] = I[V];
|
|
10848
|
+
for (T(I, p, M, $), V = 0; V < 64; V++) l[_ + V] = I[V];
|
|
10894
10849
|
for (L = 1, V = 8; V < 16; V++)
|
|
10895
10850
|
L = L + (p[V] & 255) | 0, p[V] = L & 255, L >>>= 8;
|
|
10896
10851
|
m -= 64, _ += 64;
|
|
10897
10852
|
}
|
|
10898
10853
|
if (m > 0)
|
|
10899
|
-
for (T(I, p, M, $), V = 0; V < m; V++)
|
|
10900
|
-
l[_ + V] = I[V];
|
|
10854
|
+
for (T(I, p, M, $), V = 0; V < m; V++) l[_ + V] = I[V];
|
|
10901
10855
|
return 0;
|
|
10902
10856
|
}
|
|
10903
10857
|
function Q(l, _, m, s, M) {
|
|
10904
10858
|
var p = new Uint8Array(32);
|
|
10905
10859
|
H(p, s, M, $);
|
|
10906
|
-
for (var I = new Uint8Array(8), L = 0; L < 8; L++)
|
|
10907
|
-
I[L] = s[L + 16];
|
|
10860
|
+
for (var I = new Uint8Array(8), L = 0; L < 8; L++) I[L] = s[L + 16];
|
|
10908
10861
|
return X(l, _, m, I, p);
|
|
10909
10862
|
}
|
|
10910
10863
|
function U(l, _, m, s, M, p, I) {
|
|
10911
10864
|
var L = new Uint8Array(32);
|
|
10912
10865
|
H(L, p, I, $);
|
|
10913
|
-
for (var V = new Uint8Array(8), ne = 0; ne < 8; ne++)
|
|
10914
|
-
V[ne] = p[ne + 16];
|
|
10866
|
+
for (var V = new Uint8Array(8), ne = 0; ne < 8; ne++) V[ne] = p[ne + 16];
|
|
10915
10867
|
return K(l, _, m, s, M, V, L);
|
|
10916
10868
|
}
|
|
10917
10869
|
var A = function(l) {
|
|
@@ -10926,18 +10878,15 @@ var Kn = { exports: {} };
|
|
|
10926
10878
|
}, A.prototype.finish = function(l, _) {
|
|
10927
10879
|
var m = new Uint16Array(10), s, M, p, I;
|
|
10928
10880
|
if (this.leftover) {
|
|
10929
|
-
for (I = this.leftover, this.buffer[I++] = 1; I < 16; I++)
|
|
10930
|
-
this.buffer[I] = 0;
|
|
10881
|
+
for (I = this.leftover, this.buffer[I++] = 1; I < 16; I++) this.buffer[I] = 0;
|
|
10931
10882
|
this.fin = 1, this.blocks(this.buffer, 0, 16);
|
|
10932
10883
|
}
|
|
10933
10884
|
for (s = this.h[1] >>> 13, this.h[1] &= 8191, I = 2; I < 10; I++)
|
|
10934
10885
|
this.h[I] += s, s = this.h[I] >>> 13, this.h[I] &= 8191;
|
|
10935
10886
|
for (this.h[0] += s * 5, s = this.h[0] >>> 13, this.h[0] &= 8191, this.h[1] += s, s = this.h[1] >>> 13, this.h[1] &= 8191, this.h[2] += s, m[0] = this.h[0] + 5, s = m[0] >>> 13, m[0] &= 8191, I = 1; I < 10; I++)
|
|
10936
10887
|
m[I] = this.h[I] + s, s = m[I] >>> 13, m[I] &= 8191;
|
|
10937
|
-
for (m[9] -= 8192, M = (s ^ 1) - 1, I = 0; I < 10; I++)
|
|
10938
|
-
|
|
10939
|
-
for (M = ~M, I = 0; I < 10; I++)
|
|
10940
|
-
this.h[I] = this.h[I] & M | m[I];
|
|
10888
|
+
for (m[9] -= 8192, M = (s ^ 1) - 1, I = 0; I < 10; I++) m[I] &= M;
|
|
10889
|
+
for (M = ~M, I = 0; I < 10; I++) this.h[I] = this.h[I] & M | m[I];
|
|
10941
10890
|
for (this.h[0] = (this.h[0] | this.h[1] << 13) & 65535, this.h[1] = (this.h[1] >>> 3 | this.h[2] << 10) & 65535, this.h[2] = (this.h[2] >>> 6 | this.h[3] << 7) & 65535, this.h[3] = (this.h[3] >>> 9 | this.h[4] << 4) & 65535, this.h[4] = (this.h[4] >>> 12 | this.h[5] << 1 | this.h[6] << 14) & 65535, this.h[5] = (this.h[6] >>> 2 | this.h[7] << 11) & 65535, this.h[6] = (this.h[7] >>> 5 | this.h[8] << 8) & 65535, this.h[7] = (this.h[8] >>> 8 | this.h[9] << 5) & 65535, p = this.h[0] + this.pad[0], this.h[0] = p & 65535, I = 1; I < 8; I++)
|
|
10942
10891
|
p = (this.h[I] + this.pad[I] | 0) + (p >>> 16) | 0, this.h[I] = p & 65535;
|
|
10943
10892
|
l[_ + 0] = this.h[0] >>> 0 & 255, l[_ + 1] = this.h[0] >>> 8 & 255, l[_ + 2] = this.h[1] >>> 0 & 255, l[_ + 3] = this.h[1] >>> 8 & 255, l[_ + 4] = this.h[2] >>> 0 & 255, l[_ + 5] = this.h[2] >>> 8 & 255, l[_ + 6] = this.h[3] >>> 0 & 255, l[_ + 7] = this.h[3] >>> 8 & 255, l[_ + 8] = this.h[4] >>> 0 & 255, l[_ + 9] = this.h[4] >>> 8 & 255, l[_ + 10] = this.h[5] >>> 0 & 255, l[_ + 11] = this.h[5] >>> 8 & 255, l[_ + 12] = this.h[6] >>> 0 & 255, l[_ + 13] = this.h[6] >>> 8 & 255, l[_ + 14] = this.h[7] >>> 0 & 255, l[_ + 15] = this.h[7] >>> 8 & 255;
|
|
@@ -10966,43 +10915,37 @@ var Kn = { exports: {} };
|
|
|
10966
10915
|
}
|
|
10967
10916
|
function g(l, _, m, s, M) {
|
|
10968
10917
|
var p;
|
|
10969
|
-
if (m < 32)
|
|
10970
|
-
|
|
10971
|
-
for (U(l, 0, _, 0, m, s, M), n(l, 16, l, 32, m - 32, l), p = 0; p < 16; p++)
|
|
10972
|
-
l[p] = 0;
|
|
10918
|
+
if (m < 32) return -1;
|
|
10919
|
+
for (U(l, 0, _, 0, m, s, M), n(l, 16, l, 32, m - 32, l), p = 0; p < 16; p++) l[p] = 0;
|
|
10973
10920
|
return 0;
|
|
10974
10921
|
}
|
|
10975
10922
|
function C(l, _, m, s, M) {
|
|
10976
10923
|
var p, I = new Uint8Array(32);
|
|
10977
|
-
if (m < 32 || (Q(I, 0, 32, s, M), d(_, 16, _, 32, m - 32, I) !== 0))
|
|
10978
|
-
|
|
10979
|
-
for (U(l, 0, _, 0, m, s, M), p = 0; p < 32; p++)
|
|
10980
|
-
l[p] = 0;
|
|
10924
|
+
if (m < 32 || (Q(I, 0, 32, s, M), d(_, 16, _, 32, m - 32, I) !== 0)) return -1;
|
|
10925
|
+
for (U(l, 0, _, 0, m, s, M), p = 0; p < 32; p++) l[p] = 0;
|
|
10981
10926
|
return 0;
|
|
10982
10927
|
}
|
|
10983
10928
|
function F(l, _) {
|
|
10984
10929
|
var m;
|
|
10985
|
-
for (m = 0; m < 16; m++)
|
|
10986
|
-
l[m] = _[m] | 0;
|
|
10930
|
+
for (m = 0; m < 16; m++) l[m] = _[m] | 0;
|
|
10987
10931
|
}
|
|
10988
|
-
function
|
|
10932
|
+
function q(l) {
|
|
10989
10933
|
var _, m, s = 1;
|
|
10990
10934
|
for (_ = 0; _ < 16; _++)
|
|
10991
10935
|
m = l[_] + s + 65535, s = Math.floor(m / 65536), l[_] = m - s * 65536;
|
|
10992
10936
|
l[0] += s - 1 + 37 * (s - 1);
|
|
10993
10937
|
}
|
|
10994
|
-
function
|
|
10938
|
+
function N(l, _, m) {
|
|
10995
10939
|
for (var s, M = ~(m - 1), p = 0; p < 16; p++)
|
|
10996
10940
|
s = M & (l[p] ^ _[p]), l[p] ^= s, _[p] ^= s;
|
|
10997
10941
|
}
|
|
10998
10942
|
function D(l, _) {
|
|
10999
10943
|
var m, s, M, p = t(), I = t();
|
|
11000
|
-
for (m = 0; m < 16; m++)
|
|
11001
|
-
|
|
11002
|
-
for (N(I), N(I), N(I), s = 0; s < 2; s++) {
|
|
10944
|
+
for (m = 0; m < 16; m++) I[m] = _[m];
|
|
10945
|
+
for (q(I), q(I), q(I), s = 0; s < 2; s++) {
|
|
11003
10946
|
for (p[0] = I[0] - 65517, m = 1; m < 15; m++)
|
|
11004
10947
|
p[m] = I[m] - 65535 - (p[m - 1] >> 16 & 1), p[m - 1] &= 65535;
|
|
11005
|
-
p[15] = I[15] - 32767 - (p[14] >> 16 & 1), M = p[15] >> 16 & 1, p[14] &= 65535,
|
|
10948
|
+
p[15] = I[15] - 32767 - (p[14] >> 16 & 1), M = p[15] >> 16 & 1, p[14] &= 65535, N(I, p, 1 - M);
|
|
11006
10949
|
}
|
|
11007
10950
|
for (m = 0; m < 16; m++)
|
|
11008
10951
|
l[2 * m] = I[m] & 255, l[2 * m + 1] = I[m] >> 8;
|
|
@@ -11017,17 +10960,14 @@ var Kn = { exports: {} };
|
|
|
11017
10960
|
}
|
|
11018
10961
|
function j(l, _) {
|
|
11019
10962
|
var m;
|
|
11020
|
-
for (m = 0; m < 16; m++)
|
|
11021
|
-
l[m] = _[2 * m] + (_[2 * m + 1] << 8);
|
|
10963
|
+
for (m = 0; m < 16; m++) l[m] = _[2 * m] + (_[2 * m + 1] << 8);
|
|
11022
10964
|
l[15] &= 32767;
|
|
11023
10965
|
}
|
|
11024
10966
|
function Y(l, _, m) {
|
|
11025
|
-
for (var s = 0; s < 16; s++)
|
|
11026
|
-
l[s] = _[s] + m[s];
|
|
10967
|
+
for (var s = 0; s < 16; s++) l[s] = _[s] + m[s];
|
|
11027
10968
|
}
|
|
11028
10969
|
function W(l, _, m) {
|
|
11029
|
-
for (var s = 0; s < 16; s++)
|
|
11030
|
-
l[s] = _[s] - m[s];
|
|
10970
|
+
for (var s = 0; s < 16; s++) l[s] = _[s] - m[s];
|
|
11031
10971
|
}
|
|
11032
10972
|
function re(l, _, m) {
|
|
11033
10973
|
var s, M, p = 0, I = 0, L = 0, V = 0, ne = 0, fe = 0, he = 0, te = 0, xe = 0, ue = 0, ve = 0, ge = 0, me = 0, _e = 0, pe = 0, de = 0, ye = 0, oe = 0, le = 0, be = 0, se = 0, Z = 0, G = 0, ie = 0, J = 0, ee = 0, ae = 0, Ee = 0, Be = 0, De = 0, Ce = 0, O = m[0], Te = m[1], Xe = m[2], Ze = m[3], ke = m[4], Ke = m[5], je = m[6], m0 = m[7], h0 = m[8], b0 = m[9], p0 = m[10], y0 = m[11], E0 = m[12], k0 = m[13], P0 = m[14], I0 = m[15];
|
|
@@ -11038,30 +10978,25 @@ var Kn = { exports: {} };
|
|
|
11038
10978
|
}
|
|
11039
10979
|
function we(l, _) {
|
|
11040
10980
|
var m = t(), s;
|
|
11041
|
-
for (s = 0; s < 16; s++)
|
|
11042
|
-
m[s] = _[s];
|
|
10981
|
+
for (s = 0; s < 16; s++) m[s] = _[s];
|
|
11043
10982
|
for (s = 253; s >= 0; s--)
|
|
11044
10983
|
ce(m, m), s !== 2 && s !== 4 && re(m, m, _);
|
|
11045
|
-
for (s = 0; s < 16; s++)
|
|
11046
|
-
l[s] = m[s];
|
|
10984
|
+
for (s = 0; s < 16; s++) l[s] = m[s];
|
|
11047
10985
|
}
|
|
11048
10986
|
function Ae(l, _) {
|
|
11049
10987
|
var m = t(), s;
|
|
11050
|
-
for (s = 0; s < 16; s++)
|
|
11051
|
-
m[s] = _[s];
|
|
10988
|
+
for (s = 0; s < 16; s++) m[s] = _[s];
|
|
11052
10989
|
for (s = 250; s >= 0; s--)
|
|
11053
10990
|
ce(m, m), s !== 1 && re(m, m, _);
|
|
11054
|
-
for (s = 0; s < 16; s++)
|
|
11055
|
-
l[s] = m[s];
|
|
10991
|
+
for (s = 0; s < 16; s++) l[s] = m[s];
|
|
11056
10992
|
}
|
|
11057
10993
|
function Me(l, _, m) {
|
|
11058
10994
|
var s = new Uint8Array(32), M = new Float64Array(80), p, I, L = t(), V = t(), ne = t(), fe = t(), he = t(), te = t();
|
|
11059
|
-
for (I = 0; I < 31; I++)
|
|
11060
|
-
s[I] = _[I];
|
|
10995
|
+
for (I = 0; I < 31; I++) s[I] = _[I];
|
|
11061
10996
|
for (s[31] = _[31] & 127 | 64, s[0] &= 248, j(M, m), I = 0; I < 16; I++)
|
|
11062
10997
|
V[I] = M[I], fe[I] = L[I] = ne[I] = 0;
|
|
11063
10998
|
for (L[0] = fe[0] = 1, I = 254; I >= 0; --I)
|
|
11064
|
-
p = s[I >>> 3] >>> (I & 7) & 1,
|
|
10999
|
+
p = s[I >>> 3] >>> (I & 7) & 1, N(L, V, p), N(ne, fe, p), Y(he, L, ne), W(L, L, ne), Y(ne, V, fe), W(V, V, fe), ce(fe, he), ce(te, L), re(L, ne, L), re(ne, V, he), Y(he, L, ne), W(L, L, ne), ce(V, L), W(ne, fe, te), re(L, ne, u), Y(L, L, fe), re(ne, ne, L), re(L, fe, te), re(fe, V, M), ce(V, he), N(L, V, p), N(ne, fe, p);
|
|
11065
11000
|
for (I = 0; I < 16; I++)
|
|
11066
11001
|
M[I + 16] = L[I], M[I + 32] = ne[I], M[I + 48] = V[I], M[I + 64] = fe[I];
|
|
11067
11002
|
var xe = M.subarray(32), ue = M.subarray(16);
|
|
@@ -11262,20 +11197,18 @@ var Kn = { exports: {} };
|
|
|
11262
11197
|
}
|
|
11263
11198
|
function ze(l, _, m) {
|
|
11264
11199
|
var s = new Int32Array(8), M = new Int32Array(8), p = new Uint8Array(256), I, L = m;
|
|
11265
|
-
for (s[0] = 1779033703, s[1] = 3144134277, s[2] = 1013904242, s[3] = 2773480762, s[4] = 1359893119, s[5] = 2600822924, s[6] = 528734635, s[7] = 1541459225, M[0] = 4089235720, M[1] = 2227873595, M[2] = 4271175723, M[3] = 1595750129, M[4] = 2917565137, M[5] = 725511199, M[6] = 4215389547, M[7] = 327033209, Qe(s, M, _, m), m %= 128, I = 0; I < m; I++)
|
|
11266
|
-
|
|
11267
|
-
for (p[m] = 128, m = 256 - 128 * (m < 112 ? 1 : 0), p[m - 9] = 0, w(p, m - 8, L / 536870912 | 0, L << 3), Qe(s, M, p, m), I = 0; I < 8; I++)
|
|
11268
|
-
w(l, 8 * I, s[I], M[I]);
|
|
11200
|
+
for (s[0] = 1779033703, s[1] = 3144134277, s[2] = 1013904242, s[3] = 2773480762, s[4] = 1359893119, s[5] = 2600822924, s[6] = 528734635, s[7] = 1541459225, M[0] = 4089235720, M[1] = 2227873595, M[2] = 4271175723, M[3] = 1595750129, M[4] = 2917565137, M[5] = 725511199, M[6] = 4215389547, M[7] = 327033209, Qe(s, M, _, m), m %= 128, I = 0; I < m; I++) p[I] = _[L - m + I];
|
|
11201
|
+
for (p[m] = 128, m = 256 - 128 * (m < 112 ? 1 : 0), p[m - 9] = 0, w(p, m - 8, L / 536870912 | 0, L << 3), Qe(s, M, p, m), I = 0; I < 8; I++) w(l, 8 * I, s[I], M[I]);
|
|
11269
11202
|
return 0;
|
|
11270
11203
|
}
|
|
11271
11204
|
function O0(l, _) {
|
|
11272
11205
|
var m = t(), s = t(), M = t(), p = t(), I = t(), L = t(), V = t(), ne = t(), fe = t();
|
|
11273
11206
|
W(m, l[1], l[0]), W(fe, _[1], _[0]), re(m, m, fe), Y(s, l[0], l[1]), Y(fe, _[0], _[1]), re(s, s, fe), re(M, l[3], _[3]), re(M, M, c), re(p, l[2], _[2]), Y(p, p, p), W(I, s, m), W(L, p, M), Y(V, p, M), Y(ne, s, m), re(l[0], I, L), re(l[1], ne, V), re(l[2], V, L), re(l[3], I, ne);
|
|
11274
11207
|
}
|
|
11275
|
-
function
|
|
11208
|
+
function qe(l, _, m) {
|
|
11276
11209
|
var s;
|
|
11277
11210
|
for (s = 0; s < 4; s++)
|
|
11278
|
-
|
|
11211
|
+
N(l[s], _[s], m);
|
|
11279
11212
|
}
|
|
11280
11213
|
function Se(l, _) {
|
|
11281
11214
|
var m = t(), s = t(), M = t();
|
|
@@ -11284,7 +11217,7 @@ var Kn = { exports: {} };
|
|
|
11284
11217
|
function F0(l, _, m) {
|
|
11285
11218
|
var s, M;
|
|
11286
11219
|
for (F(l[0], y), F(l[1], x), F(l[2], x), F(l[3], y), M = 255; M >= 0; --M)
|
|
11287
|
-
s = m[M / 8 | 0] >> (M & 7) & 1,
|
|
11220
|
+
s = m[M / 8 | 0] >> (M & 7) & 1, qe(l, _, s), O0(_, l), O0(l, l), qe(l, _, s);
|
|
11288
11221
|
}
|
|
11289
11222
|
function Je(l, _) {
|
|
11290
11223
|
var m = [t(), t(), t(), t()];
|
|
@@ -11292,12 +11225,11 @@ var Kn = { exports: {} };
|
|
|
11292
11225
|
}
|
|
11293
11226
|
function f0(l, _, m) {
|
|
11294
11227
|
var s = new Uint8Array(64), M = [t(), t(), t(), t()], p;
|
|
11295
|
-
for (m || r(_, 32), ze(s, _, 32), s[0] &= 248, s[31] &= 127, s[31] |= 64, Je(M, s), Se(l, M), p = 0; p < 32; p++)
|
|
11296
|
-
_[p + 32] = l[p];
|
|
11228
|
+
for (m || r(_, 32), ze(s, _, 32), s[0] &= 248, s[31] &= 127, s[31] |= 64, Je(M, s), Se(l, M), p = 0; p < 32; p++) _[p + 32] = l[p];
|
|
11297
11229
|
return 0;
|
|
11298
11230
|
}
|
|
11299
11231
|
var S0 = new Float64Array([237, 211, 245, 92, 26, 99, 18, 88, 214, 156, 247, 162, 222, 249, 222, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16]);
|
|
11300
|
-
function
|
|
11232
|
+
function Ne(l, _) {
|
|
11301
11233
|
var m, s, M, p;
|
|
11302
11234
|
for (s = 63; s >= 32; --s) {
|
|
11303
11235
|
for (m = 0, M = s - 32, p = s - 12; M < p; ++M)
|
|
@@ -11306,37 +11238,29 @@ var Kn = { exports: {} };
|
|
|
11306
11238
|
}
|
|
11307
11239
|
for (m = 0, M = 0; M < 32; M++)
|
|
11308
11240
|
_[M] += m - (_[31] >> 4) * S0[M], m = _[M] >> 8, _[M] &= 255;
|
|
11309
|
-
for (M = 0; M < 32; M++)
|
|
11310
|
-
_[M] -= m * S0[M];
|
|
11241
|
+
for (M = 0; M < 32; M++) _[M] -= m * S0[M];
|
|
11311
11242
|
for (s = 0; s < 32; s++)
|
|
11312
11243
|
_[s + 1] += _[s] >> 8, l[s] = _[s] & 255;
|
|
11313
11244
|
}
|
|
11314
11245
|
function u0(l) {
|
|
11315
11246
|
var _ = new Float64Array(64), m;
|
|
11316
|
-
for (m = 0; m < 64; m++)
|
|
11317
|
-
|
|
11318
|
-
|
|
11319
|
-
l[m] = 0;
|
|
11320
|
-
qe(l, _);
|
|
11247
|
+
for (m = 0; m < 64; m++) _[m] = l[m];
|
|
11248
|
+
for (m = 0; m < 64; m++) l[m] = 0;
|
|
11249
|
+
Ne(l, _);
|
|
11321
11250
|
}
|
|
11322
11251
|
function G0(l, _, m, s) {
|
|
11323
11252
|
var M = new Uint8Array(64), p = new Uint8Array(64), I = new Uint8Array(64), L, V, ne = new Float64Array(64), fe = [t(), t(), t(), t()];
|
|
11324
11253
|
ze(M, s, 32), M[0] &= 248, M[31] &= 127, M[31] |= 64;
|
|
11325
11254
|
var he = m + 64;
|
|
11326
|
-
for (L = 0; L < m; L++)
|
|
11327
|
-
|
|
11328
|
-
for (L =
|
|
11329
|
-
|
|
11330
|
-
for (
|
|
11331
|
-
l[L] = s[L];
|
|
11332
|
-
for (ze(p, l, m + 64), u0(p), L = 0; L < 64; L++)
|
|
11333
|
-
ne[L] = 0;
|
|
11334
|
-
for (L = 0; L < 32; L++)
|
|
11335
|
-
ne[L] = I[L];
|
|
11255
|
+
for (L = 0; L < m; L++) l[64 + L] = _[L];
|
|
11256
|
+
for (L = 0; L < 32; L++) l[32 + L] = M[32 + L];
|
|
11257
|
+
for (ze(I, l.subarray(32), m + 32), u0(I), Je(fe, I), Se(l, fe), L = 32; L < 64; L++) l[L] = s[L];
|
|
11258
|
+
for (ze(p, l, m + 64), u0(p), L = 0; L < 64; L++) ne[L] = 0;
|
|
11259
|
+
for (L = 0; L < 32; L++) ne[L] = I[L];
|
|
11336
11260
|
for (L = 0; L < 32; L++)
|
|
11337
11261
|
for (V = 0; V < 32; V++)
|
|
11338
11262
|
ne[L + V] += p[L] * M[V];
|
|
11339
|
-
return
|
|
11263
|
+
return Ne(l.subarray(32), ne), he;
|
|
11340
11264
|
}
|
|
11341
11265
|
function l0(l, _) {
|
|
11342
11266
|
var m = t(), s = t(), M = t(), p = t(), I = t(), L = t(), V = t();
|
|
@@ -11344,22 +11268,17 @@ var Kn = { exports: {} };
|
|
|
11344
11268
|
}
|
|
11345
11269
|
function He(l, _, m, s) {
|
|
11346
11270
|
var M, p = new Uint8Array(32), I = new Uint8Array(64), L = [t(), t(), t(), t()], V = [t(), t(), t(), t()];
|
|
11347
|
-
if (m < 64 || l0(V, s))
|
|
11348
|
-
|
|
11349
|
-
for (M = 0; M <
|
|
11350
|
-
l[M] = _[M];
|
|
11351
|
-
for (M = 0; M < 32; M++)
|
|
11352
|
-
l[M + 32] = s[M];
|
|
11271
|
+
if (m < 64 || l0(V, s)) return -1;
|
|
11272
|
+
for (M = 0; M < m; M++) l[M] = _[M];
|
|
11273
|
+
for (M = 0; M < 32; M++) l[M + 32] = s[M];
|
|
11353
11274
|
if (ze(I, l, m), u0(I), F0(L, V, I), Je(V, _.subarray(32)), O0(L, V), Se(p, L), m -= 64, z(_, 0, p, 0)) {
|
|
11354
|
-
for (M = 0; M < m; M++)
|
|
11355
|
-
l[M] = 0;
|
|
11275
|
+
for (M = 0; M < m; M++) l[M] = 0;
|
|
11356
11276
|
return -1;
|
|
11357
11277
|
}
|
|
11358
|
-
for (M = 0; M < m; M++)
|
|
11359
|
-
l[M] = _[M + 64];
|
|
11278
|
+
for (M = 0; M < m; M++) l[M] = _[M + 64];
|
|
11360
11279
|
return m;
|
|
11361
11280
|
}
|
|
11362
|
-
var z0 = 32, a0 = 24, r0 = 32,
|
|
11281
|
+
var z0 = 32, a0 = 24, r0 = 32, q0 = 16, i0 = 32, s0 = 32, W0 = 32, e0 = 32, n0 = 32, N0 = a0, o0 = r0, x0 = q0, D0 = 64, t0 = 32, Ve = 64, tt = 32, c0 = 64;
|
|
11363
11282
|
e.lowlevel = {
|
|
11364
11283
|
crypto_core_hsalsa20: H,
|
|
11365
11284
|
crypto_stream_xor: U,
|
|
@@ -11386,13 +11305,13 @@ var Kn = { exports: {} };
|
|
|
11386
11305
|
crypto_secretbox_KEYBYTES: z0,
|
|
11387
11306
|
crypto_secretbox_NONCEBYTES: a0,
|
|
11388
11307
|
crypto_secretbox_ZEROBYTES: r0,
|
|
11389
|
-
crypto_secretbox_BOXZEROBYTES:
|
|
11308
|
+
crypto_secretbox_BOXZEROBYTES: q0,
|
|
11390
11309
|
crypto_scalarmult_BYTES: i0,
|
|
11391
11310
|
crypto_scalarmult_SCALARBYTES: s0,
|
|
11392
11311
|
crypto_box_PUBLICKEYBYTES: W0,
|
|
11393
11312
|
crypto_box_SECRETKEYBYTES: e0,
|
|
11394
11313
|
crypto_box_BEFORENMBYTES: n0,
|
|
11395
|
-
crypto_box_NONCEBYTES:
|
|
11314
|
+
crypto_box_NONCEBYTES: N0,
|
|
11396
11315
|
crypto_box_ZEROBYTES: o0,
|
|
11397
11316
|
crypto_box_BOXZEROBYTES: x0,
|
|
11398
11317
|
crypto_sign_BYTES: D0,
|
|
@@ -11412,21 +11331,17 @@ var Kn = { exports: {} };
|
|
|
11412
11331
|
pow2523: Ae,
|
|
11413
11332
|
add: O0,
|
|
11414
11333
|
set25519: F,
|
|
11415
|
-
modL:
|
|
11334
|
+
modL: Ne,
|
|
11416
11335
|
scalarmult: F0,
|
|
11417
11336
|
scalarbase: Je
|
|
11418
11337
|
};
|
|
11419
11338
|
function d0(l, _) {
|
|
11420
|
-
if (l.length !== z0)
|
|
11421
|
-
|
|
11422
|
-
if (_.length !== a0)
|
|
11423
|
-
throw new Error("bad nonce size");
|
|
11339
|
+
if (l.length !== z0) throw new Error("bad key size");
|
|
11340
|
+
if (_.length !== a0) throw new Error("bad nonce size");
|
|
11424
11341
|
}
|
|
11425
11342
|
function yt(l, _) {
|
|
11426
|
-
if (l.length !== W0)
|
|
11427
|
-
|
|
11428
|
-
if (_.length !== e0)
|
|
11429
|
-
throw new Error("bad secret key size");
|
|
11343
|
+
if (l.length !== W0) throw new Error("bad public key size");
|
|
11344
|
+
if (_.length !== e0) throw new Error("bad secret key size");
|
|
11430
11345
|
}
|
|
11431
11346
|
function Ie() {
|
|
11432
11347
|
for (var l = 0; l < arguments.length; l++)
|
|
@@ -11434,32 +11349,26 @@ var Kn = { exports: {} };
|
|
|
11434
11349
|
throw new TypeError("unexpected type, use Uint8Array");
|
|
11435
11350
|
}
|
|
11436
11351
|
function Re(l) {
|
|
11437
|
-
for (var _ = 0; _ < l.length; _++)
|
|
11438
|
-
l[_] = 0;
|
|
11352
|
+
for (var _ = 0; _ < l.length; _++) l[_] = 0;
|
|
11439
11353
|
}
|
|
11440
11354
|
e.randomBytes = function(l) {
|
|
11441
11355
|
var _ = new Uint8Array(l);
|
|
11442
11356
|
return r(_, l), _;
|
|
11443
11357
|
}, e.secretbox = function(l, _, m) {
|
|
11444
11358
|
Ie(l, _, m), d0(m, _);
|
|
11445
|
-
for (var s = new Uint8Array(r0 + l.length), M = new Uint8Array(s.length), p = 0; p < l.length; p++)
|
|
11446
|
-
|
|
11447
|
-
return g(M, s, s.length, _, m), M.subarray(N0);
|
|
11359
|
+
for (var s = new Uint8Array(r0 + l.length), M = new Uint8Array(s.length), p = 0; p < l.length; p++) s[p + r0] = l[p];
|
|
11360
|
+
return g(M, s, s.length, _, m), M.subarray(q0);
|
|
11448
11361
|
}, e.secretbox.open = function(l, _, m) {
|
|
11449
11362
|
Ie(l, _, m), d0(m, _);
|
|
11450
|
-
for (var s = new Uint8Array(
|
|
11451
|
-
s[p + N0] = l[p];
|
|
11363
|
+
for (var s = new Uint8Array(q0 + l.length), M = new Uint8Array(s.length), p = 0; p < l.length; p++) s[p + q0] = l[p];
|
|
11452
11364
|
return s.length < 32 || C(M, s, s.length, _, m) !== 0 ? null : M.subarray(r0);
|
|
11453
|
-
}, e.secretbox.keyLength = z0, e.secretbox.nonceLength = a0, e.secretbox.overheadLength =
|
|
11454
|
-
if (Ie(l, _), l.length !== s0)
|
|
11455
|
-
|
|
11456
|
-
if (_.length !== i0)
|
|
11457
|
-
throw new Error("bad p size");
|
|
11365
|
+
}, e.secretbox.keyLength = z0, e.secretbox.nonceLength = a0, e.secretbox.overheadLength = q0, e.scalarMult = function(l, _) {
|
|
11366
|
+
if (Ie(l, _), l.length !== s0) throw new Error("bad n size");
|
|
11367
|
+
if (_.length !== i0) throw new Error("bad p size");
|
|
11458
11368
|
var m = new Uint8Array(i0);
|
|
11459
11369
|
return Me(m, l, _), m;
|
|
11460
11370
|
}, e.scalarMult.base = function(l) {
|
|
11461
|
-
if (Ie(l), l.length !== s0)
|
|
11462
|
-
throw new Error("bad n size");
|
|
11371
|
+
if (Ie(l), l.length !== s0) throw new Error("bad n size");
|
|
11463
11372
|
var _ = new Uint8Array(i0);
|
|
11464
11373
|
return Fe(_, l), _;
|
|
11465
11374
|
}, e.scalarMult.scalarLength = s0, e.scalarMult.groupElementLength = i0, e.box = function(l, _, m, s) {
|
|
@@ -11480,7 +11389,7 @@ var Kn = { exports: {} };
|
|
|
11480
11389
|
throw new Error("bad secret key size");
|
|
11481
11390
|
var _ = new Uint8Array(W0);
|
|
11482
11391
|
return Fe(_, l), { publicKey: _, secretKey: new Uint8Array(l) };
|
|
11483
|
-
}, e.box.publicKeyLength = W0, e.box.secretKeyLength = e0, e.box.sharedKeyLength = n0, e.box.nonceLength =
|
|
11392
|
+
}, e.box.publicKeyLength = W0, e.box.secretKeyLength = e0, e.box.sharedKeyLength = n0, e.box.nonceLength = N0, e.box.overheadLength = e.secretbox.overheadLength, e.sign = function(l, _) {
|
|
11484
11393
|
if (Ie(l, _), _.length !== Ve)
|
|
11485
11394
|
throw new Error("bad secret key size");
|
|
11486
11395
|
var m = new Uint8Array(D0 + l.length);
|
|
@@ -11489,14 +11398,11 @@ var Kn = { exports: {} };
|
|
|
11489
11398
|
if (Ie(l, _), _.length !== t0)
|
|
11490
11399
|
throw new Error("bad public key size");
|
|
11491
11400
|
var m = new Uint8Array(l.length), s = He(m, l, l.length, _);
|
|
11492
|
-
if (s < 0)
|
|
11493
|
-
|
|
11494
|
-
for (var M = new Uint8Array(s), p = 0; p < M.length; p++)
|
|
11495
|
-
M[p] = m[p];
|
|
11401
|
+
if (s < 0) return null;
|
|
11402
|
+
for (var M = new Uint8Array(s), p = 0; p < M.length; p++) M[p] = m[p];
|
|
11496
11403
|
return M;
|
|
11497
11404
|
}, e.sign.detached = function(l, _) {
|
|
11498
|
-
for (var m = e.sign(l, _), s = new Uint8Array(D0), M = 0; M < s.length; M++)
|
|
11499
|
-
s[M] = m[M];
|
|
11405
|
+
for (var m = e.sign(l, _), s = new Uint8Array(D0), M = 0; M < s.length; M++) s[M] = m[M];
|
|
11500
11406
|
return s;
|
|
11501
11407
|
}, e.sign.detached.verify = function(l, _, m) {
|
|
11502
11408
|
if (Ie(l, _, m), _.length !== D0)
|
|
@@ -11504,10 +11410,8 @@ var Kn = { exports: {} };
|
|
|
11504
11410
|
if (m.length !== t0)
|
|
11505
11411
|
throw new Error("bad public key size");
|
|
11506
11412
|
var s = new Uint8Array(D0 + l.length), M = new Uint8Array(D0 + l.length), p;
|
|
11507
|
-
for (p = 0; p < D0; p++)
|
|
11508
|
-
|
|
11509
|
-
for (p = 0; p < l.length; p++)
|
|
11510
|
-
s[p + D0] = l[p];
|
|
11413
|
+
for (p = 0; p < D0; p++) s[p] = _[p];
|
|
11414
|
+
for (p = 0; p < l.length; p++) s[p + D0] = l[p];
|
|
11511
11415
|
return He(M, s, s.length, m) >= 0;
|
|
11512
11416
|
}, e.sign.keyPair = function() {
|
|
11513
11417
|
var l = new Uint8Array(t0), _ = new Uint8Array(Ve);
|
|
@@ -11515,14 +11419,12 @@ var Kn = { exports: {} };
|
|
|
11515
11419
|
}, e.sign.keyPair.fromSecretKey = function(l) {
|
|
11516
11420
|
if (Ie(l), l.length !== Ve)
|
|
11517
11421
|
throw new Error("bad secret key size");
|
|
11518
|
-
for (var _ = new Uint8Array(t0), m = 0; m < _.length; m++)
|
|
11519
|
-
_[m] = l[32 + m];
|
|
11422
|
+
for (var _ = new Uint8Array(t0), m = 0; m < _.length; m++) _[m] = l[32 + m];
|
|
11520
11423
|
return { publicKey: _, secretKey: new Uint8Array(l) };
|
|
11521
11424
|
}, e.sign.keyPair.fromSeed = function(l) {
|
|
11522
11425
|
if (Ie(l), l.length !== tt)
|
|
11523
11426
|
throw new Error("bad seed size");
|
|
11524
|
-
for (var _ = new Uint8Array(t0), m = new Uint8Array(Ve), s = 0; s < 32; s++)
|
|
11525
|
-
m[s] = l[s];
|
|
11427
|
+
for (var _ = new Uint8Array(t0), m = new Uint8Array(Ve), s = 0; s < 32; s++) m[s] = l[s];
|
|
11526
11428
|
return f0(_, m, !0), { publicKey: _, secretKey: m };
|
|
11527
11429
|
}, e.sign.publicKeyLength = t0, e.sign.secretKeyLength = Ve, e.sign.seedLength = tt, e.sign.signatureLength = D0, e.hash = function(l) {
|
|
11528
11430
|
Ie(l);
|
|
@@ -11540,17 +11442,14 @@ var Kn = { exports: {} };
|
|
|
11540
11442
|
var M, p = new Uint8Array(s);
|
|
11541
11443
|
for (M = 0; M < s; M += _)
|
|
11542
11444
|
l.getRandomValues(p.subarray(M, M + Math.min(s - M, _)));
|
|
11543
|
-
for (M = 0; M < s; M++)
|
|
11544
|
-
m[M] = p[M];
|
|
11445
|
+
for (M = 0; M < s; M++) m[M] = p[M];
|
|
11545
11446
|
Re(p);
|
|
11546
11447
|
});
|
|
11547
|
-
} else
|
|
11548
|
-
|
|
11549
|
-
|
|
11550
|
-
|
|
11551
|
-
|
|
11552
|
-
Re(p);
|
|
11553
|
-
}));
|
|
11448
|
+
} else typeof vn < "u" && (l = mr, l && l.randomBytes && e.setPRNG(function(m, s) {
|
|
11449
|
+
var M, p = l.randomBytes(s);
|
|
11450
|
+
for (M = 0; M < s; M++) m[M] = p[M];
|
|
11451
|
+
Re(p);
|
|
11452
|
+
}));
|
|
11554
11453
|
}();
|
|
11555
11454
|
})(f.exports ? f.exports : self.nacl = self.nacl || {});
|
|
11556
11455
|
})(Kn);
|
|
@@ -11851,8 +11750,7 @@ function kc(f, e) {
|
|
|
11851
11750
|
}
|
|
11852
11751
|
const Jn = 4;
|
|
11853
11752
|
function A0(f) {
|
|
11854
|
-
if (f)
|
|
11855
|
-
return Pc(f);
|
|
11753
|
+
if (f) return Pc(f);
|
|
11856
11754
|
}
|
|
11857
11755
|
function Pc(f) {
|
|
11858
11756
|
for (var e in A0.prototype)
|
|
@@ -11872,8 +11770,7 @@ A0.prototype.off = A0.prototype.removeListener = A0.prototype.removeAllListeners
|
|
|
11872
11770
|
if (this._callbacks = this._callbacks || {}, arguments.length == 0)
|
|
11873
11771
|
return this._callbacks = {}, this;
|
|
11874
11772
|
var t = this._callbacks["$" + f];
|
|
11875
|
-
if (!t)
|
|
11876
|
-
return this;
|
|
11773
|
+
if (!t) return this;
|
|
11877
11774
|
if (arguments.length == 1)
|
|
11878
11775
|
return delete this._callbacks["$" + f], this;
|
|
11879
11776
|
for (var r, a = 0; a < t.length; a++)
|
|
@@ -11911,15 +11808,15 @@ function Pr(f, e) {
|
|
|
11911
11808
|
}
|
|
11912
11809
|
const Oc = 1.33;
|
|
11913
11810
|
function zc(f) {
|
|
11914
|
-
return typeof f == "string" ?
|
|
11811
|
+
return typeof f == "string" ? qc(f) : Math.ceil((f.byteLength || f.size) * Oc);
|
|
11915
11812
|
}
|
|
11916
|
-
function
|
|
11813
|
+
function qc(f) {
|
|
11917
11814
|
let e = 0, t = 0;
|
|
11918
11815
|
for (let r = 0, a = f.length; r < a; r++)
|
|
11919
11816
|
e = f.charCodeAt(r), e < 128 ? t += 1 : e < 2048 ? t += 2 : e < 55296 || e >= 57344 ? t += 3 : (r++, t += 4);
|
|
11920
11817
|
return t;
|
|
11921
11818
|
}
|
|
11922
|
-
function
|
|
11819
|
+
function Nc(f) {
|
|
11923
11820
|
let e = "";
|
|
11924
11821
|
for (let t in f)
|
|
11925
11822
|
f.hasOwnProperty(t) && (e.length && (e += "&"), e += encodeURIComponent(t) + "=" + encodeURIComponent(f[t]));
|
|
@@ -12032,7 +11929,7 @@ class Zf extends A0 {
|
|
|
12032
11929
|
return this.opts.port && (this.opts.secure && +(this.opts.port !== 443) || !this.opts.secure && Number(this.opts.port) !== 80) ? ":" + this.opts.port : "";
|
|
12033
11930
|
}
|
|
12034
11931
|
_query(e) {
|
|
12035
|
-
const t =
|
|
11932
|
+
const t = Nc(e);
|
|
12036
11933
|
return t.length ? "?" + t : "";
|
|
12037
11934
|
}
|
|
12038
11935
|
}
|
|
@@ -13972,7 +13869,7 @@ class b1 {
|
|
|
13972
13869
|
// 타입 가드 함수
|
|
13973
13870
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
13974
13871
|
isAccountCryptoType(e) {
|
|
13975
|
-
return typeof e == "object" && e !== null && typeof e.signature == "string" && typeof e.publicKey == "string" && typeof e.address == "string" && typeof e.network == "string" && typeof e.
|
|
13872
|
+
return typeof e == "object" && e !== null && typeof e.signature == "string" && typeof e.publicKey == "string" && typeof e.address == "string" && typeof e.network == "string" && typeof e.etc == "string";
|
|
13976
13873
|
}
|
|
13977
13874
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
13978
13875
|
// private isSignature(obj: any): obj is SignatureType {
|
|
@@ -14019,10 +13916,10 @@ class b1 {
|
|
|
14019
13916
|
t = `${t}
|
|
14020
13917
|
|
|
14021
13918
|
Nonce: ${r}`, await this.sendMessage(e, t);
|
|
14022
|
-
const { publicKey: i, signature: y, address: x, network: u
|
|
14023
|
-
if (!jn.xphereVerify(t, i, y))
|
|
13919
|
+
const { publicKey: i, signature: y, address: x, network: u } = await this.getAccountCrypto();
|
|
13920
|
+
if (console.log("msg2: ", t), console.log("pub2: ", i), console.log("sig2: ", y), !jn.xphereVerify(t, i, y))
|
|
14024
13921
|
throw new Error("Verification failed");
|
|
14025
|
-
return { address: x, network: u, signature: y, publicKey: i
|
|
13922
|
+
return { address: x, network: u, signature: y, publicKey: i };
|
|
14026
13923
|
} else
|
|
14027
13924
|
throw new Error("Verification failed");
|
|
14028
13925
|
} catch (a) {
|
|
@@ -14054,7 +13951,7 @@ const oa = new y1(), ca = "data:image/svg+xml,%3csvg%20width='167'%20height='166
|
|
|
14054
13951
|
logoSize: x = 30,
|
|
14055
13952
|
...u
|
|
14056
13953
|
}) => {
|
|
14057
|
-
const [o, c] =
|
|
13954
|
+
const [o, c] = qf(!0), v = jn.generateNonce(16), { qrCode: b, roomId: B } = oa.generateQrCode("login", e, t, f);
|
|
14058
13955
|
return zt(() => {
|
|
14059
13956
|
const w = setTimeout(
|
|
14060
13957
|
() => {
|
|
@@ -14072,17 +13969,14 @@ const oa = new y1(), ca = "data:image/svg+xml,%3csvg%20width='167'%20height='166
|
|
|
14072
13969
|
Nonce: ${v}`, z = {
|
|
14073
13970
|
publicKey: R.publicKey,
|
|
14074
13971
|
message: k
|
|
14075
|
-
},
|
|
13972
|
+
}, S = {
|
|
14076
13973
|
isSuccess: !0,
|
|
14077
|
-
|
|
14078
|
-
|
|
14079
|
-
|
|
14080
|
-
|
|
14081
|
-
},
|
|
14082
|
-
payload: z,
|
|
14083
|
-
signature: R.signature
|
|
13974
|
+
address: R.address,
|
|
13975
|
+
network: R.network,
|
|
13976
|
+
signature: R.signature,
|
|
13977
|
+
payload: z
|
|
14084
13978
|
};
|
|
14085
|
-
i(
|
|
13979
|
+
i(S);
|
|
14086
13980
|
} catch {
|
|
14087
13981
|
i({
|
|
14088
13982
|
isSuccess: !1
|
|
@@ -14102,7 +13996,7 @@ class g1 {
|
|
|
14102
13996
|
// 타입 가드 함수
|
|
14103
13997
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
14104
13998
|
isAccountType(e) {
|
|
14105
|
-
return typeof e == "object" && e !== null && typeof e.address == "string" && typeof e.network == "string"
|
|
13999
|
+
return typeof e == "object" && e !== null && typeof e.address == "string" && typeof e.network == "string";
|
|
14106
14000
|
}
|
|
14107
14001
|
getAccount() {
|
|
14108
14002
|
return new Promise((e, t) => {
|
|
@@ -14131,7 +14025,7 @@ const m1 = new g1(), w1 = ({
|
|
|
14131
14025
|
logoSize: y = 30,
|
|
14132
14026
|
...x
|
|
14133
14027
|
}) => {
|
|
14134
|
-
const [u, o] =
|
|
14028
|
+
const [u, o] = qf(!0), { qrCode: c, roomId: v } = oa.generateQrCode("provide", e, t, f);
|
|
14135
14029
|
return zt(() => {
|
|
14136
14030
|
const b = setTimeout(
|
|
14137
14031
|
() => {
|
|
@@ -14147,8 +14041,7 @@ const m1 = new g1(), w1 = ({
|
|
|
14147
14041
|
const B = await m1.qrAddressProvide(v), w = {
|
|
14148
14042
|
isSuccess: !0,
|
|
14149
14043
|
address: B.address,
|
|
14150
|
-
network: B.network
|
|
14151
|
-
nickName: B.nickName
|
|
14044
|
+
network: B.network
|
|
14152
14045
|
};
|
|
14153
14046
|
a(w);
|
|
14154
14047
|
} catch {
|
|
@@ -14165,11 +14058,10 @@ const m1 = new g1(), w1 = ({
|
|
|
14165
14058
|
...x
|
|
14166
14059
|
}
|
|
14167
14060
|
) : /* @__PURE__ */ vr.jsx("div", { children: "QR loading error" });
|
|
14168
|
-
}, B1 = () => {
|
|
14169
|
-
console.log("TEST..");
|
|
14170
14061
|
};
|
|
14171
14062
|
export {
|
|
14172
14063
|
w1 as AddressProvideQR,
|
|
14173
14064
|
E1 as LoginQR,
|
|
14174
|
-
|
|
14065
|
+
m1 as addressProvice,
|
|
14066
|
+
oa as qrService
|
|
14175
14067
|
};
|