@jieyin/editor-sdk-test 1.1.172 → 1.1.174
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/dist/editor-sdk.es.js +7141 -7107
- package/dist/renderWorker.js +825 -822
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/renderWorker.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var D0 = /* @__PURE__ */ ((r) => (r[r.Group = 0] = "Group", r[r.Layer = 1] = "Layer", r))(D0 || {});
|
|
2
2
|
function et(r) {
|
|
3
|
-
let
|
|
3
|
+
let d = r;
|
|
4
4
|
return () => {
|
|
5
|
-
const t =
|
|
6
|
-
return
|
|
5
|
+
const t = d;
|
|
6
|
+
return d += 1, t;
|
|
7
7
|
};
|
|
8
8
|
}
|
|
9
|
-
function tt(r,
|
|
9
|
+
function tt(r, d) {
|
|
10
10
|
return {
|
|
11
11
|
name: r.name || "",
|
|
12
12
|
type: r.type || "Layer",
|
|
@@ -23,24 +23,24 @@ function tt(r, h) {
|
|
|
23
23
|
quiltSliceY: r.quiltSliceY,
|
|
24
24
|
layerOrder: r.layerOrder,
|
|
25
25
|
imagePath: r.imagePath,
|
|
26
|
-
vectorMask: r.vectorMask ??
|
|
26
|
+
vectorMask: r.vectorMask ?? d,
|
|
27
27
|
filterList: r.filterList,
|
|
28
28
|
opacity: r.opacity,
|
|
29
29
|
clipping: r.clipping
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
function xt(r,
|
|
33
|
-
let
|
|
32
|
+
function xt(r, d, t, e) {
|
|
33
|
+
let u = r.name || "", v = d[u], _ = v?.partId ?? (r.type === "Group" ? t.get(u) : void 0);
|
|
34
34
|
if (r.type === "Group" && _ === void 0 && (!v || v.id === void 0) && r.children && r.children.length === 1) {
|
|
35
|
-
const x = r.children[0].name, n =
|
|
36
|
-
(E !== void 0 || n?.id !== void 0) && (
|
|
35
|
+
const x = r.children[0].name, n = d[x], E = n?.partId ?? t.get(x);
|
|
36
|
+
(E !== void 0 || n?.id !== void 0) && (u = x, v = n, _ = E);
|
|
37
37
|
}
|
|
38
38
|
const B = r.id ?? v?.id ?? e();
|
|
39
39
|
if (r.type === "Group")
|
|
40
40
|
return {
|
|
41
41
|
id: B,
|
|
42
42
|
partId: _,
|
|
43
|
-
name:
|
|
43
|
+
name: u,
|
|
44
44
|
blendMode: r.blendMode || "normal",
|
|
45
45
|
bounds: r.bounds || { left: 0, top: 0, width: 0, height: 0 },
|
|
46
46
|
type: D0.Group,
|
|
@@ -64,35 +64,35 @@ function xt(r, h, t, e) {
|
|
|
64
64
|
layerOrder: r.layerOrder
|
|
65
65
|
};
|
|
66
66
|
}
|
|
67
|
-
function nt(r,
|
|
68
|
-
const t = new Map(
|
|
67
|
+
function nt(r, d) {
|
|
68
|
+
const t = new Map(d.parts.map((u) => [u.name, u.id])), e = et(d.defaultIdStart ?? 1);
|
|
69
69
|
return {
|
|
70
|
-
parts:
|
|
71
|
-
models: r.map((
|
|
72
|
-
const v =
|
|
70
|
+
parts: d.parts,
|
|
71
|
+
models: r.map((u) => {
|
|
72
|
+
const v = u.layerExtrasByName ?? {}, _ = u.psdJson, B = _.layerList || _.layerList || [], C = _.canvasWidth, x = _.canvasHeight;
|
|
73
73
|
if (!C || !x)
|
|
74
74
|
throw new Error(`无法获取 PSD 画布尺寸: canvasWidth=${C}, canvasHeight=${x}。请确保 jsonurl 中的 canvasWidth 和 canvasHeight 存在`);
|
|
75
75
|
const n = (s) => {
|
|
76
|
-
const
|
|
76
|
+
const f = [];
|
|
77
77
|
for (const p of s)
|
|
78
78
|
if (p.type === "Group" && p.children) {
|
|
79
|
-
const
|
|
80
|
-
const b = o.layerOrder ?? 0, g =
|
|
79
|
+
const h = [], D = [], i = [...p.children].sort((o, l) => {
|
|
80
|
+
const b = o.layerOrder ?? 0, g = l.layerOrder ?? 0;
|
|
81
81
|
return b - g;
|
|
82
82
|
});
|
|
83
83
|
for (const o of i)
|
|
84
|
-
o.isSmartObject === !0 ?
|
|
84
|
+
o.isSmartObject === !0 ? h.push(o) : D.push(o);
|
|
85
85
|
if (D.length > 0) {
|
|
86
86
|
const o = n(D);
|
|
87
|
-
|
|
87
|
+
f.push(...o);
|
|
88
88
|
}
|
|
89
|
-
|
|
89
|
+
h.length > 0 && f.push({
|
|
90
90
|
...p,
|
|
91
|
-
children:
|
|
91
|
+
children: h
|
|
92
92
|
});
|
|
93
93
|
} else
|
|
94
|
-
|
|
95
|
-
return
|
|
94
|
+
f.push(p);
|
|
95
|
+
return f;
|
|
96
96
|
}, a = n(B).map(
|
|
97
97
|
(s) => xt(s, v, t, e)
|
|
98
98
|
);
|
|
@@ -110,30 +110,30 @@ function at(r) {
|
|
|
110
110
|
function ot(r) {
|
|
111
111
|
return r ? r.type === "bezier" ? {
|
|
112
112
|
type: "bezier",
|
|
113
|
-
paths: r.paths.map((
|
|
114
|
-
open: !!
|
|
115
|
-
knots:
|
|
113
|
+
paths: r.paths.map((d) => ({
|
|
114
|
+
open: !!d.open,
|
|
115
|
+
knots: d.knots.map((t) => ({
|
|
116
116
|
linked: !!t.linked,
|
|
117
117
|
points: Array.isArray(t.points) ? [...t.points] : []
|
|
118
118
|
}))
|
|
119
119
|
}))
|
|
120
120
|
} : r.type === "simple" ? {
|
|
121
121
|
type: "simple",
|
|
122
|
-
points: r.points.map((
|
|
123
|
-
x:
|
|
124
|
-
y:
|
|
125
|
-
type:
|
|
122
|
+
points: r.points.map((d) => ({
|
|
123
|
+
x: d.x,
|
|
124
|
+
y: d.y,
|
|
125
|
+
type: d.type
|
|
126
126
|
}))
|
|
127
127
|
} : null : null;
|
|
128
128
|
}
|
|
129
|
-
function Br(r,
|
|
130
|
-
if (
|
|
131
|
-
if (r.globalCompositeOperation = "destination-in", r.beginPath(),
|
|
132
|
-
|
|
129
|
+
function Br(r, d) {
|
|
130
|
+
if (d) {
|
|
131
|
+
if (r.globalCompositeOperation = "destination-in", r.beginPath(), d.type === "bezier" && Array.isArray(d.paths))
|
|
132
|
+
d.paths.forEach((t) => {
|
|
133
133
|
const e = t.knots;
|
|
134
134
|
if (!e || e.length < 2) return;
|
|
135
|
-
const
|
|
136
|
-
r.moveTo(
|
|
135
|
+
const u = e[0];
|
|
136
|
+
r.moveTo(u.points[2], u.points[3]);
|
|
137
137
|
for (let v = 0; v < e.length; v++) {
|
|
138
138
|
const _ = e[v];
|
|
139
139
|
let B = (v + 1) % e.length;
|
|
@@ -141,13 +141,13 @@ function Br(r, h) {
|
|
|
141
141
|
B = 0;
|
|
142
142
|
else if (t.open && v === e.length - 1)
|
|
143
143
|
break;
|
|
144
|
-
const C = e[B], x = _.points[4], n = _.points[5], E = C.points[0], a = C.points[1], s = C.points[2],
|
|
145
|
-
r.bezierCurveTo(x, n, E, a, s,
|
|
144
|
+
const C = e[B], x = _.points[4], n = _.points[5], E = C.points[0], a = C.points[1], s = C.points[2], f = C.points[3];
|
|
145
|
+
r.bezierCurveTo(x, n, E, a, s, f);
|
|
146
146
|
}
|
|
147
147
|
t.open || r.closePath();
|
|
148
148
|
});
|
|
149
|
-
else if (
|
|
150
|
-
const t =
|
|
149
|
+
else if (d.type === "simple" && Array.isArray(d.points)) {
|
|
150
|
+
const t = d.points;
|
|
151
151
|
if (t.length < 3) return;
|
|
152
152
|
r.moveTo(t[0].x, t[0].y);
|
|
153
153
|
for (let e = 1; e < t.length; e++) r.lineTo(t[e].x, t[e].y);
|
|
@@ -161,10 +161,10 @@ class p0 {
|
|
|
161
161
|
/**
|
|
162
162
|
* 获取存储项
|
|
163
163
|
*/
|
|
164
|
-
static getItem(
|
|
164
|
+
static getItem(d) {
|
|
165
165
|
if (!this.hasStorage) return null;
|
|
166
166
|
try {
|
|
167
|
-
return localStorage.getItem(
|
|
167
|
+
return localStorage.getItem(d);
|
|
168
168
|
} catch {
|
|
169
169
|
return null;
|
|
170
170
|
}
|
|
@@ -172,10 +172,10 @@ class p0 {
|
|
|
172
172
|
/**
|
|
173
173
|
* 设置存储项
|
|
174
174
|
*/
|
|
175
|
-
static setItem(
|
|
175
|
+
static setItem(d, t) {
|
|
176
176
|
if (!this.hasStorage) return !1;
|
|
177
177
|
try {
|
|
178
|
-
return localStorage.setItem(
|
|
178
|
+
return localStorage.setItem(d, t), !0;
|
|
179
179
|
} catch {
|
|
180
180
|
return !1;
|
|
181
181
|
}
|
|
@@ -183,10 +183,10 @@ class p0 {
|
|
|
183
183
|
/**
|
|
184
184
|
* 移除存储项
|
|
185
185
|
*/
|
|
186
|
-
static removeItem(
|
|
186
|
+
static removeItem(d) {
|
|
187
187
|
if (!this.hasStorage) return !1;
|
|
188
188
|
try {
|
|
189
|
-
return localStorage.removeItem(
|
|
189
|
+
return localStorage.removeItem(d), !0;
|
|
190
190
|
} catch {
|
|
191
191
|
return !1;
|
|
192
192
|
}
|
|
@@ -251,10 +251,10 @@ class v0 {
|
|
|
251
251
|
/**
|
|
252
252
|
* 安全地解析 URL
|
|
253
253
|
*/
|
|
254
|
-
static parse(
|
|
254
|
+
static parse(d) {
|
|
255
255
|
try {
|
|
256
256
|
const t = lr.getOrigin();
|
|
257
|
-
return new URL(
|
|
257
|
+
return new URL(d, t);
|
|
258
258
|
} catch {
|
|
259
259
|
return null;
|
|
260
260
|
}
|
|
@@ -262,231 +262,234 @@ class v0 {
|
|
|
262
262
|
/**
|
|
263
263
|
* 添加查询参数
|
|
264
264
|
*/
|
|
265
|
-
static addParam(
|
|
266
|
-
const
|
|
267
|
-
return !
|
|
265
|
+
static addParam(d, t, e) {
|
|
266
|
+
const u = this.parse(d);
|
|
267
|
+
return !u || u.searchParams.has(t) ? d : (u.searchParams.set(t, e), this.formatUrl(d, u));
|
|
268
268
|
}
|
|
269
269
|
/**
|
|
270
270
|
* 移除查询参数
|
|
271
271
|
*/
|
|
272
|
-
static removeParam(
|
|
273
|
-
const e = this.parse(
|
|
274
|
-
return !e || !e.searchParams.has(t) ?
|
|
272
|
+
static removeParam(d, t) {
|
|
273
|
+
const e = this.parse(d);
|
|
274
|
+
return !e || !e.searchParams.has(t) ? d : (e.searchParams.delete(t), this.formatUrl(d, e));
|
|
275
275
|
}
|
|
276
276
|
/**
|
|
277
277
|
* 检查是否有指定参数
|
|
278
278
|
*/
|
|
279
|
-
static hasParam(
|
|
280
|
-
return this.parse(
|
|
279
|
+
static hasParam(d, t) {
|
|
280
|
+
return this.parse(d)?.searchParams.has(t) ?? !1;
|
|
281
281
|
}
|
|
282
282
|
/**
|
|
283
283
|
* 格式化 URL(保持原始格式)
|
|
284
284
|
*/
|
|
285
|
-
static formatUrl(
|
|
286
|
-
const e = /^(https?:)?\/\//i.test(
|
|
287
|
-
return e ? t.toString() :
|
|
285
|
+
static formatUrl(d, t) {
|
|
286
|
+
const e = /^(https?:)?\/\//i.test(d), u = d.startsWith("//");
|
|
287
|
+
return e ? t.toString() : u ? t.toString().replace(/^https?:/, "") : `${t.pathname}${t.search}${t.hash}`;
|
|
288
288
|
}
|
|
289
289
|
/**
|
|
290
290
|
* 检查是否为数据 URL
|
|
291
291
|
*/
|
|
292
|
-
static isDataUrl(
|
|
293
|
-
return
|
|
292
|
+
static isDataUrl(d) {
|
|
293
|
+
return d?.startsWith("data:") ?? !1;
|
|
294
294
|
}
|
|
295
295
|
/**
|
|
296
296
|
* 检查是否为 Blob URL
|
|
297
297
|
*/
|
|
298
|
-
static isBlobUrl(
|
|
299
|
-
return
|
|
298
|
+
static isBlobUrl(d) {
|
|
299
|
+
return d?.startsWith("blob:") ?? !1;
|
|
300
300
|
}
|
|
301
301
|
}
|
|
302
302
|
const it = /* @__PURE__ */ new Map(), st = /* @__PURE__ */ new Map();
|
|
303
303
|
function ct() {
|
|
304
304
|
it.clear(), st.clear();
|
|
305
305
|
}
|
|
306
|
-
const x0 =
|
|
307
|
-
(function(r,
|
|
308
|
-
const t =
|
|
306
|
+
const x0 = b0;
|
|
307
|
+
(function(r, d) {
|
|
308
|
+
const t = b0, e = r();
|
|
309
309
|
for (; ; )
|
|
310
310
|
try {
|
|
311
|
-
if (parseInt(t(
|
|
311
|
+
if (parseInt(t(412)) / 1 + parseInt(t(435)) / 2 * (-parseInt(t(438)) / 3) + parseInt(t(434)) / 4 + -parseInt(t(411)) / 5 + parseInt(t(410)) / 6 * (-parseInt(t(429)) / 7) + parseInt(t(419)) / 8 + parseInt(t(402)) / 9 === d) break;
|
|
312
312
|
e.push(e.shift());
|
|
313
313
|
} catch {
|
|
314
314
|
e.push(e.shift());
|
|
315
315
|
}
|
|
316
|
-
})(
|
|
316
|
+
})(dr, 941451);
|
|
317
317
|
const F0 = /* @__PURE__ */ (function() {
|
|
318
318
|
let r = !0;
|
|
319
|
-
return function(
|
|
319
|
+
return function(d, t) {
|
|
320
320
|
const e = r ? function() {
|
|
321
321
|
if (t) {
|
|
322
|
-
const
|
|
323
|
-
return t = null,
|
|
322
|
+
const u = t.apply(d, arguments);
|
|
323
|
+
return t = null, u;
|
|
324
324
|
}
|
|
325
325
|
} : function() {
|
|
326
326
|
};
|
|
327
327
|
return r = !1, e;
|
|
328
328
|
};
|
|
329
329
|
})(), ft = F0(void 0, function() {
|
|
330
|
-
const r =
|
|
331
|
-
const v =
|
|
330
|
+
const r = b0, d = function() {
|
|
331
|
+
const v = b0;
|
|
332
332
|
let _;
|
|
333
333
|
try {
|
|
334
|
-
_ = Function("return (
|
|
334
|
+
_ = Function("return (function() " + ("{}.co" + v(418) + v(423) + '"return this")( )') + ");")();
|
|
335
335
|
} catch {
|
|
336
336
|
_ = window;
|
|
337
337
|
}
|
|
338
338
|
return _;
|
|
339
|
-
}, t =
|
|
340
|
-
for (let v =
|
|
341
|
-
const _ = F0.
|
|
342
|
-
_
|
|
339
|
+
}, t = d(), e = t.console = t.console || {}, u = ["log", "warn", "info", r(433), r(422) + r(436), "table", "trace"];
|
|
340
|
+
for (let v = 6784 + -8 * 848; v < u.length; v++) {
|
|
341
|
+
const _ = F0[r(430) + r(406) + "r"].prototype.bind(F0), B = u[v], C = e[B] || _;
|
|
342
|
+
_.__proto__ = F0.bind(F0), _[r(405) + "ing"] = C[r(405) + "ing"].bind(C), e[B] = _;
|
|
343
343
|
}
|
|
344
344
|
});
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
return ur = function() {
|
|
345
|
+
function dr() {
|
|
346
|
+
const r = ["expir", "clone", "nstru", "5229936WOebow", "efres", "isBro", "excep", "ctor(", "code", "bUrl", "remov", "token", "numbe", "184443bLpUyk", "const", "es_in", "re_ti", "error", "1740876xMDZrN", "4bZylZE", "tion", "set", "1122921aedhgA", "inclu", "oken=", "delet", "setIt", "data", "15277311FQGKQf", "okenR", "getIt", "toStr", "ructo", "statu", "fetch", "file_", "246APEkym", "2166140uAkRUq", "417162gcmIfy", "oken", "FileT", "parse"];
|
|
347
|
+
return dr = function() {
|
|
349
348
|
return r;
|
|
350
|
-
},
|
|
349
|
+
}, dr();
|
|
351
350
|
}
|
|
352
|
-
|
|
351
|
+
ft();
|
|
352
|
+
const Dr = x0(409) + "token", br = "file_token_expi" + x0(432) + "me", ut = 60 * (1496 * 5 + 2403 + -8883);
|
|
353
353
|
function Fr() {
|
|
354
|
-
return p0
|
|
354
|
+
return p0[x0(404) + "em"](Dr);
|
|
355
355
|
}
|
|
356
356
|
function dt(r = ut) {
|
|
357
|
-
const h = x0;
|
|
358
357
|
if (!Fr()) return !0;
|
|
359
|
-
const
|
|
360
|
-
if (!
|
|
361
|
-
const
|
|
362
|
-
return Date
|
|
358
|
+
const t = p0.getItem(br);
|
|
359
|
+
if (!t) return !1;
|
|
360
|
+
const e = Number(t);
|
|
361
|
+
return Date.now() + r > e;
|
|
363
362
|
}
|
|
364
|
-
function lt(r,
|
|
363
|
+
function lt(r, d) {
|
|
365
364
|
const t = x0;
|
|
366
|
-
if (p0.setItem(Dr, r), typeof
|
|
367
|
-
const e = Date
|
|
368
|
-
p0
|
|
365
|
+
if (p0.setItem(Dr, r), typeof d == t(428) + "r" && d > 386 * 1 + -1 * -7935 + -8321) {
|
|
366
|
+
const e = Date.now() + d * 1e3;
|
|
367
|
+
p0[t(442) + "em"](br, String(e));
|
|
369
368
|
}
|
|
370
369
|
}
|
|
371
370
|
function ht() {
|
|
372
|
-
|
|
371
|
+
const r = x0;
|
|
372
|
+
p0[r(426) + "eItem"](Dr), p0[r(426) + "eItem"](br), bt(), ct();
|
|
373
373
|
}
|
|
374
374
|
async function qr(r) {
|
|
375
|
-
const
|
|
376
|
-
return t?.
|
|
375
|
+
const d = x0, t = await r(), e = t?.data?.data;
|
|
376
|
+
return t?.[d(401)]?.[d(424)] === -1 * 7625 + -391 * -9 + 4306 && e?.["file_token"] ? (lt(e.file_token, e[d(416) + d(431)]), e["file_" + d(427)]) : null;
|
|
377
377
|
}
|
|
378
378
|
let vt = null;
|
|
379
|
-
function
|
|
380
|
-
return r = r -
|
|
379
|
+
function b0(r, d) {
|
|
380
|
+
return r = r - 401, dr()[r];
|
|
381
381
|
}
|
|
382
382
|
function Tr() {
|
|
383
383
|
return lr.isBrowser() ? vt : null;
|
|
384
384
|
}
|
|
385
385
|
async function we() {
|
|
386
386
|
const r = x0;
|
|
387
|
-
if (!lr
|
|
388
|
-
const
|
|
389
|
-
if (
|
|
387
|
+
if (!lr[r(421) + "wser"]()) return Fr();
|
|
388
|
+
const d = Fr();
|
|
389
|
+
if (d && !dt()) return d;
|
|
390
390
|
try {
|
|
391
391
|
const t = await Tr();
|
|
392
|
-
if (
|
|
393
|
-
const e = await qr(t["fetchFileT" + r(
|
|
392
|
+
if (d && t?.[r(408) + "FileT" + r(403) + r(420) + "h"]) {
|
|
393
|
+
const e = await qr(t["fetchFileT" + r(403) + "efresh"]);
|
|
394
394
|
if (e) return e;
|
|
395
395
|
}
|
|
396
396
|
} catch {
|
|
397
397
|
}
|
|
398
398
|
try {
|
|
399
399
|
const t = Tr();
|
|
400
|
-
return t?.["
|
|
400
|
+
return t?.[r(408) + r(414) + "oken"] ? await qr(t[r(408) + r(414) + "oken"]) : null;
|
|
401
401
|
} catch {
|
|
402
402
|
return null;
|
|
403
403
|
}
|
|
404
404
|
}
|
|
405
405
|
function ke(r) {
|
|
406
|
-
const
|
|
407
|
-
if (!r || v0.isDataUrl(r) || v0
|
|
408
|
-
const t = v0
|
|
409
|
-
return t ? t.pathname.includes("/files/") && !v0.hasParam(r, "fileToken") : r.includes(
|
|
406
|
+
const d = x0;
|
|
407
|
+
if (!r || v0.isDataUrl(r) || v0["isBlo" + d(425)](r)) return !1;
|
|
408
|
+
const t = v0[d(415)](r);
|
|
409
|
+
return t ? t.pathname.includes("/files/") && !v0.hasParam(r, "fileToken") : r.includes("/files/") && !r[d(439) + "des"]("fileT" + d(440));
|
|
410
410
|
}
|
|
411
|
-
function Se(r,
|
|
412
|
-
return !
|
|
411
|
+
function Se(r, d) {
|
|
412
|
+
return !d || !ke(r) ? r : v0.addParam(r, "fileToken", d);
|
|
413
413
|
}
|
|
414
414
|
function He(r) {
|
|
415
|
-
|
|
415
|
+
const d = x0;
|
|
416
|
+
return v0.removeParam(r, "fileT" + d(413));
|
|
416
417
|
}
|
|
417
418
|
async function pt(r) {
|
|
418
419
|
if (!ke(r)) return r;
|
|
419
|
-
const
|
|
420
|
-
return Se(r,
|
|
420
|
+
const d = await we();
|
|
421
|
+
return Se(r, d);
|
|
421
422
|
}
|
|
422
423
|
const Cr = /* @__PURE__ */ new Map();
|
|
423
|
-
function Bt(r,
|
|
424
|
+
function Bt(r, d) {
|
|
424
425
|
return "GET".toUpperCase() + "\0" + r;
|
|
425
426
|
}
|
|
426
|
-
async function Ct(r,
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
427
|
+
async function Ct(r, d) {
|
|
428
|
+
const t = x0;
|
|
429
|
+
if (!lr.isBrowser()) return fetch(r, d);
|
|
430
|
+
const e = He(r), u = Bt(e);
|
|
431
|
+
let v = Cr.get(u);
|
|
432
|
+
return !v && (v = (async () => {
|
|
433
|
+
const B = b0;
|
|
431
434
|
try {
|
|
432
|
-
const
|
|
433
|
-
let
|
|
434
|
-
if (B
|
|
435
|
+
const C = await pt(e);
|
|
436
|
+
let x = await fetch(C, d);
|
|
437
|
+
if (x[B(407) + "s"] !== -4739 + -1285 * -4) return x;
|
|
435
438
|
ht();
|
|
436
|
-
const
|
|
437
|
-
return
|
|
439
|
+
const n = await we(), E = Se(e, n);
|
|
440
|
+
return x = await fetch(E, d), x;
|
|
438
441
|
} finally {
|
|
439
|
-
Cr
|
|
442
|
+
Cr[B(441) + "e"](u);
|
|
440
443
|
}
|
|
441
|
-
})(), Cr
|
|
444
|
+
})(), Cr[t(437)](u, v)), (await v)[t(417)]();
|
|
442
445
|
}
|
|
443
446
|
const Et = 96, At = 200 * 1024 * 1024, t0 = /* @__PURE__ */ new Map();
|
|
444
447
|
let hr = 0;
|
|
445
|
-
const
|
|
446
|
-
function Ft(r,
|
|
448
|
+
const w0 = /* @__PURE__ */ new Map();
|
|
449
|
+
function Ft(r, d) {
|
|
447
450
|
return `${"GET".toUpperCase()}\0${He(r)}`;
|
|
448
451
|
}
|
|
449
452
|
function gt() {
|
|
450
453
|
const r = t0.keys().next().value;
|
|
451
454
|
if (r === void 0) return;
|
|
452
|
-
const
|
|
453
|
-
t0.delete(r),
|
|
455
|
+
const d = t0.get(r);
|
|
456
|
+
t0.delete(r), d && (hr -= d.size);
|
|
454
457
|
}
|
|
455
458
|
function Dt(r) {
|
|
456
459
|
for (; t0.size > 0; ) {
|
|
457
|
-
const
|
|
458
|
-
if (!
|
|
460
|
+
const d = t0.size >= Et, t = hr + r > At;
|
|
461
|
+
if (!d && !t) break;
|
|
459
462
|
gt();
|
|
460
463
|
}
|
|
461
464
|
}
|
|
462
|
-
async function $e(r,
|
|
465
|
+
async function $e(r, d) {
|
|
463
466
|
const t = Ft(r), e = t0.get(t);
|
|
464
467
|
if (e)
|
|
465
468
|
return t0.delete(t), t0.set(t, e), e;
|
|
466
|
-
let
|
|
467
|
-
return
|
|
469
|
+
let u = w0.get(t);
|
|
470
|
+
return u || (u = (async () => {
|
|
468
471
|
try {
|
|
469
|
-
const v = await Ct(r,
|
|
472
|
+
const v = await Ct(r, d);
|
|
470
473
|
if (!v.ok)
|
|
471
474
|
throw new Error(`fetch failed: ${v.status} ${v.statusText}`);
|
|
472
475
|
const _ = await v.blob();
|
|
473
476
|
return Dt(_.size), t0.set(t, _), hr += _.size, _;
|
|
474
477
|
} finally {
|
|
475
|
-
|
|
478
|
+
w0.delete(t);
|
|
476
479
|
}
|
|
477
|
-
})(),
|
|
480
|
+
})(), w0.set(t, u), u);
|
|
478
481
|
}
|
|
479
482
|
function bt() {
|
|
480
|
-
t0.clear(),
|
|
483
|
+
t0.clear(), w0.clear(), hr = 0;
|
|
481
484
|
}
|
|
482
|
-
const Re = (r,
|
|
485
|
+
const Re = (r, d) => {
|
|
483
486
|
if (!r) return r;
|
|
484
|
-
const t = (
|
|
487
|
+
const t = (d || "").replace(/\/$/, "");
|
|
485
488
|
if (t && r.startsWith(t))
|
|
486
489
|
return r;
|
|
487
490
|
if (typeof window < "u") {
|
|
488
|
-
const
|
|
489
|
-
if (
|
|
491
|
+
const u = window.location.hostname;
|
|
492
|
+
if (u === "localhost" || u === "127.0.0.1")
|
|
490
493
|
try {
|
|
491
494
|
const v = new URL(r);
|
|
492
495
|
if (t)
|
|
@@ -504,33 +507,33 @@ const Re = (r, h) => {
|
|
|
504
507
|
if (typeof window < "u" && window.location.hostname !== "localhost") return r;
|
|
505
508
|
const e = r.match(/^https?:\/\/([^/]+\.oss[^/]*\.aliyuncs\.com)(.*)$/);
|
|
506
509
|
return e ? `/oss${e[2]}` : r;
|
|
507
|
-
}, mt = (r,
|
|
510
|
+
}, mt = (r, d) => {
|
|
508
511
|
if (typeof OffscreenCanvas < "u" && typeof document > "u")
|
|
509
|
-
return new OffscreenCanvas(r,
|
|
512
|
+
return new OffscreenCanvas(r, d);
|
|
510
513
|
const t = document.createElement("canvas");
|
|
511
|
-
return t.width = r, t.height =
|
|
512
|
-
},
|
|
513
|
-
if (!
|
|
514
|
+
return t.width = r, t.height = d, t;
|
|
515
|
+
}, k0 = async (r, d) => {
|
|
516
|
+
if (!d || d <= 0) return r;
|
|
514
517
|
const t = Math.max(r.width, r.height);
|
|
515
|
-
if (t <=
|
|
516
|
-
const e =
|
|
517
|
-
return B ? (B.drawImage(r, 0, 0,
|
|
518
|
+
if (t <= d) return r;
|
|
519
|
+
const e = d / t, u = Math.max(1, Math.round(r.width * e)), v = Math.max(1, Math.round(r.height * e)), _ = mt(u, v), B = _.getContext("2d");
|
|
520
|
+
return B ? (B.drawImage(r, 0, 0, u, v), r.close?.(), await createImageBitmap(_)) : r;
|
|
518
521
|
};
|
|
519
|
-
async function _t(r,
|
|
522
|
+
async function _t(r, d, t) {
|
|
520
523
|
if (typeof r == "string")
|
|
521
524
|
try {
|
|
522
525
|
const e = Re(r, t);
|
|
523
|
-
let
|
|
526
|
+
let u;
|
|
524
527
|
try {
|
|
525
|
-
|
|
528
|
+
u = await $e(e);
|
|
526
529
|
} catch {
|
|
527
530
|
throw new Error(`加载图片失败: ${r}`);
|
|
528
531
|
}
|
|
529
|
-
if (!
|
|
532
|
+
if (!u.type.startsWith("image/") && u.size === 0)
|
|
530
533
|
throw new Error(`图片数据无效: URL=${r}`);
|
|
531
534
|
try {
|
|
532
|
-
const v = await createImageBitmap(
|
|
533
|
-
return await
|
|
535
|
+
const v = await createImageBitmap(u);
|
|
536
|
+
return await k0(v, d);
|
|
534
537
|
} catch (v) {
|
|
535
538
|
throw new Error(`图片解码失败: URL=${r}, 错误=${v instanceof Error ? v.message : v}`);
|
|
536
539
|
}
|
|
@@ -538,13 +541,13 @@ async function _t(r, h, t) {
|
|
|
538
541
|
throw e instanceof Error ? e : new Error(`加载图片失败: ${r}, ${e}`);
|
|
539
542
|
}
|
|
540
543
|
if (r instanceof HTMLImageElement) {
|
|
541
|
-
if ((!r.complete || r.naturalWidth === 0) && await new Promise((e,
|
|
542
|
-
r.onload = e, r.onerror = () =>
|
|
544
|
+
if ((!r.complete || r.naturalWidth === 0) && await new Promise((e, u) => {
|
|
545
|
+
r.onload = e, r.onerror = () => u(new Error(`图片加载失败: src=${r.src}`)), r.complete && e(null);
|
|
543
546
|
}), r.naturalWidth === 0 || r.naturalHeight === 0)
|
|
544
547
|
throw new Error(`图片尺寸无效: src=${r.src}, width=${r.naturalWidth}, height=${r.naturalHeight}`);
|
|
545
548
|
try {
|
|
546
549
|
const e = await createImageBitmap(r);
|
|
547
|
-
return await
|
|
550
|
+
return await k0(e, d);
|
|
548
551
|
} catch (e) {
|
|
549
552
|
throw new Error(`图片解码失败: src=${r.src}, 错误=${e instanceof Error ? e.message : e}`);
|
|
550
553
|
}
|
|
@@ -552,24 +555,24 @@ async function _t(r, h, t) {
|
|
|
552
555
|
if (r instanceof ImageBitmap) {
|
|
553
556
|
if (r.width === 0 || r.height === 0)
|
|
554
557
|
throw new Error(`ImageBitmap 尺寸无效: width=${r.width}, height=${r.height}`);
|
|
555
|
-
return await
|
|
558
|
+
return await k0(r, d);
|
|
556
559
|
}
|
|
557
560
|
throw new Error("不支持的图片类型");
|
|
558
561
|
}
|
|
559
|
-
async function yt(r,
|
|
562
|
+
async function yt(r, d, t) {
|
|
560
563
|
try {
|
|
561
564
|
const e = Re(r, t);
|
|
562
|
-
let
|
|
565
|
+
let u;
|
|
563
566
|
try {
|
|
564
|
-
|
|
567
|
+
u = await $e(e);
|
|
565
568
|
} catch {
|
|
566
569
|
throw new Error(`加载图片失败: ${r}`);
|
|
567
570
|
}
|
|
568
|
-
if (!
|
|
571
|
+
if (!u.type.startsWith("image/") && u.size === 0)
|
|
569
572
|
throw new Error(`图片数据无效: URL=${r}`);
|
|
570
573
|
try {
|
|
571
|
-
const v = await createImageBitmap(
|
|
572
|
-
return await
|
|
574
|
+
const v = await createImageBitmap(u);
|
|
575
|
+
return await k0(v, d);
|
|
573
576
|
} catch (v) {
|
|
574
577
|
throw new Error(`图片解码失败: URL=${r}, 错误=${v instanceof Error ? v.message : v}`);
|
|
575
578
|
}
|
|
@@ -579,7 +582,7 @@ async function yt(r, h, t) {
|
|
|
579
582
|
}
|
|
580
583
|
function Mr(r) {
|
|
581
584
|
if (!r) return "source-over";
|
|
582
|
-
const
|
|
585
|
+
const d = r.trim().toLowerCase();
|
|
583
586
|
return {
|
|
584
587
|
normal: "source-over",
|
|
585
588
|
multiply: "multiply",
|
|
@@ -605,26 +608,26 @@ function Mr(r) {
|
|
|
605
608
|
"linear dodge": "lighter",
|
|
606
609
|
lighter: "lighter",
|
|
607
610
|
"pass-through": "source-over"
|
|
608
|
-
}[
|
|
611
|
+
}[d] || "source-over";
|
|
609
612
|
}
|
|
610
613
|
var Er = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
611
614
|
function wt(r) {
|
|
612
615
|
if (Object.prototype.hasOwnProperty.call(r, "__esModule")) return r;
|
|
613
|
-
var
|
|
614
|
-
if (typeof
|
|
616
|
+
var d = r.default;
|
|
617
|
+
if (typeof d == "function") {
|
|
615
618
|
var t = function e() {
|
|
616
|
-
var
|
|
619
|
+
var u = !1;
|
|
617
620
|
try {
|
|
618
|
-
|
|
621
|
+
u = this instanceof e;
|
|
619
622
|
} catch {
|
|
620
623
|
}
|
|
621
|
-
return
|
|
624
|
+
return u ? Reflect.construct(d, arguments, this.constructor) : d.apply(this, arguments);
|
|
622
625
|
};
|
|
623
|
-
t.prototype =
|
|
626
|
+
t.prototype = d.prototype;
|
|
624
627
|
} else t = {};
|
|
625
628
|
return Object.defineProperty(t, "__esModule", { value: !0 }), Object.keys(r).forEach(function(e) {
|
|
626
|
-
var
|
|
627
|
-
Object.defineProperty(t, e,
|
|
629
|
+
var u = Object.getOwnPropertyDescriptor(r, e);
|
|
630
|
+
Object.defineProperty(t, e, u.get ? u : {
|
|
628
631
|
enumerable: !0,
|
|
629
632
|
get: function() {
|
|
630
633
|
return r[e];
|
|
@@ -632,20 +635,20 @@ function wt(r) {
|
|
|
632
635
|
});
|
|
633
636
|
}), t;
|
|
634
637
|
}
|
|
635
|
-
var
|
|
638
|
+
var S0 = { exports: {} };
|
|
636
639
|
function kt(r) {
|
|
637
640
|
throw new Error('Could not dynamically require "' + r + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
638
641
|
}
|
|
639
|
-
var
|
|
642
|
+
var H0 = { exports: {} }, St = {}, Ht = /* @__PURE__ */ Object.freeze({
|
|
640
643
|
__proto__: null,
|
|
641
644
|
default: St
|
|
642
|
-
}), $t = /* @__PURE__ */ wt(Ht), Rt =
|
|
645
|
+
}), $t = /* @__PURE__ */ wt(Ht), Rt = H0.exports, Nr;
|
|
643
646
|
function M() {
|
|
644
|
-
return Nr || (Nr = 1, (function(r,
|
|
647
|
+
return Nr || (Nr = 1, (function(r, d) {
|
|
645
648
|
(function(t, e) {
|
|
646
649
|
r.exports = e();
|
|
647
650
|
})(Rt, function() {
|
|
648
|
-
var t = t || (function(e,
|
|
651
|
+
var t = t || (function(e, u) {
|
|
649
652
|
var v;
|
|
650
653
|
if (typeof window < "u" && window.crypto && (v = window.crypto), typeof self < "u" && self.crypto && (v = self.crypto), typeof globalThis < "u" && globalThis.crypto && (v = globalThis.crypto), !v && typeof window < "u" && window.msCrypto && (v = window.msCrypto), !v && typeof Er < "u" && Er.crypto && (v = Er.crypto), !v && typeof kt == "function")
|
|
651
654
|
try {
|
|
@@ -670,8 +673,8 @@ function M() {
|
|
|
670
673
|
function i() {
|
|
671
674
|
}
|
|
672
675
|
return function(o) {
|
|
673
|
-
var
|
|
674
|
-
return i.prototype = o,
|
|
676
|
+
var l;
|
|
677
|
+
return i.prototype = o, l = new i(), i.prototype = null, l;
|
|
675
678
|
};
|
|
676
679
|
})(), C = {}, x = C.lib = {}, n = x.Base = /* @__PURE__ */ (function() {
|
|
677
680
|
return {
|
|
@@ -772,7 +775,7 @@ function M() {
|
|
|
772
775
|
* var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6);
|
|
773
776
|
*/
|
|
774
777
|
init: function(i, o) {
|
|
775
|
-
i = this.words = i || [], o !=
|
|
778
|
+
i = this.words = i || [], o != u ? this.sigBytes = o : this.sigBytes = i.length * 4;
|
|
776
779
|
},
|
|
777
780
|
/**
|
|
778
781
|
* Converts this word array to a string.
|
|
@@ -802,15 +805,15 @@ function M() {
|
|
|
802
805
|
* wordArray1.concat(wordArray2);
|
|
803
806
|
*/
|
|
804
807
|
concat: function(i) {
|
|
805
|
-
var o = this.words,
|
|
808
|
+
var o = this.words, l = i.words, b = this.sigBytes, g = i.sigBytes;
|
|
806
809
|
if (this.clamp(), b % 4)
|
|
807
810
|
for (var y = 0; y < g; y++) {
|
|
808
|
-
var k =
|
|
811
|
+
var k = l[y >>> 2] >>> 24 - y % 4 * 8 & 255;
|
|
809
812
|
o[b + y >>> 2] |= k << 24 - (b + y) % 4 * 8;
|
|
810
813
|
}
|
|
811
814
|
else
|
|
812
815
|
for (var R = 0; R < g; R += 4)
|
|
813
|
-
o[b + R >>> 2] =
|
|
816
|
+
o[b + R >>> 2] = l[R >>> 2];
|
|
814
817
|
return this.sigBytes += g, this;
|
|
815
818
|
},
|
|
816
819
|
/**
|
|
@@ -851,7 +854,7 @@ function M() {
|
|
|
851
854
|
* var wordArray = CryptoJS.lib.WordArray.random(16);
|
|
852
855
|
*/
|
|
853
856
|
random: function(i) {
|
|
854
|
-
for (var o = [],
|
|
857
|
+
for (var o = [], l = 0; l < i; l += 4)
|
|
855
858
|
o.push(_());
|
|
856
859
|
return new E.init(o, i);
|
|
857
860
|
}
|
|
@@ -870,7 +873,7 @@ function M() {
|
|
|
870
873
|
* var hexString = CryptoJS.enc.Hex.stringify(wordArray);
|
|
871
874
|
*/
|
|
872
875
|
stringify: function(i) {
|
|
873
|
-
for (var o = i.words,
|
|
876
|
+
for (var o = i.words, l = i.sigBytes, b = [], g = 0; g < l; g++) {
|
|
874
877
|
var y = o[g >>> 2] >>> 24 - g % 4 * 8 & 255;
|
|
875
878
|
b.push((y >>> 4).toString(16)), b.push((y & 15).toString(16));
|
|
876
879
|
}
|
|
@@ -890,11 +893,11 @@ function M() {
|
|
|
890
893
|
* var wordArray = CryptoJS.enc.Hex.parse(hexString);
|
|
891
894
|
*/
|
|
892
895
|
parse: function(i) {
|
|
893
|
-
for (var o = i.length,
|
|
894
|
-
|
|
895
|
-
return new E.init(
|
|
896
|
+
for (var o = i.length, l = [], b = 0; b < o; b += 2)
|
|
897
|
+
l[b >>> 3] |= parseInt(i.substr(b, 2), 16) << 24 - b % 8 * 4;
|
|
898
|
+
return new E.init(l, o / 2);
|
|
896
899
|
}
|
|
897
|
-
},
|
|
900
|
+
}, f = a.Latin1 = {
|
|
898
901
|
/**
|
|
899
902
|
* Converts a word array to a Latin1 string.
|
|
900
903
|
*
|
|
@@ -909,7 +912,7 @@ function M() {
|
|
|
909
912
|
* var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);
|
|
910
913
|
*/
|
|
911
914
|
stringify: function(i) {
|
|
912
|
-
for (var o = i.words,
|
|
915
|
+
for (var o = i.words, l = i.sigBytes, b = [], g = 0; g < l; g++) {
|
|
913
916
|
var y = o[g >>> 2] >>> 24 - g % 4 * 8 & 255;
|
|
914
917
|
b.push(String.fromCharCode(y));
|
|
915
918
|
}
|
|
@@ -929,9 +932,9 @@ function M() {
|
|
|
929
932
|
* var wordArray = CryptoJS.enc.Latin1.parse(latin1String);
|
|
930
933
|
*/
|
|
931
934
|
parse: function(i) {
|
|
932
|
-
for (var o = i.length,
|
|
933
|
-
|
|
934
|
-
return new E.init(
|
|
935
|
+
for (var o = i.length, l = [], b = 0; b < o; b++)
|
|
936
|
+
l[b >>> 2] |= (i.charCodeAt(b) & 255) << 24 - b % 4 * 8;
|
|
937
|
+
return new E.init(l, o);
|
|
935
938
|
}
|
|
936
939
|
}, p = a.Utf8 = {
|
|
937
940
|
/**
|
|
@@ -949,7 +952,7 @@ function M() {
|
|
|
949
952
|
*/
|
|
950
953
|
stringify: function(i) {
|
|
951
954
|
try {
|
|
952
|
-
return decodeURIComponent(escape(
|
|
955
|
+
return decodeURIComponent(escape(f.stringify(i)));
|
|
953
956
|
} catch {
|
|
954
957
|
throw new Error("Malformed UTF-8 data");
|
|
955
958
|
}
|
|
@@ -968,9 +971,9 @@ function M() {
|
|
|
968
971
|
* var wordArray = CryptoJS.enc.Utf8.parse(utf8String);
|
|
969
972
|
*/
|
|
970
973
|
parse: function(i) {
|
|
971
|
-
return
|
|
974
|
+
return f.parse(unescape(encodeURIComponent(i)));
|
|
972
975
|
}
|
|
973
|
-
},
|
|
976
|
+
}, h = x.BufferedBlockAlgorithm = n.extend({
|
|
974
977
|
/**
|
|
975
978
|
* Resets this block algorithm's data buffer to its initial state.
|
|
976
979
|
*
|
|
@@ -1009,13 +1012,13 @@ function M() {
|
|
|
1009
1012
|
* var processedData = bufferedBlockAlgorithm._process(!!'flush');
|
|
1010
1013
|
*/
|
|
1011
1014
|
_process: function(i) {
|
|
1012
|
-
var o,
|
|
1015
|
+
var o, l = this._data, b = l.words, g = l.sigBytes, y = this.blockSize, k = y * 4, R = g / k;
|
|
1013
1016
|
i ? R = e.ceil(R) : R = e.max((R | 0) - this._minBufferSize, 0);
|
|
1014
1017
|
var F = R * y, w = e.min(F * 4, g);
|
|
1015
1018
|
if (F) {
|
|
1016
1019
|
for (var H = 0; H < F; H += y)
|
|
1017
1020
|
this._doProcessBlock(b, H);
|
|
1018
|
-
o = b.splice(0, F),
|
|
1021
|
+
o = b.splice(0, F), l.sigBytes -= w;
|
|
1019
1022
|
}
|
|
1020
1023
|
return new E.init(o, w);
|
|
1021
1024
|
},
|
|
@@ -1034,7 +1037,7 @@ function M() {
|
|
|
1034
1037
|
},
|
|
1035
1038
|
_minBufferSize: 0
|
|
1036
1039
|
});
|
|
1037
|
-
x.Hasher =
|
|
1040
|
+
x.Hasher = h.extend({
|
|
1038
1041
|
/**
|
|
1039
1042
|
* Configuration options.
|
|
1040
1043
|
*/
|
|
@@ -1059,7 +1062,7 @@ function M() {
|
|
|
1059
1062
|
* hasher.reset();
|
|
1060
1063
|
*/
|
|
1061
1064
|
reset: function() {
|
|
1062
|
-
|
|
1065
|
+
h.reset.call(this), this._doReset();
|
|
1063
1066
|
},
|
|
1064
1067
|
/**
|
|
1065
1068
|
* Updates this hasher with a message.
|
|
@@ -1110,8 +1113,8 @@ function M() {
|
|
|
1110
1113
|
* var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256);
|
|
1111
1114
|
*/
|
|
1112
1115
|
_createHelper: function(i) {
|
|
1113
|
-
return function(o,
|
|
1114
|
-
return new i.init(
|
|
1116
|
+
return function(o, l) {
|
|
1117
|
+
return new i.init(l).finalize(o);
|
|
1115
1118
|
};
|
|
1116
1119
|
},
|
|
1117
1120
|
/**
|
|
@@ -1128,8 +1131,8 @@ function M() {
|
|
|
1128
1131
|
* var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256);
|
|
1129
1132
|
*/
|
|
1130
1133
|
_createHmacHelper: function(i) {
|
|
1131
|
-
return function(o,
|
|
1132
|
-
return new D.HMAC.init(i,
|
|
1134
|
+
return function(o, l) {
|
|
1135
|
+
return new D.HMAC.init(i, l).finalize(o);
|
|
1133
1136
|
};
|
|
1134
1137
|
}
|
|
1135
1138
|
});
|
|
@@ -1138,16 +1141,16 @@ function M() {
|
|
|
1138
1141
|
})(Math);
|
|
1139
1142
|
return t;
|
|
1140
1143
|
});
|
|
1141
|
-
})(
|
|
1144
|
+
})(H0)), H0.exports;
|
|
1142
1145
|
}
|
|
1143
|
-
var
|
|
1146
|
+
var $0 = { exports: {} }, Pt = $0.exports, Ur;
|
|
1144
1147
|
function vr() {
|
|
1145
|
-
return Ur || (Ur = 1, (function(r,
|
|
1148
|
+
return Ur || (Ur = 1, (function(r, d) {
|
|
1146
1149
|
(function(t, e) {
|
|
1147
1150
|
r.exports = e(M());
|
|
1148
1151
|
})(Pt, function(t) {
|
|
1149
1152
|
return (function(e) {
|
|
1150
|
-
var
|
|
1153
|
+
var u = t, v = u.lib, _ = v.Base, B = v.WordArray, C = u.x64 = {};
|
|
1151
1154
|
C.Word = _.extend({
|
|
1152
1155
|
/**
|
|
1153
1156
|
* Initializes a newly created 64-bit word.
|
|
@@ -1368,17 +1371,17 @@ function vr() {
|
|
|
1368
1371
|
});
|
|
1369
1372
|
})(), t;
|
|
1370
1373
|
});
|
|
1371
|
-
})(
|
|
1374
|
+
})($0)), $0.exports;
|
|
1372
1375
|
}
|
|
1373
|
-
var
|
|
1374
|
-
function
|
|
1375
|
-
return jr || (jr = 1, (function(r,
|
|
1376
|
+
var R0 = { exports: {} }, zt = R0.exports, jr;
|
|
1377
|
+
function Wt() {
|
|
1378
|
+
return jr || (jr = 1, (function(r, d) {
|
|
1376
1379
|
(function(t, e) {
|
|
1377
1380
|
r.exports = e(M());
|
|
1378
1381
|
})(zt, function(t) {
|
|
1379
1382
|
return (function() {
|
|
1380
1383
|
if (typeof ArrayBuffer == "function") {
|
|
1381
|
-
var e = t,
|
|
1384
|
+
var e = t, u = e.lib, v = u.WordArray, _ = v.init, B = v.init = function(C) {
|
|
1382
1385
|
if (C instanceof ArrayBuffer && (C = new Uint8Array(C)), (C instanceof Int8Array || typeof Uint8ClampedArray < "u" && C instanceof Uint8ClampedArray || C instanceof Int16Array || C instanceof Uint16Array || C instanceof Int32Array || C instanceof Uint32Array || C instanceof Float32Array || C instanceof Float64Array) && (C = new Uint8Array(C.buffer, C.byteOffset, C.byteLength)), C instanceof Uint8Array) {
|
|
1383
1386
|
for (var x = C.byteLength, n = [], E = 0; E < x; E++)
|
|
1384
1387
|
n[E >>> 2] |= C[E] << 24 - E % 4 * 8;
|
|
@@ -1390,16 +1393,16 @@ function It() {
|
|
|
1390
1393
|
}
|
|
1391
1394
|
})(), t.lib.WordArray;
|
|
1392
1395
|
});
|
|
1393
|
-
})(
|
|
1396
|
+
})(R0)), R0.exports;
|
|
1394
1397
|
}
|
|
1395
|
-
var
|
|
1398
|
+
var P0 = { exports: {} }, It = P0.exports, Gr;
|
|
1396
1399
|
function Lt() {
|
|
1397
|
-
return Gr || (Gr = 1, (function(r,
|
|
1400
|
+
return Gr || (Gr = 1, (function(r, d) {
|
|
1398
1401
|
(function(t, e) {
|
|
1399
1402
|
r.exports = e(M());
|
|
1400
|
-
})(
|
|
1403
|
+
})(It, function(t) {
|
|
1401
1404
|
return (function() {
|
|
1402
|
-
var e = t,
|
|
1405
|
+
var e = t, u = e.lib, v = u.WordArray, _ = e.enc;
|
|
1403
1406
|
_.Utf16 = _.Utf16BE = {
|
|
1404
1407
|
/**
|
|
1405
1408
|
* Converts a word array to a UTF-16 BE string.
|
|
@@ -1484,16 +1487,16 @@ function Lt() {
|
|
|
1484
1487
|
}
|
|
1485
1488
|
})(), t.enc.Utf16;
|
|
1486
1489
|
});
|
|
1487
|
-
})(
|
|
1490
|
+
})(P0)), P0.exports;
|
|
1488
1491
|
}
|
|
1489
|
-
var
|
|
1492
|
+
var z0 = { exports: {} }, Ot = z0.exports, Kr;
|
|
1490
1493
|
function c0() {
|
|
1491
|
-
return Kr || (Kr = 1, (function(r,
|
|
1494
|
+
return Kr || (Kr = 1, (function(r, d) {
|
|
1492
1495
|
(function(t, e) {
|
|
1493
1496
|
r.exports = e(M());
|
|
1494
1497
|
})(Ot, function(t) {
|
|
1495
1498
|
return (function() {
|
|
1496
|
-
var e = t,
|
|
1499
|
+
var e = t, u = e.lib, v = u.WordArray, _ = e.enc;
|
|
1497
1500
|
_.Base64 = {
|
|
1498
1501
|
/**
|
|
1499
1502
|
* Converts a word array to a Base64 string.
|
|
@@ -1512,7 +1515,7 @@ function c0() {
|
|
|
1512
1515
|
var x = C.words, n = C.sigBytes, E = this._map;
|
|
1513
1516
|
C.clamp();
|
|
1514
1517
|
for (var a = [], s = 0; s < n; s += 3)
|
|
1515
|
-
for (var
|
|
1518
|
+
for (var f = x[s >>> 2] >>> 24 - s % 4 * 8 & 255, p = x[s + 1 >>> 2] >>> 24 - (s + 1) % 4 * 8 & 255, h = x[s + 2 >>> 2] >>> 24 - (s + 2) % 4 * 8 & 255, D = f << 16 | p << 8 | h, i = 0; i < 4 && s + i * 0.75 < n; i++)
|
|
1516
1519
|
a.push(E.charAt(D >>> 6 * (3 - i) & 63));
|
|
1517
1520
|
var o = E.charAt(64);
|
|
1518
1521
|
if (o)
|
|
@@ -1542,8 +1545,8 @@ function c0() {
|
|
|
1542
1545
|
}
|
|
1543
1546
|
var s = n.charAt(64);
|
|
1544
1547
|
if (s) {
|
|
1545
|
-
var
|
|
1546
|
-
|
|
1548
|
+
var f = C.indexOf(s);
|
|
1549
|
+
f !== -1 && (x = f);
|
|
1547
1550
|
}
|
|
1548
1551
|
return B(C, x, E);
|
|
1549
1552
|
},
|
|
@@ -1552,23 +1555,23 @@ function c0() {
|
|
|
1552
1555
|
function B(C, x, n) {
|
|
1553
1556
|
for (var E = [], a = 0, s = 0; s < x; s++)
|
|
1554
1557
|
if (s % 4) {
|
|
1555
|
-
var
|
|
1556
|
-
E[a >>> 2] |=
|
|
1558
|
+
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2, p = n[C.charCodeAt(s)] >>> 6 - s % 4 * 2, h = f | p;
|
|
1559
|
+
E[a >>> 2] |= h << 24 - a % 4 * 8, a++;
|
|
1557
1560
|
}
|
|
1558
1561
|
return v.create(E, a);
|
|
1559
1562
|
}
|
|
1560
1563
|
})(), t.enc.Base64;
|
|
1561
1564
|
});
|
|
1562
|
-
})(
|
|
1565
|
+
})(z0)), z0.exports;
|
|
1563
1566
|
}
|
|
1564
|
-
var
|
|
1567
|
+
var W0 = { exports: {} }, qt = W0.exports, Xr;
|
|
1565
1568
|
function Tt() {
|
|
1566
|
-
return Xr || (Xr = 1, (function(r,
|
|
1569
|
+
return Xr || (Xr = 1, (function(r, d) {
|
|
1567
1570
|
(function(t, e) {
|
|
1568
1571
|
r.exports = e(M());
|
|
1569
1572
|
})(qt, function(t) {
|
|
1570
1573
|
return (function() {
|
|
1571
|
-
var e = t,
|
|
1574
|
+
var e = t, u = e.lib, v = u.WordArray, _ = e.enc;
|
|
1572
1575
|
_.Base64url = {
|
|
1573
1576
|
/**
|
|
1574
1577
|
* Converts a word array to a Base64url string.
|
|
@@ -1589,13 +1592,13 @@ function Tt() {
|
|
|
1589
1592
|
x === void 0 && (x = !0);
|
|
1590
1593
|
var n = C.words, E = C.sigBytes, a = x ? this._safe_map : this._map;
|
|
1591
1594
|
C.clamp();
|
|
1592
|
-
for (var s = [],
|
|
1593
|
-
for (var p = n[
|
|
1595
|
+
for (var s = [], f = 0; f < E; f += 3)
|
|
1596
|
+
for (var p = n[f >>> 2] >>> 24 - f % 4 * 8 & 255, h = n[f + 1 >>> 2] >>> 24 - (f + 1) % 4 * 8 & 255, D = n[f + 2 >>> 2] >>> 24 - (f + 2) % 4 * 8 & 255, i = p << 16 | h << 8 | D, o = 0; o < 4 && f + o * 0.75 < E; o++)
|
|
1594
1597
|
s.push(a.charAt(i >>> 6 * (3 - o) & 63));
|
|
1595
|
-
var
|
|
1596
|
-
if (
|
|
1598
|
+
var l = a.charAt(64);
|
|
1599
|
+
if (l)
|
|
1597
1600
|
for (; s.length % 4; )
|
|
1598
|
-
s.push(
|
|
1601
|
+
s.push(l);
|
|
1599
1602
|
return s.join("");
|
|
1600
1603
|
},
|
|
1601
1604
|
/**
|
|
@@ -1621,9 +1624,9 @@ function Tt() {
|
|
|
1621
1624
|
for (var s = 0; s < E.length; s++)
|
|
1622
1625
|
a[E.charCodeAt(s)] = s;
|
|
1623
1626
|
}
|
|
1624
|
-
var
|
|
1625
|
-
if (
|
|
1626
|
-
var p = C.indexOf(
|
|
1627
|
+
var f = E.charAt(64);
|
|
1628
|
+
if (f) {
|
|
1629
|
+
var p = C.indexOf(f);
|
|
1627
1630
|
p !== -1 && (n = p);
|
|
1628
1631
|
}
|
|
1629
1632
|
return B(C, n, a);
|
|
@@ -1634,23 +1637,23 @@ function Tt() {
|
|
|
1634
1637
|
function B(C, x, n) {
|
|
1635
1638
|
for (var E = [], a = 0, s = 0; s < x; s++)
|
|
1636
1639
|
if (s % 4) {
|
|
1637
|
-
var
|
|
1638
|
-
E[a >>> 2] |=
|
|
1640
|
+
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2, p = n[C.charCodeAt(s)] >>> 6 - s % 4 * 2, h = f | p;
|
|
1641
|
+
E[a >>> 2] |= h << 24 - a % 4 * 8, a++;
|
|
1639
1642
|
}
|
|
1640
1643
|
return v.create(E, a);
|
|
1641
1644
|
}
|
|
1642
1645
|
})(), t.enc.Base64url;
|
|
1643
1646
|
});
|
|
1644
|
-
})(
|
|
1647
|
+
})(W0)), W0.exports;
|
|
1645
1648
|
}
|
|
1646
|
-
var I0 = { exports: {} }, Mt = I0.exports,
|
|
1649
|
+
var I0 = { exports: {} }, Mt = I0.exports, Zr;
|
|
1647
1650
|
function f0() {
|
|
1648
|
-
return
|
|
1651
|
+
return Zr || (Zr = 1, (function(r, d) {
|
|
1649
1652
|
(function(t, e) {
|
|
1650
1653
|
r.exports = e(M());
|
|
1651
1654
|
})(Mt, function(t) {
|
|
1652
1655
|
return (function(e) {
|
|
1653
|
-
var
|
|
1656
|
+
var u = t, v = u.lib, _ = v.WordArray, B = v.Hasher, C = u.algo, x = [];
|
|
1654
1657
|
(function() {
|
|
1655
1658
|
for (var p = 0; p < 64; p++)
|
|
1656
1659
|
x[p] = e.abs(e.sin(p + 1)) * 4294967296 | 0;
|
|
@@ -1664,19 +1667,19 @@ function f0() {
|
|
|
1664
1667
|
271733878
|
|
1665
1668
|
]);
|
|
1666
1669
|
},
|
|
1667
|
-
_doProcessBlock: function(p,
|
|
1670
|
+
_doProcessBlock: function(p, h) {
|
|
1668
1671
|
for (var D = 0; D < 16; D++) {
|
|
1669
|
-
var i =
|
|
1672
|
+
var i = h + D, o = p[i];
|
|
1670
1673
|
p[i] = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360;
|
|
1671
1674
|
}
|
|
1672
|
-
var
|
|
1673
|
-
S = E(S,
|
|
1675
|
+
var l = this._hash.words, b = p[h + 0], g = p[h + 1], y = p[h + 2], k = p[h + 3], R = p[h + 4], F = p[h + 5], w = p[h + 6], H = p[h + 7], $ = p[h + 8], z = p[h + 9], O = p[h + 10], q = p[h + 11], U = p[h + 12], T = p[h + 13], N = p[h + 14], j = p[h + 15], S = l[0], c = l[1], A = l[2], m = l[3];
|
|
1676
|
+
S = E(S, c, A, m, b, 7, x[0]), m = E(m, S, c, A, g, 12, x[1]), A = E(A, m, S, c, y, 17, x[2]), c = E(c, A, m, S, k, 22, x[3]), S = E(S, c, A, m, R, 7, x[4]), m = E(m, S, c, A, F, 12, x[5]), A = E(A, m, S, c, w, 17, x[6]), c = E(c, A, m, S, H, 22, x[7]), S = E(S, c, A, m, $, 7, x[8]), m = E(m, S, c, A, z, 12, x[9]), A = E(A, m, S, c, O, 17, x[10]), c = E(c, A, m, S, q, 22, x[11]), S = E(S, c, A, m, U, 7, x[12]), m = E(m, S, c, A, T, 12, x[13]), A = E(A, m, S, c, N, 17, x[14]), c = E(c, A, m, S, j, 22, x[15]), S = a(S, c, A, m, g, 5, x[16]), m = a(m, S, c, A, w, 9, x[17]), A = a(A, m, S, c, q, 14, x[18]), c = a(c, A, m, S, b, 20, x[19]), S = a(S, c, A, m, F, 5, x[20]), m = a(m, S, c, A, O, 9, x[21]), A = a(A, m, S, c, j, 14, x[22]), c = a(c, A, m, S, R, 20, x[23]), S = a(S, c, A, m, z, 5, x[24]), m = a(m, S, c, A, N, 9, x[25]), A = a(A, m, S, c, k, 14, x[26]), c = a(c, A, m, S, $, 20, x[27]), S = a(S, c, A, m, T, 5, x[28]), m = a(m, S, c, A, y, 9, x[29]), A = a(A, m, S, c, H, 14, x[30]), c = a(c, A, m, S, U, 20, x[31]), S = s(S, c, A, m, F, 4, x[32]), m = s(m, S, c, A, $, 11, x[33]), A = s(A, m, S, c, q, 16, x[34]), c = s(c, A, m, S, N, 23, x[35]), S = s(S, c, A, m, g, 4, x[36]), m = s(m, S, c, A, R, 11, x[37]), A = s(A, m, S, c, H, 16, x[38]), c = s(c, A, m, S, O, 23, x[39]), S = s(S, c, A, m, T, 4, x[40]), m = s(m, S, c, A, b, 11, x[41]), A = s(A, m, S, c, k, 16, x[42]), c = s(c, A, m, S, w, 23, x[43]), S = s(S, c, A, m, z, 4, x[44]), m = s(m, S, c, A, U, 11, x[45]), A = s(A, m, S, c, j, 16, x[46]), c = s(c, A, m, S, y, 23, x[47]), S = f(S, c, A, m, b, 6, x[48]), m = f(m, S, c, A, H, 10, x[49]), A = f(A, m, S, c, N, 15, x[50]), c = f(c, A, m, S, F, 21, x[51]), S = f(S, c, A, m, U, 6, x[52]), m = f(m, S, c, A, k, 10, x[53]), A = f(A, m, S, c, O, 15, x[54]), c = f(c, A, m, S, g, 21, x[55]), S = f(S, c, A, m, $, 6, x[56]), m = f(m, S, c, A, j, 10, x[57]), A = f(A, m, S, c, w, 15, x[58]), c = f(c, A, m, S, T, 21, x[59]), S = f(S, c, A, m, R, 6, x[60]), m = f(m, S, c, A, q, 10, x[61]), A = f(A, m, S, c, y, 15, x[62]), c = f(c, A, m, S, z, 21, x[63]), l[0] = l[0] + S | 0, l[1] = l[1] + c | 0, l[2] = l[2] + A | 0, l[3] = l[3] + m | 0;
|
|
1674
1677
|
},
|
|
1675
1678
|
_doFinalize: function() {
|
|
1676
|
-
var p = this._data,
|
|
1677
|
-
|
|
1678
|
-
var o = e.floor(D / 4294967296),
|
|
1679
|
-
|
|
1679
|
+
var p = this._data, h = p.words, D = this._nDataBytes * 8, i = p.sigBytes * 8;
|
|
1680
|
+
h[i >>> 5] |= 128 << 24 - i % 32;
|
|
1681
|
+
var o = e.floor(D / 4294967296), l = D;
|
|
1682
|
+
h[(i + 64 >>> 9 << 4) + 15] = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360, h[(i + 64 >>> 9 << 4) + 14] = (l << 8 | l >>> 24) & 16711935 | (l << 24 | l >>> 8) & 4278255360, p.sigBytes = (h.length + 1) * 4, this._process();
|
|
1680
1683
|
for (var b = this._hash, g = b.words, y = 0; y < 4; y++) {
|
|
1681
1684
|
var k = g[y];
|
|
1682
1685
|
g[y] = (k << 8 | k >>> 24) & 16711935 | (k << 24 | k >>> 8) & 4278255360;
|
|
@@ -1688,35 +1691,35 @@ function f0() {
|
|
|
1688
1691
|
return p._hash = this._hash.clone(), p;
|
|
1689
1692
|
}
|
|
1690
1693
|
});
|
|
1691
|
-
function E(p,
|
|
1692
|
-
var g = p + (
|
|
1693
|
-
return (g <<
|
|
1694
|
+
function E(p, h, D, i, o, l, b) {
|
|
1695
|
+
var g = p + (h & D | ~h & i) + o + b;
|
|
1696
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1694
1697
|
}
|
|
1695
|
-
function a(p,
|
|
1696
|
-
var g = p + (
|
|
1697
|
-
return (g <<
|
|
1698
|
+
function a(p, h, D, i, o, l, b) {
|
|
1699
|
+
var g = p + (h & i | D & ~i) + o + b;
|
|
1700
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1698
1701
|
}
|
|
1699
|
-
function s(p,
|
|
1700
|
-
var g = p + (
|
|
1701
|
-
return (g <<
|
|
1702
|
+
function s(p, h, D, i, o, l, b) {
|
|
1703
|
+
var g = p + (h ^ D ^ i) + o + b;
|
|
1704
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1702
1705
|
}
|
|
1703
|
-
function
|
|
1704
|
-
var g = p + (D ^ (
|
|
1705
|
-
return (g <<
|
|
1706
|
+
function f(p, h, D, i, o, l, b) {
|
|
1707
|
+
var g = p + (D ^ (h | ~i)) + o + b;
|
|
1708
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1706
1709
|
}
|
|
1707
|
-
|
|
1710
|
+
u.MD5 = B._createHelper(n), u.HmacMD5 = B._createHmacHelper(n);
|
|
1708
1711
|
})(Math), t.MD5;
|
|
1709
1712
|
});
|
|
1710
1713
|
})(I0)), I0.exports;
|
|
1711
1714
|
}
|
|
1712
|
-
var
|
|
1715
|
+
var L0 = { exports: {} }, Nt = L0.exports, Yr;
|
|
1713
1716
|
function Pe() {
|
|
1714
|
-
return
|
|
1717
|
+
return Yr || (Yr = 1, (function(r, d) {
|
|
1715
1718
|
(function(t, e) {
|
|
1716
1719
|
r.exports = e(M());
|
|
1717
1720
|
})(Nt, function(t) {
|
|
1718
1721
|
return (function() {
|
|
1719
|
-
var e = t,
|
|
1722
|
+
var e = t, u = e.lib, v = u.WordArray, _ = u.Hasher, B = e.algo, C = [], x = B.SHA1 = _.extend({
|
|
1720
1723
|
_doReset: function() {
|
|
1721
1724
|
this._hash = new v.init([
|
|
1722
1725
|
1732584193,
|
|
@@ -1727,17 +1730,17 @@ function Pe() {
|
|
|
1727
1730
|
]);
|
|
1728
1731
|
},
|
|
1729
1732
|
_doProcessBlock: function(n, E) {
|
|
1730
|
-
for (var a = this._hash.words, s = a[0],
|
|
1733
|
+
for (var a = this._hash.words, s = a[0], f = a[1], p = a[2], h = a[3], D = a[4], i = 0; i < 80; i++) {
|
|
1731
1734
|
if (i < 16)
|
|
1732
1735
|
C[i] = n[E + i] | 0;
|
|
1733
1736
|
else {
|
|
1734
1737
|
var o = C[i - 3] ^ C[i - 8] ^ C[i - 14] ^ C[i - 16];
|
|
1735
1738
|
C[i] = o << 1 | o >>> 31;
|
|
1736
1739
|
}
|
|
1737
|
-
var
|
|
1738
|
-
i < 20 ?
|
|
1740
|
+
var l = (s << 5 | s >>> 27) + D + C[i];
|
|
1741
|
+
i < 20 ? l += (f & p | ~f & h) + 1518500249 : i < 40 ? l += (f ^ p ^ h) + 1859775393 : i < 60 ? l += (f & p | f & h | p & h) - 1894007588 : l += (f ^ p ^ h) - 899497514, D = h, h = p, p = f << 30 | f >>> 2, f = s, s = l;
|
|
1739
1742
|
}
|
|
1740
|
-
a[0] = a[0] + s | 0, a[1] = a[1] +
|
|
1743
|
+
a[0] = a[0] + s | 0, a[1] = a[1] + f | 0, a[2] = a[2] + p | 0, a[3] = a[3] + h | 0, a[4] = a[4] + D | 0;
|
|
1741
1744
|
},
|
|
1742
1745
|
_doFinalize: function() {
|
|
1743
1746
|
var n = this._data, E = n.words, a = this._nDataBytes * 8, s = n.sigBytes * 8;
|
|
@@ -1751,16 +1754,16 @@ function Pe() {
|
|
|
1751
1754
|
e.SHA1 = _._createHelper(x), e.HmacSHA1 = _._createHmacHelper(x);
|
|
1752
1755
|
})(), t.SHA1;
|
|
1753
1756
|
});
|
|
1754
|
-
})(
|
|
1757
|
+
})(L0)), L0.exports;
|
|
1755
1758
|
}
|
|
1756
|
-
var
|
|
1759
|
+
var O0 = { exports: {} }, Ut = O0.exports, Qr;
|
|
1757
1760
|
function mr() {
|
|
1758
|
-
return Qr || (Qr = 1, (function(r,
|
|
1761
|
+
return Qr || (Qr = 1, (function(r, d) {
|
|
1759
1762
|
(function(t, e) {
|
|
1760
1763
|
r.exports = e(M());
|
|
1761
1764
|
})(Ut, function(t) {
|
|
1762
1765
|
return (function(e) {
|
|
1763
|
-
var
|
|
1766
|
+
var u = t, v = u.lib, _ = v.WordArray, B = v.Hasher, C = u.algo, x = [], n = [];
|
|
1764
1767
|
(function() {
|
|
1765
1768
|
function s(D) {
|
|
1766
1769
|
for (var i = e.sqrt(D), o = 2; o <= i; o++)
|
|
@@ -1768,51 +1771,51 @@ function mr() {
|
|
|
1768
1771
|
return !1;
|
|
1769
1772
|
return !0;
|
|
1770
1773
|
}
|
|
1771
|
-
function
|
|
1774
|
+
function f(D) {
|
|
1772
1775
|
return (D - (D | 0)) * 4294967296 | 0;
|
|
1773
1776
|
}
|
|
1774
|
-
for (var p = 2,
|
|
1775
|
-
s(p) && (
|
|
1777
|
+
for (var p = 2, h = 0; h < 64; )
|
|
1778
|
+
s(p) && (h < 8 && (x[h] = f(e.pow(p, 1 / 2))), n[h] = f(e.pow(p, 1 / 3)), h++), p++;
|
|
1776
1779
|
})();
|
|
1777
1780
|
var E = [], a = C.SHA256 = B.extend({
|
|
1778
1781
|
_doReset: function() {
|
|
1779
1782
|
this._hash = new _.init(x.slice(0));
|
|
1780
1783
|
},
|
|
1781
|
-
_doProcessBlock: function(s,
|
|
1782
|
-
for (var p = this._hash.words,
|
|
1784
|
+
_doProcessBlock: function(s, f) {
|
|
1785
|
+
for (var p = this._hash.words, h = p[0], D = p[1], i = p[2], o = p[3], l = p[4], b = p[5], g = p[6], y = p[7], k = 0; k < 64; k++) {
|
|
1783
1786
|
if (k < 16)
|
|
1784
|
-
E[k] = s[
|
|
1787
|
+
E[k] = s[f + k] | 0;
|
|
1785
1788
|
else {
|
|
1786
1789
|
var R = E[k - 15], F = (R << 25 | R >>> 7) ^ (R << 14 | R >>> 18) ^ R >>> 3, w = E[k - 2], H = (w << 15 | w >>> 17) ^ (w << 13 | w >>> 19) ^ w >>> 10;
|
|
1787
1790
|
E[k] = F + E[k - 7] + H + E[k - 16];
|
|
1788
1791
|
}
|
|
1789
|
-
var $ =
|
|
1790
|
-
y = g, g = b, b =
|
|
1792
|
+
var $ = l & b ^ ~l & g, z = h & D ^ h & i ^ D & i, O = (h << 30 | h >>> 2) ^ (h << 19 | h >>> 13) ^ (h << 10 | h >>> 22), q = (l << 26 | l >>> 6) ^ (l << 21 | l >>> 11) ^ (l << 7 | l >>> 25), U = y + q + $ + n[k] + E[k], T = O + z;
|
|
1793
|
+
y = g, g = b, b = l, l = o + U | 0, o = i, i = D, D = h, h = U + T | 0;
|
|
1791
1794
|
}
|
|
1792
|
-
p[0] = p[0] +
|
|
1795
|
+
p[0] = p[0] + h | 0, p[1] = p[1] + D | 0, p[2] = p[2] + i | 0, p[3] = p[3] + o | 0, p[4] = p[4] + l | 0, p[5] = p[5] + b | 0, p[6] = p[6] + g | 0, p[7] = p[7] + y | 0;
|
|
1793
1796
|
},
|
|
1794
1797
|
_doFinalize: function() {
|
|
1795
|
-
var s = this._data,
|
|
1796
|
-
return
|
|
1798
|
+
var s = this._data, f = s.words, p = this._nDataBytes * 8, h = s.sigBytes * 8;
|
|
1799
|
+
return f[h >>> 5] |= 128 << 24 - h % 32, f[(h + 64 >>> 9 << 4) + 14] = e.floor(p / 4294967296), f[(h + 64 >>> 9 << 4) + 15] = p, s.sigBytes = f.length * 4, this._process(), this._hash;
|
|
1797
1800
|
},
|
|
1798
1801
|
clone: function() {
|
|
1799
1802
|
var s = B.clone.call(this);
|
|
1800
1803
|
return s._hash = this._hash.clone(), s;
|
|
1801
1804
|
}
|
|
1802
1805
|
});
|
|
1803
|
-
|
|
1806
|
+
u.SHA256 = B._createHelper(a), u.HmacSHA256 = B._createHmacHelper(a);
|
|
1804
1807
|
})(Math), t.SHA256;
|
|
1805
1808
|
});
|
|
1806
|
-
})(
|
|
1809
|
+
})(O0)), O0.exports;
|
|
1807
1810
|
}
|
|
1808
|
-
var
|
|
1811
|
+
var q0 = { exports: {} }, jt = q0.exports, Vr;
|
|
1809
1812
|
function Gt() {
|
|
1810
|
-
return Vr || (Vr = 1, (function(r,
|
|
1811
|
-
(function(t, e,
|
|
1813
|
+
return Vr || (Vr = 1, (function(r, d) {
|
|
1814
|
+
(function(t, e, u) {
|
|
1812
1815
|
r.exports = e(M(), mr());
|
|
1813
1816
|
})(jt, function(t) {
|
|
1814
1817
|
return (function() {
|
|
1815
|
-
var e = t,
|
|
1818
|
+
var e = t, u = e.lib, v = u.WordArray, _ = e.algo, B = _.SHA256, C = _.SHA224 = B.extend({
|
|
1816
1819
|
_doReset: function() {
|
|
1817
1820
|
this._hash = new v.init([
|
|
1818
1821
|
3238371032,
|
|
@@ -1833,16 +1836,16 @@ function Gt() {
|
|
|
1833
1836
|
e.SHA224 = B._createHelper(C), e.HmacSHA224 = B._createHmacHelper(C);
|
|
1834
1837
|
})(), t.SHA224;
|
|
1835
1838
|
});
|
|
1836
|
-
})(
|
|
1839
|
+
})(q0)), q0.exports;
|
|
1837
1840
|
}
|
|
1838
|
-
var
|
|
1841
|
+
var T0 = { exports: {} }, Kt = T0.exports, Jr;
|
|
1839
1842
|
function ze() {
|
|
1840
|
-
return Jr || (Jr = 1, (function(r,
|
|
1841
|
-
(function(t, e,
|
|
1843
|
+
return Jr || (Jr = 1, (function(r, d) {
|
|
1844
|
+
(function(t, e, u) {
|
|
1842
1845
|
r.exports = e(M(), vr());
|
|
1843
1846
|
})(Kt, function(t) {
|
|
1844
1847
|
return (function() {
|
|
1845
|
-
var e = t,
|
|
1848
|
+
var e = t, u = e.lib, v = u.Hasher, _ = e.x64, B = _.Word, C = _.WordArray, x = e.algo;
|
|
1846
1849
|
function n() {
|
|
1847
1850
|
return B.create.apply(B, arguments);
|
|
1848
1851
|
}
|
|
@@ -1929,8 +1932,8 @@ function ze() {
|
|
|
1929
1932
|
n(1816402316, 1246189591)
|
|
1930
1933
|
], a = [];
|
|
1931
1934
|
(function() {
|
|
1932
|
-
for (var
|
|
1933
|
-
a[
|
|
1935
|
+
for (var f = 0; f < 80; f++)
|
|
1936
|
+
a[f] = n();
|
|
1934
1937
|
})();
|
|
1935
1938
|
var s = x.SHA512 = v.extend({
|
|
1936
1939
|
_doReset: function() {
|
|
@@ -1945,45 +1948,45 @@ function ze() {
|
|
|
1945
1948
|
new B.init(1541459225, 327033209)
|
|
1946
1949
|
]);
|
|
1947
1950
|
},
|
|
1948
|
-
_doProcessBlock: function(
|
|
1949
|
-
for (var
|
|
1950
|
-
var J, n0,
|
|
1951
|
+
_doProcessBlock: function(f, p) {
|
|
1952
|
+
for (var h = this._hash.words, D = h[0], i = h[1], o = h[2], l = h[3], b = h[4], g = h[5], y = h[6], k = h[7], R = D.high, F = D.low, w = i.high, H = i.low, $ = o.high, z = o.low, O = l.high, q = l.low, U = b.high, T = b.low, N = g.high, j = g.low, S = y.high, c = y.low, A = k.high, m = k.low, W = R, P = F, L = w, I = H, Y = $, Q = z, i0 = O, K = q, G = U, Z = T, r0 = N, u0 = j, m0 = S, B0 = c, pr = A, C0 = m, e0 = 0; e0 < 80; e0++) {
|
|
1953
|
+
var J, n0, _0 = a[e0];
|
|
1951
1954
|
if (e0 < 16)
|
|
1952
|
-
n0 =
|
|
1955
|
+
n0 = _0.high = f[p + e0 * 2] | 0, J = _0.low = f[p + e0 * 2 + 1] | 0;
|
|
1953
1956
|
else {
|
|
1954
1957
|
var wr = a[e0 - 15], d0 = wr.high, E0 = wr.low, Me = (d0 >>> 1 | E0 << 31) ^ (d0 >>> 8 | E0 << 24) ^ d0 >>> 7, kr = (E0 >>> 1 | d0 << 31) ^ (E0 >>> 8 | d0 << 24) ^ (E0 >>> 7 | d0 << 25), Sr = a[e0 - 2], l0 = Sr.high, A0 = Sr.low, Ne = (l0 >>> 19 | A0 << 13) ^ (l0 << 3 | A0 >>> 29) ^ l0 >>> 6, Hr = (A0 >>> 19 | l0 << 13) ^ (A0 << 3 | l0 >>> 29) ^ (A0 >>> 6 | l0 << 26), $r = a[e0 - 7], Ue = $r.high, je = $r.low, Rr = a[e0 - 16], Ge = Rr.high, Pr = Rr.low;
|
|
1955
|
-
J = kr + je, n0 = Me + Ue + (J >>> 0 < kr >>> 0 ? 1 : 0), J = J + Hr, n0 = n0 + Ne + (J >>> 0 < Hr >>> 0 ? 1 : 0), J = J + Pr, n0 = n0 + Ge + (J >>> 0 < Pr >>> 0 ? 1 : 0),
|
|
1958
|
+
J = kr + je, n0 = Me + Ue + (J >>> 0 < kr >>> 0 ? 1 : 0), J = J + Hr, n0 = n0 + Ne + (J >>> 0 < Hr >>> 0 ? 1 : 0), J = J + Pr, n0 = n0 + Ge + (J >>> 0 < Pr >>> 0 ? 1 : 0), _0.high = n0, _0.low = J;
|
|
1956
1959
|
}
|
|
1957
|
-
var Ke = G & r0 ^ ~G &
|
|
1958
|
-
pr =
|
|
1960
|
+
var Ke = G & r0 ^ ~G & m0, zr = Z & u0 ^ ~Z & B0, Xe = W & L ^ W & Y ^ L & Y, Ze = P & I ^ P & Q ^ I & Q, Ye = (W >>> 28 | P << 4) ^ (W << 30 | P >>> 2) ^ (W << 25 | P >>> 7), Wr = (P >>> 28 | W << 4) ^ (P << 30 | W >>> 2) ^ (P << 25 | W >>> 7), Qe = (G >>> 14 | Z << 18) ^ (G >>> 18 | Z << 14) ^ (G << 23 | Z >>> 9), Ve = (Z >>> 14 | G << 18) ^ (Z >>> 18 | G << 14) ^ (Z << 23 | G >>> 9), Ir = E[e0], Je = Ir.high, Lr = Ir.low, V = C0 + Ve, a0 = pr + Qe + (V >>> 0 < C0 >>> 0 ? 1 : 0), V = V + zr, a0 = a0 + Ke + (V >>> 0 < zr >>> 0 ? 1 : 0), V = V + Lr, a0 = a0 + Je + (V >>> 0 < Lr >>> 0 ? 1 : 0), V = V + J, a0 = a0 + n0 + (V >>> 0 < J >>> 0 ? 1 : 0), Or = Wr + Ze, rt = Ye + Xe + (Or >>> 0 < Wr >>> 0 ? 1 : 0);
|
|
1961
|
+
pr = m0, C0 = B0, m0 = r0, B0 = u0, r0 = G, u0 = Z, Z = K + V | 0, G = i0 + a0 + (Z >>> 0 < K >>> 0 ? 1 : 0) | 0, i0 = Y, K = Q, Y = L, Q = I, L = W, I = P, P = V + Or | 0, W = a0 + rt + (P >>> 0 < V >>> 0 ? 1 : 0) | 0;
|
|
1959
1962
|
}
|
|
1960
|
-
F = D.low = F + P, D.high = R +
|
|
1963
|
+
F = D.low = F + P, D.high = R + W + (F >>> 0 < P >>> 0 ? 1 : 0), H = i.low = H + I, i.high = w + L + (H >>> 0 < I >>> 0 ? 1 : 0), z = o.low = z + Q, o.high = $ + Y + (z >>> 0 < Q >>> 0 ? 1 : 0), q = l.low = q + K, l.high = O + i0 + (q >>> 0 < K >>> 0 ? 1 : 0), T = b.low = T + Z, b.high = U + G + (T >>> 0 < Z >>> 0 ? 1 : 0), j = g.low = j + u0, g.high = N + r0 + (j >>> 0 < u0 >>> 0 ? 1 : 0), c = y.low = c + B0, y.high = S + m0 + (c >>> 0 < B0 >>> 0 ? 1 : 0), m = k.low = m + C0, k.high = A + pr + (m >>> 0 < C0 >>> 0 ? 1 : 0);
|
|
1961
1964
|
},
|
|
1962
1965
|
_doFinalize: function() {
|
|
1963
|
-
var
|
|
1964
|
-
p[D >>> 5] |= 128 << 24 - D % 32, p[(D + 128 >>> 10 << 5) + 30] = Math.floor(
|
|
1966
|
+
var f = this._data, p = f.words, h = this._nDataBytes * 8, D = f.sigBytes * 8;
|
|
1967
|
+
p[D >>> 5] |= 128 << 24 - D % 32, p[(D + 128 >>> 10 << 5) + 30] = Math.floor(h / 4294967296), p[(D + 128 >>> 10 << 5) + 31] = h, f.sigBytes = p.length * 4, this._process();
|
|
1965
1968
|
var i = this._hash.toX32();
|
|
1966
1969
|
return i;
|
|
1967
1970
|
},
|
|
1968
1971
|
clone: function() {
|
|
1969
|
-
var
|
|
1970
|
-
return
|
|
1972
|
+
var f = v.clone.call(this);
|
|
1973
|
+
return f._hash = this._hash.clone(), f;
|
|
1971
1974
|
},
|
|
1972
1975
|
blockSize: 1024 / 32
|
|
1973
1976
|
});
|
|
1974
1977
|
e.SHA512 = v._createHelper(s), e.HmacSHA512 = v._createHmacHelper(s);
|
|
1975
1978
|
})(), t.SHA512;
|
|
1976
1979
|
});
|
|
1977
|
-
})(
|
|
1980
|
+
})(T0)), T0.exports;
|
|
1978
1981
|
}
|
|
1979
|
-
var
|
|
1980
|
-
function
|
|
1981
|
-
return re || (re = 1, (function(r,
|
|
1982
|
-
(function(t, e,
|
|
1982
|
+
var M0 = { exports: {} }, Xt = M0.exports, re;
|
|
1983
|
+
function Zt() {
|
|
1984
|
+
return re || (re = 1, (function(r, d) {
|
|
1985
|
+
(function(t, e, u) {
|
|
1983
1986
|
r.exports = e(M(), vr(), ze());
|
|
1984
1987
|
})(Xt, function(t) {
|
|
1985
1988
|
return (function() {
|
|
1986
|
-
var e = t,
|
|
1989
|
+
var e = t, u = e.x64, v = u.Word, _ = u.WordArray, B = e.algo, C = B.SHA512, x = B.SHA384 = C.extend({
|
|
1987
1990
|
_doReset: function() {
|
|
1988
1991
|
this._hash = new _.init([
|
|
1989
1992
|
new v.init(3418070365, 3238371032),
|
|
@@ -2004,25 +2007,25 @@ function Yt() {
|
|
|
2004
2007
|
e.SHA384 = C._createHelper(x), e.HmacSHA384 = C._createHmacHelper(x);
|
|
2005
2008
|
})(), t.SHA384;
|
|
2006
2009
|
});
|
|
2007
|
-
})(
|
|
2010
|
+
})(M0)), M0.exports;
|
|
2008
2011
|
}
|
|
2009
|
-
var
|
|
2012
|
+
var N0 = { exports: {} }, Yt = N0.exports, ee;
|
|
2010
2013
|
function Qt() {
|
|
2011
|
-
return ee || (ee = 1, (function(r,
|
|
2012
|
-
(function(t, e,
|
|
2014
|
+
return ee || (ee = 1, (function(r, d) {
|
|
2015
|
+
(function(t, e, u) {
|
|
2013
2016
|
r.exports = e(M(), vr());
|
|
2014
|
-
})(
|
|
2017
|
+
})(Yt, function(t) {
|
|
2015
2018
|
return (function(e) {
|
|
2016
|
-
var
|
|
2019
|
+
var u = t, v = u.lib, _ = v.WordArray, B = v.Hasher, C = u.x64, x = C.Word, n = u.algo, E = [], a = [], s = [];
|
|
2017
2020
|
(function() {
|
|
2018
|
-
for (var
|
|
2019
|
-
E[
|
|
2020
|
-
var o = D % 5,
|
|
2021
|
-
|
|
2021
|
+
for (var h = 1, D = 0, i = 0; i < 24; i++) {
|
|
2022
|
+
E[h + 5 * D] = (i + 1) * (i + 2) / 2 % 64;
|
|
2023
|
+
var o = D % 5, l = (2 * h + 3 * D) % 5;
|
|
2024
|
+
h = o, D = l;
|
|
2022
2025
|
}
|
|
2023
|
-
for (var
|
|
2026
|
+
for (var h = 0; h < 5; h++)
|
|
2024
2027
|
for (var D = 0; D < 5; D++)
|
|
2025
|
-
a[
|
|
2028
|
+
a[h + 5 * D] = D + (2 * h + 3 * D) % 5 * 5;
|
|
2026
2029
|
for (var b = 1, g = 0; g < 24; g++) {
|
|
2027
2030
|
for (var y = 0, k = 0, R = 0; R < 7; R++) {
|
|
2028
2031
|
if (b & 1) {
|
|
@@ -2034,10 +2037,10 @@ function Qt() {
|
|
|
2034
2037
|
s[g] = x.create(y, k);
|
|
2035
2038
|
}
|
|
2036
2039
|
})();
|
|
2037
|
-
var
|
|
2040
|
+
var f = [];
|
|
2038
2041
|
(function() {
|
|
2039
|
-
for (var
|
|
2040
|
-
|
|
2042
|
+
for (var h = 0; h < 25; h++)
|
|
2043
|
+
f[h] = x.create();
|
|
2041
2044
|
})();
|
|
2042
2045
|
var p = n.SHA3 = B.extend({
|
|
2043
2046
|
/**
|
|
@@ -2052,15 +2055,15 @@ function Qt() {
|
|
|
2052
2055
|
outputLength: 512
|
|
2053
2056
|
}),
|
|
2054
2057
|
_doReset: function() {
|
|
2055
|
-
for (var
|
|
2056
|
-
|
|
2058
|
+
for (var h = this._state = [], D = 0; D < 25; D++)
|
|
2059
|
+
h[D] = new x.init();
|
|
2057
2060
|
this.blockSize = (1600 - 2 * this.cfg.outputLength) / 32;
|
|
2058
2061
|
},
|
|
2059
|
-
_doProcessBlock: function(
|
|
2060
|
-
for (var i = this._state, o = this.blockSize / 2,
|
|
2061
|
-
var b =
|
|
2062
|
+
_doProcessBlock: function(h, D) {
|
|
2063
|
+
for (var i = this._state, o = this.blockSize / 2, l = 0; l < o; l++) {
|
|
2064
|
+
var b = h[D + 2 * l], g = h[D + 2 * l + 1];
|
|
2062
2065
|
b = (b << 8 | b >>> 24) & 16711935 | (b << 24 | b >>> 8) & 4278255360, g = (g << 8 | g >>> 24) & 16711935 | (g << 24 | g >>> 8) & 4278255360;
|
|
2063
|
-
var y = i[
|
|
2066
|
+
var y = i[l];
|
|
2064
2067
|
y.high ^= g, y.low ^= b;
|
|
2065
2068
|
}
|
|
2066
2069
|
for (var k = 0; k < 24; k++) {
|
|
@@ -2069,61 +2072,61 @@ function Qt() {
|
|
|
2069
2072
|
var y = i[R + 5 * H];
|
|
2070
2073
|
F ^= y.high, w ^= y.low;
|
|
2071
2074
|
}
|
|
2072
|
-
var $ =
|
|
2075
|
+
var $ = f[R];
|
|
2073
2076
|
$.high = F, $.low = w;
|
|
2074
2077
|
}
|
|
2075
2078
|
for (var R = 0; R < 5; R++)
|
|
2076
|
-
for (var z =
|
|
2079
|
+
for (var z = f[(R + 4) % 5], O = f[(R + 1) % 5], q = O.high, U = O.low, F = z.high ^ (q << 1 | U >>> 31), w = z.low ^ (U << 1 | q >>> 31), H = 0; H < 5; H++) {
|
|
2077
2080
|
var y = i[R + 5 * H];
|
|
2078
2081
|
y.high ^= F, y.low ^= w;
|
|
2079
2082
|
}
|
|
2080
2083
|
for (var T = 1; T < 25; T++) {
|
|
2081
2084
|
var F, w, y = i[T], N = y.high, j = y.low, S = E[T];
|
|
2082
2085
|
S < 32 ? (F = N << S | j >>> 32 - S, w = j << S | N >>> 32 - S) : (F = j << S - 32 | N >>> 64 - S, w = N << S - 32 | j >>> 64 - S);
|
|
2083
|
-
var
|
|
2084
|
-
|
|
2086
|
+
var c = f[a[T]];
|
|
2087
|
+
c.high = F, c.low = w;
|
|
2085
2088
|
}
|
|
2086
|
-
var A =
|
|
2089
|
+
var A = f[0], m = i[0];
|
|
2087
2090
|
A.high = m.high, A.low = m.low;
|
|
2088
2091
|
for (var R = 0; R < 5; R++)
|
|
2089
2092
|
for (var H = 0; H < 5; H++) {
|
|
2090
|
-
var T = R + 5 * H, y = i[T],
|
|
2091
|
-
y.high =
|
|
2093
|
+
var T = R + 5 * H, y = i[T], W = f[T], P = f[(R + 1) % 5 + 5 * H], L = f[(R + 2) % 5 + 5 * H];
|
|
2094
|
+
y.high = W.high ^ ~P.high & L.high, y.low = W.low ^ ~P.low & L.low;
|
|
2092
2095
|
}
|
|
2093
|
-
var y = i[0],
|
|
2094
|
-
y.high ^=
|
|
2096
|
+
var y = i[0], I = s[k];
|
|
2097
|
+
y.high ^= I.high, y.low ^= I.low;
|
|
2095
2098
|
}
|
|
2096
2099
|
},
|
|
2097
2100
|
_doFinalize: function() {
|
|
2098
|
-
var
|
|
2101
|
+
var h = this._data, D = h.words;
|
|
2099
2102
|
this._nDataBytes * 8;
|
|
2100
|
-
var i =
|
|
2101
|
-
D[i >>> 5] |= 1 << 24 - i % 32, D[(e.ceil((i + 1) / o) * o >>> 5) - 1] |= 128,
|
|
2102
|
-
for (var
|
|
2103
|
-
var R =
|
|
2103
|
+
var i = h.sigBytes * 8, o = this.blockSize * 32;
|
|
2104
|
+
D[i >>> 5] |= 1 << 24 - i % 32, D[(e.ceil((i + 1) / o) * o >>> 5) - 1] |= 128, h.sigBytes = D.length * 4, this._process();
|
|
2105
|
+
for (var l = this._state, b = this.cfg.outputLength / 8, g = b / 8, y = [], k = 0; k < g; k++) {
|
|
2106
|
+
var R = l[k], F = R.high, w = R.low;
|
|
2104
2107
|
F = (F << 8 | F >>> 24) & 16711935 | (F << 24 | F >>> 8) & 4278255360, w = (w << 8 | w >>> 24) & 16711935 | (w << 24 | w >>> 8) & 4278255360, y.push(w), y.push(F);
|
|
2105
2108
|
}
|
|
2106
2109
|
return new _.init(y, b);
|
|
2107
2110
|
},
|
|
2108
2111
|
clone: function() {
|
|
2109
|
-
for (var
|
|
2112
|
+
for (var h = B.clone.call(this), D = h._state = this._state.slice(0), i = 0; i < 25; i++)
|
|
2110
2113
|
D[i] = D[i].clone();
|
|
2111
|
-
return
|
|
2114
|
+
return h;
|
|
2112
2115
|
}
|
|
2113
2116
|
});
|
|
2114
|
-
|
|
2117
|
+
u.SHA3 = B._createHelper(p), u.HmacSHA3 = B._createHmacHelper(p);
|
|
2115
2118
|
})(Math), t.SHA3;
|
|
2116
2119
|
});
|
|
2117
|
-
})(
|
|
2120
|
+
})(N0)), N0.exports;
|
|
2118
2121
|
}
|
|
2119
|
-
var
|
|
2122
|
+
var U0 = { exports: {} }, Vt = U0.exports, te;
|
|
2120
2123
|
function Jt() {
|
|
2121
|
-
return te || (te = 1, (function(r,
|
|
2124
|
+
return te || (te = 1, (function(r, d) {
|
|
2122
2125
|
(function(t, e) {
|
|
2123
2126
|
r.exports = e(M());
|
|
2124
2127
|
})(Vt, function(t) {
|
|
2125
2128
|
return (function(e) {
|
|
2126
|
-
var
|
|
2129
|
+
var u = t, v = u.lib, _ = v.WordArray, B = v.Hasher, C = u.algo, x = _.create([
|
|
2127
2130
|
0,
|
|
2128
2131
|
1,
|
|
2129
2132
|
2,
|
|
@@ -2447,7 +2450,7 @@ function Jt() {
|
|
|
2447
2450
|
13,
|
|
2448
2451
|
11,
|
|
2449
2452
|
11
|
|
2450
|
-
]), s = _.create([0, 1518500249, 1859775393, 2400959708, 2840853838]),
|
|
2453
|
+
]), s = _.create([0, 1518500249, 1859775393, 2400959708, 2840853838]), f = _.create([1352829926, 1548603684, 1836072691, 2053994217, 0]), p = C.RIPEMD160 = B.extend({
|
|
2451
2454
|
_doReset: function() {
|
|
2452
2455
|
this._hash = _.create([1732584193, 4023233417, 2562383102, 271733878, 3285377520]);
|
|
2453
2456
|
},
|
|
@@ -2456,11 +2459,11 @@ function Jt() {
|
|
|
2456
2459
|
var R = y + k, F = g[R];
|
|
2457
2460
|
g[R] = (F << 8 | F >>> 24) & 16711935 | (F << 24 | F >>> 8) & 4278255360;
|
|
2458
2461
|
}
|
|
2459
|
-
var w = this._hash.words, H = s.words, $ =
|
|
2460
|
-
A = T = w[0], m = N = w[1],
|
|
2461
|
-
for (var
|
|
2462
|
-
|
|
2463
|
-
|
|
2462
|
+
var w = this._hash.words, H = s.words, $ = f.words, z = x.words, O = n.words, q = E.words, U = a.words, T, N, j, S, c, A, m, W, P, L;
|
|
2463
|
+
A = T = w[0], m = N = w[1], W = j = w[2], P = S = w[3], L = c = w[4];
|
|
2464
|
+
for (var I, k = 0; k < 80; k += 1)
|
|
2465
|
+
I = T + g[y + z[k]] | 0, k < 16 ? I += h(N, j, S) + H[0] : k < 32 ? I += D(N, j, S) + H[1] : k < 48 ? I += i(N, j, S) + H[2] : k < 64 ? I += o(N, j, S) + H[3] : I += l(N, j, S) + H[4], I = I | 0, I = b(I, q[k]), I = I + c | 0, T = c, c = S, S = b(j, 10), j = N, N = I, I = A + g[y + O[k]] | 0, k < 16 ? I += l(m, W, P) + $[0] : k < 32 ? I += o(m, W, P) + $[1] : k < 48 ? I += i(m, W, P) + $[2] : k < 64 ? I += D(m, W, P) + $[3] : I += h(m, W, P) + $[4], I = I | 0, I = b(I, U[k]), I = I + L | 0, A = L, L = P, P = b(W, 10), W = m, m = I;
|
|
2466
|
+
I = w[1] + j + P | 0, w[1] = w[2] + S + L | 0, w[2] = w[3] + c + A | 0, w[3] = w[4] + T + m | 0, w[4] = w[0] + N + W | 0, w[0] = I;
|
|
2464
2467
|
},
|
|
2465
2468
|
_doFinalize: function() {
|
|
2466
2469
|
var g = this._data, y = g.words, k = this._nDataBytes * 8, R = g.sigBytes * 8;
|
|
@@ -2476,7 +2479,7 @@ function Jt() {
|
|
|
2476
2479
|
return g._hash = this._hash.clone(), g;
|
|
2477
2480
|
}
|
|
2478
2481
|
});
|
|
2479
|
-
function
|
|
2482
|
+
function h(g, y, k) {
|
|
2480
2483
|
return g ^ y ^ k;
|
|
2481
2484
|
}
|
|
2482
2485
|
function D(g, y, k) {
|
|
@@ -2488,25 +2491,25 @@ function Jt() {
|
|
|
2488
2491
|
function o(g, y, k) {
|
|
2489
2492
|
return g & k | y & ~k;
|
|
2490
2493
|
}
|
|
2491
|
-
function
|
|
2494
|
+
function l(g, y, k) {
|
|
2492
2495
|
return g ^ (y | ~k);
|
|
2493
2496
|
}
|
|
2494
2497
|
function b(g, y) {
|
|
2495
2498
|
return g << y | g >>> 32 - y;
|
|
2496
2499
|
}
|
|
2497
|
-
|
|
2500
|
+
u.RIPEMD160 = B._createHelper(p), u.HmacRIPEMD160 = B._createHmacHelper(p);
|
|
2498
2501
|
})(), t.RIPEMD160;
|
|
2499
2502
|
});
|
|
2500
|
-
})(
|
|
2503
|
+
})(U0)), U0.exports;
|
|
2501
2504
|
}
|
|
2502
|
-
var
|
|
2505
|
+
var j0 = { exports: {} }, rx = j0.exports, xe;
|
|
2503
2506
|
function _r() {
|
|
2504
|
-
return xe || (xe = 1, (function(r,
|
|
2507
|
+
return xe || (xe = 1, (function(r, d) {
|
|
2505
2508
|
(function(t, e) {
|
|
2506
2509
|
r.exports = e(M());
|
|
2507
2510
|
})(rx, function(t) {
|
|
2508
2511
|
(function() {
|
|
2509
|
-
var e = t,
|
|
2512
|
+
var e = t, u = e.lib, v = u.Base, _ = e.enc, B = _.Utf8, C = e.algo;
|
|
2510
2513
|
C.HMAC = v.extend({
|
|
2511
2514
|
/**
|
|
2512
2515
|
* Initializes a newly created HMAC.
|
|
@@ -2522,9 +2525,9 @@ function _r() {
|
|
|
2522
2525
|
x = this._hasher = new x.init(), typeof n == "string" && (n = B.parse(n));
|
|
2523
2526
|
var E = x.blockSize, a = E * 4;
|
|
2524
2527
|
n.sigBytes > a && (n = x.finalize(n)), n.clamp();
|
|
2525
|
-
for (var s = this._oKey = n.clone(),
|
|
2526
|
-
p[D] ^= 1549556828,
|
|
2527
|
-
s.sigBytes =
|
|
2528
|
+
for (var s = this._oKey = n.clone(), f = this._iKey = n.clone(), p = s.words, h = f.words, D = 0; D < E; D++)
|
|
2529
|
+
p[D] ^= 1549556828, h[D] ^= 909522486;
|
|
2530
|
+
s.sigBytes = f.sigBytes = a, this.reset();
|
|
2528
2531
|
},
|
|
2529
2532
|
/**
|
|
2530
2533
|
* Resets this HMAC to its initial state.
|
|
@@ -2575,16 +2578,16 @@ function _r() {
|
|
|
2575
2578
|
});
|
|
2576
2579
|
})();
|
|
2577
2580
|
});
|
|
2578
|
-
})(
|
|
2581
|
+
})(j0)), j0.exports;
|
|
2579
2582
|
}
|
|
2580
|
-
var
|
|
2583
|
+
var G0 = { exports: {} }, ex = G0.exports, ne;
|
|
2581
2584
|
function tx() {
|
|
2582
|
-
return ne || (ne = 1, (function(r,
|
|
2583
|
-
(function(t, e,
|
|
2585
|
+
return ne || (ne = 1, (function(r, d) {
|
|
2586
|
+
(function(t, e, u) {
|
|
2584
2587
|
r.exports = e(M(), mr(), _r());
|
|
2585
2588
|
})(ex, function(t) {
|
|
2586
2589
|
return (function() {
|
|
2587
|
-
var e = t,
|
|
2590
|
+
var e = t, u = e.lib, v = u.Base, _ = u.WordArray, B = e.algo, C = B.SHA256, x = B.HMAC, n = B.PBKDF2 = v.extend({
|
|
2588
2591
|
/**
|
|
2589
2592
|
* Configuration options.
|
|
2590
2593
|
*
|
|
@@ -2624,11 +2627,11 @@ function tx() {
|
|
|
2624
2627
|
* var key = kdf.compute(password, salt);
|
|
2625
2628
|
*/
|
|
2626
2629
|
compute: function(E, a) {
|
|
2627
|
-
for (var s = this.cfg,
|
|
2628
|
-
var b =
|
|
2629
|
-
|
|
2630
|
-
for (var g = b.words, y = g.length, k = b, R = 1; R <
|
|
2631
|
-
k =
|
|
2630
|
+
for (var s = this.cfg, f = x.create(s.hasher, E), p = _.create(), h = _.create([1]), D = p.words, i = h.words, o = s.keySize, l = s.iterations; D.length < o; ) {
|
|
2631
|
+
var b = f.update(a).finalize(h);
|
|
2632
|
+
f.reset();
|
|
2633
|
+
for (var g = b.words, y = g.length, k = b, R = 1; R < l; R++) {
|
|
2634
|
+
k = f.finalize(k), f.reset();
|
|
2632
2635
|
for (var F = k.words, w = 0; w < y; w++)
|
|
2633
2636
|
g[w] ^= F[w];
|
|
2634
2637
|
}
|
|
@@ -2642,16 +2645,16 @@ function tx() {
|
|
|
2642
2645
|
};
|
|
2643
2646
|
})(), t.PBKDF2;
|
|
2644
2647
|
});
|
|
2645
|
-
})(
|
|
2648
|
+
})(G0)), G0.exports;
|
|
2646
2649
|
}
|
|
2647
|
-
var
|
|
2650
|
+
var K0 = { exports: {} }, xx = K0.exports, ae;
|
|
2648
2651
|
function o0() {
|
|
2649
|
-
return ae || (ae = 1, (function(r,
|
|
2650
|
-
(function(t, e,
|
|
2652
|
+
return ae || (ae = 1, (function(r, d) {
|
|
2653
|
+
(function(t, e, u) {
|
|
2651
2654
|
r.exports = e(M(), Pe(), _r());
|
|
2652
2655
|
})(xx, function(t) {
|
|
2653
2656
|
return (function() {
|
|
2654
|
-
var e = t,
|
|
2657
|
+
var e = t, u = e.lib, v = u.Base, _ = u.WordArray, B = e.algo, C = B.MD5, x = B.EvpKDF = v.extend({
|
|
2655
2658
|
/**
|
|
2656
2659
|
* Configuration options.
|
|
2657
2660
|
*
|
|
@@ -2691,10 +2694,10 @@ function o0() {
|
|
|
2691
2694
|
* var key = kdf.compute(password, salt);
|
|
2692
2695
|
*/
|
|
2693
2696
|
compute: function(n, E) {
|
|
2694
|
-
for (var a, s = this.cfg,
|
|
2695
|
-
a &&
|
|
2697
|
+
for (var a, s = this.cfg, f = s.hasher.create(), p = _.create(), h = p.words, D = s.keySize, i = s.iterations; h.length < D; ) {
|
|
2698
|
+
a && f.update(a), a = f.update(n).finalize(E), f.reset();
|
|
2696
2699
|
for (var o = 1; o < i; o++)
|
|
2697
|
-
a =
|
|
2700
|
+
a = f.finalize(a), f.reset();
|
|
2698
2701
|
p.concat(a);
|
|
2699
2702
|
}
|
|
2700
2703
|
return p.sigBytes = D * 4, p;
|
|
@@ -2705,18 +2708,18 @@ function o0() {
|
|
|
2705
2708
|
};
|
|
2706
2709
|
})(), t.EvpKDF;
|
|
2707
2710
|
});
|
|
2708
|
-
})(
|
|
2711
|
+
})(K0)), K0.exports;
|
|
2709
2712
|
}
|
|
2710
|
-
var
|
|
2713
|
+
var X0 = { exports: {} }, nx = X0.exports, oe;
|
|
2711
2714
|
function X() {
|
|
2712
|
-
return oe || (oe = 1, (function(r,
|
|
2713
|
-
(function(t, e,
|
|
2715
|
+
return oe || (oe = 1, (function(r, d) {
|
|
2716
|
+
(function(t, e, u) {
|
|
2714
2717
|
r.exports = e(M(), o0());
|
|
2715
2718
|
})(nx, function(t) {
|
|
2716
2719
|
t.lib.Cipher || (function(e) {
|
|
2717
|
-
var
|
|
2720
|
+
var u = t, v = u.lib, _ = v.Base, B = v.WordArray, C = v.BufferedBlockAlgorithm, x = u.enc;
|
|
2718
2721
|
x.Utf8;
|
|
2719
|
-
var n = x.Base64, E =
|
|
2722
|
+
var n = x.Base64, E = u.algo, a = E.EvpKDF, s = v.Cipher = C.extend({
|
|
2720
2723
|
/**
|
|
2721
2724
|
* Configuration options.
|
|
2722
2725
|
*
|
|
@@ -2855,7 +2858,7 @@ function X() {
|
|
|
2855
2858
|
},
|
|
2856
2859
|
blockSize: 1
|
|
2857
2860
|
});
|
|
2858
|
-
var
|
|
2861
|
+
var f = u.mode = {}, p = v.BlockCipherMode = _.extend({
|
|
2859
2862
|
/**
|
|
2860
2863
|
* Creates this mode for encryption.
|
|
2861
2864
|
*
|
|
@@ -2899,7 +2902,7 @@ function X() {
|
|
|
2899
2902
|
init: function(F, w) {
|
|
2900
2903
|
this._cipher = F, this._iv = w;
|
|
2901
2904
|
}
|
|
2902
|
-
}),
|
|
2905
|
+
}), h = f.CBC = (function() {
|
|
2903
2906
|
var F = p.extend();
|
|
2904
2907
|
F.Encryptor = F.extend({
|
|
2905
2908
|
/**
|
|
@@ -2939,7 +2942,7 @@ function X() {
|
|
|
2939
2942
|
H[$ + U] ^= O[U];
|
|
2940
2943
|
}
|
|
2941
2944
|
return F;
|
|
2942
|
-
})(), D =
|
|
2945
|
+
})(), D = u.pad = {}, i = D.Pkcs7 = {
|
|
2943
2946
|
/**
|
|
2944
2947
|
* Pads data using the algorithm defined in PKCS #5/7.
|
|
2945
2948
|
*
|
|
@@ -2982,7 +2985,7 @@ function X() {
|
|
|
2982
2985
|
* @property {Padding} padding The padding strategy to use. Default: Pkcs7
|
|
2983
2986
|
*/
|
|
2984
2987
|
cfg: s.cfg.extend({
|
|
2985
|
-
mode:
|
|
2988
|
+
mode: h,
|
|
2986
2989
|
padding: i
|
|
2987
2990
|
}),
|
|
2988
2991
|
reset: function() {
|
|
@@ -3041,7 +3044,7 @@ function X() {
|
|
|
3041
3044
|
toString: function(F) {
|
|
3042
3045
|
return (F || this.formatter).stringify(this);
|
|
3043
3046
|
}
|
|
3044
|
-
}),
|
|
3047
|
+
}), l = u.format = {}, b = l.OpenSSL = {
|
|
3045
3048
|
/**
|
|
3046
3049
|
* Converts a cipher params object to an OpenSSL-compatible string.
|
|
3047
3050
|
*
|
|
@@ -3157,7 +3160,7 @@ function X() {
|
|
|
3157
3160
|
_parse: function(F, w) {
|
|
3158
3161
|
return typeof F == "string" ? w.parse(F, this) : F;
|
|
3159
3162
|
}
|
|
3160
|
-
}), y =
|
|
3163
|
+
}), y = u.kdf = {}, k = y.OpenSSL = {
|
|
3161
3164
|
/**
|
|
3162
3165
|
* Derives a key and IV from a password.
|
|
3163
3166
|
*
|
|
@@ -3243,12 +3246,12 @@ function X() {
|
|
|
3243
3246
|
});
|
|
3244
3247
|
})();
|
|
3245
3248
|
});
|
|
3246
|
-
})(
|
|
3249
|
+
})(X0)), X0.exports;
|
|
3247
3250
|
}
|
|
3248
|
-
var
|
|
3251
|
+
var Z0 = { exports: {} }, ax = Z0.exports, ie;
|
|
3249
3252
|
function ox() {
|
|
3250
|
-
return ie || (ie = 1, (function(r,
|
|
3251
|
-
(function(t, e,
|
|
3253
|
+
return ie || (ie = 1, (function(r, d) {
|
|
3254
|
+
(function(t, e, u) {
|
|
3252
3255
|
r.exports = e(M(), X());
|
|
3253
3256
|
})(ax, function(t) {
|
|
3254
3257
|
return t.mode.CFB = (function() {
|
|
@@ -3256,15 +3259,15 @@ function ox() {
|
|
|
3256
3259
|
e.Encryptor = e.extend({
|
|
3257
3260
|
processBlock: function(v, _) {
|
|
3258
3261
|
var B = this._cipher, C = B.blockSize;
|
|
3259
|
-
|
|
3262
|
+
u.call(this, v, _, C, B), this._prevBlock = v.slice(_, _ + C);
|
|
3260
3263
|
}
|
|
3261
3264
|
}), e.Decryptor = e.extend({
|
|
3262
3265
|
processBlock: function(v, _) {
|
|
3263
3266
|
var B = this._cipher, C = B.blockSize, x = v.slice(_, _ + C);
|
|
3264
|
-
|
|
3267
|
+
u.call(this, v, _, C, B), this._prevBlock = x;
|
|
3265
3268
|
}
|
|
3266
3269
|
});
|
|
3267
|
-
function
|
|
3270
|
+
function u(v, _, B, C) {
|
|
3268
3271
|
var x, n = this._iv;
|
|
3269
3272
|
n ? (x = n.slice(0), this._iv = void 0) : x = this._prevBlock, C.encryptBlock(x, 0);
|
|
3270
3273
|
for (var E = 0; E < B; E++)
|
|
@@ -3273,16 +3276,16 @@ function ox() {
|
|
|
3273
3276
|
return e;
|
|
3274
3277
|
})(), t.mode.CFB;
|
|
3275
3278
|
});
|
|
3276
|
-
})(
|
|
3279
|
+
})(Z0)), Z0.exports;
|
|
3277
3280
|
}
|
|
3278
3281
|
var Y0 = { exports: {} }, ix = Y0.exports, se;
|
|
3279
3282
|
function sx() {
|
|
3280
|
-
return se || (se = 1, (function(r,
|
|
3281
|
-
(function(t, e,
|
|
3283
|
+
return se || (se = 1, (function(r, d) {
|
|
3284
|
+
(function(t, e, u) {
|
|
3282
3285
|
r.exports = e(M(), X());
|
|
3283
3286
|
})(ix, function(t) {
|
|
3284
3287
|
return t.mode.CTR = (function() {
|
|
3285
|
-
var e = t.lib.BlockCipherMode.extend(),
|
|
3288
|
+
var e = t.lib.BlockCipherMode.extend(), u = e.Encryptor = e.extend({
|
|
3286
3289
|
processBlock: function(v, _) {
|
|
3287
3290
|
var B = this._cipher, C = B.blockSize, x = this._iv, n = this._counter;
|
|
3288
3291
|
x && (n = this._counter = x.slice(0), this._iv = void 0);
|
|
@@ -3292,20 +3295,20 @@ function sx() {
|
|
|
3292
3295
|
v[_ + a] ^= E[a];
|
|
3293
3296
|
}
|
|
3294
3297
|
});
|
|
3295
|
-
return e.Decryptor =
|
|
3298
|
+
return e.Decryptor = u, e;
|
|
3296
3299
|
})(), t.mode.CTR;
|
|
3297
3300
|
});
|
|
3298
3301
|
})(Y0)), Y0.exports;
|
|
3299
3302
|
}
|
|
3300
|
-
var
|
|
3303
|
+
var Q0 = { exports: {} }, cx = Q0.exports, ce;
|
|
3301
3304
|
function fx() {
|
|
3302
|
-
return ce || (ce = 1, (function(r,
|
|
3303
|
-
(function(t, e,
|
|
3305
|
+
return ce || (ce = 1, (function(r, d) {
|
|
3306
|
+
(function(t, e, u) {
|
|
3304
3307
|
r.exports = e(M(), X());
|
|
3305
3308
|
})(cx, function(t) {
|
|
3306
3309
|
return t.mode.CTRGladman = (function() {
|
|
3307
3310
|
var e = t.lib.BlockCipherMode.extend();
|
|
3308
|
-
function
|
|
3311
|
+
function u(B) {
|
|
3309
3312
|
if ((B >> 24 & 255) === 255) {
|
|
3310
3313
|
var C = B >> 16 & 255, x = B >> 8 & 255, n = B & 255;
|
|
3311
3314
|
C === 255 ? (C = 0, x === 255 ? (x = 0, n === 255 ? n = 0 : ++n) : ++x) : ++C, B = 0, B += C << 16, B += x << 8, B += n;
|
|
@@ -3314,7 +3317,7 @@ function fx() {
|
|
|
3314
3317
|
return B;
|
|
3315
3318
|
}
|
|
3316
3319
|
function v(B) {
|
|
3317
|
-
return (B[0] =
|
|
3320
|
+
return (B[0] = u(B[0])) === 0 && (B[1] = u(B[1])), B;
|
|
3318
3321
|
}
|
|
3319
3322
|
var _ = e.Encryptor = e.extend({
|
|
3320
3323
|
processBlock: function(B, C) {
|
|
@@ -3322,23 +3325,23 @@ function fx() {
|
|
|
3322
3325
|
E && (a = this._counter = E.slice(0), this._iv = void 0), v(a);
|
|
3323
3326
|
var s = a.slice(0);
|
|
3324
3327
|
x.encryptBlock(s, 0);
|
|
3325
|
-
for (var
|
|
3326
|
-
B[C +
|
|
3328
|
+
for (var f = 0; f < n; f++)
|
|
3329
|
+
B[C + f] ^= s[f];
|
|
3327
3330
|
}
|
|
3328
3331
|
});
|
|
3329
3332
|
return e.Decryptor = _, e;
|
|
3330
3333
|
})(), t.mode.CTRGladman;
|
|
3331
3334
|
});
|
|
3332
|
-
})(
|
|
3335
|
+
})(Q0)), Q0.exports;
|
|
3333
3336
|
}
|
|
3334
|
-
var
|
|
3337
|
+
var V0 = { exports: {} }, ux = V0.exports, fe;
|
|
3335
3338
|
function dx() {
|
|
3336
|
-
return fe || (fe = 1, (function(r,
|
|
3337
|
-
(function(t, e,
|
|
3339
|
+
return fe || (fe = 1, (function(r, d) {
|
|
3340
|
+
(function(t, e, u) {
|
|
3338
3341
|
r.exports = e(M(), X());
|
|
3339
3342
|
})(ux, function(t) {
|
|
3340
3343
|
return t.mode.OFB = (function() {
|
|
3341
|
-
var e = t.lib.BlockCipherMode.extend(),
|
|
3344
|
+
var e = t.lib.BlockCipherMode.extend(), u = e.Encryptor = e.extend({
|
|
3342
3345
|
processBlock: function(v, _) {
|
|
3343
3346
|
var B = this._cipher, C = B.blockSize, x = this._iv, n = this._keystream;
|
|
3344
3347
|
x && (n = this._keystream = x.slice(0), this._iv = void 0), B.encryptBlock(n, 0);
|
|
@@ -3346,113 +3349,113 @@ function dx() {
|
|
|
3346
3349
|
v[_ + E] ^= n[E];
|
|
3347
3350
|
}
|
|
3348
3351
|
});
|
|
3349
|
-
return e.Decryptor =
|
|
3352
|
+
return e.Decryptor = u, e;
|
|
3350
3353
|
})(), t.mode.OFB;
|
|
3351
3354
|
});
|
|
3352
|
-
})(
|
|
3355
|
+
})(V0)), V0.exports;
|
|
3353
3356
|
}
|
|
3354
|
-
var
|
|
3357
|
+
var J0 = { exports: {} }, lx = J0.exports, ue;
|
|
3355
3358
|
function hx() {
|
|
3356
|
-
return ue || (ue = 1, (function(r,
|
|
3357
|
-
(function(t, e,
|
|
3359
|
+
return ue || (ue = 1, (function(r, d) {
|
|
3360
|
+
(function(t, e, u) {
|
|
3358
3361
|
r.exports = e(M(), X());
|
|
3359
3362
|
})(lx, function(t) {
|
|
3360
3363
|
return t.mode.ECB = (function() {
|
|
3361
3364
|
var e = t.lib.BlockCipherMode.extend();
|
|
3362
3365
|
return e.Encryptor = e.extend({
|
|
3363
|
-
processBlock: function(
|
|
3364
|
-
this._cipher.encryptBlock(
|
|
3366
|
+
processBlock: function(u, v) {
|
|
3367
|
+
this._cipher.encryptBlock(u, v);
|
|
3365
3368
|
}
|
|
3366
3369
|
}), e.Decryptor = e.extend({
|
|
3367
|
-
processBlock: function(
|
|
3368
|
-
this._cipher.decryptBlock(
|
|
3370
|
+
processBlock: function(u, v) {
|
|
3371
|
+
this._cipher.decryptBlock(u, v);
|
|
3369
3372
|
}
|
|
3370
3373
|
}), e;
|
|
3371
3374
|
})(), t.mode.ECB;
|
|
3372
3375
|
});
|
|
3373
|
-
})(
|
|
3376
|
+
})(J0)), J0.exports;
|
|
3374
3377
|
}
|
|
3375
|
-
var
|
|
3378
|
+
var rr = { exports: {} }, vx = rr.exports, de;
|
|
3376
3379
|
function px() {
|
|
3377
|
-
return de || (de = 1, (function(r,
|
|
3378
|
-
(function(t, e,
|
|
3380
|
+
return de || (de = 1, (function(r, d) {
|
|
3381
|
+
(function(t, e, u) {
|
|
3379
3382
|
r.exports = e(M(), X());
|
|
3380
3383
|
})(vx, function(t) {
|
|
3381
3384
|
return t.pad.AnsiX923 = {
|
|
3382
|
-
pad: function(e,
|
|
3383
|
-
var v = e.sigBytes, _ =
|
|
3385
|
+
pad: function(e, u) {
|
|
3386
|
+
var v = e.sigBytes, _ = u * 4, B = _ - v % _, C = v + B - 1;
|
|
3384
3387
|
e.clamp(), e.words[C >>> 2] |= B << 24 - C % 4 * 8, e.sigBytes += B;
|
|
3385
3388
|
},
|
|
3386
3389
|
unpad: function(e) {
|
|
3387
|
-
var
|
|
3388
|
-
e.sigBytes -=
|
|
3390
|
+
var u = e.words[e.sigBytes - 1 >>> 2] & 255;
|
|
3391
|
+
e.sigBytes -= u;
|
|
3389
3392
|
}
|
|
3390
3393
|
}, t.pad.Ansix923;
|
|
3391
3394
|
});
|
|
3392
|
-
})(
|
|
3395
|
+
})(rr)), rr.exports;
|
|
3393
3396
|
}
|
|
3394
|
-
var
|
|
3397
|
+
var er = { exports: {} }, Bx = er.exports, le;
|
|
3395
3398
|
function Cx() {
|
|
3396
|
-
return le || (le = 1, (function(r,
|
|
3397
|
-
(function(t, e,
|
|
3399
|
+
return le || (le = 1, (function(r, d) {
|
|
3400
|
+
(function(t, e, u) {
|
|
3398
3401
|
r.exports = e(M(), X());
|
|
3399
3402
|
})(Bx, function(t) {
|
|
3400
3403
|
return t.pad.Iso10126 = {
|
|
3401
|
-
pad: function(e,
|
|
3402
|
-
var v =
|
|
3404
|
+
pad: function(e, u) {
|
|
3405
|
+
var v = u * 4, _ = v - e.sigBytes % v;
|
|
3403
3406
|
e.concat(t.lib.WordArray.random(_ - 1)).concat(t.lib.WordArray.create([_ << 24], 1));
|
|
3404
3407
|
},
|
|
3405
3408
|
unpad: function(e) {
|
|
3406
|
-
var
|
|
3407
|
-
e.sigBytes -=
|
|
3409
|
+
var u = e.words[e.sigBytes - 1 >>> 2] & 255;
|
|
3410
|
+
e.sigBytes -= u;
|
|
3408
3411
|
}
|
|
3409
3412
|
}, t.pad.Iso10126;
|
|
3410
3413
|
});
|
|
3411
|
-
})(
|
|
3414
|
+
})(er)), er.exports;
|
|
3412
3415
|
}
|
|
3413
|
-
var
|
|
3416
|
+
var tr = { exports: {} }, Ex = tr.exports, he;
|
|
3414
3417
|
function Ax() {
|
|
3415
|
-
return he || (he = 1, (function(r,
|
|
3416
|
-
(function(t, e,
|
|
3418
|
+
return he || (he = 1, (function(r, d) {
|
|
3419
|
+
(function(t, e, u) {
|
|
3417
3420
|
r.exports = e(M(), X());
|
|
3418
3421
|
})(Ex, function(t) {
|
|
3419
3422
|
return t.pad.Iso97971 = {
|
|
3420
|
-
pad: function(e,
|
|
3421
|
-
e.concat(t.lib.WordArray.create([2147483648], 1)), t.pad.ZeroPadding.pad(e,
|
|
3423
|
+
pad: function(e, u) {
|
|
3424
|
+
e.concat(t.lib.WordArray.create([2147483648], 1)), t.pad.ZeroPadding.pad(e, u);
|
|
3422
3425
|
},
|
|
3423
3426
|
unpad: function(e) {
|
|
3424
3427
|
t.pad.ZeroPadding.unpad(e), e.sigBytes--;
|
|
3425
3428
|
}
|
|
3426
3429
|
}, t.pad.Iso97971;
|
|
3427
3430
|
});
|
|
3428
|
-
})(
|
|
3431
|
+
})(tr)), tr.exports;
|
|
3429
3432
|
}
|
|
3430
|
-
var
|
|
3433
|
+
var xr = { exports: {} }, Fx = xr.exports, ve;
|
|
3431
3434
|
function gx() {
|
|
3432
|
-
return ve || (ve = 1, (function(r,
|
|
3433
|
-
(function(t, e,
|
|
3435
|
+
return ve || (ve = 1, (function(r, d) {
|
|
3436
|
+
(function(t, e, u) {
|
|
3434
3437
|
r.exports = e(M(), X());
|
|
3435
3438
|
})(Fx, function(t) {
|
|
3436
3439
|
return t.pad.ZeroPadding = {
|
|
3437
|
-
pad: function(e,
|
|
3438
|
-
var v =
|
|
3440
|
+
pad: function(e, u) {
|
|
3441
|
+
var v = u * 4;
|
|
3439
3442
|
e.clamp(), e.sigBytes += v - (e.sigBytes % v || v);
|
|
3440
3443
|
},
|
|
3441
3444
|
unpad: function(e) {
|
|
3442
|
-
for (var
|
|
3443
|
-
if (
|
|
3445
|
+
for (var u = e.words, v = e.sigBytes - 1, v = e.sigBytes - 1; v >= 0; v--)
|
|
3446
|
+
if (u[v >>> 2] >>> 24 - v % 4 * 8 & 255) {
|
|
3444
3447
|
e.sigBytes = v + 1;
|
|
3445
3448
|
break;
|
|
3446
3449
|
}
|
|
3447
3450
|
}
|
|
3448
3451
|
}, t.pad.ZeroPadding;
|
|
3449
3452
|
});
|
|
3450
|
-
})(
|
|
3453
|
+
})(xr)), xr.exports;
|
|
3451
3454
|
}
|
|
3452
|
-
var
|
|
3455
|
+
var nr = { exports: {} }, Dx = nr.exports, pe;
|
|
3453
3456
|
function bx() {
|
|
3454
|
-
return pe || (pe = 1, (function(r,
|
|
3455
|
-
(function(t, e,
|
|
3457
|
+
return pe || (pe = 1, (function(r, d) {
|
|
3458
|
+
(function(t, e, u) {
|
|
3456
3459
|
r.exports = e(M(), X());
|
|
3457
3460
|
})(Dx, function(t) {
|
|
3458
3461
|
return t.pad.NoPadding = {
|
|
@@ -3462,16 +3465,16 @@ function bx() {
|
|
|
3462
3465
|
}
|
|
3463
3466
|
}, t.pad.NoPadding;
|
|
3464
3467
|
});
|
|
3465
|
-
})(
|
|
3468
|
+
})(nr)), nr.exports;
|
|
3466
3469
|
}
|
|
3467
|
-
var
|
|
3470
|
+
var ar = { exports: {} }, mx = ar.exports, Be;
|
|
3468
3471
|
function _x() {
|
|
3469
|
-
return Be || (Be = 1, (function(r,
|
|
3470
|
-
(function(t, e,
|
|
3472
|
+
return Be || (Be = 1, (function(r, d) {
|
|
3473
|
+
(function(t, e, u) {
|
|
3471
3474
|
r.exports = e(M(), X());
|
|
3472
3475
|
})(mx, function(t) {
|
|
3473
3476
|
return (function(e) {
|
|
3474
|
-
var
|
|
3477
|
+
var u = t, v = u.lib, _ = v.CipherParams, B = u.enc, C = B.Hex, x = u.format;
|
|
3475
3478
|
x.Hex = {
|
|
3476
3479
|
/**
|
|
3477
3480
|
* Converts the ciphertext of a cipher params object to a hexadecimally encoded string.
|
|
@@ -3509,33 +3512,33 @@ function _x() {
|
|
|
3509
3512
|
};
|
|
3510
3513
|
})(), t.format.Hex;
|
|
3511
3514
|
});
|
|
3512
|
-
})(
|
|
3515
|
+
})(ar)), ar.exports;
|
|
3513
3516
|
}
|
|
3514
|
-
var
|
|
3517
|
+
var or = { exports: {} }, yx = or.exports, Ce;
|
|
3515
3518
|
function wx() {
|
|
3516
|
-
return Ce || (Ce = 1, (function(r,
|
|
3517
|
-
(function(t, e,
|
|
3519
|
+
return Ce || (Ce = 1, (function(r, d) {
|
|
3520
|
+
(function(t, e, u) {
|
|
3518
3521
|
r.exports = e(M(), c0(), f0(), o0(), X());
|
|
3519
3522
|
})(yx, function(t) {
|
|
3520
3523
|
return (function() {
|
|
3521
|
-
var e = t,
|
|
3524
|
+
var e = t, u = e.lib, v = u.BlockCipher, _ = e.algo, B = [], C = [], x = [], n = [], E = [], a = [], s = [], f = [], p = [], h = [];
|
|
3522
3525
|
(function() {
|
|
3523
|
-
for (var o = [],
|
|
3524
|
-
|
|
3525
|
-
for (var b = 0, g = 0,
|
|
3526
|
+
for (var o = [], l = 0; l < 256; l++)
|
|
3527
|
+
l < 128 ? o[l] = l << 1 : o[l] = l << 1 ^ 283;
|
|
3528
|
+
for (var b = 0, g = 0, l = 0; l < 256; l++) {
|
|
3526
3529
|
var y = g ^ g << 1 ^ g << 2 ^ g << 3 ^ g << 4;
|
|
3527
3530
|
y = y >>> 8 ^ y & 255 ^ 99, B[b] = y, C[y] = b;
|
|
3528
3531
|
var k = o[b], R = o[k], F = o[R], w = o[y] * 257 ^ y * 16843008;
|
|
3529
3532
|
x[b] = w << 24 | w >>> 8, n[b] = w << 16 | w >>> 16, E[b] = w << 8 | w >>> 24, a[b] = w;
|
|
3530
3533
|
var w = F * 16843009 ^ R * 65537 ^ k * 257 ^ b * 16843008;
|
|
3531
|
-
s[y] = w << 24 | w >>> 8,
|
|
3534
|
+
s[y] = w << 24 | w >>> 8, f[y] = w << 16 | w >>> 16, p[y] = w << 8 | w >>> 24, h[y] = w, b ? (b = k ^ o[o[o[F ^ k]]], g ^= o[o[g]]) : b = g = 1;
|
|
3532
3535
|
}
|
|
3533
3536
|
})();
|
|
3534
3537
|
var D = [0, 1, 2, 4, 8, 16, 32, 64, 128, 27, 54], i = _.AES = v.extend({
|
|
3535
3538
|
_doReset: function() {
|
|
3536
3539
|
var o;
|
|
3537
3540
|
if (!(this._nRounds && this._keyPriorReset === this._key)) {
|
|
3538
|
-
for (var
|
|
3541
|
+
for (var l = this._keyPriorReset = this._key, b = l.words, g = l.sigBytes / 4, y = this._nRounds = g + 6, k = (y + 1) * 4, R = this._keySchedule = [], F = 0; F < k; F++)
|
|
3539
3542
|
F < g ? R[F] = b[F] : (o = R[F - 1], F % g ? g > 6 && F % g == 4 && (o = B[o >>> 24] << 24 | B[o >>> 16 & 255] << 16 | B[o >>> 8 & 255] << 8 | B[o & 255]) : (o = o << 8 | o >>> 24, o = B[o >>> 24] << 24 | B[o >>> 16 & 255] << 16 | B[o >>> 8 & 255] << 8 | B[o & 255], o ^= D[F / g | 0] << 24), R[F] = R[F - g] ^ o);
|
|
3540
3543
|
for (var w = this._invKeySchedule = [], H = 0; H < k; H++) {
|
|
3541
3544
|
var F = k - H;
|
|
@@ -3543,42 +3546,42 @@ function wx() {
|
|
|
3543
3546
|
var o = R[F];
|
|
3544
3547
|
else
|
|
3545
3548
|
var o = R[F - 4];
|
|
3546
|
-
H < 4 || F <= 4 ? w[H] = o : w[H] = s[B[o >>> 24]] ^
|
|
3549
|
+
H < 4 || F <= 4 ? w[H] = o : w[H] = s[B[o >>> 24]] ^ f[B[o >>> 16 & 255]] ^ p[B[o >>> 8 & 255]] ^ h[B[o & 255]];
|
|
3547
3550
|
}
|
|
3548
3551
|
}
|
|
3549
3552
|
},
|
|
3550
|
-
encryptBlock: function(o,
|
|
3551
|
-
this._doCryptBlock(o,
|
|
3553
|
+
encryptBlock: function(o, l) {
|
|
3554
|
+
this._doCryptBlock(o, l, this._keySchedule, x, n, E, a, B);
|
|
3552
3555
|
},
|
|
3553
|
-
decryptBlock: function(o,
|
|
3554
|
-
var b = o[
|
|
3555
|
-
o[
|
|
3556
|
-
var b = o[
|
|
3557
|
-
o[
|
|
3556
|
+
decryptBlock: function(o, l) {
|
|
3557
|
+
var b = o[l + 1];
|
|
3558
|
+
o[l + 1] = o[l + 3], o[l + 3] = b, this._doCryptBlock(o, l, this._invKeySchedule, s, f, p, h, C);
|
|
3559
|
+
var b = o[l + 1];
|
|
3560
|
+
o[l + 1] = o[l + 3], o[l + 3] = b;
|
|
3558
3561
|
},
|
|
3559
|
-
_doCryptBlock: function(o,
|
|
3560
|
-
for (var w = this._nRounds, H = o[
|
|
3562
|
+
_doCryptBlock: function(o, l, b, g, y, k, R, F) {
|
|
3563
|
+
for (var w = this._nRounds, H = o[l] ^ b[0], $ = o[l + 1] ^ b[1], z = o[l + 2] ^ b[2], O = o[l + 3] ^ b[3], q = 4, U = 1; U < w; U++) {
|
|
3561
3564
|
var T = g[H >>> 24] ^ y[$ >>> 16 & 255] ^ k[z >>> 8 & 255] ^ R[O & 255] ^ b[q++], N = g[$ >>> 24] ^ y[z >>> 16 & 255] ^ k[O >>> 8 & 255] ^ R[H & 255] ^ b[q++], j = g[z >>> 24] ^ y[O >>> 16 & 255] ^ k[H >>> 8 & 255] ^ R[$ & 255] ^ b[q++], S = g[O >>> 24] ^ y[H >>> 16 & 255] ^ k[$ >>> 8 & 255] ^ R[z & 255] ^ b[q++];
|
|
3562
3565
|
H = T, $ = N, z = j, O = S;
|
|
3563
3566
|
}
|
|
3564
3567
|
var T = (F[H >>> 24] << 24 | F[$ >>> 16 & 255] << 16 | F[z >>> 8 & 255] << 8 | F[O & 255]) ^ b[q++], N = (F[$ >>> 24] << 24 | F[z >>> 16 & 255] << 16 | F[O >>> 8 & 255] << 8 | F[H & 255]) ^ b[q++], j = (F[z >>> 24] << 24 | F[O >>> 16 & 255] << 16 | F[H >>> 8 & 255] << 8 | F[$ & 255]) ^ b[q++], S = (F[O >>> 24] << 24 | F[H >>> 16 & 255] << 16 | F[$ >>> 8 & 255] << 8 | F[z & 255]) ^ b[q++];
|
|
3565
|
-
o[
|
|
3568
|
+
o[l] = T, o[l + 1] = N, o[l + 2] = j, o[l + 3] = S;
|
|
3566
3569
|
},
|
|
3567
3570
|
keySize: 256 / 32
|
|
3568
3571
|
});
|
|
3569
3572
|
e.AES = v._createHelper(i);
|
|
3570
3573
|
})(), t.AES;
|
|
3571
3574
|
});
|
|
3572
|
-
})(
|
|
3575
|
+
})(or)), or.exports;
|
|
3573
3576
|
}
|
|
3574
|
-
var
|
|
3577
|
+
var ir = { exports: {} }, kx = ir.exports, Ee;
|
|
3575
3578
|
function Sx() {
|
|
3576
|
-
return Ee || (Ee = 1, (function(r,
|
|
3577
|
-
(function(t, e,
|
|
3579
|
+
return Ee || (Ee = 1, (function(r, d) {
|
|
3580
|
+
(function(t, e, u) {
|
|
3578
3581
|
r.exports = e(M(), c0(), f0(), o0(), X());
|
|
3579
3582
|
})(kx, function(t) {
|
|
3580
3583
|
return (function() {
|
|
3581
|
-
var e = t,
|
|
3584
|
+
var e = t, u = e.lib, v = u.WordArray, _ = u.BlockCipher, B = e.algo, C = [
|
|
3582
3585
|
57,
|
|
3583
3586
|
49,
|
|
3584
3587
|
41,
|
|
@@ -4224,20 +4227,20 @@ function Sx() {
|
|
|
4224
4227
|
2147483679
|
|
4225
4228
|
], s = B.DES = _.extend({
|
|
4226
4229
|
_doReset: function() {
|
|
4227
|
-
for (var D = this._key, i = D.words, o = [],
|
|
4228
|
-
var b = C[
|
|
4229
|
-
o[
|
|
4230
|
+
for (var D = this._key, i = D.words, o = [], l = 0; l < 56; l++) {
|
|
4231
|
+
var b = C[l] - 1;
|
|
4232
|
+
o[l] = i[b >>> 5] >>> 31 - b % 32 & 1;
|
|
4230
4233
|
}
|
|
4231
4234
|
for (var g = this._subKeys = [], y = 0; y < 16; y++) {
|
|
4232
|
-
for (var k = g[y] = [], R = n[y],
|
|
4233
|
-
k[
|
|
4235
|
+
for (var k = g[y] = [], R = n[y], l = 0; l < 24; l++)
|
|
4236
|
+
k[l / 6 | 0] |= o[(x[l] - 1 + R) % 28] << 31 - l % 6, k[4 + (l / 6 | 0)] |= o[28 + (x[l + 24] - 1 + R) % 28] << 31 - l % 6;
|
|
4234
4237
|
k[0] = k[0] << 1 | k[0] >>> 31;
|
|
4235
|
-
for (var
|
|
4236
|
-
k[
|
|
4238
|
+
for (var l = 1; l < 7; l++)
|
|
4239
|
+
k[l] = k[l] >>> (l - 1) * 4 + 3;
|
|
4237
4240
|
k[7] = k[7] << 5 | k[7] >>> 27;
|
|
4238
4241
|
}
|
|
4239
|
-
for (var F = this._invSubKeys = [],
|
|
4240
|
-
F[
|
|
4242
|
+
for (var F = this._invSubKeys = [], l = 0; l < 16; l++)
|
|
4243
|
+
F[l] = g[15 - l];
|
|
4241
4244
|
},
|
|
4242
4245
|
encryptBlock: function(D, i) {
|
|
4243
4246
|
this._doCryptBlock(D, i, this._subKeys);
|
|
@@ -4246,20 +4249,20 @@ function Sx() {
|
|
|
4246
4249
|
this._doCryptBlock(D, i, this._invSubKeys);
|
|
4247
4250
|
},
|
|
4248
4251
|
_doCryptBlock: function(D, i, o) {
|
|
4249
|
-
this._lBlock = D[i], this._rBlock = D[i + 1],
|
|
4250
|
-
for (var
|
|
4251
|
-
for (var b = o[
|
|
4252
|
+
this._lBlock = D[i], this._rBlock = D[i + 1], f.call(this, 4, 252645135), f.call(this, 16, 65535), p.call(this, 2, 858993459), p.call(this, 8, 16711935), f.call(this, 1, 1431655765);
|
|
4253
|
+
for (var l = 0; l < 16; l++) {
|
|
4254
|
+
for (var b = o[l], g = this._lBlock, y = this._rBlock, k = 0, R = 0; R < 8; R++)
|
|
4252
4255
|
k |= E[R][((y ^ b[R]) & a[R]) >>> 0];
|
|
4253
4256
|
this._lBlock = y, this._rBlock = g ^ k;
|
|
4254
4257
|
}
|
|
4255
4258
|
var F = this._lBlock;
|
|
4256
|
-
this._lBlock = this._rBlock, this._rBlock = F,
|
|
4259
|
+
this._lBlock = this._rBlock, this._rBlock = F, f.call(this, 1, 1431655765), p.call(this, 8, 16711935), p.call(this, 2, 858993459), f.call(this, 16, 65535), f.call(this, 4, 252645135), D[i] = this._lBlock, D[i + 1] = this._rBlock;
|
|
4257
4260
|
},
|
|
4258
4261
|
keySize: 64 / 32,
|
|
4259
4262
|
ivSize: 64 / 32,
|
|
4260
4263
|
blockSize: 64 / 32
|
|
4261
4264
|
});
|
|
4262
|
-
function
|
|
4265
|
+
function f(D, i) {
|
|
4263
4266
|
var o = (this._lBlock >>> D ^ this._rBlock) & i;
|
|
4264
4267
|
this._rBlock ^= o, this._lBlock ^= o << D;
|
|
4265
4268
|
}
|
|
@@ -4268,13 +4271,13 @@ function Sx() {
|
|
|
4268
4271
|
this._lBlock ^= o, this._rBlock ^= o << D;
|
|
4269
4272
|
}
|
|
4270
4273
|
e.DES = _._createHelper(s);
|
|
4271
|
-
var
|
|
4274
|
+
var h = B.TripleDES = _.extend({
|
|
4272
4275
|
_doReset: function() {
|
|
4273
4276
|
var D = this._key, i = D.words;
|
|
4274
4277
|
if (i.length !== 2 && i.length !== 4 && i.length < 6)
|
|
4275
4278
|
throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");
|
|
4276
|
-
var o = i.slice(0, 2),
|
|
4277
|
-
this._des1 = s.createEncryptor(v.create(o)), this._des2 = s.createEncryptor(v.create(
|
|
4279
|
+
var o = i.slice(0, 2), l = i.length < 4 ? i.slice(0, 2) : i.slice(2, 4), b = i.length < 6 ? i.slice(0, 2) : i.slice(4, 6);
|
|
4280
|
+
this._des1 = s.createEncryptor(v.create(o)), this._des2 = s.createEncryptor(v.create(l)), this._des3 = s.createEncryptor(v.create(b));
|
|
4278
4281
|
},
|
|
4279
4282
|
encryptBlock: function(D, i) {
|
|
4280
4283
|
this._des1.encryptBlock(D, i), this._des2.decryptBlock(D, i), this._des3.encryptBlock(D, i);
|
|
@@ -4286,27 +4289,27 @@ function Sx() {
|
|
|
4286
4289
|
ivSize: 64 / 32,
|
|
4287
4290
|
blockSize: 64 / 32
|
|
4288
4291
|
});
|
|
4289
|
-
e.TripleDES = _._createHelper(
|
|
4292
|
+
e.TripleDES = _._createHelper(h);
|
|
4290
4293
|
})(), t.TripleDES;
|
|
4291
4294
|
});
|
|
4292
|
-
})(
|
|
4295
|
+
})(ir)), ir.exports;
|
|
4293
4296
|
}
|
|
4294
|
-
var
|
|
4297
|
+
var sr = { exports: {} }, Hx = sr.exports, Ae;
|
|
4295
4298
|
function $x() {
|
|
4296
|
-
return Ae || (Ae = 1, (function(r,
|
|
4297
|
-
(function(t, e,
|
|
4299
|
+
return Ae || (Ae = 1, (function(r, d) {
|
|
4300
|
+
(function(t, e, u) {
|
|
4298
4301
|
r.exports = e(M(), c0(), f0(), o0(), X());
|
|
4299
4302
|
})(Hx, function(t) {
|
|
4300
4303
|
return (function() {
|
|
4301
|
-
var e = t,
|
|
4304
|
+
var e = t, u = e.lib, v = u.StreamCipher, _ = e.algo, B = _.RC4 = v.extend({
|
|
4302
4305
|
_doReset: function() {
|
|
4303
|
-
for (var n = this._key, E = n.words, a = n.sigBytes, s = this._S = [],
|
|
4304
|
-
s[
|
|
4305
|
-
for (var
|
|
4306
|
-
var
|
|
4307
|
-
p = (p + s[
|
|
4308
|
-
var i = s[
|
|
4309
|
-
s[
|
|
4306
|
+
for (var n = this._key, E = n.words, a = n.sigBytes, s = this._S = [], f = 0; f < 256; f++)
|
|
4307
|
+
s[f] = f;
|
|
4308
|
+
for (var f = 0, p = 0; f < 256; f++) {
|
|
4309
|
+
var h = f % a, D = E[h >>> 2] >>> 24 - h % 4 * 8 & 255;
|
|
4310
|
+
p = (p + s[f] + D) % 256;
|
|
4311
|
+
var i = s[f];
|
|
4312
|
+
s[f] = s[p], s[p] = i;
|
|
4310
4313
|
}
|
|
4311
4314
|
this._i = this._j = 0;
|
|
4312
4315
|
},
|
|
@@ -4317,10 +4320,10 @@ function $x() {
|
|
|
4317
4320
|
ivSize: 0
|
|
4318
4321
|
});
|
|
4319
4322
|
function C() {
|
|
4320
|
-
for (var n = this._S, E = this._i, a = this._j, s = 0,
|
|
4323
|
+
for (var n = this._S, E = this._i, a = this._j, s = 0, f = 0; f < 4; f++) {
|
|
4321
4324
|
E = (E + 1) % 256, a = (a + n[E]) % 256;
|
|
4322
4325
|
var p = n[E];
|
|
4323
|
-
n[E] = n[a], n[a] = p, s |= n[(n[E] + n[a]) % 256] << 24 -
|
|
4326
|
+
n[E] = n[a], n[a] = p, s |= n[(n[E] + n[a]) % 256] << 24 - f * 8;
|
|
4324
4327
|
}
|
|
4325
4328
|
return this._i = E, this._j = a, s;
|
|
4326
4329
|
}
|
|
@@ -4343,19 +4346,19 @@ function $x() {
|
|
|
4343
4346
|
e.RC4Drop = v._createHelper(x);
|
|
4344
4347
|
})(), t.RC4;
|
|
4345
4348
|
});
|
|
4346
|
-
})(
|
|
4349
|
+
})(sr)), sr.exports;
|
|
4347
4350
|
}
|
|
4348
|
-
var
|
|
4351
|
+
var cr = { exports: {} }, Rx = cr.exports, Fe;
|
|
4349
4352
|
function Px() {
|
|
4350
|
-
return Fe || (Fe = 1, (function(r,
|
|
4351
|
-
(function(t, e,
|
|
4353
|
+
return Fe || (Fe = 1, (function(r, d) {
|
|
4354
|
+
(function(t, e, u) {
|
|
4352
4355
|
r.exports = e(M(), c0(), f0(), o0(), X());
|
|
4353
4356
|
})(Rx, function(t) {
|
|
4354
4357
|
return (function() {
|
|
4355
|
-
var e = t,
|
|
4358
|
+
var e = t, u = e.lib, v = u.StreamCipher, _ = e.algo, B = [], C = [], x = [], n = _.Rabbit = v.extend({
|
|
4356
4359
|
_doReset: function() {
|
|
4357
|
-
for (var a = this._key.words, s = this.cfg.iv,
|
|
4358
|
-
a[
|
|
4360
|
+
for (var a = this._key.words, s = this.cfg.iv, f = 0; f < 4; f++)
|
|
4361
|
+
a[f] = (a[f] << 8 | a[f] >>> 24) & 16711935 | (a[f] << 24 | a[f] >>> 8) & 4278255360;
|
|
4359
4362
|
var p = this._X = [
|
|
4360
4363
|
a[0],
|
|
4361
4364
|
a[3] << 16 | a[2] >>> 16,
|
|
@@ -4365,7 +4368,7 @@ function Px() {
|
|
|
4365
4368
|
a[1] << 16 | a[0] >>> 16,
|
|
4366
4369
|
a[3],
|
|
4367
4370
|
a[2] << 16 | a[1] >>> 16
|
|
4368
|
-
],
|
|
4371
|
+
], h = this._C = [
|
|
4369
4372
|
a[2] << 16 | a[2] >>> 16,
|
|
4370
4373
|
a[0] & 4294901760 | a[1] & 65535,
|
|
4371
4374
|
a[3] << 16 | a[3] >>> 16,
|
|
@@ -4376,20 +4379,20 @@ function Px() {
|
|
|
4376
4379
|
a[3] & 4294901760 | a[0] & 65535
|
|
4377
4380
|
];
|
|
4378
4381
|
this._b = 0;
|
|
4379
|
-
for (var
|
|
4382
|
+
for (var f = 0; f < 4; f++)
|
|
4380
4383
|
E.call(this);
|
|
4381
|
-
for (var
|
|
4382
|
-
|
|
4384
|
+
for (var f = 0; f < 8; f++)
|
|
4385
|
+
h[f] ^= p[f + 4 & 7];
|
|
4383
4386
|
if (s) {
|
|
4384
|
-
var D = s.words, i = D[0], o = D[1],
|
|
4385
|
-
|
|
4386
|
-
for (var
|
|
4387
|
+
var D = s.words, i = D[0], o = D[1], l = (i << 8 | i >>> 24) & 16711935 | (i << 24 | i >>> 8) & 4278255360, b = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360, g = l >>> 16 | b & 4294901760, y = b << 16 | l & 65535;
|
|
4388
|
+
h[0] ^= l, h[1] ^= g, h[2] ^= b, h[3] ^= y, h[4] ^= l, h[5] ^= g, h[6] ^= b, h[7] ^= y;
|
|
4389
|
+
for (var f = 0; f < 4; f++)
|
|
4387
4390
|
E.call(this);
|
|
4388
4391
|
}
|
|
4389
4392
|
},
|
|
4390
4393
|
_doProcessBlock: function(a, s) {
|
|
4391
|
-
var
|
|
4392
|
-
E.call(this), B[0] =
|
|
4394
|
+
var f = this._X;
|
|
4395
|
+
E.call(this), B[0] = f[0] ^ f[5] >>> 16 ^ f[3] << 16, B[1] = f[2] ^ f[7] >>> 16 ^ f[5] << 16, B[2] = f[4] ^ f[1] >>> 16 ^ f[7] << 16, B[3] = f[6] ^ f[3] >>> 16 ^ f[1] << 16;
|
|
4393
4396
|
for (var p = 0; p < 4; p++)
|
|
4394
4397
|
B[p] = (B[p] << 8 | B[p] >>> 24) & 16711935 | (B[p] << 24 | B[p] >>> 8) & 4278255360, a[s + p] ^= B[p];
|
|
4395
4398
|
},
|
|
@@ -4397,30 +4400,30 @@ function Px() {
|
|
|
4397
4400
|
ivSize: 64 / 32
|
|
4398
4401
|
});
|
|
4399
4402
|
function E() {
|
|
4400
|
-
for (var a = this._X, s = this._C,
|
|
4401
|
-
C[
|
|
4403
|
+
for (var a = this._X, s = this._C, f = 0; f < 8; f++)
|
|
4404
|
+
C[f] = s[f];
|
|
4402
4405
|
s[0] = s[0] + 1295307597 + this._b | 0, s[1] = s[1] + 3545052371 + (s[0] >>> 0 < C[0] >>> 0 ? 1 : 0) | 0, s[2] = s[2] + 886263092 + (s[1] >>> 0 < C[1] >>> 0 ? 1 : 0) | 0, s[3] = s[3] + 1295307597 + (s[2] >>> 0 < C[2] >>> 0 ? 1 : 0) | 0, s[4] = s[4] + 3545052371 + (s[3] >>> 0 < C[3] >>> 0 ? 1 : 0) | 0, s[5] = s[5] + 886263092 + (s[4] >>> 0 < C[4] >>> 0 ? 1 : 0) | 0, s[6] = s[6] + 1295307597 + (s[5] >>> 0 < C[5] >>> 0 ? 1 : 0) | 0, s[7] = s[7] + 3545052371 + (s[6] >>> 0 < C[6] >>> 0 ? 1 : 0) | 0, this._b = s[7] >>> 0 < C[7] >>> 0 ? 1 : 0;
|
|
4403
|
-
for (var
|
|
4404
|
-
var p = a[
|
|
4405
|
-
x[
|
|
4406
|
+
for (var f = 0; f < 8; f++) {
|
|
4407
|
+
var p = a[f] + s[f], h = p & 65535, D = p >>> 16, i = ((h * h >>> 17) + h * D >>> 15) + D * D, o = ((p & 4294901760) * p | 0) + ((p & 65535) * p | 0);
|
|
4408
|
+
x[f] = i ^ o;
|
|
4406
4409
|
}
|
|
4407
4410
|
a[0] = x[0] + (x[7] << 16 | x[7] >>> 16) + (x[6] << 16 | x[6] >>> 16) | 0, a[1] = x[1] + (x[0] << 8 | x[0] >>> 24) + x[7] | 0, a[2] = x[2] + (x[1] << 16 | x[1] >>> 16) + (x[0] << 16 | x[0] >>> 16) | 0, a[3] = x[3] + (x[2] << 8 | x[2] >>> 24) + x[1] | 0, a[4] = x[4] + (x[3] << 16 | x[3] >>> 16) + (x[2] << 16 | x[2] >>> 16) | 0, a[5] = x[5] + (x[4] << 8 | x[4] >>> 24) + x[3] | 0, a[6] = x[6] + (x[5] << 16 | x[5] >>> 16) + (x[4] << 16 | x[4] >>> 16) | 0, a[7] = x[7] + (x[6] << 8 | x[6] >>> 24) + x[5] | 0;
|
|
4408
4411
|
}
|
|
4409
4412
|
e.Rabbit = v._createHelper(n);
|
|
4410
4413
|
})(), t.Rabbit;
|
|
4411
4414
|
});
|
|
4412
|
-
})(
|
|
4415
|
+
})(cr)), cr.exports;
|
|
4413
4416
|
}
|
|
4414
|
-
var
|
|
4415
|
-
function
|
|
4416
|
-
return ge || (ge = 1, (function(r,
|
|
4417
|
-
(function(t, e,
|
|
4417
|
+
var fr = { exports: {} }, zx = fr.exports, ge;
|
|
4418
|
+
function Wx() {
|
|
4419
|
+
return ge || (ge = 1, (function(r, d) {
|
|
4420
|
+
(function(t, e, u) {
|
|
4418
4421
|
r.exports = e(M(), c0(), f0(), o0(), X());
|
|
4419
4422
|
})(zx, function(t) {
|
|
4420
4423
|
return (function() {
|
|
4421
|
-
var e = t,
|
|
4424
|
+
var e = t, u = e.lib, v = u.StreamCipher, _ = e.algo, B = [], C = [], x = [], n = _.RabbitLegacy = v.extend({
|
|
4422
4425
|
_doReset: function() {
|
|
4423
|
-
var a = this._key.words, s = this.cfg.iv,
|
|
4426
|
+
var a = this._key.words, s = this.cfg.iv, f = this._X = [
|
|
4424
4427
|
a[0],
|
|
4425
4428
|
a[3] << 16 | a[2] >>> 16,
|
|
4426
4429
|
a[1],
|
|
@@ -4440,20 +4443,20 @@ function Ix() {
|
|
|
4440
4443
|
a[3] & 4294901760 | a[0] & 65535
|
|
4441
4444
|
];
|
|
4442
4445
|
this._b = 0;
|
|
4443
|
-
for (var
|
|
4446
|
+
for (var h = 0; h < 4; h++)
|
|
4444
4447
|
E.call(this);
|
|
4445
|
-
for (var
|
|
4446
|
-
p[
|
|
4448
|
+
for (var h = 0; h < 8; h++)
|
|
4449
|
+
p[h] ^= f[h + 4 & 7];
|
|
4447
4450
|
if (s) {
|
|
4448
|
-
var D = s.words, i = D[0], o = D[1],
|
|
4449
|
-
p[0] ^=
|
|
4450
|
-
for (var
|
|
4451
|
+
var D = s.words, i = D[0], o = D[1], l = (i << 8 | i >>> 24) & 16711935 | (i << 24 | i >>> 8) & 4278255360, b = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360, g = l >>> 16 | b & 4294901760, y = b << 16 | l & 65535;
|
|
4452
|
+
p[0] ^= l, p[1] ^= g, p[2] ^= b, p[3] ^= y, p[4] ^= l, p[5] ^= g, p[6] ^= b, p[7] ^= y;
|
|
4453
|
+
for (var h = 0; h < 4; h++)
|
|
4451
4454
|
E.call(this);
|
|
4452
4455
|
}
|
|
4453
4456
|
},
|
|
4454
4457
|
_doProcessBlock: function(a, s) {
|
|
4455
|
-
var
|
|
4456
|
-
E.call(this), B[0] =
|
|
4458
|
+
var f = this._X;
|
|
4459
|
+
E.call(this), B[0] = f[0] ^ f[5] >>> 16 ^ f[3] << 16, B[1] = f[2] ^ f[7] >>> 16 ^ f[5] << 16, B[2] = f[4] ^ f[1] >>> 16 ^ f[7] << 16, B[3] = f[6] ^ f[3] >>> 16 ^ f[1] << 16;
|
|
4457
4460
|
for (var p = 0; p < 4; p++)
|
|
4458
4461
|
B[p] = (B[p] << 8 | B[p] >>> 24) & 16711935 | (B[p] << 24 | B[p] >>> 8) & 4278255360, a[s + p] ^= B[p];
|
|
4459
4462
|
},
|
|
@@ -4461,28 +4464,28 @@ function Ix() {
|
|
|
4461
4464
|
ivSize: 64 / 32
|
|
4462
4465
|
});
|
|
4463
4466
|
function E() {
|
|
4464
|
-
for (var a = this._X, s = this._C,
|
|
4465
|
-
C[
|
|
4467
|
+
for (var a = this._X, s = this._C, f = 0; f < 8; f++)
|
|
4468
|
+
C[f] = s[f];
|
|
4466
4469
|
s[0] = s[0] + 1295307597 + this._b | 0, s[1] = s[1] + 3545052371 + (s[0] >>> 0 < C[0] >>> 0 ? 1 : 0) | 0, s[2] = s[2] + 886263092 + (s[1] >>> 0 < C[1] >>> 0 ? 1 : 0) | 0, s[3] = s[3] + 1295307597 + (s[2] >>> 0 < C[2] >>> 0 ? 1 : 0) | 0, s[4] = s[4] + 3545052371 + (s[3] >>> 0 < C[3] >>> 0 ? 1 : 0) | 0, s[5] = s[5] + 886263092 + (s[4] >>> 0 < C[4] >>> 0 ? 1 : 0) | 0, s[6] = s[6] + 1295307597 + (s[5] >>> 0 < C[5] >>> 0 ? 1 : 0) | 0, s[7] = s[7] + 3545052371 + (s[6] >>> 0 < C[6] >>> 0 ? 1 : 0) | 0, this._b = s[7] >>> 0 < C[7] >>> 0 ? 1 : 0;
|
|
4467
|
-
for (var
|
|
4468
|
-
var p = a[
|
|
4469
|
-
x[
|
|
4470
|
+
for (var f = 0; f < 8; f++) {
|
|
4471
|
+
var p = a[f] + s[f], h = p & 65535, D = p >>> 16, i = ((h * h >>> 17) + h * D >>> 15) + D * D, o = ((p & 4294901760) * p | 0) + ((p & 65535) * p | 0);
|
|
4472
|
+
x[f] = i ^ o;
|
|
4470
4473
|
}
|
|
4471
4474
|
a[0] = x[0] + (x[7] << 16 | x[7] >>> 16) + (x[6] << 16 | x[6] >>> 16) | 0, a[1] = x[1] + (x[0] << 8 | x[0] >>> 24) + x[7] | 0, a[2] = x[2] + (x[1] << 16 | x[1] >>> 16) + (x[0] << 16 | x[0] >>> 16) | 0, a[3] = x[3] + (x[2] << 8 | x[2] >>> 24) + x[1] | 0, a[4] = x[4] + (x[3] << 16 | x[3] >>> 16) + (x[2] << 16 | x[2] >>> 16) | 0, a[5] = x[5] + (x[4] << 8 | x[4] >>> 24) + x[3] | 0, a[6] = x[6] + (x[5] << 16 | x[5] >>> 16) + (x[4] << 16 | x[4] >>> 16) | 0, a[7] = x[7] + (x[6] << 8 | x[6] >>> 24) + x[5] | 0;
|
|
4472
4475
|
}
|
|
4473
4476
|
e.RabbitLegacy = v._createHelper(n);
|
|
4474
4477
|
})(), t.RabbitLegacy;
|
|
4475
4478
|
});
|
|
4476
|
-
})(
|
|
4479
|
+
})(fr)), fr.exports;
|
|
4477
4480
|
}
|
|
4478
|
-
var
|
|
4481
|
+
var ur = { exports: {} }, Ix = ur.exports, De;
|
|
4479
4482
|
function Lx() {
|
|
4480
|
-
return De || (De = 1, (function(r,
|
|
4481
|
-
(function(t, e,
|
|
4483
|
+
return De || (De = 1, (function(r, d) {
|
|
4484
|
+
(function(t, e, u) {
|
|
4482
4485
|
r.exports = e(M(), c0(), f0(), o0(), X());
|
|
4483
|
-
})(
|
|
4486
|
+
})(Ix, function(t) {
|
|
4484
4487
|
return (function() {
|
|
4485
|
-
var e = t,
|
|
4488
|
+
var e = t, u = e.lib, v = u.BlockCipher, _ = e.algo;
|
|
4486
4489
|
const B = 16, C = [
|
|
4487
4490
|
608135816,
|
|
4488
4491
|
2242054355,
|
|
@@ -5540,53 +5543,53 @@ function Lx() {
|
|
|
5540
5543
|
pbox: [],
|
|
5541
5544
|
sbox: []
|
|
5542
5545
|
};
|
|
5543
|
-
function E(
|
|
5544
|
-
let i = D >> 24 & 255, o = D >> 16 & 255,
|
|
5545
|
-
return g = g ^
|
|
5546
|
+
function E(h, D) {
|
|
5547
|
+
let i = D >> 24 & 255, o = D >> 16 & 255, l = D >> 8 & 255, b = D & 255, g = h.sbox[0][i] + h.sbox[1][o];
|
|
5548
|
+
return g = g ^ h.sbox[2][l], g = g + h.sbox[3][b], g;
|
|
5546
5549
|
}
|
|
5547
|
-
function a(
|
|
5548
|
-
let o = D,
|
|
5550
|
+
function a(h, D, i) {
|
|
5551
|
+
let o = D, l = i, b;
|
|
5549
5552
|
for (let g = 0; g < B; ++g)
|
|
5550
|
-
o = o ^
|
|
5551
|
-
return b = o, o =
|
|
5553
|
+
o = o ^ h.pbox[g], l = E(h, o) ^ l, b = o, o = l, l = b;
|
|
5554
|
+
return b = o, o = l, l = b, l = l ^ h.pbox[B], o = o ^ h.pbox[B + 1], { left: o, right: l };
|
|
5552
5555
|
}
|
|
5553
|
-
function s(
|
|
5554
|
-
let o = D,
|
|
5556
|
+
function s(h, D, i) {
|
|
5557
|
+
let o = D, l = i, b;
|
|
5555
5558
|
for (let g = B + 1; g > 1; --g)
|
|
5556
|
-
o = o ^
|
|
5557
|
-
return b = o, o =
|
|
5559
|
+
o = o ^ h.pbox[g], l = E(h, o) ^ l, b = o, o = l, l = b;
|
|
5560
|
+
return b = o, o = l, l = b, l = l ^ h.pbox[1], o = o ^ h.pbox[0], { left: o, right: l };
|
|
5558
5561
|
}
|
|
5559
|
-
function
|
|
5562
|
+
function f(h, D, i) {
|
|
5560
5563
|
for (let y = 0; y < 4; y++) {
|
|
5561
|
-
|
|
5564
|
+
h.sbox[y] = [];
|
|
5562
5565
|
for (let k = 0; k < 256; k++)
|
|
5563
|
-
|
|
5566
|
+
h.sbox[y][k] = x[y][k];
|
|
5564
5567
|
}
|
|
5565
5568
|
let o = 0;
|
|
5566
5569
|
for (let y = 0; y < B + 2; y++)
|
|
5567
|
-
|
|
5568
|
-
let
|
|
5570
|
+
h.pbox[y] = C[y] ^ D[o], o++, o >= i && (o = 0);
|
|
5571
|
+
let l = 0, b = 0, g = 0;
|
|
5569
5572
|
for (let y = 0; y < B + 2; y += 2)
|
|
5570
|
-
g = a(
|
|
5573
|
+
g = a(h, l, b), l = g.left, b = g.right, h.pbox[y] = l, h.pbox[y + 1] = b;
|
|
5571
5574
|
for (let y = 0; y < 4; y++)
|
|
5572
5575
|
for (let k = 0; k < 256; k += 2)
|
|
5573
|
-
g = a(
|
|
5576
|
+
g = a(h, l, b), l = g.left, b = g.right, h.sbox[y][k] = l, h.sbox[y][k + 1] = b;
|
|
5574
5577
|
return !0;
|
|
5575
5578
|
}
|
|
5576
5579
|
var p = _.Blowfish = v.extend({
|
|
5577
5580
|
_doReset: function() {
|
|
5578
5581
|
if (this._keyPriorReset !== this._key) {
|
|
5579
|
-
var
|
|
5580
|
-
|
|
5582
|
+
var h = this._keyPriorReset = this._key, D = h.words, i = h.sigBytes / 4;
|
|
5583
|
+
f(n, D, i);
|
|
5581
5584
|
}
|
|
5582
5585
|
},
|
|
5583
|
-
encryptBlock: function(
|
|
5584
|
-
var i = a(n,
|
|
5585
|
-
|
|
5586
|
+
encryptBlock: function(h, D) {
|
|
5587
|
+
var i = a(n, h[D], h[D + 1]);
|
|
5588
|
+
h[D] = i.left, h[D + 1] = i.right;
|
|
5586
5589
|
},
|
|
5587
|
-
decryptBlock: function(
|
|
5588
|
-
var i = s(n,
|
|
5589
|
-
|
|
5590
|
+
decryptBlock: function(h, D) {
|
|
5591
|
+
var i = s(n, h[D], h[D + 1]);
|
|
5592
|
+
h[D] = i.left, h[D + 1] = i.right;
|
|
5590
5593
|
},
|
|
5591
5594
|
blockSize: 64 / 32,
|
|
5592
5595
|
keySize: 128 / 32,
|
|
@@ -5595,38 +5598,38 @@ function Lx() {
|
|
|
5595
5598
|
e.Blowfish = v._createHelper(p);
|
|
5596
5599
|
})(), t.Blowfish;
|
|
5597
5600
|
});
|
|
5598
|
-
})(
|
|
5601
|
+
})(ur)), ur.exports;
|
|
5599
5602
|
}
|
|
5600
|
-
var Ox =
|
|
5603
|
+
var Ox = S0.exports, be;
|
|
5601
5604
|
function qx() {
|
|
5602
|
-
return be || (be = 1, (function(r,
|
|
5603
|
-
(function(t, e,
|
|
5604
|
-
r.exports = e(M(), vr(),
|
|
5605
|
+
return be || (be = 1, (function(r, d) {
|
|
5606
|
+
(function(t, e, u) {
|
|
5607
|
+
r.exports = e(M(), vr(), Wt(), Lt(), c0(), Tt(), f0(), Pe(), mr(), Gt(), ze(), Zt(), Qt(), Jt(), _r(), tx(), o0(), X(), ox(), sx(), fx(), dx(), hx(), px(), Cx(), Ax(), gx(), bx(), _x(), wx(), Sx(), $x(), Px(), Wx(), Lx());
|
|
5605
5608
|
})(Ox, function(t) {
|
|
5606
5609
|
return t;
|
|
5607
5610
|
});
|
|
5608
|
-
})(
|
|
5611
|
+
})(S0)), S0.exports;
|
|
5609
5612
|
}
|
|
5610
5613
|
qx();
|
|
5611
|
-
let
|
|
5614
|
+
let We = null, Ie = null, Le = null, Oe = null;
|
|
5612
5615
|
Math.random().toString(36).substring(7);
|
|
5613
5616
|
function Tx(r) {
|
|
5614
|
-
|
|
5617
|
+
We = r.token, Ie = r.apiUrl, Le = r.deviceId, Oe = r.domain;
|
|
5615
5618
|
}
|
|
5616
5619
|
function Mx() {
|
|
5617
5620
|
return {
|
|
5618
|
-
token:
|
|
5619
|
-
apiUrl:
|
|
5621
|
+
token: We,
|
|
5622
|
+
apiUrl: Ie,
|
|
5620
5623
|
deviceId: Le,
|
|
5621
5624
|
domain: Oe
|
|
5622
5625
|
};
|
|
5623
5626
|
}
|
|
5624
5627
|
function Nx(r) {
|
|
5625
|
-
return `/sdk-workers/${(r.split("/").pop() || r).replace(/\.ts$/, ".js")}?v=1.1.
|
|
5628
|
+
return `/sdk-workers/${(r.split("/").pop() || r).replace(/\.ts$/, ".js")}?v=1.1.174`;
|
|
5626
5629
|
}
|
|
5627
|
-
function Ux(r,
|
|
5630
|
+
function Ux(r, d) {
|
|
5628
5631
|
const t = Nx(r);
|
|
5629
|
-
return new Worker(t, { type: "module", ...
|
|
5632
|
+
return new Worker(t, { type: "module", ...d });
|
|
5630
5633
|
}
|
|
5631
5634
|
const yr = () => {
|
|
5632
5635
|
try {
|
|
@@ -5634,23 +5637,23 @@ const yr = () => {
|
|
|
5634
5637
|
} catch {
|
|
5635
5638
|
}
|
|
5636
5639
|
return !1;
|
|
5637
|
-
},
|
|
5640
|
+
}, y0 = (...r) => {
|
|
5638
5641
|
yr();
|
|
5639
5642
|
}, me = (...r) => {
|
|
5640
5643
|
yr();
|
|
5641
5644
|
}, _e = /* @__PURE__ */ new Map(), gr = /* @__PURE__ */ new Map();
|
|
5642
5645
|
let jx = 0;
|
|
5643
5646
|
function Gx(r) {
|
|
5644
|
-
const
|
|
5645
|
-
if (
|
|
5647
|
+
const d = _e.get(r);
|
|
5648
|
+
if (d) return d;
|
|
5646
5649
|
const t = Ux("./deform.worker.ts");
|
|
5647
5650
|
try {
|
|
5648
5651
|
t.postMessage({ type: "SET_DEBUG", debugRender: yr() });
|
|
5649
5652
|
} catch {
|
|
5650
5653
|
}
|
|
5651
|
-
t.onmessage = (
|
|
5652
|
-
const { id: v, imageBitmap: _, error: B, duration: C } =
|
|
5653
|
-
|
|
5654
|
+
t.onmessage = (u) => {
|
|
5655
|
+
const { id: v, imageBitmap: _, error: B, duration: C } = u.data ?? {}, x = C ? ` worker耗时=${Math.round(C)}ms` : "";
|
|
5656
|
+
y0(`[renderService] deform worker 响应 id=${v}${x}`, {
|
|
5654
5657
|
hasImageBitmap: !!_,
|
|
5655
5658
|
width: _?.width,
|
|
5656
5659
|
height: _?.height,
|
|
@@ -5664,24 +5667,24 @@ function Gx(r) {
|
|
|
5664
5667
|
}
|
|
5665
5668
|
n.resolve(_);
|
|
5666
5669
|
}
|
|
5667
|
-
}, t.onerror = (
|
|
5670
|
+
}, t.onerror = (u) => {
|
|
5668
5671
|
};
|
|
5669
5672
|
const e = () => {
|
|
5670
|
-
const
|
|
5671
|
-
return
|
|
5672
|
-
hasToken: !!
|
|
5673
|
-
tokenPreview:
|
|
5673
|
+
const u = Mx();
|
|
5674
|
+
return y0("🔍 [workerManager] 检查 License Token:", {
|
|
5675
|
+
hasToken: !!u.token,
|
|
5676
|
+
tokenPreview: u.token ? u.token.substring(0, 20) + "..." : "undefined",
|
|
5674
5677
|
faceId: r,
|
|
5675
5678
|
source: "licenseStore模块"
|
|
5676
|
-
}),
|
|
5679
|
+
}), u.token ? (y0("📤 [workerManager] 发送 License 到新创建的 Worker", { faceId: r }), t.postMessage({
|
|
5677
5680
|
type: "SET_LICENSE",
|
|
5678
|
-
licenseToken:
|
|
5679
|
-
licenseApiUrl:
|
|
5680
|
-
deviceId:
|
|
5681
|
-
domain:
|
|
5681
|
+
licenseToken: u.token,
|
|
5682
|
+
licenseApiUrl: u.apiUrl,
|
|
5683
|
+
deviceId: u.deviceId,
|
|
5684
|
+
domain: u.domain
|
|
5682
5685
|
}), !0) : !1;
|
|
5683
5686
|
};
|
|
5684
|
-
return e() || (
|
|
5687
|
+
return e() || (y0("⏳ [workerManager] License Token 未设置,等待后重试...", { faceId: r }), setTimeout(() => {
|
|
5685
5688
|
e() || me("⚠️ [workerManager] 等待后 License Token 仍未设置", { faceId: r });
|
|
5686
5689
|
}, 200), setTimeout(() => {
|
|
5687
5690
|
e() || me("⚠️ [workerManager] 第二次等待后 License Token 仍未设置", { faceId: r });
|
|
@@ -5693,10 +5696,10 @@ function Kx(r) {
|
|
|
5693
5696
|
type: r.type,
|
|
5694
5697
|
blendMode: r.blendMode,
|
|
5695
5698
|
transform: Array.isArray(r.transform) ? [...r.transform] : [],
|
|
5696
|
-
meshPoints: Array.isArray(r.meshPoints) ? r.meshPoints.map((
|
|
5697
|
-
x:
|
|
5698
|
-
y:
|
|
5699
|
-
type:
|
|
5699
|
+
meshPoints: Array.isArray(r.meshPoints) ? r.meshPoints.map((d) => ({
|
|
5700
|
+
x: d.x,
|
|
5701
|
+
y: d.y,
|
|
5702
|
+
type: d.type
|
|
5700
5703
|
})) : [],
|
|
5701
5704
|
bounds: r.bounds ? {
|
|
5702
5705
|
width: r.bounds.width,
|
|
@@ -5719,30 +5722,30 @@ function Kx(r) {
|
|
|
5719
5722
|
layerOrder: r.layerOrder,
|
|
5720
5723
|
imagePath: r.imagePath,
|
|
5721
5724
|
vectorMask: r.vectorMask ? {
|
|
5722
|
-
paths: r.vectorMask.paths?.map((
|
|
5723
|
-
open:
|
|
5724
|
-
knots:
|
|
5725
|
+
paths: r.vectorMask.paths?.map((d) => ({
|
|
5726
|
+
open: d.open,
|
|
5727
|
+
knots: d.knots?.map((t) => ({
|
|
5725
5728
|
linked: t.linked,
|
|
5726
5729
|
points: [...t.points]
|
|
5727
5730
|
})),
|
|
5728
|
-
fillRule:
|
|
5729
|
-
operation:
|
|
5731
|
+
fillRule: d.fillRule,
|
|
5732
|
+
operation: d.operation
|
|
5730
5733
|
})),
|
|
5731
|
-
points: r.vectorMask.points?.map((
|
|
5732
|
-
x:
|
|
5733
|
-
y:
|
|
5734
|
-
type:
|
|
5734
|
+
points: r.vectorMask.points?.map((d) => ({
|
|
5735
|
+
x: d.x,
|
|
5736
|
+
y: d.y,
|
|
5737
|
+
type: d.type
|
|
5735
5738
|
})),
|
|
5736
5739
|
invert: r.vectorMask.invert,
|
|
5737
5740
|
notLink: r.vectorMask.notLink,
|
|
5738
5741
|
disable: r.vectorMask.disable,
|
|
5739
5742
|
fillStartsWithAllPixels: r.vectorMask.fillStartsWithAllPixels
|
|
5740
5743
|
} : void 0,
|
|
5741
|
-
filterList: r.filterList ? r.filterList.map((
|
|
5742
|
-
type:
|
|
5743
|
-
enabled:
|
|
5744
|
-
filter:
|
|
5745
|
-
puppetShapeList:
|
|
5744
|
+
filterList: r.filterList ? r.filterList.map((d) => ({
|
|
5745
|
+
type: d.type,
|
|
5746
|
+
enabled: d.enabled,
|
|
5747
|
+
filter: d.filter ? {
|
|
5748
|
+
puppetShapeList: d.filter.puppetShapeList?.map((t) => ({
|
|
5746
5749
|
originalVertexArray: t.originalVertexArray.map((e) => ({
|
|
5747
5750
|
x: e.x,
|
|
5748
5751
|
y: e.y
|
|
@@ -5759,33 +5762,33 @@ function Kx(r) {
|
|
|
5759
5762
|
clipping: r.clipping
|
|
5760
5763
|
};
|
|
5761
5764
|
}
|
|
5762
|
-
function Xx(r,
|
|
5763
|
-
const
|
|
5765
|
+
function Xx(r, d, t, e) {
|
|
5766
|
+
const u = ++jx, v = Gx(t);
|
|
5764
5767
|
return performance.now(), (/* @__PURE__ */ new Date()).toISOString(), new Promise((_, B) => {
|
|
5765
|
-
gr.set(
|
|
5768
|
+
gr.set(u, {
|
|
5766
5769
|
resolve: (x) => {
|
|
5767
5770
|
performance.now(), (/* @__PURE__ */ new Date()).toISOString(), _(x);
|
|
5768
5771
|
},
|
|
5769
5772
|
reject: B
|
|
5770
5773
|
});
|
|
5771
|
-
const C = Kx(
|
|
5772
|
-
v.postMessage({ id:
|
|
5774
|
+
const C = Kx(d);
|
|
5775
|
+
v.postMessage({ id: u, designBitmap: r, layerData: C, canvasSize: e }, [
|
|
5773
5776
|
r
|
|
5774
5777
|
]);
|
|
5775
5778
|
});
|
|
5776
5779
|
}
|
|
5777
|
-
async function
|
|
5778
|
-
const _ = await _t(r,
|
|
5780
|
+
async function Zx(r, d, t = 0, e, u, v) {
|
|
5781
|
+
const _ = await _t(r, u, v);
|
|
5779
5782
|
if (!_ || _.width === 0 || _.height === 0)
|
|
5780
5783
|
throw new Error("图片无效:尺寸为 0");
|
|
5781
|
-
return await Xx(_,
|
|
5784
|
+
return await Xx(_, d, t, e);
|
|
5782
5785
|
}
|
|
5783
|
-
function h0(r,
|
|
5786
|
+
function h0(r, d) {
|
|
5784
5787
|
if (typeof OffscreenCanvas < "u" && typeof document > "u")
|
|
5785
|
-
return new OffscreenCanvas(r,
|
|
5788
|
+
return new OffscreenCanvas(r, d);
|
|
5786
5789
|
if (typeof document < "u") {
|
|
5787
5790
|
const t = document.createElement("canvas");
|
|
5788
|
-
return t.width = r, t.height =
|
|
5791
|
+
return t.width = r, t.height = d, t;
|
|
5789
5792
|
} else
|
|
5790
5793
|
throw new Error("无法创建 canvas:不在 Worker 或主线程环境中");
|
|
5791
5794
|
}
|
|
@@ -5793,21 +5796,21 @@ function g0(r) {
|
|
|
5793
5796
|
return r.getContext("2d");
|
|
5794
5797
|
}
|
|
5795
5798
|
function ye(r) {
|
|
5796
|
-
const
|
|
5797
|
-
if (!
|
|
5799
|
+
const d = g0(r);
|
|
5800
|
+
if (!d)
|
|
5798
5801
|
throw new Error("无法创建 canvas context");
|
|
5799
|
-
return
|
|
5802
|
+
return d;
|
|
5800
5803
|
}
|
|
5801
|
-
async function
|
|
5802
|
-
const
|
|
5804
|
+
async function Yx(r) {
|
|
5805
|
+
const d = performance.now(), t = () => {
|
|
5803
5806
|
try {
|
|
5804
5807
|
if (globalThis.__DEBUG_RENDER__ === !0 || typeof localStorage < "u" && localStorage.getItem("DEBUG_RENDER") === "1") return !0;
|
|
5805
5808
|
} catch {
|
|
5806
5809
|
}
|
|
5807
5810
|
return !1;
|
|
5808
|
-
}, e = (...
|
|
5811
|
+
}, e = (...c) => {
|
|
5809
5812
|
t();
|
|
5810
|
-
},
|
|
5813
|
+
}, u = (...c) => {
|
|
5811
5814
|
t();
|
|
5812
5815
|
}, {
|
|
5813
5816
|
psdJson: v,
|
|
@@ -5819,13 +5822,13 @@ async function Zx(r) {
|
|
|
5819
5822
|
} = r, E = r.maxImageSize;
|
|
5820
5823
|
e("[renderByJson] 接收到的数据:", {
|
|
5821
5824
|
psdJsonLayerCount: v.layerList?.length || 0,
|
|
5822
|
-
psdJsonLayers: v.layerList?.map((
|
|
5823
|
-
name:
|
|
5824
|
-
type:
|
|
5825
|
-
id:
|
|
5826
|
-
hasChildren: !!
|
|
5827
|
-
childrenCount:
|
|
5828
|
-
children:
|
|
5825
|
+
psdJsonLayers: v.layerList?.map((c) => ({
|
|
5826
|
+
name: c.name,
|
|
5827
|
+
type: c.type,
|
|
5828
|
+
id: c.id,
|
|
5829
|
+
hasChildren: !!c.children,
|
|
5830
|
+
childrenCount: c.children?.length || 0,
|
|
5831
|
+
children: c.children?.map((A) => ({
|
|
5829
5832
|
name: A.name,
|
|
5830
5833
|
type: A.type,
|
|
5831
5834
|
isSmartObject: A.isSmartObject,
|
|
@@ -5833,103 +5836,103 @@ async function Zx(r) {
|
|
|
5833
5836
|
}))
|
|
5834
5837
|
})),
|
|
5835
5838
|
fabricScreenshotListCount: B.length,
|
|
5836
|
-
fabricScreenshotList: B.map((
|
|
5839
|
+
fabricScreenshotList: B.map((c) => ({ id: c.id, url: c.url.substring(0, 50) + "..." }))
|
|
5837
5840
|
});
|
|
5838
|
-
const a = (
|
|
5839
|
-
if (!
|
|
5840
|
-
if (/^(https?:)?\/\//i.test(
|
|
5841
|
-
return
|
|
5841
|
+
const a = (c) => {
|
|
5842
|
+
if (!c || typeof c != "string" || !c.includes("http")) return;
|
|
5843
|
+
if (/^(https?:)?\/\//i.test(c) || c.startsWith("data:") || c.startsWith("blob:"))
|
|
5844
|
+
return c;
|
|
5842
5845
|
if (!n)
|
|
5843
|
-
return !
|
|
5846
|
+
return !c.includes("http") && !c.startsWith("data:") && !c.startsWith("blob:") ? void 0 : c;
|
|
5844
5847
|
try {
|
|
5845
|
-
const m = new URL(
|
|
5848
|
+
const m = new URL(c, n).toString();
|
|
5846
5849
|
return !m.includes("http") && !m.startsWith("data:") && !m.startsWith("blob:") ? void 0 : m;
|
|
5847
5850
|
} catch (m) {
|
|
5848
|
-
|
|
5851
|
+
u(`[renderByJson] 解析图片 URL 失败: ${c}`, m);
|
|
5849
5852
|
return;
|
|
5850
5853
|
}
|
|
5851
|
-
}, s = {},
|
|
5852
|
-
for (const
|
|
5853
|
-
const A =
|
|
5854
|
+
}, s = {}, f = /* @__PURE__ */ new Map();
|
|
5855
|
+
for (const c of _) {
|
|
5856
|
+
const A = c.sourceName || c.layerName;
|
|
5854
5857
|
A && (s[A] = {
|
|
5855
|
-
url:
|
|
5856
|
-
},
|
|
5857
|
-
url:
|
|
5858
|
-
}),
|
|
5858
|
+
url: c.url
|
|
5859
|
+
}, f.set(A, c.url)), c.layerName && c.layerName !== A && (s[c.layerName] || (s[c.layerName] = {
|
|
5860
|
+
url: c.url
|
|
5861
|
+
}), f.set(c.layerName, c.url));
|
|
5859
5862
|
}
|
|
5860
5863
|
const p = /* @__PURE__ */ new Map();
|
|
5861
|
-
for (const
|
|
5862
|
-
p.set(
|
|
5863
|
-
e("[renderByJson] fabricScreenshotMap:", Array.from(p.entries())), e("[renderByJson] psdJson.layerList 结构:", v.layerList?.map((
|
|
5864
|
-
name:
|
|
5865
|
-
type:
|
|
5866
|
-
id:
|
|
5867
|
-
hasChildren: !!
|
|
5868
|
-
childrenCount:
|
|
5864
|
+
for (const c of B)
|
|
5865
|
+
p.set(c.id, c.url);
|
|
5866
|
+
e("[renderByJson] fabricScreenshotMap:", Array.from(p.entries())), e("[renderByJson] psdJson.layerList 结构:", v.layerList?.map((c) => ({
|
|
5867
|
+
name: c.name,
|
|
5868
|
+
type: c.type,
|
|
5869
|
+
id: c.id,
|
|
5870
|
+
hasChildren: !!c.children,
|
|
5871
|
+
childrenCount: c.children?.length || 0
|
|
5869
5872
|
})));
|
|
5870
|
-
function
|
|
5871
|
-
const m =
|
|
5872
|
-
if (
|
|
5873
|
-
if (
|
|
5874
|
-
const
|
|
5873
|
+
function h(c, A) {
|
|
5874
|
+
const m = c.color || (c.name && ["粉", "白", "绿", "红", "蓝", "黄", "黑", "灰"].includes(c.name) ? c.name : A);
|
|
5875
|
+
if (c.type === "Layer") {
|
|
5876
|
+
if (c.imagePath) {
|
|
5877
|
+
const W = _.find((P) => {
|
|
5875
5878
|
const L = P.sourceName || P.layerName;
|
|
5876
|
-
return !L || !
|
|
5879
|
+
return !L || !c.imagePath ? !1 : L === c.imagePath || L.endsWith(c.imagePath) || c.imagePath.endsWith(L);
|
|
5877
5880
|
});
|
|
5878
|
-
|
|
5879
|
-
url:
|
|
5881
|
+
W && (s[c.imagePath] = {
|
|
5882
|
+
url: W.url
|
|
5880
5883
|
});
|
|
5881
5884
|
}
|
|
5882
|
-
if (
|
|
5885
|
+
if (c.name) {
|
|
5883
5886
|
if (m) {
|
|
5884
|
-
const
|
|
5885
|
-
const
|
|
5886
|
-
return
|
|
5887
|
+
const W = `${m}-${c.name}`, P = _.find((L) => {
|
|
5888
|
+
const I = L.sourceName || L.layerName;
|
|
5889
|
+
return I ? (I.split("/").pop() || I).replace(/\.(png|jpg|jpeg|gif|webp)$/i, "").startsWith(`${m}-${c.name}`) : !1;
|
|
5887
5890
|
});
|
|
5888
|
-
P && (s[
|
|
5891
|
+
P && (s[W] = {
|
|
5889
5892
|
url: P.url
|
|
5890
5893
|
});
|
|
5891
5894
|
}
|
|
5892
|
-
if (
|
|
5893
|
-
const
|
|
5894
|
-
const
|
|
5895
|
-
return
|
|
5895
|
+
if (c.imagePath && c.name) {
|
|
5896
|
+
const W = c.imagePath.split("/").pop() || c.imagePath, P = _.find((L) => {
|
|
5897
|
+
const I = L.sourceName || L.layerName;
|
|
5898
|
+
return I ? (I.split("/").pop() || I) === W : !1;
|
|
5896
5899
|
});
|
|
5897
|
-
P && (s[
|
|
5900
|
+
P && (s[c.imagePath] = {
|
|
5898
5901
|
url: P.url
|
|
5899
5902
|
});
|
|
5900
5903
|
}
|
|
5901
5904
|
}
|
|
5902
5905
|
}
|
|
5903
|
-
if (
|
|
5904
|
-
for (const
|
|
5905
|
-
|
|
5906
|
+
if (c.children)
|
|
5907
|
+
for (const W of c.children)
|
|
5908
|
+
W && h(W, m);
|
|
5906
5909
|
}
|
|
5907
|
-
function D(
|
|
5908
|
-
const m =
|
|
5909
|
-
if (
|
|
5910
|
-
if (e(`[renderByJson] processLayer 检查 Group: name="${
|
|
5911
|
-
const
|
|
5912
|
-
if (e(`[renderByJson] ✅ 找到匹配的 fabricScreenshot: Group id=${m}, name="${
|
|
5913
|
-
e(`[renderByJson] Group "${
|
|
5914
|
-
for (const P of
|
|
5910
|
+
function D(c, A) {
|
|
5911
|
+
const m = c.id ?? A;
|
|
5912
|
+
if (c.type === "Group" && m)
|
|
5913
|
+
if (e(`[renderByJson] processLayer 检查 Group: name="${c.name}", id=${m}, hasFabricScreenshot=${p.has(m)}`), p.has(m)) {
|
|
5914
|
+
const W = p.get(m);
|
|
5915
|
+
if (e(`[renderByJson] ✅ 找到匹配的 fabricScreenshot: Group id=${m}, name="${c.name}", url=${W.substring(0, 50)}...`), c.children) {
|
|
5916
|
+
e(`[renderByJson] Group "${c.name}" 有 ${c.children.length} 个子图层`);
|
|
5917
|
+
for (const P of c.children)
|
|
5915
5918
|
if (P && P.isSmartObject === !0) {
|
|
5916
5919
|
const L = P?.name || "";
|
|
5917
|
-
e(`[renderByJson] 找到智能对象: name="${L}"`), L && !s[L] && (s[L] = {}), L ? (s[L].designImage =
|
|
5920
|
+
e(`[renderByJson] 找到智能对象: name="${L}"`), L && !s[L] && (s[L] = {}), L ? (s[L].designImage = W, e(`[renderByJson] ✅ 为智能对象 "${L}" 设置 designImage: ${W.substring(0, 50)}...`)) : u("[renderByJson] ⚠️ 智能对象没有 name,无法设置 designImage");
|
|
5918
5921
|
}
|
|
5919
5922
|
} else
|
|
5920
|
-
|
|
5923
|
+
u(`[renderByJson] ⚠️ Group id=${m} 没有 children`);
|
|
5921
5924
|
} else
|
|
5922
|
-
e(`[renderByJson] ⚠️ Group id=${m}, name="${
|
|
5923
|
-
if (
|
|
5924
|
-
for (const
|
|
5925
|
-
|
|
5925
|
+
e(`[renderByJson] ⚠️ Group id=${m}, name="${c.name}" 没有匹配的 fabricScreenshot`);
|
|
5926
|
+
if (c.children)
|
|
5927
|
+
for (const W of c.children)
|
|
5928
|
+
W && D(W, m);
|
|
5926
5929
|
}
|
|
5927
5930
|
if (v.layerList)
|
|
5928
|
-
for (const
|
|
5929
|
-
|
|
5931
|
+
for (const c of v.layerList)
|
|
5932
|
+
c && h(c);
|
|
5930
5933
|
if (v.layerList)
|
|
5931
|
-
for (const
|
|
5932
|
-
|
|
5934
|
+
for (const c of v.layerList)
|
|
5935
|
+
c && D(c);
|
|
5933
5936
|
const o = nt([{
|
|
5934
5937
|
psdJson: v,
|
|
5935
5938
|
layerExtrasByName: s
|
|
@@ -5939,41 +5942,41 @@ async function Zx(r) {
|
|
|
5939
5942
|
});
|
|
5940
5943
|
if (!o.models || o.models.length === 0)
|
|
5941
5944
|
throw new Error("无法解析 JSON 数据");
|
|
5942
|
-
const
|
|
5943
|
-
if (!
|
|
5945
|
+
const l = o.models[0];
|
|
5946
|
+
if (!l.psdPartData)
|
|
5944
5947
|
throw new Error("JSON 数据中没有 psdPartData");
|
|
5945
|
-
const b =
|
|
5946
|
-
if (
|
|
5947
|
-
return s[
|
|
5948
|
-
if (
|
|
5949
|
-
const A =
|
|
5948
|
+
const b = l.width, g = l.height, y = h0(b, g), k = ye(y), R = [], F = (c) => {
|
|
5949
|
+
if (c.url && s[c.url])
|
|
5950
|
+
return s[c.url];
|
|
5951
|
+
if (c.url) {
|
|
5952
|
+
const A = c.url.split("/").pop() || c.url;
|
|
5950
5953
|
if (s[A])
|
|
5951
5954
|
return s[A];
|
|
5952
|
-
const m = _.find((
|
|
5953
|
-
const P =
|
|
5954
|
-
return !P || !
|
|
5955
|
+
const m = _.find((W) => {
|
|
5956
|
+
const P = W.sourceName || W.layerName;
|
|
5957
|
+
return !P || !c.url ? !1 : (P.split("/").pop() || P) === A || P === c.url || P.endsWith(c.url) || c.url.endsWith(P);
|
|
5955
5958
|
});
|
|
5956
5959
|
if (m) {
|
|
5957
|
-
const
|
|
5958
|
-
if (
|
|
5959
|
-
return s[
|
|
5960
|
+
const W = m.sourceName || m.layerName;
|
|
5961
|
+
if (W)
|
|
5962
|
+
return s[W] || { url: m.url };
|
|
5960
5963
|
}
|
|
5961
5964
|
}
|
|
5962
5965
|
};
|
|
5963
|
-
for (let
|
|
5964
|
-
const A =
|
|
5966
|
+
for (let c = 0; c < l.psdPartData.length; c++) {
|
|
5967
|
+
const A = l.psdPartData[c], m = F(A);
|
|
5965
5968
|
if (A.type === D0.Layer) {
|
|
5966
5969
|
if (!m || !m.url) {
|
|
5967
|
-
|
|
5970
|
+
u(`图层 "${A.name}" 没有匹配的 material,跳过`);
|
|
5968
5971
|
continue;
|
|
5969
5972
|
}
|
|
5970
|
-
const
|
|
5973
|
+
const W = m.url, P = a(W);
|
|
5971
5974
|
if (!P) {
|
|
5972
|
-
|
|
5975
|
+
u(`图层 "${A.name}" 没有有效的 url,跳过`);
|
|
5973
5976
|
continue;
|
|
5974
5977
|
}
|
|
5975
5978
|
R.push({
|
|
5976
|
-
index:
|
|
5979
|
+
index: c,
|
|
5977
5980
|
type: "layer",
|
|
5978
5981
|
partData: A,
|
|
5979
5982
|
promise: yt(P, E, n).catch((L) => null)
|
|
@@ -5981,16 +5984,16 @@ async function Zx(r) {
|
|
|
5981
5984
|
} else if (A.type === D0.Group) {
|
|
5982
5985
|
if (!A.smartObjects || A.smartObjects.length === 0)
|
|
5983
5986
|
continue;
|
|
5984
|
-
for (let
|
|
5985
|
-
const P = A.smartObjects[
|
|
5987
|
+
for (let W = 0; W < A.smartObjects.length; W++) {
|
|
5988
|
+
const P = A.smartObjects[W];
|
|
5986
5989
|
if (!P || !P.name)
|
|
5987
5990
|
continue;
|
|
5988
5991
|
let L = s[P.name] ?? m;
|
|
5989
5992
|
if (!L && P.imagePath && (L = s[P.imagePath], !L)) {
|
|
5990
5993
|
const K = P.imagePath.split("/").pop() || P.imagePath;
|
|
5991
5994
|
if (L = s[K], !L) {
|
|
5992
|
-
const G = _.find((
|
|
5993
|
-
const r0 =
|
|
5995
|
+
const G = _.find((Z) => {
|
|
5996
|
+
const r0 = Z.sourceName || Z.layerName;
|
|
5994
5997
|
return !r0 || !P.imagePath ? !1 : (r0.split("/").pop() || r0) === K || r0 === P.imagePath || r0.endsWith(P.imagePath) || P.imagePath.endsWith(r0);
|
|
5995
5998
|
});
|
|
5996
5999
|
G && (L = { url: G.url });
|
|
@@ -5998,27 +6001,27 @@ async function Zx(r) {
|
|
|
5998
6001
|
}
|
|
5999
6002
|
if (!L || !L.designImage && !L.url)
|
|
6000
6003
|
continue;
|
|
6001
|
-
let
|
|
6002
|
-
if (!
|
|
6004
|
+
let I = L.designImage ?? L.url;
|
|
6005
|
+
if (!I)
|
|
6003
6006
|
continue;
|
|
6004
|
-
if (typeof
|
|
6005
|
-
/^(https?:)?\/\//i.test(
|
|
6006
|
-
const G = a(
|
|
6007
|
+
if (typeof I == "string") {
|
|
6008
|
+
/^(https?:)?\/\//i.test(I) || I.startsWith("data:") || I.startsWith("blob:") || (I = f.get(I) ?? I);
|
|
6009
|
+
const G = a(I);
|
|
6007
6010
|
if (!G)
|
|
6008
6011
|
continue;
|
|
6009
|
-
|
|
6012
|
+
I = G;
|
|
6010
6013
|
}
|
|
6011
|
-
const
|
|
6014
|
+
const Y = (A.partId ?? A.id) * 100 + W, Q = ot(at(P)), i0 = { width: b, height: g };
|
|
6012
6015
|
R.push({
|
|
6013
|
-
index:
|
|
6016
|
+
index: c + W * 0.01,
|
|
6014
6017
|
type: "group",
|
|
6015
6018
|
partData: A,
|
|
6016
6019
|
smartObject: P,
|
|
6017
6020
|
maskData: Q,
|
|
6018
|
-
promise:
|
|
6019
|
-
|
|
6021
|
+
promise: Zx(
|
|
6022
|
+
I,
|
|
6020
6023
|
P,
|
|
6021
|
-
|
|
6024
|
+
Y,
|
|
6022
6025
|
i0,
|
|
6023
6026
|
E,
|
|
6024
6027
|
n
|
|
@@ -6027,42 +6030,42 @@ async function Zx(r) {
|
|
|
6027
6030
|
}
|
|
6028
6031
|
}
|
|
6029
6032
|
}
|
|
6030
|
-
const w = await Promise.all(R.map((
|
|
6031
|
-
task:
|
|
6033
|
+
const w = await Promise.all(R.map((c) => c.promise)), H = R.map((c, A) => ({
|
|
6034
|
+
task: c,
|
|
6032
6035
|
imageBitmap: w[A]
|
|
6033
|
-
})).sort((
|
|
6034
|
-
const m =
|
|
6035
|
-
return m -
|
|
6036
|
+
})).sort((c, A) => {
|
|
6037
|
+
const m = c.task.type === "group" && c.task.smartObject?.layerOrder !== void 0 ? c.task.smartObject.layerOrder : c.task.partData.layerOrder ?? c.task.index, W = A.task.type === "group" && A.task.smartObject?.layerOrder !== void 0 ? A.task.smartObject.layerOrder : A.task.partData.layerOrder ?? A.task.index;
|
|
6038
|
+
return m - W;
|
|
6036
6039
|
});
|
|
6037
6040
|
let $ = h0(b, g), z = g0($), O = !1, q = "normal";
|
|
6038
|
-
for (let
|
|
6039
|
-
const { task: A, imageBitmap: m } = H[
|
|
6041
|
+
for (let c = 0; c < H.length; c++) {
|
|
6042
|
+
const { task: A, imageBitmap: m } = H[c];
|
|
6040
6043
|
if (!m) {
|
|
6041
|
-
|
|
6044
|
+
u(`[renderByJson] 图层 "${A.partData.name}" 没有 imageBitmap,跳过`);
|
|
6042
6045
|
continue;
|
|
6043
6046
|
}
|
|
6044
|
-
const { partData:
|
|
6047
|
+
const { partData: W } = A, P = W.bounds;
|
|
6045
6048
|
let L;
|
|
6046
|
-
A.type === "group" && A.smartObject ? L = A.smartObject.opacity ??
|
|
6047
|
-
let
|
|
6048
|
-
A.type === "group" && A.smartObject ?
|
|
6049
|
-
const
|
|
6049
|
+
A.type === "group" && A.smartObject ? L = A.smartObject.opacity ?? W.opacity : L = W.opacity, (typeof L != "number" || isNaN(L)) && (L = 1);
|
|
6050
|
+
let I;
|
|
6051
|
+
A.type === "group" && A.smartObject ? I = A.smartObject.clipping ?? W.clipping === !0 : I = W.clipping === !0;
|
|
6052
|
+
const Y = H[c + 1];
|
|
6050
6053
|
let Q = !1;
|
|
6051
|
-
if (
|
|
6052
|
-
const K =
|
|
6053
|
-
|
|
6054
|
+
if (Y) {
|
|
6055
|
+
const K = Y.task.partData;
|
|
6056
|
+
Y.task.type === "group" && Y.task.smartObject ? Q = Y.task.smartObject.clipping ?? K.clipping === !0 : Q = K.clipping === !0;
|
|
6054
6057
|
}
|
|
6055
|
-
const i0 = A.type === "group" && A.smartObject && A.smartObject.name ? A.smartObject.name :
|
|
6058
|
+
const i0 = A.type === "group" && A.smartObject && A.smartObject.name ? A.smartObject.name : W?.name || "未命名图层";
|
|
6056
6059
|
if (e(`[renderByJson] 绘制图层 "${i0}"`, {
|
|
6057
6060
|
type: A.type,
|
|
6058
6061
|
bitmapSize: { width: m.width, height: m.height },
|
|
6059
6062
|
bounds: P,
|
|
6060
6063
|
hasMask: !!A.maskData,
|
|
6061
|
-
blendMode:
|
|
6064
|
+
blendMode: W.blendMode,
|
|
6062
6065
|
opacity: L,
|
|
6063
|
-
clipping:
|
|
6064
|
-
}), !
|
|
6065
|
-
if (O = !0, q =
|
|
6066
|
+
clipping: I
|
|
6067
|
+
}), !I && Q) {
|
|
6068
|
+
if (O = !0, q = W.blendMode || "normal", z) {
|
|
6066
6069
|
if (z.clearRect(0, 0, b, g), z.globalCompositeOperation = "source-over", z.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6067
6070
|
if (A.maskData) {
|
|
6068
6071
|
const K = h0(b, g), G = g0(K);
|
|
@@ -6078,7 +6081,7 @@ async function Zx(r) {
|
|
|
6078
6081
|
) : z.drawImage(m, 0, 0));
|
|
6079
6082
|
z.globalAlpha = 1;
|
|
6080
6083
|
}
|
|
6081
|
-
} else if (
|
|
6084
|
+
} else if (I) {
|
|
6082
6085
|
if (z) {
|
|
6083
6086
|
if (z.globalCompositeOperation = "source-atop", z.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6084
6087
|
if (A.maskData) {
|
|
@@ -6096,7 +6099,7 @@ async function Zx(r) {
|
|
|
6096
6099
|
z.globalAlpha = 1, z.globalCompositeOperation = "source-over";
|
|
6097
6100
|
}
|
|
6098
6101
|
} else {
|
|
6099
|
-
if (k.globalCompositeOperation = Mr(
|
|
6102
|
+
if (k.globalCompositeOperation = Mr(W.blendMode), k.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6100
6103
|
if (A.maskData) {
|
|
6101
6104
|
const K = h0(b, g), G = g0(K);
|
|
6102
6105
|
G && (G.drawImage(m, 0, 0), Br(G, A.maskData), k.drawImage(K, 0, 0));
|
|
@@ -6126,10 +6129,10 @@ async function Zx(r) {
|
|
|
6126
6129
|
T = Math.round(b * A), N = x;
|
|
6127
6130
|
}
|
|
6128
6131
|
U = h0(T, N);
|
|
6129
|
-
const
|
|
6130
|
-
|
|
6132
|
+
const c = ye(U);
|
|
6133
|
+
c.imageSmoothingEnabled = !0, c.imageSmoothingQuality = "high", c.drawImage(y, 0, 0, b, g, 0, 0, T, N), e(`[renderByJson] 已缩放结果: ${b}x${g} -> ${T}x${N}`);
|
|
6131
6134
|
}
|
|
6132
|
-
const S = performance.now() -
|
|
6135
|
+
const S = performance.now() - d;
|
|
6133
6136
|
return e(`[renderByJson] 绘制完成,总渲染时间: ${Math.round(S)}ms`), {
|
|
6134
6137
|
canvas: U,
|
|
6135
6138
|
width: T,
|
|
@@ -6137,7 +6140,7 @@ async function Zx(r) {
|
|
|
6137
6140
|
};
|
|
6138
6141
|
}
|
|
6139
6142
|
const qe = async (r) => {
|
|
6140
|
-
const t = (await
|
|
6143
|
+
const t = (await Yx(r)).canvas;
|
|
6141
6144
|
return t ? createImageBitmap(t) : null;
|
|
6142
6145
|
};
|
|
6143
6146
|
let s0 = null, Ar = !1;
|
|
@@ -6149,17 +6152,17 @@ const Te = async () => {
|
|
|
6149
6152
|
const r = s0;
|
|
6150
6153
|
s0 = null;
|
|
6151
6154
|
try {
|
|
6152
|
-
const
|
|
6155
|
+
const d = await qe(r.renderData);
|
|
6153
6156
|
if (s0) {
|
|
6154
|
-
|
|
6157
|
+
d?.close?.();
|
|
6155
6158
|
continue;
|
|
6156
6159
|
}
|
|
6157
|
-
self.postMessage({ id: r.id, bitmap:
|
|
6158
|
-
} catch (
|
|
6160
|
+
self.postMessage({ id: r.id, bitmap: d }, d ? [d] : []);
|
|
6161
|
+
} catch (d) {
|
|
6159
6162
|
if (s0) continue;
|
|
6160
6163
|
self.postMessage({
|
|
6161
6164
|
id: r.id,
|
|
6162
|
-
error:
|
|
6165
|
+
error: d instanceof Error ? d.message : String(d)
|
|
6163
6166
|
});
|
|
6164
6167
|
}
|
|
6165
6168
|
}
|
|
@@ -6169,9 +6172,9 @@ const Te = async () => {
|
|
|
6169
6172
|
}
|
|
6170
6173
|
};
|
|
6171
6174
|
self.onmessage = async (r) => {
|
|
6172
|
-
const
|
|
6173
|
-
if (
|
|
6174
|
-
const e =
|
|
6175
|
+
const d = r.data;
|
|
6176
|
+
if (d && typeof d == "object" && "type" in d && d.type === "SET_LICENSE") {
|
|
6177
|
+
const e = d;
|
|
6175
6178
|
Tx({
|
|
6176
6179
|
token: e.licenseToken,
|
|
6177
6180
|
apiUrl: e.licenseApiUrl,
|
|
@@ -6180,7 +6183,7 @@ self.onmessage = async (r) => {
|
|
|
6180
6183
|
});
|
|
6181
6184
|
return;
|
|
6182
6185
|
}
|
|
6183
|
-
const t =
|
|
6186
|
+
const t = d;
|
|
6184
6187
|
if (t.coalesce === !0) {
|
|
6185
6188
|
s0 = { id: t.id, renderData: t.renderData }, Te();
|
|
6186
6189
|
return;
|