@jieyin/editor-sdk-test 1.1.156 → 1.1.157
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 +6123 -6144
- package/dist/renderWorker.js +776 -778
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/renderWorker.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var g0 = /* @__PURE__ */ ((r) => (r[r.Group = 0] = "Group", r[r.Layer = 1] = "Layer", r))(g0 || {});
|
|
2
|
-
function
|
|
3
|
-
let
|
|
2
|
+
function Ze(r) {
|
|
3
|
+
let u = r;
|
|
4
4
|
return () => {
|
|
5
|
-
const t =
|
|
6
|
-
return
|
|
5
|
+
const t = u;
|
|
6
|
+
return u += 1, t;
|
|
7
7
|
};
|
|
8
8
|
}
|
|
9
|
-
function Qe(r,
|
|
9
|
+
function Qe(r, u) {
|
|
10
10
|
return {
|
|
11
11
|
name: r.name || "",
|
|
12
12
|
type: r.type || "Layer",
|
|
@@ -23,24 +23,24 @@ function Qe(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 ?? u,
|
|
27
27
|
filterList: r.filterList,
|
|
28
28
|
opacity: r.opacity,
|
|
29
29
|
clipping: r.clipping
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
function Ve(r,
|
|
33
|
-
let
|
|
34
|
-
if (r.type === "Group" && m === void 0 && (!
|
|
35
|
-
const x = r.children[0].name, n =
|
|
36
|
-
(E !== void 0 || n?.id !== void 0) && (
|
|
32
|
+
function Ve(r, u, t, e) {
|
|
33
|
+
let d = r.name || "", p = u[d], m = p?.partId ?? (r.type === "Group" ? t.get(d) : void 0);
|
|
34
|
+
if (r.type === "Group" && m === void 0 && (!p || p.id === void 0) && r.children && r.children.length === 1) {
|
|
35
|
+
const x = r.children[0].name, n = u[x], E = n?.partId ?? t.get(x);
|
|
36
|
+
(E !== void 0 || n?.id !== void 0) && (d = x, p = n, m = E);
|
|
37
37
|
}
|
|
38
|
-
const B = r.id ??
|
|
38
|
+
const B = r.id ?? p?.id ?? e();
|
|
39
39
|
if (r.type === "Group")
|
|
40
40
|
return {
|
|
41
41
|
id: B,
|
|
42
42
|
partId: m,
|
|
43
|
-
name:
|
|
43
|
+
name: d,
|
|
44
44
|
blendMode: r.blendMode || "normal",
|
|
45
45
|
bounds: r.bounds || { left: 0, top: 0, width: 0, height: 0 },
|
|
46
46
|
type: g0.Group,
|
|
@@ -51,7 +51,7 @@ function Ve(r, h, t, e) {
|
|
|
51
51
|
clipping: r.clipping,
|
|
52
52
|
layerOrder: r.layerOrder
|
|
53
53
|
};
|
|
54
|
-
let C =
|
|
54
|
+
let C = p?.url;
|
|
55
55
|
return !C && r.imagePath && (C = r.imagePath), {
|
|
56
56
|
id: B,
|
|
57
57
|
name: r.name || "",
|
|
@@ -64,37 +64,37 @@ function Ve(r, h, t, e) {
|
|
|
64
64
|
layerOrder: r.layerOrder
|
|
65
65
|
};
|
|
66
66
|
}
|
|
67
|
-
function Je(r,
|
|
68
|
-
const t = new Map(
|
|
67
|
+
function Je(r, u) {
|
|
68
|
+
const t = new Map(u.parts.map((d) => [d.name, d.id])), e = Ze(u.defaultIdStart ?? 1);
|
|
69
69
|
return {
|
|
70
|
-
parts:
|
|
71
|
-
models: r.map((
|
|
72
|
-
const
|
|
70
|
+
parts: u.parts,
|
|
71
|
+
models: r.map((d) => {
|
|
72
|
+
const p = d.layerExtrasByName ?? {}, m = d.psdJson, B = m.layerList || m.layerList || [], C = m.canvasWidth, x = m.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
76
|
const f = [];
|
|
77
|
-
for (const
|
|
78
|
-
if (
|
|
79
|
-
const
|
|
80
|
-
const b = o.layerOrder ?? 0, g =
|
|
77
|
+
for (const v of s)
|
|
78
|
+
if (v.type === "Group" && v.children) {
|
|
79
|
+
const h = [], D = [], i = [...v.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
|
-
|
|
90
|
-
...
|
|
91
|
-
children:
|
|
89
|
+
h.length > 0 && f.push({
|
|
90
|
+
...v,
|
|
91
|
+
children: h
|
|
92
92
|
});
|
|
93
93
|
} else
|
|
94
|
-
f.push(
|
|
94
|
+
f.push(v);
|
|
95
95
|
return f;
|
|
96
96
|
}, a = n(B).map(
|
|
97
|
-
(s) => Ve(s,
|
|
97
|
+
(s) => Ve(s, p, t, e)
|
|
98
98
|
);
|
|
99
99
|
return {
|
|
100
100
|
width: C,
|
|
@@ -110,44 +110,44 @@ function rt(r) {
|
|
|
110
110
|
function et(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((u) => ({
|
|
114
|
+
open: !!u.open,
|
|
115
|
+
knots: u.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((u) => ({
|
|
123
|
+
x: u.x,
|
|
124
|
+
y: u.y,
|
|
125
|
+
type: u.type
|
|
126
126
|
}))
|
|
127
127
|
} : null : null;
|
|
128
128
|
}
|
|
129
|
-
function
|
|
130
|
-
if (
|
|
131
|
-
if (r.globalCompositeOperation = "destination-in", r.beginPath(),
|
|
132
|
-
|
|
129
|
+
function lr(r, u) {
|
|
130
|
+
if (u) {
|
|
131
|
+
if (r.globalCompositeOperation = "destination-in", r.beginPath(), u.type === "bezier" && Array.isArray(u.paths))
|
|
132
|
+
u.paths.forEach((t) => {
|
|
133
133
|
const e = t.knots;
|
|
134
134
|
if (!e || e.length < 2) return;
|
|
135
|
-
const
|
|
136
|
-
r.moveTo(
|
|
137
|
-
for (let
|
|
138
|
-
const m = e[
|
|
139
|
-
let B = (
|
|
140
|
-
if (!t.open &&
|
|
135
|
+
const d = e[0];
|
|
136
|
+
r.moveTo(d.points[2], d.points[3]);
|
|
137
|
+
for (let p = 0; p < e.length; p++) {
|
|
138
|
+
const m = e[p];
|
|
139
|
+
let B = (p + 1) % e.length;
|
|
140
|
+
if (!t.open && p === e.length - 1)
|
|
141
141
|
B = 0;
|
|
142
|
-
else if (t.open &&
|
|
142
|
+
else if (t.open && p === e.length - 1)
|
|
143
143
|
break;
|
|
144
144
|
const C = e[B], x = m.points[4], n = m.points[5], E = C.points[0], a = C.points[1], s = C.points[2], f = C.points[3];
|
|
145
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 (u.type === "simple" && Array.isArray(u.points)) {
|
|
150
|
+
const t = u.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 v0 {
|
|
|
161
161
|
/**
|
|
162
162
|
* 获取存储项
|
|
163
163
|
*/
|
|
164
|
-
static getItem(
|
|
164
|
+
static getItem(u) {
|
|
165
165
|
if (!this.hasStorage) return null;
|
|
166
166
|
try {
|
|
167
|
-
return localStorage.getItem(
|
|
167
|
+
return localStorage.getItem(u);
|
|
168
168
|
} catch {
|
|
169
169
|
return null;
|
|
170
170
|
}
|
|
@@ -172,10 +172,10 @@ class v0 {
|
|
|
172
172
|
/**
|
|
173
173
|
* 设置存储项
|
|
174
174
|
*/
|
|
175
|
-
static setItem(
|
|
175
|
+
static setItem(u, t) {
|
|
176
176
|
if (!this.hasStorage) return !1;
|
|
177
177
|
try {
|
|
178
|
-
return localStorage.setItem(
|
|
178
|
+
return localStorage.setItem(u, t), !0;
|
|
179
179
|
} catch {
|
|
180
180
|
return !1;
|
|
181
181
|
}
|
|
@@ -183,10 +183,10 @@ class v0 {
|
|
|
183
183
|
/**
|
|
184
184
|
* 移除存储项
|
|
185
185
|
*/
|
|
186
|
-
static removeItem(
|
|
186
|
+
static removeItem(u) {
|
|
187
187
|
if (!this.hasStorage) return !1;
|
|
188
188
|
try {
|
|
189
|
-
return localStorage.removeItem(
|
|
189
|
+
return localStorage.removeItem(u), !0;
|
|
190
190
|
} catch {
|
|
191
191
|
return !1;
|
|
192
192
|
}
|
|
@@ -251,10 +251,10 @@ class h0 {
|
|
|
251
251
|
/**
|
|
252
252
|
* 安全地解析 URL
|
|
253
253
|
*/
|
|
254
|
-
static parse(
|
|
254
|
+
static parse(u) {
|
|
255
255
|
try {
|
|
256
256
|
const t = fr.getOrigin();
|
|
257
|
-
return new URL(
|
|
257
|
+
return new URL(u, t);
|
|
258
258
|
} catch {
|
|
259
259
|
return null;
|
|
260
260
|
}
|
|
@@ -262,220 +262,218 @@ class h0 {
|
|
|
262
262
|
/**
|
|
263
263
|
* 添加查询参数
|
|
264
264
|
*/
|
|
265
|
-
static addParam(
|
|
266
|
-
const
|
|
267
|
-
return !
|
|
265
|
+
static addParam(u, t, e) {
|
|
266
|
+
const d = this.parse(u);
|
|
267
|
+
return !d || d.searchParams.has(t) ? u : (d.searchParams.set(t, e), this.formatUrl(u, d));
|
|
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(u, t) {
|
|
273
|
+
const e = this.parse(u);
|
|
274
|
+
return !e || !e.searchParams.has(t) ? u : (e.searchParams.delete(t), this.formatUrl(u, e));
|
|
275
275
|
}
|
|
276
276
|
/**
|
|
277
277
|
* 检查是否有指定参数
|
|
278
278
|
*/
|
|
279
|
-
static hasParam(
|
|
280
|
-
return this.parse(
|
|
279
|
+
static hasParam(u, t) {
|
|
280
|
+
return this.parse(u)?.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(u, t) {
|
|
286
|
+
const e = /^(https?:)?\/\//i.test(u), d = u.startsWith("//");
|
|
287
|
+
return e ? t.toString() : d ? 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(u) {
|
|
293
|
+
return u?.startsWith("data:") ?? !1;
|
|
294
294
|
}
|
|
295
295
|
/**
|
|
296
296
|
* 检查是否为 Blob URL
|
|
297
297
|
*/
|
|
298
|
-
static isBlobUrl(
|
|
299
|
-
return
|
|
298
|
+
static isBlobUrl(u) {
|
|
299
|
+
return u?.startsWith("blob:") ?? !1;
|
|
300
300
|
}
|
|
301
301
|
}
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
return r = r - 157, cr()[r];
|
|
302
|
+
function Cr(r, u) {
|
|
303
|
+
return r = r - 193, cr()[r];
|
|
305
304
|
}
|
|
306
|
-
|
|
307
|
-
|
|
305
|
+
const r0 = Cr;
|
|
306
|
+
(function(r, u) {
|
|
307
|
+
const t = Cr, e = r();
|
|
308
308
|
for (; ; )
|
|
309
309
|
try {
|
|
310
|
-
if (-parseInt(t(
|
|
310
|
+
if (-parseInt(t(219)) / 1 * (-parseInt(t(230)) / 2) + parseInt(t(207)) / 3 * (-parseInt(t(231)) / 4) + -parseInt(t(215)) / 5 + parseInt(t(203)) / 6 + -parseInt(t(206)) / 7 + parseInt(t(212)) / 8 * (-parseInt(t(198)) / 9) + parseInt(t(222)) / 10 === u) break;
|
|
311
311
|
e.push(e.shift());
|
|
312
312
|
} catch {
|
|
313
313
|
e.push(e.shift());
|
|
314
314
|
}
|
|
315
|
-
})(cr, -
|
|
315
|
+
})(cr, -1 * -440957 + -1005813 + 56 * 22152);
|
|
316
316
|
const A0 = /* @__PURE__ */ (function() {
|
|
317
317
|
let r = !0;
|
|
318
|
-
return function(
|
|
318
|
+
return function(u, t) {
|
|
319
319
|
const e = r ? function() {
|
|
320
|
-
const u = ur;
|
|
321
320
|
if (t) {
|
|
322
|
-
const
|
|
323
|
-
return t = null,
|
|
321
|
+
const d = t.apply(u, arguments);
|
|
322
|
+
return t = null, d;
|
|
324
323
|
}
|
|
325
324
|
} : function() {
|
|
326
325
|
};
|
|
327
326
|
return r = !1, e;
|
|
328
327
|
};
|
|
329
328
|
})(), tt = A0(void 0, function() {
|
|
330
|
-
const r =
|
|
331
|
-
let
|
|
329
|
+
const r = Cr;
|
|
330
|
+
let u;
|
|
332
331
|
try {
|
|
333
|
-
|
|
332
|
+
u = Function(r(223) + "n (function() " + ("{}.constru" + r(216) + r(233) + 'rn this")( )') + ");")();
|
|
334
333
|
} catch {
|
|
335
|
-
|
|
334
|
+
u = window;
|
|
336
335
|
}
|
|
337
|
-
const t =
|
|
338
|
-
for (let
|
|
339
|
-
const
|
|
340
|
-
|
|
336
|
+
const t = u.console = u.console || {}, e = [r(226), "warn", "info", "error", "excep" + r(227), "table", "trace"];
|
|
337
|
+
for (let d = -2714 + 1 * -7507 + 10221; d < e.length; d++) {
|
|
338
|
+
const p = A0[r(228) + r(195) + "r"]["proto" + r(214)].bind(A0), m = e[d], B = t[m] || p;
|
|
339
|
+
p.__proto__ = A0.bind(A0), p[r(209) + r(204)] = B[r(209) + "ing"].bind(B), t[m] = p;
|
|
341
340
|
}
|
|
342
341
|
});
|
|
343
|
-
function cr() {
|
|
344
|
-
const r = ["1050BxjbAl", "8944115WclhZB", "FileT", "token", "conso", "{}.co", "2NXQMOo", "bind", 'is")(', "expir", "eItem", "addPa", "15392264nQBvxO", "now", "2872tbgMmu", "efres", "des", "warn", "9sEVCSD", "isBro", "getIt", '"retu', "file_", "apply", "/file", "95326aKqoPB", "6957UgafPT", "numbe", "rn th", "statu", "okenR", "info", "ing", "data", "fileT", "357VTmysJ", "9918432OPAPyF", "n (fu", "ram", "11715508VXyBMp", "remov", "ctor("];
|
|
345
|
-
return cr = function() {
|
|
346
|
-
return r;
|
|
347
|
-
}, cr();
|
|
348
|
-
}
|
|
349
342
|
tt();
|
|
350
|
-
const Er =
|
|
351
|
-
function
|
|
343
|
+
const Er = r0(213) + "token", Ar = "file_token" + r0(224) + "re_time", xt = (-394 * 14 + -5320 + 2724 * 4) * 1e3;
|
|
344
|
+
function pr() {
|
|
352
345
|
return v0.getItem(Er);
|
|
353
346
|
}
|
|
354
347
|
function nt(r = xt) {
|
|
355
|
-
const
|
|
356
|
-
if (!
|
|
357
|
-
const e = v0
|
|
348
|
+
const u = r0;
|
|
349
|
+
if (!pr()) return !0;
|
|
350
|
+
const e = v0.getItem(Ar);
|
|
358
351
|
if (!e) return !1;
|
|
359
|
-
const
|
|
360
|
-
return Date
|
|
352
|
+
const d = Number(e);
|
|
353
|
+
return Date[u(235)]() + r > d;
|
|
361
354
|
}
|
|
362
|
-
function at(r,
|
|
363
|
-
const t =
|
|
364
|
-
if (v0.setItem(Er, r), typeof
|
|
365
|
-
const e = Date[t(
|
|
366
|
-
v0
|
|
355
|
+
function at(r, u) {
|
|
356
|
+
const t = r0;
|
|
357
|
+
if (v0.setItem(Er, r), typeof u == t(202) + "r" && u > 8415 + 6 * 423 + -10953) {
|
|
358
|
+
const e = Date[t(235)]() + u * 1e3;
|
|
359
|
+
v0[t(194) + "em"](Ar, String(e));
|
|
367
360
|
}
|
|
368
361
|
}
|
|
369
362
|
function ot() {
|
|
370
|
-
const r =
|
|
371
|
-
v0.removeItem(Er), v0[
|
|
363
|
+
const r = r0;
|
|
364
|
+
v0.removeItem(Er), v0["remov" + r(234)](Ar);
|
|
372
365
|
}
|
|
373
|
-
async function
|
|
374
|
-
const
|
|
375
|
-
return t?.data?.code === -
|
|
366
|
+
async function Wr(r) {
|
|
367
|
+
const u = r0, t = await r(), e = t?.data?.[u(211)];
|
|
368
|
+
return t?.data?.code === -2989 * 2 + -1174 + 3676 * 2 && e?.[u(213) + u(220)] ? (at(e[u(213) + "token"], e[u(193) + "es_in"]), e["file_" + u(220)]) : null;
|
|
376
369
|
}
|
|
377
370
|
let it = null;
|
|
378
371
|
function Ir() {
|
|
379
|
-
return fr[
|
|
372
|
+
return fr["isBro" + r0(225)]() ? it : null;
|
|
373
|
+
}
|
|
374
|
+
function cr() {
|
|
375
|
+
const r = ["3788BWcrCC", "inclu", '"retu', "eItem", "now", "expir", "setIt", "ructo", "fileT", "oken=", "891hLgcvp", "fetch", "isBro", "FileT", "numbe", "8056530OFGYRJ", "ing", "des", "3585351mSbEZI", "651vSAHlo", "hasPa", "toStr", "oken", "data", "24072cXoMDM", "file_", "type", "2274035mazwyC", "ctor(", "addPa", "/file", "124121GsPcOt", "token", "aUrl", "3068070yMGvlT", "retur", "_expi", "wser", "log", "tion", "const", "ePara", "8FMVEOu"];
|
|
376
|
+
return cr = function() {
|
|
377
|
+
return r;
|
|
378
|
+
}, cr();
|
|
380
379
|
}
|
|
381
380
|
async function be() {
|
|
382
|
-
const r =
|
|
383
|
-
if (!fr
|
|
384
|
-
const
|
|
385
|
-
if (
|
|
381
|
+
const r = r0;
|
|
382
|
+
if (!fr["isBro" + r(225)]()) return pr();
|
|
383
|
+
const u = pr();
|
|
384
|
+
if (u && !nt()) return u;
|
|
386
385
|
try {
|
|
387
386
|
const t = await Ir();
|
|
388
|
-
if (
|
|
389
|
-
const e = await
|
|
387
|
+
if (u && t?.["fetchFileTokenRefresh"]) {
|
|
388
|
+
const e = await Wr(t[r(199) + "FileTokenRefresh"]);
|
|
390
389
|
if (e) return e;
|
|
391
390
|
}
|
|
392
391
|
} catch {
|
|
393
392
|
}
|
|
394
393
|
try {
|
|
395
394
|
const t = Ir();
|
|
396
|
-
return t?.["
|
|
395
|
+
return t?.["fetch" + r(201) + "oken"] ? await Wr(t.fetchFileToken) : null;
|
|
397
396
|
} catch {
|
|
398
397
|
return null;
|
|
399
398
|
}
|
|
400
399
|
}
|
|
401
400
|
function me(r) {
|
|
402
|
-
const
|
|
403
|
-
if (!r || h0
|
|
401
|
+
const u = r0;
|
|
402
|
+
if (!r || h0["isDat" + u(221)](r) || h0.isBlobUrl(r)) return !1;
|
|
404
403
|
const t = h0.parse(r);
|
|
405
|
-
return t ? t.pathname
|
|
404
|
+
return t ? t.pathname["inclu" + u(205)](u(218) + "s/") && !h0[u(208) + "ram"](r, "fileT" + u(210)) : r[u(232) + "des"]("/files/") && !r[u(232) + "des"](u(196) + u(197));
|
|
406
405
|
}
|
|
407
|
-
function _e(r,
|
|
408
|
-
const t =
|
|
409
|
-
return !
|
|
406
|
+
function _e(r, u) {
|
|
407
|
+
const t = r0;
|
|
408
|
+
return !u || !me(r) ? r : h0[t(217) + "ram"](r, "fileToken", u);
|
|
410
409
|
}
|
|
411
410
|
function st(r) {
|
|
412
|
-
return h0
|
|
411
|
+
return h0["remov" + r0(229) + "m"](r, "fileToken");
|
|
413
412
|
}
|
|
414
413
|
async function ct(r) {
|
|
415
414
|
if (!me(r)) return r;
|
|
416
|
-
const
|
|
417
|
-
return _e(r,
|
|
415
|
+
const u = await be();
|
|
416
|
+
return _e(r, u);
|
|
418
417
|
}
|
|
419
|
-
async function ye(r,
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
if (v[t(176) + "s"] !== -18 * -405 + 9482 + -16371) return v;
|
|
418
|
+
async function ye(r, u) {
|
|
419
|
+
if (!fr[r0(200) + "wser"]()) return fetch(r, u);
|
|
420
|
+
const e = st(r), d = await ct(e), p = await fetch(d, u);
|
|
421
|
+
if (p.status !== 401) return p;
|
|
424
422
|
ot();
|
|
425
423
|
const m = await be(), B = _e(e, m);
|
|
426
|
-
return fetch(B,
|
|
424
|
+
return fetch(B, u);
|
|
427
425
|
}
|
|
428
|
-
const we = (r,
|
|
426
|
+
const we = (r, u) => {
|
|
429
427
|
if (!r) return r;
|
|
430
|
-
const t = (
|
|
428
|
+
const t = (u || "").replace(/\/$/, "");
|
|
431
429
|
if (t && r.startsWith(t))
|
|
432
430
|
return r;
|
|
433
431
|
if (typeof window < "u") {
|
|
434
|
-
const
|
|
435
|
-
if (
|
|
432
|
+
const d = window.location.hostname;
|
|
433
|
+
if (d === "localhost" || d === "127.0.0.1")
|
|
436
434
|
try {
|
|
437
|
-
const
|
|
435
|
+
const p = new URL(r);
|
|
438
436
|
if (t)
|
|
439
437
|
try {
|
|
440
438
|
const m = new URL(t).origin;
|
|
441
|
-
if (
|
|
439
|
+
if (p.origin === m)
|
|
442
440
|
return r;
|
|
443
441
|
} catch {
|
|
444
442
|
}
|
|
445
|
-
if (
|
|
446
|
-
return t ? `${t}${
|
|
443
|
+
if (p.pathname.startsWith("/files/"))
|
|
444
|
+
return t ? `${t}${p.pathname}${p.search}${p.hash}` : `${p.pathname}${p.search}${p.hash}`;
|
|
447
445
|
} catch {
|
|
448
446
|
}
|
|
449
447
|
}
|
|
450
448
|
if (typeof window < "u" && window.location.hostname !== "localhost") return r;
|
|
451
449
|
const e = r.match(/^https?:\/\/([^/]+\.oss[^/]*\.aliyuncs\.com)(.*)$/);
|
|
452
450
|
return e ? `/oss${e[2]}` : r;
|
|
453
|
-
}, ft = (r,
|
|
451
|
+
}, ft = (r, u) => {
|
|
454
452
|
if (typeof OffscreenCanvas < "u" && typeof document > "u")
|
|
455
|
-
return new OffscreenCanvas(r,
|
|
453
|
+
return new OffscreenCanvas(r, u);
|
|
456
454
|
const t = document.createElement("canvas");
|
|
457
|
-
return t.width = r, t.height =
|
|
458
|
-
}, _0 = async (r,
|
|
459
|
-
if (!
|
|
455
|
+
return t.width = r, t.height = u, t;
|
|
456
|
+
}, _0 = async (r, u) => {
|
|
457
|
+
if (!u || u <= 0) return r;
|
|
460
458
|
const t = Math.max(r.width, r.height);
|
|
461
|
-
if (t <=
|
|
462
|
-
const e =
|
|
463
|
-
return B ? (B.drawImage(r, 0, 0,
|
|
459
|
+
if (t <= u) return r;
|
|
460
|
+
const e = u / t, d = Math.max(1, Math.round(r.width * e)), p = Math.max(1, Math.round(r.height * e)), m = ft(d, p), B = m.getContext("2d");
|
|
461
|
+
return B ? (B.drawImage(r, 0, 0, d, p), r.close?.(), await createImageBitmap(m)) : r;
|
|
464
462
|
};
|
|
465
|
-
async function
|
|
463
|
+
async function dt(r, u, t) {
|
|
466
464
|
if (typeof r == "string")
|
|
467
465
|
try {
|
|
468
|
-
const e = we(r, t),
|
|
469
|
-
if (!
|
|
470
|
-
const m =
|
|
466
|
+
const e = we(r, t), d = await ye(e);
|
|
467
|
+
if (!d.ok) {
|
|
468
|
+
const m = d.status === 404 ? `图片不存在 (404): ${r}` : `加载图片失败 (${d.status} ${d.statusText}): ${r}`;
|
|
471
469
|
throw new Error(m);
|
|
472
470
|
}
|
|
473
|
-
const
|
|
474
|
-
if (!
|
|
471
|
+
const p = await d.blob();
|
|
472
|
+
if (!p.type.startsWith("image/") && p.size === 0)
|
|
475
473
|
throw new Error(`图片数据无效: URL=${r}`);
|
|
476
474
|
try {
|
|
477
|
-
const m = await createImageBitmap(
|
|
478
|
-
return await _0(m,
|
|
475
|
+
const m = await createImageBitmap(p);
|
|
476
|
+
return await _0(m, u);
|
|
479
477
|
} catch (m) {
|
|
480
478
|
throw new Error(`图片解码失败: URL=${r}, 错误=${m instanceof Error ? m.message : m}`);
|
|
481
479
|
}
|
|
@@ -483,13 +481,13 @@ async function ut(r, h, t) {
|
|
|
483
481
|
throw e instanceof Error ? e : new Error(`加载图片失败: ${r}, ${e}`);
|
|
484
482
|
}
|
|
485
483
|
if (r instanceof HTMLImageElement) {
|
|
486
|
-
if ((!r.complete || r.naturalWidth === 0) && await new Promise((e,
|
|
487
|
-
r.onload = e, r.onerror = () =>
|
|
484
|
+
if ((!r.complete || r.naturalWidth === 0) && await new Promise((e, d) => {
|
|
485
|
+
r.onload = e, r.onerror = () => d(new Error(`图片加载失败: src=${r.src}`)), r.complete && e(null);
|
|
488
486
|
}), r.naturalWidth === 0 || r.naturalHeight === 0)
|
|
489
487
|
throw new Error(`图片尺寸无效: src=${r.src}, width=${r.naturalWidth}, height=${r.naturalHeight}`);
|
|
490
488
|
try {
|
|
491
489
|
const e = await createImageBitmap(r);
|
|
492
|
-
return await _0(e,
|
|
490
|
+
return await _0(e, u);
|
|
493
491
|
} catch (e) {
|
|
494
492
|
throw new Error(`图片解码失败: src=${r.src}, 错误=${e instanceof Error ? e.message : e}`);
|
|
495
493
|
}
|
|
@@ -497,23 +495,23 @@ async function ut(r, h, t) {
|
|
|
497
495
|
if (r instanceof ImageBitmap) {
|
|
498
496
|
if (r.width === 0 || r.height === 0)
|
|
499
497
|
throw new Error(`ImageBitmap 尺寸无效: width=${r.width}, height=${r.height}`);
|
|
500
|
-
return await _0(r,
|
|
498
|
+
return await _0(r, u);
|
|
501
499
|
}
|
|
502
500
|
throw new Error("不支持的图片类型");
|
|
503
501
|
}
|
|
504
|
-
async function
|
|
502
|
+
async function ut(r, u, t) {
|
|
505
503
|
try {
|
|
506
|
-
const e = we(r, t),
|
|
507
|
-
if (!
|
|
508
|
-
const m =
|
|
504
|
+
const e = we(r, t), d = await ye(e);
|
|
505
|
+
if (!d.ok) {
|
|
506
|
+
const m = d.status === 404 ? `图片不存在 (404): ${r}` : `加载图片失败 (${d.status} ${d.statusText}): ${r}`;
|
|
509
507
|
throw new Error(m);
|
|
510
508
|
}
|
|
511
|
-
const
|
|
512
|
-
if (!
|
|
509
|
+
const p = await d.blob();
|
|
510
|
+
if (!p.type.startsWith("image/") && p.size === 0)
|
|
513
511
|
throw new Error(`图片数据无效: URL=${r}`);
|
|
514
512
|
try {
|
|
515
|
-
const m = await createImageBitmap(
|
|
516
|
-
return await _0(m,
|
|
513
|
+
const m = await createImageBitmap(p);
|
|
514
|
+
return await _0(m, u);
|
|
517
515
|
} catch (m) {
|
|
518
516
|
throw new Error(`图片解码失败: URL=${r}, 错误=${m instanceof Error ? m.message : m}`);
|
|
519
517
|
}
|
|
@@ -523,7 +521,7 @@ async function dt(r, h, t) {
|
|
|
523
521
|
}
|
|
524
522
|
function Lr(r) {
|
|
525
523
|
if (!r) return "source-over";
|
|
526
|
-
const
|
|
524
|
+
const u = r.trim().toLowerCase();
|
|
527
525
|
return {
|
|
528
526
|
normal: "source-over",
|
|
529
527
|
multiply: "multiply",
|
|
@@ -549,26 +547,26 @@ function Lr(r) {
|
|
|
549
547
|
"linear dodge": "lighter",
|
|
550
548
|
lighter: "lighter",
|
|
551
549
|
"pass-through": "source-over"
|
|
552
|
-
}[
|
|
550
|
+
}[u] || "source-over";
|
|
553
551
|
}
|
|
554
|
-
var
|
|
552
|
+
var hr = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
555
553
|
function lt(r) {
|
|
556
554
|
if (Object.prototype.hasOwnProperty.call(r, "__esModule")) return r;
|
|
557
|
-
var
|
|
558
|
-
if (typeof
|
|
555
|
+
var u = r.default;
|
|
556
|
+
if (typeof u == "function") {
|
|
559
557
|
var t = function e() {
|
|
560
|
-
var
|
|
558
|
+
var d = !1;
|
|
561
559
|
try {
|
|
562
|
-
|
|
560
|
+
d = this instanceof e;
|
|
563
561
|
} catch {
|
|
564
562
|
}
|
|
565
|
-
return
|
|
563
|
+
return d ? Reflect.construct(u, arguments, this.constructor) : u.apply(this, arguments);
|
|
566
564
|
};
|
|
567
|
-
t.prototype =
|
|
565
|
+
t.prototype = u.prototype;
|
|
568
566
|
} else t = {};
|
|
569
567
|
return Object.defineProperty(t, "__esModule", { value: !0 }), Object.keys(r).forEach(function(e) {
|
|
570
|
-
var
|
|
571
|
-
Object.defineProperty(t, e,
|
|
568
|
+
var d = Object.getOwnPropertyDescriptor(r, e);
|
|
569
|
+
Object.defineProperty(t, e, d.get ? d : {
|
|
572
570
|
enumerable: !0,
|
|
573
571
|
get: function() {
|
|
574
572
|
return r[e];
|
|
@@ -585,27 +583,27 @@ var w0 = { exports: {} }, vt = {}, pt = /* @__PURE__ */ Object.freeze({
|
|
|
585
583
|
default: vt
|
|
586
584
|
}), Bt = /* @__PURE__ */ lt(pt), Ct = w0.exports, Or;
|
|
587
585
|
function M() {
|
|
588
|
-
return Or || (Or = 1, (function(r,
|
|
586
|
+
return Or || (Or = 1, (function(r, u) {
|
|
589
587
|
(function(t, e) {
|
|
590
588
|
r.exports = e();
|
|
591
589
|
})(Ct, function() {
|
|
592
|
-
var t = t || (function(e,
|
|
593
|
-
var
|
|
594
|
-
if (typeof window < "u" && window.crypto && (
|
|
590
|
+
var t = t || (function(e, d) {
|
|
591
|
+
var p;
|
|
592
|
+
if (typeof window < "u" && window.crypto && (p = window.crypto), typeof self < "u" && self.crypto && (p = self.crypto), typeof globalThis < "u" && globalThis.crypto && (p = globalThis.crypto), !p && typeof window < "u" && window.msCrypto && (p = window.msCrypto), !p && typeof hr < "u" && hr.crypto && (p = hr.crypto), !p && typeof ht == "function")
|
|
595
593
|
try {
|
|
596
|
-
|
|
594
|
+
p = Bt;
|
|
597
595
|
} catch {
|
|
598
596
|
}
|
|
599
597
|
var m = function() {
|
|
600
|
-
if (
|
|
601
|
-
if (typeof
|
|
598
|
+
if (p) {
|
|
599
|
+
if (typeof p.getRandomValues == "function")
|
|
602
600
|
try {
|
|
603
|
-
return
|
|
601
|
+
return p.getRandomValues(new Uint32Array(1))[0];
|
|
604
602
|
} catch {
|
|
605
603
|
}
|
|
606
|
-
if (typeof
|
|
604
|
+
if (typeof p.randomBytes == "function")
|
|
607
605
|
try {
|
|
608
|
-
return
|
|
606
|
+
return p.randomBytes(4).readInt32LE();
|
|
609
607
|
} catch {
|
|
610
608
|
}
|
|
611
609
|
}
|
|
@@ -614,8 +612,8 @@ function M() {
|
|
|
614
612
|
function i() {
|
|
615
613
|
}
|
|
616
614
|
return function(o) {
|
|
617
|
-
var
|
|
618
|
-
return i.prototype = o,
|
|
615
|
+
var l;
|
|
616
|
+
return i.prototype = o, l = new i(), i.prototype = null, l;
|
|
619
617
|
};
|
|
620
618
|
})(), C = {}, x = C.lib = {}, n = x.Base = /* @__PURE__ */ (function() {
|
|
621
619
|
return {
|
|
@@ -716,7 +714,7 @@ function M() {
|
|
|
716
714
|
* var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6);
|
|
717
715
|
*/
|
|
718
716
|
init: function(i, o) {
|
|
719
|
-
i = this.words = i || [], o !=
|
|
717
|
+
i = this.words = i || [], o != d ? this.sigBytes = o : this.sigBytes = i.length * 4;
|
|
720
718
|
},
|
|
721
719
|
/**
|
|
722
720
|
* Converts this word array to a string.
|
|
@@ -746,15 +744,15 @@ function M() {
|
|
|
746
744
|
* wordArray1.concat(wordArray2);
|
|
747
745
|
*/
|
|
748
746
|
concat: function(i) {
|
|
749
|
-
var o = this.words,
|
|
747
|
+
var o = this.words, l = i.words, b = this.sigBytes, g = i.sigBytes;
|
|
750
748
|
if (this.clamp(), b % 4)
|
|
751
749
|
for (var y = 0; y < g; y++) {
|
|
752
|
-
var k =
|
|
750
|
+
var k = l[y >>> 2] >>> 24 - y % 4 * 8 & 255;
|
|
753
751
|
o[b + y >>> 2] |= k << 24 - (b + y) % 4 * 8;
|
|
754
752
|
}
|
|
755
753
|
else
|
|
756
754
|
for (var R = 0; R < g; R += 4)
|
|
757
|
-
o[b + R >>> 2] =
|
|
755
|
+
o[b + R >>> 2] = l[R >>> 2];
|
|
758
756
|
return this.sigBytes += g, this;
|
|
759
757
|
},
|
|
760
758
|
/**
|
|
@@ -795,7 +793,7 @@ function M() {
|
|
|
795
793
|
* var wordArray = CryptoJS.lib.WordArray.random(16);
|
|
796
794
|
*/
|
|
797
795
|
random: function(i) {
|
|
798
|
-
for (var o = [],
|
|
796
|
+
for (var o = [], l = 0; l < i; l += 4)
|
|
799
797
|
o.push(m());
|
|
800
798
|
return new E.init(o, i);
|
|
801
799
|
}
|
|
@@ -814,7 +812,7 @@ function M() {
|
|
|
814
812
|
* var hexString = CryptoJS.enc.Hex.stringify(wordArray);
|
|
815
813
|
*/
|
|
816
814
|
stringify: function(i) {
|
|
817
|
-
for (var o = i.words,
|
|
815
|
+
for (var o = i.words, l = i.sigBytes, b = [], g = 0; g < l; g++) {
|
|
818
816
|
var y = o[g >>> 2] >>> 24 - g % 4 * 8 & 255;
|
|
819
817
|
b.push((y >>> 4).toString(16)), b.push((y & 15).toString(16));
|
|
820
818
|
}
|
|
@@ -834,9 +832,9 @@ function M() {
|
|
|
834
832
|
* var wordArray = CryptoJS.enc.Hex.parse(hexString);
|
|
835
833
|
*/
|
|
836
834
|
parse: function(i) {
|
|
837
|
-
for (var o = i.length,
|
|
838
|
-
|
|
839
|
-
return new E.init(
|
|
835
|
+
for (var o = i.length, l = [], b = 0; b < o; b += 2)
|
|
836
|
+
l[b >>> 3] |= parseInt(i.substr(b, 2), 16) << 24 - b % 8 * 4;
|
|
837
|
+
return new E.init(l, o / 2);
|
|
840
838
|
}
|
|
841
839
|
}, f = a.Latin1 = {
|
|
842
840
|
/**
|
|
@@ -853,7 +851,7 @@ function M() {
|
|
|
853
851
|
* var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);
|
|
854
852
|
*/
|
|
855
853
|
stringify: function(i) {
|
|
856
|
-
for (var o = i.words,
|
|
854
|
+
for (var o = i.words, l = i.sigBytes, b = [], g = 0; g < l; g++) {
|
|
857
855
|
var y = o[g >>> 2] >>> 24 - g % 4 * 8 & 255;
|
|
858
856
|
b.push(String.fromCharCode(y));
|
|
859
857
|
}
|
|
@@ -873,11 +871,11 @@ function M() {
|
|
|
873
871
|
* var wordArray = CryptoJS.enc.Latin1.parse(latin1String);
|
|
874
872
|
*/
|
|
875
873
|
parse: function(i) {
|
|
876
|
-
for (var o = i.length,
|
|
877
|
-
|
|
878
|
-
return new E.init(
|
|
874
|
+
for (var o = i.length, l = [], b = 0; b < o; b++)
|
|
875
|
+
l[b >>> 2] |= (i.charCodeAt(b) & 255) << 24 - b % 4 * 8;
|
|
876
|
+
return new E.init(l, o);
|
|
879
877
|
}
|
|
880
|
-
},
|
|
878
|
+
}, v = a.Utf8 = {
|
|
881
879
|
/**
|
|
882
880
|
* Converts a word array to a UTF-8 string.
|
|
883
881
|
*
|
|
@@ -914,7 +912,7 @@ function M() {
|
|
|
914
912
|
parse: function(i) {
|
|
915
913
|
return f.parse(unescape(encodeURIComponent(i)));
|
|
916
914
|
}
|
|
917
|
-
},
|
|
915
|
+
}, h = x.BufferedBlockAlgorithm = n.extend({
|
|
918
916
|
/**
|
|
919
917
|
* Resets this block algorithm's data buffer to its initial state.
|
|
920
918
|
*
|
|
@@ -936,7 +934,7 @@ function M() {
|
|
|
936
934
|
* bufferedBlockAlgorithm._append(wordArray);
|
|
937
935
|
*/
|
|
938
936
|
_append: function(i) {
|
|
939
|
-
typeof i == "string" && (i =
|
|
937
|
+
typeof i == "string" && (i = v.parse(i)), this._data.concat(i), this._nDataBytes += i.sigBytes;
|
|
940
938
|
},
|
|
941
939
|
/**
|
|
942
940
|
* Processes available data blocks.
|
|
@@ -953,13 +951,13 @@ function M() {
|
|
|
953
951
|
* var processedData = bufferedBlockAlgorithm._process(!!'flush');
|
|
954
952
|
*/
|
|
955
953
|
_process: function(i) {
|
|
956
|
-
var o,
|
|
954
|
+
var o, l = this._data, b = l.words, g = l.sigBytes, y = this.blockSize, k = y * 4, R = g / k;
|
|
957
955
|
i ? R = e.ceil(R) : R = e.max((R | 0) - this._minBufferSize, 0);
|
|
958
956
|
var F = R * y, w = e.min(F * 4, g);
|
|
959
957
|
if (F) {
|
|
960
958
|
for (var H = 0; H < F; H += y)
|
|
961
959
|
this._doProcessBlock(b, H);
|
|
962
|
-
o = b.splice(0, F),
|
|
960
|
+
o = b.splice(0, F), l.sigBytes -= w;
|
|
963
961
|
}
|
|
964
962
|
return new E.init(o, w);
|
|
965
963
|
},
|
|
@@ -978,7 +976,7 @@ function M() {
|
|
|
978
976
|
},
|
|
979
977
|
_minBufferSize: 0
|
|
980
978
|
});
|
|
981
|
-
x.Hasher =
|
|
979
|
+
x.Hasher = h.extend({
|
|
982
980
|
/**
|
|
983
981
|
* Configuration options.
|
|
984
982
|
*/
|
|
@@ -1003,7 +1001,7 @@ function M() {
|
|
|
1003
1001
|
* hasher.reset();
|
|
1004
1002
|
*/
|
|
1005
1003
|
reset: function() {
|
|
1006
|
-
|
|
1004
|
+
h.reset.call(this), this._doReset();
|
|
1007
1005
|
},
|
|
1008
1006
|
/**
|
|
1009
1007
|
* Updates this hasher with a message.
|
|
@@ -1054,8 +1052,8 @@ function M() {
|
|
|
1054
1052
|
* var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256);
|
|
1055
1053
|
*/
|
|
1056
1054
|
_createHelper: function(i) {
|
|
1057
|
-
return function(o,
|
|
1058
|
-
return new i.init(
|
|
1055
|
+
return function(o, l) {
|
|
1056
|
+
return new i.init(l).finalize(o);
|
|
1059
1057
|
};
|
|
1060
1058
|
},
|
|
1061
1059
|
/**
|
|
@@ -1072,8 +1070,8 @@ function M() {
|
|
|
1072
1070
|
* var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256);
|
|
1073
1071
|
*/
|
|
1074
1072
|
_createHmacHelper: function(i) {
|
|
1075
|
-
return function(o,
|
|
1076
|
-
return new D.HMAC.init(i,
|
|
1073
|
+
return function(o, l) {
|
|
1074
|
+
return new D.HMAC.init(i, l).finalize(o);
|
|
1077
1075
|
};
|
|
1078
1076
|
}
|
|
1079
1077
|
});
|
|
@@ -1086,12 +1084,12 @@ function M() {
|
|
|
1086
1084
|
}
|
|
1087
1085
|
var k0 = { exports: {} }, Et = k0.exports, qr;
|
|
1088
1086
|
function dr() {
|
|
1089
|
-
return qr || (qr = 1, (function(r,
|
|
1087
|
+
return qr || (qr = 1, (function(r, u) {
|
|
1090
1088
|
(function(t, e) {
|
|
1091
1089
|
r.exports = e(M());
|
|
1092
1090
|
})(Et, function(t) {
|
|
1093
1091
|
return (function(e) {
|
|
1094
|
-
var
|
|
1092
|
+
var d = t, p = d.lib, m = p.Base, B = p.WordArray, C = d.x64 = {};
|
|
1095
1093
|
C.Word = m.extend({
|
|
1096
1094
|
/**
|
|
1097
1095
|
* Initializes a newly created 64-bit word.
|
|
@@ -1316,13 +1314,13 @@ function dr() {
|
|
|
1316
1314
|
}
|
|
1317
1315
|
var S0 = { exports: {} }, At = S0.exports, Tr;
|
|
1318
1316
|
function Ft() {
|
|
1319
|
-
return Tr || (Tr = 1, (function(r,
|
|
1317
|
+
return Tr || (Tr = 1, (function(r, u) {
|
|
1320
1318
|
(function(t, e) {
|
|
1321
1319
|
r.exports = e(M());
|
|
1322
1320
|
})(At, function(t) {
|
|
1323
1321
|
return (function() {
|
|
1324
1322
|
if (typeof ArrayBuffer == "function") {
|
|
1325
|
-
var e = t,
|
|
1323
|
+
var e = t, d = e.lib, p = d.WordArray, m = p.init, B = p.init = function(C) {
|
|
1326
1324
|
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) {
|
|
1327
1325
|
for (var x = C.byteLength, n = [], E = 0; E < x; E++)
|
|
1328
1326
|
n[E >>> 2] |= C[E] << 24 - E % 4 * 8;
|
|
@@ -1330,7 +1328,7 @@ function Ft() {
|
|
|
1330
1328
|
} else
|
|
1331
1329
|
m.apply(this, arguments);
|
|
1332
1330
|
};
|
|
1333
|
-
B.prototype =
|
|
1331
|
+
B.prototype = p;
|
|
1334
1332
|
}
|
|
1335
1333
|
})(), t.lib.WordArray;
|
|
1336
1334
|
});
|
|
@@ -1338,12 +1336,12 @@ function Ft() {
|
|
|
1338
1336
|
}
|
|
1339
1337
|
var H0 = { exports: {} }, gt = H0.exports, Mr;
|
|
1340
1338
|
function Dt() {
|
|
1341
|
-
return Mr || (Mr = 1, (function(r,
|
|
1339
|
+
return Mr || (Mr = 1, (function(r, u) {
|
|
1342
1340
|
(function(t, e) {
|
|
1343
1341
|
r.exports = e(M());
|
|
1344
1342
|
})(gt, function(t) {
|
|
1345
1343
|
return (function() {
|
|
1346
|
-
var e = t,
|
|
1344
|
+
var e = t, d = e.lib, p = d.WordArray, m = e.enc;
|
|
1347
1345
|
m.Utf16 = m.Utf16BE = {
|
|
1348
1346
|
/**
|
|
1349
1347
|
* Converts a word array to a UTF-16 BE string.
|
|
@@ -1381,7 +1379,7 @@ function Dt() {
|
|
|
1381
1379
|
parse: function(C) {
|
|
1382
1380
|
for (var x = C.length, n = [], E = 0; E < x; E++)
|
|
1383
1381
|
n[E >>> 1] |= C.charCodeAt(E) << 16 - E % 2 * 16;
|
|
1384
|
-
return
|
|
1382
|
+
return p.create(n, x * 2);
|
|
1385
1383
|
}
|
|
1386
1384
|
}, m.Utf16LE = {
|
|
1387
1385
|
/**
|
|
@@ -1420,7 +1418,7 @@ function Dt() {
|
|
|
1420
1418
|
parse: function(C) {
|
|
1421
1419
|
for (var x = C.length, n = [], E = 0; E < x; E++)
|
|
1422
1420
|
n[E >>> 1] |= B(C.charCodeAt(E) << 16 - E % 2 * 16);
|
|
1423
|
-
return
|
|
1421
|
+
return p.create(n, x * 2);
|
|
1424
1422
|
}
|
|
1425
1423
|
};
|
|
1426
1424
|
function B(C) {
|
|
@@ -1432,12 +1430,12 @@ function Dt() {
|
|
|
1432
1430
|
}
|
|
1433
1431
|
var $0 = { exports: {} }, bt = $0.exports, Nr;
|
|
1434
1432
|
function s0() {
|
|
1435
|
-
return Nr || (Nr = 1, (function(r,
|
|
1433
|
+
return Nr || (Nr = 1, (function(r, u) {
|
|
1436
1434
|
(function(t, e) {
|
|
1437
1435
|
r.exports = e(M());
|
|
1438
1436
|
})(bt, function(t) {
|
|
1439
1437
|
return (function() {
|
|
1440
|
-
var e = t,
|
|
1438
|
+
var e = t, d = e.lib, p = d.WordArray, m = e.enc;
|
|
1441
1439
|
m.Base64 = {
|
|
1442
1440
|
/**
|
|
1443
1441
|
* Converts a word array to a Base64 string.
|
|
@@ -1456,7 +1454,7 @@ function s0() {
|
|
|
1456
1454
|
var x = C.words, n = C.sigBytes, E = this._map;
|
|
1457
1455
|
C.clamp();
|
|
1458
1456
|
for (var a = [], s = 0; s < n; s += 3)
|
|
1459
|
-
for (var f = x[s >>> 2] >>> 24 - s % 4 * 8 & 255,
|
|
1457
|
+
for (var f = x[s >>> 2] >>> 24 - s % 4 * 8 & 255, v = x[s + 1 >>> 2] >>> 24 - (s + 1) % 4 * 8 & 255, h = x[s + 2 >>> 2] >>> 24 - (s + 2) % 4 * 8 & 255, D = f << 16 | v << 8 | h, i = 0; i < 4 && s + i * 0.75 < n; i++)
|
|
1460
1458
|
a.push(E.charAt(D >>> 6 * (3 - i) & 63));
|
|
1461
1459
|
var o = E.charAt(64);
|
|
1462
1460
|
if (o)
|
|
@@ -1496,10 +1494,10 @@ function s0() {
|
|
|
1496
1494
|
function B(C, x, n) {
|
|
1497
1495
|
for (var E = [], a = 0, s = 0; s < x; s++)
|
|
1498
1496
|
if (s % 4) {
|
|
1499
|
-
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2,
|
|
1500
|
-
E[a >>> 2] |=
|
|
1497
|
+
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2, v = n[C.charCodeAt(s)] >>> 6 - s % 4 * 2, h = f | v;
|
|
1498
|
+
E[a >>> 2] |= h << 24 - a % 4 * 8, a++;
|
|
1501
1499
|
}
|
|
1502
|
-
return
|
|
1500
|
+
return p.create(E, a);
|
|
1503
1501
|
}
|
|
1504
1502
|
})(), t.enc.Base64;
|
|
1505
1503
|
});
|
|
@@ -1507,12 +1505,12 @@ function s0() {
|
|
|
1507
1505
|
}
|
|
1508
1506
|
var R0 = { exports: {} }, mt = R0.exports, Ur;
|
|
1509
1507
|
function _t() {
|
|
1510
|
-
return Ur || (Ur = 1, (function(r,
|
|
1508
|
+
return Ur || (Ur = 1, (function(r, u) {
|
|
1511
1509
|
(function(t, e) {
|
|
1512
1510
|
r.exports = e(M());
|
|
1513
1511
|
})(mt, function(t) {
|
|
1514
1512
|
return (function() {
|
|
1515
|
-
var e = t,
|
|
1513
|
+
var e = t, d = e.lib, p = d.WordArray, m = e.enc;
|
|
1516
1514
|
m.Base64url = {
|
|
1517
1515
|
/**
|
|
1518
1516
|
* Converts a word array to a Base64url string.
|
|
@@ -1534,12 +1532,12 @@ function _t() {
|
|
|
1534
1532
|
var n = C.words, E = C.sigBytes, a = x ? this._safe_map : this._map;
|
|
1535
1533
|
C.clamp();
|
|
1536
1534
|
for (var s = [], f = 0; f < E; f += 3)
|
|
1537
|
-
for (var
|
|
1535
|
+
for (var v = 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 = v << 16 | h << 8 | D, o = 0; o < 4 && f + o * 0.75 < E; o++)
|
|
1538
1536
|
s.push(a.charAt(i >>> 6 * (3 - o) & 63));
|
|
1539
|
-
var
|
|
1540
|
-
if (
|
|
1537
|
+
var l = a.charAt(64);
|
|
1538
|
+
if (l)
|
|
1541
1539
|
for (; s.length % 4; )
|
|
1542
|
-
s.push(
|
|
1540
|
+
s.push(l);
|
|
1543
1541
|
return s.join("");
|
|
1544
1542
|
},
|
|
1545
1543
|
/**
|
|
@@ -1567,8 +1565,8 @@ function _t() {
|
|
|
1567
1565
|
}
|
|
1568
1566
|
var f = E.charAt(64);
|
|
1569
1567
|
if (f) {
|
|
1570
|
-
var
|
|
1571
|
-
|
|
1568
|
+
var v = C.indexOf(f);
|
|
1569
|
+
v !== -1 && (n = v);
|
|
1572
1570
|
}
|
|
1573
1571
|
return B(C, n, a);
|
|
1574
1572
|
},
|
|
@@ -1578,10 +1576,10 @@ function _t() {
|
|
|
1578
1576
|
function B(C, x, n) {
|
|
1579
1577
|
for (var E = [], a = 0, s = 0; s < x; s++)
|
|
1580
1578
|
if (s % 4) {
|
|
1581
|
-
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2,
|
|
1582
|
-
E[a >>> 2] |=
|
|
1579
|
+
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2, v = n[C.charCodeAt(s)] >>> 6 - s % 4 * 2, h = f | v;
|
|
1580
|
+
E[a >>> 2] |= h << 24 - a % 4 * 8, a++;
|
|
1583
1581
|
}
|
|
1584
|
-
return
|
|
1582
|
+
return p.create(E, a);
|
|
1585
1583
|
}
|
|
1586
1584
|
})(), t.enc.Base64url;
|
|
1587
1585
|
});
|
|
@@ -1589,15 +1587,15 @@ function _t() {
|
|
|
1589
1587
|
}
|
|
1590
1588
|
var P0 = { exports: {} }, yt = P0.exports, jr;
|
|
1591
1589
|
function c0() {
|
|
1592
|
-
return jr || (jr = 1, (function(r,
|
|
1590
|
+
return jr || (jr = 1, (function(r, u) {
|
|
1593
1591
|
(function(t, e) {
|
|
1594
1592
|
r.exports = e(M());
|
|
1595
1593
|
})(yt, function(t) {
|
|
1596
1594
|
return (function(e) {
|
|
1597
|
-
var
|
|
1595
|
+
var d = t, p = d.lib, m = p.WordArray, B = p.Hasher, C = d.algo, x = [];
|
|
1598
1596
|
(function() {
|
|
1599
|
-
for (var
|
|
1600
|
-
x[
|
|
1597
|
+
for (var v = 0; v < 64; v++)
|
|
1598
|
+
x[v] = e.abs(e.sin(v + 1)) * 4294967296 | 0;
|
|
1601
1599
|
})();
|
|
1602
1600
|
var n = C.MD5 = B.extend({
|
|
1603
1601
|
_doReset: function() {
|
|
@@ -1608,19 +1606,19 @@ function c0() {
|
|
|
1608
1606
|
271733878
|
|
1609
1607
|
]);
|
|
1610
1608
|
},
|
|
1611
|
-
_doProcessBlock: function(
|
|
1609
|
+
_doProcessBlock: function(v, h) {
|
|
1612
1610
|
for (var D = 0; D < 16; D++) {
|
|
1613
|
-
var i =
|
|
1614
|
-
|
|
1611
|
+
var i = h + D, o = v[i];
|
|
1612
|
+
v[i] = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360;
|
|
1615
1613
|
}
|
|
1616
|
-
var
|
|
1617
|
-
S = E(S, c, A, _, b, 7, x[0]), _ = E(_, S, c, A, g, 12, x[1]), A = E(A, _, S, c, y, 17, x[2]), c = E(c, A, _, S, k, 22, x[3]), S = E(S, c, A, _, R, 7, x[4]), _ = E(_, S, c, A, F, 12, x[5]), A = E(A, _, S, c, w, 17, x[6]), c = E(c, A, _, S, H, 22, x[7]), S = E(S, c, A, _, $, 7, x[8]), _ = E(_, S, c, A,
|
|
1614
|
+
var l = this._hash.words, b = v[h + 0], g = v[h + 1], y = v[h + 2], k = v[h + 3], R = v[h + 4], F = v[h + 5], w = v[h + 6], H = v[h + 7], $ = v[h + 8], z = v[h + 9], O = v[h + 10], q = v[h + 11], U = v[h + 12], T = v[h + 13], N = v[h + 14], j = v[h + 15], S = l[0], c = l[1], A = l[2], _ = l[3];
|
|
1615
|
+
S = E(S, c, A, _, b, 7, x[0]), _ = E(_, S, c, A, g, 12, x[1]), A = E(A, _, S, c, y, 17, x[2]), c = E(c, A, _, S, k, 22, x[3]), S = E(S, c, A, _, R, 7, x[4]), _ = E(_, S, c, A, F, 12, x[5]), A = E(A, _, S, c, w, 17, x[6]), c = E(c, A, _, S, H, 22, x[7]), S = E(S, c, A, _, $, 7, x[8]), _ = E(_, S, c, A, z, 12, x[9]), A = E(A, _, S, c, O, 17, x[10]), c = E(c, A, _, S, q, 22, x[11]), S = E(S, c, A, _, U, 7, x[12]), _ = E(_, S, c, A, T, 12, x[13]), A = E(A, _, S, c, N, 17, x[14]), c = E(c, A, _, S, j, 22, x[15]), S = a(S, c, A, _, g, 5, x[16]), _ = a(_, S, c, A, w, 9, x[17]), A = a(A, _, S, c, q, 14, x[18]), c = a(c, A, _, S, b, 20, x[19]), S = a(S, c, A, _, F, 5, x[20]), _ = a(_, S, c, A, O, 9, x[21]), A = a(A, _, S, c, j, 14, x[22]), c = a(c, A, _, S, R, 20, x[23]), S = a(S, c, A, _, z, 5, x[24]), _ = a(_, S, c, A, N, 9, x[25]), A = a(A, _, S, c, k, 14, x[26]), c = a(c, A, _, S, $, 20, x[27]), S = a(S, c, A, _, T, 5, x[28]), _ = a(_, S, c, A, y, 9, x[29]), A = a(A, _, S, c, H, 14, x[30]), c = a(c, A, _, S, U, 20, x[31]), S = s(S, c, A, _, F, 4, x[32]), _ = s(_, S, c, A, $, 11, x[33]), A = s(A, _, S, c, q, 16, x[34]), c = s(c, A, _, S, N, 23, x[35]), S = s(S, c, A, _, g, 4, x[36]), _ = s(_, S, c, A, R, 11, x[37]), A = s(A, _, S, c, H, 16, x[38]), c = s(c, A, _, S, O, 23, x[39]), S = s(S, c, A, _, T, 4, x[40]), _ = s(_, S, c, A, b, 11, x[41]), A = s(A, _, S, c, k, 16, x[42]), c = s(c, A, _, S, w, 23, x[43]), S = s(S, c, A, _, z, 4, x[44]), _ = s(_, S, c, A, U, 11, x[45]), A = s(A, _, S, c, j, 16, x[46]), c = s(c, A, _, S, y, 23, x[47]), S = f(S, c, A, _, b, 6, x[48]), _ = f(_, S, c, A, H, 10, x[49]), A = f(A, _, S, c, N, 15, x[50]), c = f(c, A, _, S, F, 21, x[51]), S = f(S, c, A, _, U, 6, x[52]), _ = f(_, S, c, A, k, 10, x[53]), A = f(A, _, S, c, O, 15, x[54]), c = f(c, A, _, S, g, 21, x[55]), S = f(S, c, A, _, $, 6, x[56]), _ = f(_, S, c, A, j, 10, x[57]), A = f(A, _, S, c, w, 15, x[58]), c = f(c, A, _, S, T, 21, x[59]), S = f(S, c, A, _, R, 6, x[60]), _ = f(_, S, c, A, q, 10, x[61]), A = f(A, _, S, c, y, 15, x[62]), c = f(c, A, _, 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] + _ | 0;
|
|
1618
1616
|
},
|
|
1619
1617
|
_doFinalize: function() {
|
|
1620
|
-
var
|
|
1621
|
-
|
|
1622
|
-
var o = e.floor(D / 4294967296),
|
|
1623
|
-
|
|
1618
|
+
var v = this._data, h = v.words, D = this._nDataBytes * 8, i = v.sigBytes * 8;
|
|
1619
|
+
h[i >>> 5] |= 128 << 24 - i % 32;
|
|
1620
|
+
var o = e.floor(D / 4294967296), l = D;
|
|
1621
|
+
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, v.sigBytes = (h.length + 1) * 4, this._process();
|
|
1624
1622
|
for (var b = this._hash, g = b.words, y = 0; y < 4; y++) {
|
|
1625
1623
|
var k = g[y];
|
|
1626
1624
|
g[y] = (k << 8 | k >>> 24) & 16711935 | (k << 24 | k >>> 8) & 4278255360;
|
|
@@ -1628,41 +1626,41 @@ function c0() {
|
|
|
1628
1626
|
return b;
|
|
1629
1627
|
},
|
|
1630
1628
|
clone: function() {
|
|
1631
|
-
var
|
|
1632
|
-
return
|
|
1629
|
+
var v = B.clone.call(this);
|
|
1630
|
+
return v._hash = this._hash.clone(), v;
|
|
1633
1631
|
}
|
|
1634
1632
|
});
|
|
1635
|
-
function E(
|
|
1636
|
-
var g =
|
|
1637
|
-
return (g <<
|
|
1633
|
+
function E(v, h, D, i, o, l, b) {
|
|
1634
|
+
var g = v + (h & D | ~h & i) + o + b;
|
|
1635
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1638
1636
|
}
|
|
1639
|
-
function a(
|
|
1640
|
-
var g =
|
|
1641
|
-
return (g <<
|
|
1637
|
+
function a(v, h, D, i, o, l, b) {
|
|
1638
|
+
var g = v + (h & i | D & ~i) + o + b;
|
|
1639
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1642
1640
|
}
|
|
1643
|
-
function s(
|
|
1644
|
-
var g =
|
|
1645
|
-
return (g <<
|
|
1641
|
+
function s(v, h, D, i, o, l, b) {
|
|
1642
|
+
var g = v + (h ^ D ^ i) + o + b;
|
|
1643
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1646
1644
|
}
|
|
1647
|
-
function f(
|
|
1648
|
-
var g =
|
|
1649
|
-
return (g <<
|
|
1645
|
+
function f(v, h, D, i, o, l, b) {
|
|
1646
|
+
var g = v + (D ^ (h | ~i)) + o + b;
|
|
1647
|
+
return (g << l | g >>> 32 - l) + h;
|
|
1650
1648
|
}
|
|
1651
|
-
|
|
1649
|
+
d.MD5 = B._createHelper(n), d.HmacMD5 = B._createHmacHelper(n);
|
|
1652
1650
|
})(Math), t.MD5;
|
|
1653
1651
|
});
|
|
1654
1652
|
})(P0)), P0.exports;
|
|
1655
1653
|
}
|
|
1656
|
-
var
|
|
1654
|
+
var z0 = { exports: {} }, wt = z0.exports, Gr;
|
|
1657
1655
|
function ke() {
|
|
1658
|
-
return Gr || (Gr = 1, (function(r,
|
|
1656
|
+
return Gr || (Gr = 1, (function(r, u) {
|
|
1659
1657
|
(function(t, e) {
|
|
1660
1658
|
r.exports = e(M());
|
|
1661
1659
|
})(wt, function(t) {
|
|
1662
1660
|
return (function() {
|
|
1663
|
-
var e = t,
|
|
1661
|
+
var e = t, d = e.lib, p = d.WordArray, m = d.Hasher, B = e.algo, C = [], x = B.SHA1 = m.extend({
|
|
1664
1662
|
_doReset: function() {
|
|
1665
|
-
this._hash = new
|
|
1663
|
+
this._hash = new p.init([
|
|
1666
1664
|
1732584193,
|
|
1667
1665
|
4023233417,
|
|
1668
1666
|
2562383102,
|
|
@@ -1671,17 +1669,17 @@ function ke() {
|
|
|
1671
1669
|
]);
|
|
1672
1670
|
},
|
|
1673
1671
|
_doProcessBlock: function(n, E) {
|
|
1674
|
-
for (var a = this._hash.words, s = a[0], f = a[1],
|
|
1672
|
+
for (var a = this._hash.words, s = a[0], f = a[1], v = a[2], h = a[3], D = a[4], i = 0; i < 80; i++) {
|
|
1675
1673
|
if (i < 16)
|
|
1676
1674
|
C[i] = n[E + i] | 0;
|
|
1677
1675
|
else {
|
|
1678
1676
|
var o = C[i - 3] ^ C[i - 8] ^ C[i - 14] ^ C[i - 16];
|
|
1679
1677
|
C[i] = o << 1 | o >>> 31;
|
|
1680
1678
|
}
|
|
1681
|
-
var
|
|
1682
|
-
i < 20 ?
|
|
1679
|
+
var l = (s << 5 | s >>> 27) + D + C[i];
|
|
1680
|
+
i < 20 ? l += (f & v | ~f & h) + 1518500249 : i < 40 ? l += (f ^ v ^ h) + 1859775393 : i < 60 ? l += (f & v | f & h | v & h) - 1894007588 : l += (f ^ v ^ h) - 899497514, D = h, h = v, v = f << 30 | f >>> 2, f = s, s = l;
|
|
1683
1681
|
}
|
|
1684
|
-
a[0] = a[0] + s | 0, a[1] = a[1] + f | 0, a[2] = a[2] +
|
|
1682
|
+
a[0] = a[0] + s | 0, a[1] = a[1] + f | 0, a[2] = a[2] + v | 0, a[3] = a[3] + h | 0, a[4] = a[4] + D | 0;
|
|
1685
1683
|
},
|
|
1686
1684
|
_doFinalize: function() {
|
|
1687
1685
|
var n = this._data, E = n.words, a = this._nDataBytes * 8, s = n.sigBytes * 8;
|
|
@@ -1695,16 +1693,16 @@ function ke() {
|
|
|
1695
1693
|
e.SHA1 = m._createHelper(x), e.HmacSHA1 = m._createHmacHelper(x);
|
|
1696
1694
|
})(), t.SHA1;
|
|
1697
1695
|
});
|
|
1698
|
-
})(
|
|
1696
|
+
})(z0)), z0.exports;
|
|
1699
1697
|
}
|
|
1700
|
-
var
|
|
1698
|
+
var W0 = { exports: {} }, kt = W0.exports, Kr;
|
|
1701
1699
|
function Fr() {
|
|
1702
|
-
return Kr || (Kr = 1, (function(r,
|
|
1700
|
+
return Kr || (Kr = 1, (function(r, u) {
|
|
1703
1701
|
(function(t, e) {
|
|
1704
1702
|
r.exports = e(M());
|
|
1705
1703
|
})(kt, function(t) {
|
|
1706
1704
|
return (function(e) {
|
|
1707
|
-
var
|
|
1705
|
+
var d = t, p = d.lib, m = p.WordArray, B = p.Hasher, C = d.algo, x = [], n = [];
|
|
1708
1706
|
(function() {
|
|
1709
1707
|
function s(D) {
|
|
1710
1708
|
for (var i = e.sqrt(D), o = 2; o <= i; o++)
|
|
@@ -1715,50 +1713,50 @@ function Fr() {
|
|
|
1715
1713
|
function f(D) {
|
|
1716
1714
|
return (D - (D | 0)) * 4294967296 | 0;
|
|
1717
1715
|
}
|
|
1718
|
-
for (var
|
|
1719
|
-
s(
|
|
1716
|
+
for (var v = 2, h = 0; h < 64; )
|
|
1717
|
+
s(v) && (h < 8 && (x[h] = f(e.pow(v, 1 / 2))), n[h] = f(e.pow(v, 1 / 3)), h++), v++;
|
|
1720
1718
|
})();
|
|
1721
1719
|
var E = [], a = C.SHA256 = B.extend({
|
|
1722
1720
|
_doReset: function() {
|
|
1723
1721
|
this._hash = new m.init(x.slice(0));
|
|
1724
1722
|
},
|
|
1725
1723
|
_doProcessBlock: function(s, f) {
|
|
1726
|
-
for (var
|
|
1724
|
+
for (var v = this._hash.words, h = v[0], D = v[1], i = v[2], o = v[3], l = v[4], b = v[5], g = v[6], y = v[7], k = 0; k < 64; k++) {
|
|
1727
1725
|
if (k < 16)
|
|
1728
1726
|
E[k] = s[f + k] | 0;
|
|
1729
1727
|
else {
|
|
1730
1728
|
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;
|
|
1731
1729
|
E[k] = F + E[k - 7] + H + E[k - 16];
|
|
1732
1730
|
}
|
|
1733
|
-
var $ =
|
|
1734
|
-
y = g, g = b, b =
|
|
1731
|
+
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;
|
|
1732
|
+
y = g, g = b, b = l, l = o + U | 0, o = i, i = D, D = h, h = U + T | 0;
|
|
1735
1733
|
}
|
|
1736
|
-
|
|
1734
|
+
v[0] = v[0] + h | 0, v[1] = v[1] + D | 0, v[2] = v[2] + i | 0, v[3] = v[3] + o | 0, v[4] = v[4] + l | 0, v[5] = v[5] + b | 0, v[6] = v[6] + g | 0, v[7] = v[7] + y | 0;
|
|
1737
1735
|
},
|
|
1738
1736
|
_doFinalize: function() {
|
|
1739
|
-
var s = this._data, f = s.words,
|
|
1740
|
-
return f[
|
|
1737
|
+
var s = this._data, f = s.words, v = this._nDataBytes * 8, h = s.sigBytes * 8;
|
|
1738
|
+
return f[h >>> 5] |= 128 << 24 - h % 32, f[(h + 64 >>> 9 << 4) + 14] = e.floor(v / 4294967296), f[(h + 64 >>> 9 << 4) + 15] = v, s.sigBytes = f.length * 4, this._process(), this._hash;
|
|
1741
1739
|
},
|
|
1742
1740
|
clone: function() {
|
|
1743
1741
|
var s = B.clone.call(this);
|
|
1744
1742
|
return s._hash = this._hash.clone(), s;
|
|
1745
1743
|
}
|
|
1746
1744
|
});
|
|
1747
|
-
|
|
1745
|
+
d.SHA256 = B._createHelper(a), d.HmacSHA256 = B._createHmacHelper(a);
|
|
1748
1746
|
})(Math), t.SHA256;
|
|
1749
1747
|
});
|
|
1750
|
-
})(
|
|
1748
|
+
})(W0)), W0.exports;
|
|
1751
1749
|
}
|
|
1752
1750
|
var I0 = { exports: {} }, St = I0.exports, Xr;
|
|
1753
1751
|
function Ht() {
|
|
1754
|
-
return Xr || (Xr = 1, (function(r,
|
|
1755
|
-
(function(t, e,
|
|
1752
|
+
return Xr || (Xr = 1, (function(r, u) {
|
|
1753
|
+
(function(t, e, d) {
|
|
1756
1754
|
r.exports = e(M(), Fr());
|
|
1757
1755
|
})(St, function(t) {
|
|
1758
1756
|
return (function() {
|
|
1759
|
-
var e = t,
|
|
1757
|
+
var e = t, d = e.lib, p = d.WordArray, m = e.algo, B = m.SHA256, C = m.SHA224 = B.extend({
|
|
1760
1758
|
_doReset: function() {
|
|
1761
|
-
this._hash = new
|
|
1759
|
+
this._hash = new p.init([
|
|
1762
1760
|
3238371032,
|
|
1763
1761
|
914150663,
|
|
1764
1762
|
812702999,
|
|
@@ -1779,14 +1777,14 @@ function Ht() {
|
|
|
1779
1777
|
});
|
|
1780
1778
|
})(I0)), I0.exports;
|
|
1781
1779
|
}
|
|
1782
|
-
var L0 = { exports: {} }, $t = L0.exports,
|
|
1780
|
+
var L0 = { exports: {} }, $t = L0.exports, Yr;
|
|
1783
1781
|
function Se() {
|
|
1784
|
-
return
|
|
1785
|
-
(function(t, e,
|
|
1782
|
+
return Yr || (Yr = 1, (function(r, u) {
|
|
1783
|
+
(function(t, e, d) {
|
|
1786
1784
|
r.exports = e(M(), dr());
|
|
1787
1785
|
})($t, function(t) {
|
|
1788
1786
|
return (function() {
|
|
1789
|
-
var e = t,
|
|
1787
|
+
var e = t, d = e.lib, p = d.Hasher, m = e.x64, B = m.Word, C = m.WordArray, x = e.algo;
|
|
1790
1788
|
function n() {
|
|
1791
1789
|
return B.create.apply(B, arguments);
|
|
1792
1790
|
}
|
|
@@ -1876,7 +1874,7 @@ function Se() {
|
|
|
1876
1874
|
for (var f = 0; f < 80; f++)
|
|
1877
1875
|
a[f] = n();
|
|
1878
1876
|
})();
|
|
1879
|
-
var s = x.SHA512 =
|
|
1877
|
+
var s = x.SHA512 = p.extend({
|
|
1880
1878
|
_doReset: function() {
|
|
1881
1879
|
this._hash = new C.init([
|
|
1882
1880
|
new B.init(1779033703, 4089235720),
|
|
@@ -1889,55 +1887,55 @@ function Se() {
|
|
|
1889
1887
|
new B.init(1541459225, 327033209)
|
|
1890
1888
|
]);
|
|
1891
1889
|
},
|
|
1892
|
-
_doProcessBlock: function(f,
|
|
1893
|
-
for (var
|
|
1894
|
-
var J, x0, b0 = a[
|
|
1895
|
-
if (
|
|
1896
|
-
x0 = b0.high = f[
|
|
1890
|
+
_doProcessBlock: function(f, v) {
|
|
1891
|
+
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, _ = k.low, W = R, P = F, L = w, I = H, Z = $, Q = z, o0 = O, K = q, G = U, Y = T, e0 = N, f0 = j, D0 = S, p0 = c, ur = A, B0 = _, t0 = 0; t0 < 80; t0++) {
|
|
1892
|
+
var J, x0, b0 = a[t0];
|
|
1893
|
+
if (t0 < 16)
|
|
1894
|
+
x0 = b0.high = f[v + t0 * 2] | 0, J = b0.low = f[v + t0 * 2 + 1] | 0;
|
|
1897
1895
|
else {
|
|
1898
|
-
var br = a[
|
|
1896
|
+
var br = a[t0 - 15], d0 = br.high, C0 = br.low, Ie = (d0 >>> 1 | C0 << 31) ^ (d0 >>> 8 | C0 << 24) ^ d0 >>> 7, mr = (C0 >>> 1 | d0 << 31) ^ (C0 >>> 8 | d0 << 24) ^ (C0 >>> 7 | d0 << 25), _r = a[t0 - 2], u0 = _r.high, E0 = _r.low, Le = (u0 >>> 19 | E0 << 13) ^ (u0 << 3 | E0 >>> 29) ^ u0 >>> 6, yr = (E0 >>> 19 | u0 << 13) ^ (E0 << 3 | u0 >>> 29) ^ (E0 >>> 6 | u0 << 26), wr = a[t0 - 7], Oe = wr.high, qe = wr.low, kr = a[t0 - 16], Te = kr.high, Sr = kr.low;
|
|
1899
1897
|
J = mr + qe, x0 = Ie + Oe + (J >>> 0 < mr >>> 0 ? 1 : 0), J = J + yr, x0 = x0 + Le + (J >>> 0 < yr >>> 0 ? 1 : 0), J = J + Sr, x0 = x0 + Te + (J >>> 0 < Sr >>> 0 ? 1 : 0), b0.high = x0, b0.low = J;
|
|
1900
1898
|
}
|
|
1901
|
-
var Me = G &
|
|
1902
|
-
|
|
1899
|
+
var Me = G & e0 ^ ~G & D0, Hr = Y & f0 ^ ~Y & p0, Ne = W & L ^ W & Z ^ L & Z, Ue = P & I ^ P & Q ^ I & Q, je = (W >>> 28 | P << 4) ^ (W << 30 | P >>> 2) ^ (W << 25 | P >>> 7), $r = (P >>> 28 | W << 4) ^ (P << 30 | W >>> 2) ^ (P << 25 | W >>> 7), Ge = (G >>> 14 | Y << 18) ^ (G >>> 18 | Y << 14) ^ (G << 23 | Y >>> 9), Ke = (Y >>> 14 | G << 18) ^ (Y >>> 18 | G << 14) ^ (Y << 23 | G >>> 9), Rr = E[t0], Xe = Rr.high, Pr = Rr.low, V = B0 + Ke, n0 = ur + Ge + (V >>> 0 < B0 >>> 0 ? 1 : 0), V = V + Hr, n0 = n0 + Me + (V >>> 0 < Hr >>> 0 ? 1 : 0), V = V + Pr, n0 = n0 + Xe + (V >>> 0 < Pr >>> 0 ? 1 : 0), V = V + J, n0 = n0 + x0 + (V >>> 0 < J >>> 0 ? 1 : 0), zr = $r + Ue, Ye = je + Ne + (zr >>> 0 < $r >>> 0 ? 1 : 0);
|
|
1900
|
+
ur = D0, B0 = p0, D0 = e0, p0 = f0, e0 = G, f0 = Y, Y = K + V | 0, G = o0 + n0 + (Y >>> 0 < K >>> 0 ? 1 : 0) | 0, o0 = Z, K = Q, Z = L, Q = I, L = W, I = P, P = V + zr | 0, W = n0 + Ye + (P >>> 0 < V >>> 0 ? 1 : 0) | 0;
|
|
1903
1901
|
}
|
|
1904
|
-
F = D.low = F + P, D.high = R +
|
|
1902
|
+
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 = $ + Z + (z >>> 0 < Q >>> 0 ? 1 : 0), q = l.low = q + K, l.high = O + o0 + (q >>> 0 < K >>> 0 ? 1 : 0), T = b.low = T + Y, b.high = U + G + (T >>> 0 < Y >>> 0 ? 1 : 0), j = g.low = j + f0, g.high = N + e0 + (j >>> 0 < f0 >>> 0 ? 1 : 0), c = y.low = c + p0, y.high = S + D0 + (c >>> 0 < p0 >>> 0 ? 1 : 0), _ = k.low = _ + B0, k.high = A + ur + (_ >>> 0 < B0 >>> 0 ? 1 : 0);
|
|
1905
1903
|
},
|
|
1906
1904
|
_doFinalize: function() {
|
|
1907
|
-
var f = this._data,
|
|
1908
|
-
|
|
1905
|
+
var f = this._data, v = f.words, h = this._nDataBytes * 8, D = f.sigBytes * 8;
|
|
1906
|
+
v[D >>> 5] |= 128 << 24 - D % 32, v[(D + 128 >>> 10 << 5) + 30] = Math.floor(h / 4294967296), v[(D + 128 >>> 10 << 5) + 31] = h, f.sigBytes = v.length * 4, this._process();
|
|
1909
1907
|
var i = this._hash.toX32();
|
|
1910
1908
|
return i;
|
|
1911
1909
|
},
|
|
1912
1910
|
clone: function() {
|
|
1913
|
-
var f =
|
|
1911
|
+
var f = p.clone.call(this);
|
|
1914
1912
|
return f._hash = this._hash.clone(), f;
|
|
1915
1913
|
},
|
|
1916
1914
|
blockSize: 1024 / 32
|
|
1917
1915
|
});
|
|
1918
|
-
e.SHA512 =
|
|
1916
|
+
e.SHA512 = p._createHelper(s), e.HmacSHA512 = p._createHmacHelper(s);
|
|
1919
1917
|
})(), t.SHA512;
|
|
1920
1918
|
});
|
|
1921
1919
|
})(L0)), L0.exports;
|
|
1922
1920
|
}
|
|
1923
|
-
var O0 = { exports: {} }, Rt = O0.exports,
|
|
1921
|
+
var O0 = { exports: {} }, Rt = O0.exports, Zr;
|
|
1924
1922
|
function Pt() {
|
|
1925
|
-
return
|
|
1926
|
-
(function(t, e,
|
|
1923
|
+
return Zr || (Zr = 1, (function(r, u) {
|
|
1924
|
+
(function(t, e, d) {
|
|
1927
1925
|
r.exports = e(M(), dr(), Se());
|
|
1928
1926
|
})(Rt, function(t) {
|
|
1929
1927
|
return (function() {
|
|
1930
|
-
var e = t,
|
|
1928
|
+
var e = t, d = e.x64, p = d.Word, m = d.WordArray, B = e.algo, C = B.SHA512, x = B.SHA384 = C.extend({
|
|
1931
1929
|
_doReset: function() {
|
|
1932
1930
|
this._hash = new m.init([
|
|
1933
|
-
new
|
|
1934
|
-
new
|
|
1935
|
-
new
|
|
1936
|
-
new
|
|
1937
|
-
new
|
|
1938
|
-
new
|
|
1939
|
-
new
|
|
1940
|
-
new
|
|
1931
|
+
new p.init(3418070365, 3238371032),
|
|
1932
|
+
new p.init(1654270250, 914150663),
|
|
1933
|
+
new p.init(2438529370, 812702999),
|
|
1934
|
+
new p.init(355462360, 4144912697),
|
|
1935
|
+
new p.init(1731405415, 4290775857),
|
|
1936
|
+
new p.init(2394180231, 1750603025),
|
|
1937
|
+
new p.init(3675008525, 1694076839),
|
|
1938
|
+
new p.init(1203062813, 3204075428)
|
|
1941
1939
|
]);
|
|
1942
1940
|
},
|
|
1943
1941
|
_doFinalize: function() {
|
|
@@ -1950,23 +1948,23 @@ function Pt() {
|
|
|
1950
1948
|
});
|
|
1951
1949
|
})(O0)), O0.exports;
|
|
1952
1950
|
}
|
|
1953
|
-
var q0 = { exports: {} },
|
|
1954
|
-
function
|
|
1955
|
-
return Qr || (Qr = 1, (function(r,
|
|
1956
|
-
(function(t, e,
|
|
1951
|
+
var q0 = { exports: {} }, zt = q0.exports, Qr;
|
|
1952
|
+
function Wt() {
|
|
1953
|
+
return Qr || (Qr = 1, (function(r, u) {
|
|
1954
|
+
(function(t, e, d) {
|
|
1957
1955
|
r.exports = e(M(), dr());
|
|
1958
|
-
})(
|
|
1956
|
+
})(zt, function(t) {
|
|
1959
1957
|
return (function(e) {
|
|
1960
|
-
var
|
|
1958
|
+
var d = t, p = d.lib, m = p.WordArray, B = p.Hasher, C = d.x64, x = C.Word, n = d.algo, E = [], a = [], s = [];
|
|
1961
1959
|
(function() {
|
|
1962
|
-
for (var
|
|
1963
|
-
E[
|
|
1964
|
-
var o = D % 5,
|
|
1965
|
-
|
|
1960
|
+
for (var h = 1, D = 0, i = 0; i < 24; i++) {
|
|
1961
|
+
E[h + 5 * D] = (i + 1) * (i + 2) / 2 % 64;
|
|
1962
|
+
var o = D % 5, l = (2 * h + 3 * D) % 5;
|
|
1963
|
+
h = o, D = l;
|
|
1966
1964
|
}
|
|
1967
|
-
for (var
|
|
1965
|
+
for (var h = 0; h < 5; h++)
|
|
1968
1966
|
for (var D = 0; D < 5; D++)
|
|
1969
|
-
a[
|
|
1967
|
+
a[h + 5 * D] = D + (2 * h + 3 * D) % 5 * 5;
|
|
1970
1968
|
for (var b = 1, g = 0; g < 24; g++) {
|
|
1971
1969
|
for (var y = 0, k = 0, R = 0; R < 7; R++) {
|
|
1972
1970
|
if (b & 1) {
|
|
@@ -1980,10 +1978,10 @@ function zt() {
|
|
|
1980
1978
|
})();
|
|
1981
1979
|
var f = [];
|
|
1982
1980
|
(function() {
|
|
1983
|
-
for (var
|
|
1984
|
-
f[
|
|
1981
|
+
for (var h = 0; h < 25; h++)
|
|
1982
|
+
f[h] = x.create();
|
|
1985
1983
|
})();
|
|
1986
|
-
var
|
|
1984
|
+
var v = n.SHA3 = B.extend({
|
|
1987
1985
|
/**
|
|
1988
1986
|
* Configuration options.
|
|
1989
1987
|
*
|
|
@@ -1996,15 +1994,15 @@ function zt() {
|
|
|
1996
1994
|
outputLength: 512
|
|
1997
1995
|
}),
|
|
1998
1996
|
_doReset: function() {
|
|
1999
|
-
for (var
|
|
2000
|
-
|
|
1997
|
+
for (var h = this._state = [], D = 0; D < 25; D++)
|
|
1998
|
+
h[D] = new x.init();
|
|
2001
1999
|
this.blockSize = (1600 - 2 * this.cfg.outputLength) / 32;
|
|
2002
2000
|
},
|
|
2003
|
-
_doProcessBlock: function(
|
|
2004
|
-
for (var i = this._state, o = this.blockSize / 2,
|
|
2005
|
-
var b =
|
|
2001
|
+
_doProcessBlock: function(h, D) {
|
|
2002
|
+
for (var i = this._state, o = this.blockSize / 2, l = 0; l < o; l++) {
|
|
2003
|
+
var b = h[D + 2 * l], g = h[D + 2 * l + 1];
|
|
2006
2004
|
b = (b << 8 | b >>> 24) & 16711935 | (b << 24 | b >>> 8) & 4278255360, g = (g << 8 | g >>> 24) & 16711935 | (g << 24 | g >>> 8) & 4278255360;
|
|
2007
|
-
var y = i[
|
|
2005
|
+
var y = i[l];
|
|
2008
2006
|
y.high ^= g, y.low ^= b;
|
|
2009
2007
|
}
|
|
2010
2008
|
for (var k = 0; k < 24; k++) {
|
|
@@ -2017,7 +2015,7 @@ function zt() {
|
|
|
2017
2015
|
$.high = F, $.low = w;
|
|
2018
2016
|
}
|
|
2019
2017
|
for (var R = 0; R < 5; R++)
|
|
2020
|
-
for (var
|
|
2018
|
+
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++) {
|
|
2021
2019
|
var y = i[R + 5 * H];
|
|
2022
2020
|
y.high ^= F, y.low ^= w;
|
|
2023
2021
|
}
|
|
@@ -2031,43 +2029,43 @@ function zt() {
|
|
|
2031
2029
|
A.high = _.high, A.low = _.low;
|
|
2032
2030
|
for (var R = 0; R < 5; R++)
|
|
2033
2031
|
for (var H = 0; H < 5; H++) {
|
|
2034
|
-
var T = R + 5 * H, y = i[T],
|
|
2035
|
-
y.high =
|
|
2032
|
+
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];
|
|
2033
|
+
y.high = W.high ^ ~P.high & L.high, y.low = W.low ^ ~P.low & L.low;
|
|
2036
2034
|
}
|
|
2037
2035
|
var y = i[0], I = s[k];
|
|
2038
2036
|
y.high ^= I.high, y.low ^= I.low;
|
|
2039
2037
|
}
|
|
2040
2038
|
},
|
|
2041
2039
|
_doFinalize: function() {
|
|
2042
|
-
var
|
|
2040
|
+
var h = this._data, D = h.words;
|
|
2043
2041
|
this._nDataBytes * 8;
|
|
2044
|
-
var i =
|
|
2045
|
-
D[i >>> 5] |= 1 << 24 - i % 32, D[(e.ceil((i + 1) / o) * o >>> 5) - 1] |= 128,
|
|
2046
|
-
for (var
|
|
2047
|
-
var R =
|
|
2042
|
+
var i = h.sigBytes * 8, o = this.blockSize * 32;
|
|
2043
|
+
D[i >>> 5] |= 1 << 24 - i % 32, D[(e.ceil((i + 1) / o) * o >>> 5) - 1] |= 128, h.sigBytes = D.length * 4, this._process();
|
|
2044
|
+
for (var l = this._state, b = this.cfg.outputLength / 8, g = b / 8, y = [], k = 0; k < g; k++) {
|
|
2045
|
+
var R = l[k], F = R.high, w = R.low;
|
|
2048
2046
|
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);
|
|
2049
2047
|
}
|
|
2050
2048
|
return new m.init(y, b);
|
|
2051
2049
|
},
|
|
2052
2050
|
clone: function() {
|
|
2053
|
-
for (var
|
|
2051
|
+
for (var h = B.clone.call(this), D = h._state = this._state.slice(0), i = 0; i < 25; i++)
|
|
2054
2052
|
D[i] = D[i].clone();
|
|
2055
|
-
return
|
|
2053
|
+
return h;
|
|
2056
2054
|
}
|
|
2057
2055
|
});
|
|
2058
|
-
|
|
2056
|
+
d.SHA3 = B._createHelper(v), d.HmacSHA3 = B._createHmacHelper(v);
|
|
2059
2057
|
})(Math), t.SHA3;
|
|
2060
2058
|
});
|
|
2061
2059
|
})(q0)), q0.exports;
|
|
2062
2060
|
}
|
|
2063
2061
|
var T0 = { exports: {} }, It = T0.exports, Vr;
|
|
2064
2062
|
function Lt() {
|
|
2065
|
-
return Vr || (Vr = 1, (function(r,
|
|
2063
|
+
return Vr || (Vr = 1, (function(r, u) {
|
|
2066
2064
|
(function(t, e) {
|
|
2067
2065
|
r.exports = e(M());
|
|
2068
2066
|
})(It, function(t) {
|
|
2069
2067
|
return (function(e) {
|
|
2070
|
-
var
|
|
2068
|
+
var d = t, p = d.lib, m = p.WordArray, B = p.Hasher, C = d.algo, x = m.create([
|
|
2071
2069
|
0,
|
|
2072
2070
|
1,
|
|
2073
2071
|
2,
|
|
@@ -2391,7 +2389,7 @@ function Lt() {
|
|
|
2391
2389
|
13,
|
|
2392
2390
|
11,
|
|
2393
2391
|
11
|
|
2394
|
-
]), s = m.create([0, 1518500249, 1859775393, 2400959708, 2840853838]), f = m.create([1352829926, 1548603684, 1836072691, 2053994217, 0]),
|
|
2392
|
+
]), s = m.create([0, 1518500249, 1859775393, 2400959708, 2840853838]), f = m.create([1352829926, 1548603684, 1836072691, 2053994217, 0]), v = C.RIPEMD160 = B.extend({
|
|
2395
2393
|
_doReset: function() {
|
|
2396
2394
|
this._hash = m.create([1732584193, 4023233417, 2562383102, 271733878, 3285377520]);
|
|
2397
2395
|
},
|
|
@@ -2400,11 +2398,11 @@ function Lt() {
|
|
|
2400
2398
|
var R = y + k, F = g[R];
|
|
2401
2399
|
g[R] = (F << 8 | F >>> 24) & 16711935 | (F << 24 | F >>> 8) & 4278255360;
|
|
2402
2400
|
}
|
|
2403
|
-
var w = this._hash.words, H = s.words, $ = f.words,
|
|
2404
|
-
A = T = w[0], _ = N = w[1],
|
|
2401
|
+
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, _, W, P, L;
|
|
2402
|
+
A = T = w[0], _ = N = w[1], W = j = w[2], P = S = w[3], L = c = w[4];
|
|
2405
2403
|
for (var I, k = 0; k < 80; k += 1)
|
|
2406
|
-
I = T + g[y +
|
|
2407
|
-
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 + _ | 0, w[4] = w[0] + N +
|
|
2404
|
+
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(_, W, P) + $[0] : k < 32 ? I += o(_, W, P) + $[1] : k < 48 ? I += i(_, W, P) + $[2] : k < 64 ? I += D(_, W, P) + $[3] : I += h(_, W, P) + $[4], I = I | 0, I = b(I, U[k]), I = I + L | 0, A = L, L = P, P = b(W, 10), W = _, _ = I;
|
|
2405
|
+
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 + _ | 0, w[4] = w[0] + N + W | 0, w[0] = I;
|
|
2408
2406
|
},
|
|
2409
2407
|
_doFinalize: function() {
|
|
2410
2408
|
var g = this._data, y = g.words, k = this._nDataBytes * 8, R = g.sigBytes * 8;
|
|
@@ -2420,7 +2418,7 @@ function Lt() {
|
|
|
2420
2418
|
return g._hash = this._hash.clone(), g;
|
|
2421
2419
|
}
|
|
2422
2420
|
});
|
|
2423
|
-
function
|
|
2421
|
+
function h(g, y, k) {
|
|
2424
2422
|
return g ^ y ^ k;
|
|
2425
2423
|
}
|
|
2426
2424
|
function D(g, y, k) {
|
|
@@ -2432,26 +2430,26 @@ function Lt() {
|
|
|
2432
2430
|
function o(g, y, k) {
|
|
2433
2431
|
return g & k | y & ~k;
|
|
2434
2432
|
}
|
|
2435
|
-
function
|
|
2433
|
+
function l(g, y, k) {
|
|
2436
2434
|
return g ^ (y | ~k);
|
|
2437
2435
|
}
|
|
2438
2436
|
function b(g, y) {
|
|
2439
2437
|
return g << y | g >>> 32 - y;
|
|
2440
2438
|
}
|
|
2441
|
-
|
|
2439
|
+
d.RIPEMD160 = B._createHelper(v), d.HmacRIPEMD160 = B._createHmacHelper(v);
|
|
2442
2440
|
})(), t.RIPEMD160;
|
|
2443
2441
|
});
|
|
2444
2442
|
})(T0)), T0.exports;
|
|
2445
2443
|
}
|
|
2446
2444
|
var M0 = { exports: {} }, Ot = M0.exports, Jr;
|
|
2447
2445
|
function gr() {
|
|
2448
|
-
return Jr || (Jr = 1, (function(r,
|
|
2446
|
+
return Jr || (Jr = 1, (function(r, u) {
|
|
2449
2447
|
(function(t, e) {
|
|
2450
2448
|
r.exports = e(M());
|
|
2451
2449
|
})(Ot, function(t) {
|
|
2452
2450
|
(function() {
|
|
2453
|
-
var e = t,
|
|
2454
|
-
C.HMAC =
|
|
2451
|
+
var e = t, d = e.lib, p = d.Base, m = e.enc, B = m.Utf8, C = e.algo;
|
|
2452
|
+
C.HMAC = p.extend({
|
|
2455
2453
|
/**
|
|
2456
2454
|
* Initializes a newly created HMAC.
|
|
2457
2455
|
*
|
|
@@ -2466,8 +2464,8 @@ function gr() {
|
|
|
2466
2464
|
x = this._hasher = new x.init(), typeof n == "string" && (n = B.parse(n));
|
|
2467
2465
|
var E = x.blockSize, a = E * 4;
|
|
2468
2466
|
n.sigBytes > a && (n = x.finalize(n)), n.clamp();
|
|
2469
|
-
for (var s = this._oKey = n.clone(), f = this._iKey = n.clone(),
|
|
2470
|
-
|
|
2467
|
+
for (var s = this._oKey = n.clone(), f = this._iKey = n.clone(), v = s.words, h = f.words, D = 0; D < E; D++)
|
|
2468
|
+
v[D] ^= 1549556828, h[D] ^= 909522486;
|
|
2471
2469
|
s.sigBytes = f.sigBytes = a, this.reset();
|
|
2472
2470
|
},
|
|
2473
2471
|
/**
|
|
@@ -2523,12 +2521,12 @@ function gr() {
|
|
|
2523
2521
|
}
|
|
2524
2522
|
var N0 = { exports: {} }, qt = N0.exports, re;
|
|
2525
2523
|
function Tt() {
|
|
2526
|
-
return re || (re = 1, (function(r,
|
|
2527
|
-
(function(t, e,
|
|
2524
|
+
return re || (re = 1, (function(r, u) {
|
|
2525
|
+
(function(t, e, d) {
|
|
2528
2526
|
r.exports = e(M(), Fr(), gr());
|
|
2529
2527
|
})(qt, function(t) {
|
|
2530
2528
|
return (function() {
|
|
2531
|
-
var e = t,
|
|
2529
|
+
var e = t, d = e.lib, p = d.Base, m = d.WordArray, B = e.algo, C = B.SHA256, x = B.HMAC, n = B.PBKDF2 = p.extend({
|
|
2532
2530
|
/**
|
|
2533
2531
|
* Configuration options.
|
|
2534
2532
|
*
|
|
@@ -2536,7 +2534,7 @@ function Tt() {
|
|
|
2536
2534
|
* @property {Hasher} hasher The hasher to use. Default: SHA256
|
|
2537
2535
|
* @property {number} iterations The number of iterations to perform. Default: 250000
|
|
2538
2536
|
*/
|
|
2539
|
-
cfg:
|
|
2537
|
+
cfg: p.extend({
|
|
2540
2538
|
keySize: 128 / 32,
|
|
2541
2539
|
hasher: C,
|
|
2542
2540
|
iterations: 25e4
|
|
@@ -2568,17 +2566,17 @@ function Tt() {
|
|
|
2568
2566
|
* var key = kdf.compute(password, salt);
|
|
2569
2567
|
*/
|
|
2570
2568
|
compute: function(E, a) {
|
|
2571
|
-
for (var s = this.cfg, f = x.create(s.hasher, E),
|
|
2572
|
-
var b = f.update(a).finalize(
|
|
2569
|
+
for (var s = this.cfg, f = x.create(s.hasher, E), v = m.create(), h = m.create([1]), D = v.words, i = h.words, o = s.keySize, l = s.iterations; D.length < o; ) {
|
|
2570
|
+
var b = f.update(a).finalize(h);
|
|
2573
2571
|
f.reset();
|
|
2574
|
-
for (var g = b.words, y = g.length, k = b, R = 1; R <
|
|
2572
|
+
for (var g = b.words, y = g.length, k = b, R = 1; R < l; R++) {
|
|
2575
2573
|
k = f.finalize(k), f.reset();
|
|
2576
2574
|
for (var F = k.words, w = 0; w < y; w++)
|
|
2577
2575
|
g[w] ^= F[w];
|
|
2578
2576
|
}
|
|
2579
|
-
|
|
2577
|
+
v.concat(b), i[0]++;
|
|
2580
2578
|
}
|
|
2581
|
-
return
|
|
2579
|
+
return v.sigBytes = o * 4, v;
|
|
2582
2580
|
}
|
|
2583
2581
|
});
|
|
2584
2582
|
e.PBKDF2 = function(E, a, s) {
|
|
@@ -2590,12 +2588,12 @@ function Tt() {
|
|
|
2590
2588
|
}
|
|
2591
2589
|
var U0 = { exports: {} }, Mt = U0.exports, ee;
|
|
2592
2590
|
function a0() {
|
|
2593
|
-
return ee || (ee = 1, (function(r,
|
|
2594
|
-
(function(t, e,
|
|
2591
|
+
return ee || (ee = 1, (function(r, u) {
|
|
2592
|
+
(function(t, e, d) {
|
|
2595
2593
|
r.exports = e(M(), ke(), gr());
|
|
2596
2594
|
})(Mt, function(t) {
|
|
2597
2595
|
return (function() {
|
|
2598
|
-
var e = t,
|
|
2596
|
+
var e = t, d = e.lib, p = d.Base, m = d.WordArray, B = e.algo, C = B.MD5, x = B.EvpKDF = p.extend({
|
|
2599
2597
|
/**
|
|
2600
2598
|
* Configuration options.
|
|
2601
2599
|
*
|
|
@@ -2603,7 +2601,7 @@ function a0() {
|
|
|
2603
2601
|
* @property {Hasher} hasher The hash algorithm to use. Default: MD5
|
|
2604
2602
|
* @property {number} iterations The number of iterations to perform. Default: 1
|
|
2605
2603
|
*/
|
|
2606
|
-
cfg:
|
|
2604
|
+
cfg: p.extend({
|
|
2607
2605
|
keySize: 128 / 32,
|
|
2608
2606
|
hasher: C,
|
|
2609
2607
|
iterations: 1
|
|
@@ -2635,13 +2633,13 @@ function a0() {
|
|
|
2635
2633
|
* var key = kdf.compute(password, salt);
|
|
2636
2634
|
*/
|
|
2637
2635
|
compute: function(n, E) {
|
|
2638
|
-
for (var a, s = this.cfg, f = s.hasher.create(),
|
|
2636
|
+
for (var a, s = this.cfg, f = s.hasher.create(), v = m.create(), h = v.words, D = s.keySize, i = s.iterations; h.length < D; ) {
|
|
2639
2637
|
a && f.update(a), a = f.update(n).finalize(E), f.reset();
|
|
2640
2638
|
for (var o = 1; o < i; o++)
|
|
2641
2639
|
a = f.finalize(a), f.reset();
|
|
2642
|
-
|
|
2640
|
+
v.concat(a);
|
|
2643
2641
|
}
|
|
2644
|
-
return
|
|
2642
|
+
return v.sigBytes = D * 4, v;
|
|
2645
2643
|
}
|
|
2646
2644
|
});
|
|
2647
2645
|
e.EvpKDF = function(n, E, a) {
|
|
@@ -2653,14 +2651,14 @@ function a0() {
|
|
|
2653
2651
|
}
|
|
2654
2652
|
var j0 = { exports: {} }, Nt = j0.exports, te;
|
|
2655
2653
|
function X() {
|
|
2656
|
-
return te || (te = 1, (function(r,
|
|
2657
|
-
(function(t, e,
|
|
2654
|
+
return te || (te = 1, (function(r, u) {
|
|
2655
|
+
(function(t, e, d) {
|
|
2658
2656
|
r.exports = e(M(), a0());
|
|
2659
2657
|
})(Nt, function(t) {
|
|
2660
2658
|
t.lib.Cipher || (function(e) {
|
|
2661
|
-
var
|
|
2659
|
+
var d = t, p = d.lib, m = p.Base, B = p.WordArray, C = p.BufferedBlockAlgorithm, x = d.enc;
|
|
2662
2660
|
x.Utf8;
|
|
2663
|
-
var n = x.Base64, E =
|
|
2661
|
+
var n = x.Base64, E = d.algo, a = E.EvpKDF, s = p.Cipher = C.extend({
|
|
2664
2662
|
/**
|
|
2665
2663
|
* Configuration options.
|
|
2666
2664
|
*
|
|
@@ -2782,24 +2780,24 @@ function X() {
|
|
|
2782
2780
|
}
|
|
2783
2781
|
return function(w) {
|
|
2784
2782
|
return {
|
|
2785
|
-
encrypt: function(H, $,
|
|
2786
|
-
return F($).encrypt(w, H, $,
|
|
2783
|
+
encrypt: function(H, $, z) {
|
|
2784
|
+
return F($).encrypt(w, H, $, z);
|
|
2787
2785
|
},
|
|
2788
|
-
decrypt: function(H, $,
|
|
2789
|
-
return F($).decrypt(w, H, $,
|
|
2786
|
+
decrypt: function(H, $, z) {
|
|
2787
|
+
return F($).decrypt(w, H, $, z);
|
|
2790
2788
|
}
|
|
2791
2789
|
};
|
|
2792
2790
|
};
|
|
2793
2791
|
})()
|
|
2794
2792
|
});
|
|
2795
|
-
|
|
2793
|
+
p.StreamCipher = s.extend({
|
|
2796
2794
|
_doFinalize: function() {
|
|
2797
2795
|
var F = this._process(!0);
|
|
2798
2796
|
return F;
|
|
2799
2797
|
},
|
|
2800
2798
|
blockSize: 1
|
|
2801
2799
|
});
|
|
2802
|
-
var f =
|
|
2800
|
+
var f = d.mode = {}, v = p.BlockCipherMode = m.extend({
|
|
2803
2801
|
/**
|
|
2804
2802
|
* Creates this mode for encryption.
|
|
2805
2803
|
*
|
|
@@ -2843,8 +2841,8 @@ function X() {
|
|
|
2843
2841
|
init: function(F, w) {
|
|
2844
2842
|
this._cipher = F, this._iv = w;
|
|
2845
2843
|
}
|
|
2846
|
-
}),
|
|
2847
|
-
var F =
|
|
2844
|
+
}), h = f.CBC = (function() {
|
|
2845
|
+
var F = v.extend();
|
|
2848
2846
|
F.Encryptor = F.extend({
|
|
2849
2847
|
/**
|
|
2850
2848
|
* Processes the data block at offset.
|
|
@@ -2857,8 +2855,8 @@ function X() {
|
|
|
2857
2855
|
* mode.processBlock(data.words, offset);
|
|
2858
2856
|
*/
|
|
2859
2857
|
processBlock: function(H, $) {
|
|
2860
|
-
var
|
|
2861
|
-
w.call(this, H, $, O),
|
|
2858
|
+
var z = this._cipher, O = z.blockSize;
|
|
2859
|
+
w.call(this, H, $, O), z.encryptBlock(H, $), this._prevBlock = H.slice($, $ + O);
|
|
2862
2860
|
}
|
|
2863
2861
|
}), F.Decryptor = F.extend({
|
|
2864
2862
|
/**
|
|
@@ -2872,18 +2870,18 @@ function X() {
|
|
|
2872
2870
|
* mode.processBlock(data.words, offset);
|
|
2873
2871
|
*/
|
|
2874
2872
|
processBlock: function(H, $) {
|
|
2875
|
-
var
|
|
2876
|
-
|
|
2873
|
+
var z = this._cipher, O = z.blockSize, q = H.slice($, $ + O);
|
|
2874
|
+
z.decryptBlock(H, $), w.call(this, H, $, O), this._prevBlock = q;
|
|
2877
2875
|
}
|
|
2878
2876
|
});
|
|
2879
|
-
function w(H, $,
|
|
2877
|
+
function w(H, $, z) {
|
|
2880
2878
|
var O, q = this._iv;
|
|
2881
2879
|
q ? (O = q, this._iv = e) : O = this._prevBlock;
|
|
2882
|
-
for (var U = 0; U <
|
|
2880
|
+
for (var U = 0; U < z; U++)
|
|
2883
2881
|
H[$ + U] ^= O[U];
|
|
2884
2882
|
}
|
|
2885
2883
|
return F;
|
|
2886
|
-
})(), D =
|
|
2884
|
+
})(), D = d.pad = {}, i = D.Pkcs7 = {
|
|
2887
2885
|
/**
|
|
2888
2886
|
* Pads data using the algorithm defined in PKCS #5/7.
|
|
2889
2887
|
*
|
|
@@ -2897,8 +2895,8 @@ function X() {
|
|
|
2897
2895
|
* CryptoJS.pad.Pkcs7.pad(wordArray, 4);
|
|
2898
2896
|
*/
|
|
2899
2897
|
pad: function(F, w) {
|
|
2900
|
-
for (var H = w * 4, $ = H - F.sigBytes % H,
|
|
2901
|
-
O.push(
|
|
2898
|
+
for (var H = w * 4, $ = H - F.sigBytes % H, z = $ << 24 | $ << 16 | $ << 8 | $, O = [], q = 0; q < $; q += 4)
|
|
2899
|
+
O.push(z);
|
|
2902
2900
|
var U = B.create(O, $);
|
|
2903
2901
|
F.concat(U);
|
|
2904
2902
|
},
|
|
@@ -2918,7 +2916,7 @@ function X() {
|
|
|
2918
2916
|
F.sigBytes -= w;
|
|
2919
2917
|
}
|
|
2920
2918
|
};
|
|
2921
|
-
|
|
2919
|
+
p.BlockCipher = s.extend({
|
|
2922
2920
|
/**
|
|
2923
2921
|
* Configuration options.
|
|
2924
2922
|
*
|
|
@@ -2926,7 +2924,7 @@ function X() {
|
|
|
2926
2924
|
* @property {Padding} padding The padding strategy to use. Default: Pkcs7
|
|
2927
2925
|
*/
|
|
2928
2926
|
cfg: s.cfg.extend({
|
|
2929
|
-
mode:
|
|
2927
|
+
mode: h,
|
|
2930
2928
|
padding: i
|
|
2931
2929
|
}),
|
|
2932
2930
|
reset: function() {
|
|
@@ -2944,7 +2942,7 @@ function X() {
|
|
|
2944
2942
|
},
|
|
2945
2943
|
blockSize: 128 / 32
|
|
2946
2944
|
});
|
|
2947
|
-
var o =
|
|
2945
|
+
var o = p.CipherParams = m.extend({
|
|
2948
2946
|
/**
|
|
2949
2947
|
* Initializes a newly created cipher params object.
|
|
2950
2948
|
*
|
|
@@ -2985,7 +2983,7 @@ function X() {
|
|
|
2985
2983
|
toString: function(F) {
|
|
2986
2984
|
return (F || this.formatter).stringify(this);
|
|
2987
2985
|
}
|
|
2988
|
-
}),
|
|
2986
|
+
}), l = d.format = {}, b = l.OpenSSL = {
|
|
2989
2987
|
/**
|
|
2990
2988
|
* Converts a cipher params object to an OpenSSL-compatible string.
|
|
2991
2989
|
*
|
|
@@ -3020,7 +3018,7 @@ function X() {
|
|
|
3020
3018
|
var w, H = n.parse(F), $ = H.words;
|
|
3021
3019
|
return $[0] == 1398893684 && $[1] == 1701076831 && (w = B.create($.slice(2, 4)), $.splice(0, 4), H.sigBytes -= 16), o.create({ ciphertext: H, salt: w });
|
|
3022
3020
|
}
|
|
3023
|
-
}, g =
|
|
3021
|
+
}, g = p.SerializableCipher = m.extend({
|
|
3024
3022
|
/**
|
|
3025
3023
|
* Configuration options.
|
|
3026
3024
|
*
|
|
@@ -3049,7 +3047,7 @@ function X() {
|
|
|
3049
3047
|
*/
|
|
3050
3048
|
encrypt: function(F, w, H, $) {
|
|
3051
3049
|
$ = this.cfg.extend($);
|
|
3052
|
-
var
|
|
3050
|
+
var z = F.createEncryptor(H, $), O = z.finalize(w), q = z.cfg;
|
|
3053
3051
|
return o.create({
|
|
3054
3052
|
ciphertext: O,
|
|
3055
3053
|
key: H,
|
|
@@ -3080,8 +3078,8 @@ function X() {
|
|
|
3080
3078
|
*/
|
|
3081
3079
|
decrypt: function(F, w, H, $) {
|
|
3082
3080
|
$ = this.cfg.extend($), w = this._parse(w, $.format);
|
|
3083
|
-
var
|
|
3084
|
-
return
|
|
3081
|
+
var z = F.createDecryptor(H, $).finalize(w.ciphertext);
|
|
3082
|
+
return z;
|
|
3085
3083
|
},
|
|
3086
3084
|
/**
|
|
3087
3085
|
* Converts serialized ciphertext to CipherParams,
|
|
@@ -3101,7 +3099,7 @@ function X() {
|
|
|
3101
3099
|
_parse: function(F, w) {
|
|
3102
3100
|
return typeof F == "string" ? w.parse(F, this) : F;
|
|
3103
3101
|
}
|
|
3104
|
-
}), y =
|
|
3102
|
+
}), y = d.kdf = {}, k = y.OpenSSL = {
|
|
3105
3103
|
/**
|
|
3106
3104
|
* Derives a key and IV from a password.
|
|
3107
3105
|
*
|
|
@@ -3119,15 +3117,15 @@ function X() {
|
|
|
3119
3117
|
* var derivedParams = CryptoJS.kdf.OpenSSL.execute('Password', 256/32, 128/32);
|
|
3120
3118
|
* var derivedParams = CryptoJS.kdf.OpenSSL.execute('Password', 256/32, 128/32, 'saltsalt');
|
|
3121
3119
|
*/
|
|
3122
|
-
execute: function(F, w, H, $,
|
|
3123
|
-
if ($ || ($ = B.random(64 / 8)),
|
|
3124
|
-
var O = a.create({ keySize: w + H, hasher:
|
|
3120
|
+
execute: function(F, w, H, $, z) {
|
|
3121
|
+
if ($ || ($ = B.random(64 / 8)), z)
|
|
3122
|
+
var O = a.create({ keySize: w + H, hasher: z }).compute(F, $);
|
|
3125
3123
|
else
|
|
3126
3124
|
var O = a.create({ keySize: w + H }).compute(F, $);
|
|
3127
3125
|
var q = B.create(O.words.slice(w), H * 4);
|
|
3128
3126
|
return O.sigBytes = w * 4, o.create({ key: O, iv: q, salt: $ });
|
|
3129
3127
|
}
|
|
3130
|
-
}, R =
|
|
3128
|
+
}, R = p.PasswordBasedCipher = g.extend({
|
|
3131
3129
|
/**
|
|
3132
3130
|
* Configuration options.
|
|
3133
3131
|
*
|
|
@@ -3155,10 +3153,10 @@ function X() {
|
|
|
3155
3153
|
*/
|
|
3156
3154
|
encrypt: function(F, w, H, $) {
|
|
3157
3155
|
$ = this.cfg.extend($);
|
|
3158
|
-
var
|
|
3159
|
-
$.iv =
|
|
3160
|
-
var O = g.encrypt.call(this, F, w,
|
|
3161
|
-
return O.mixIn(
|
|
3156
|
+
var z = $.kdf.execute(H, F.keySize, F.ivSize, $.salt, $.hasher);
|
|
3157
|
+
$.iv = z.iv;
|
|
3158
|
+
var O = g.encrypt.call(this, F, w, z.key, $);
|
|
3159
|
+
return O.mixIn(z), O;
|
|
3162
3160
|
},
|
|
3163
3161
|
/**
|
|
3164
3162
|
* Decrypts serialized ciphertext using a password.
|
|
@@ -3179,9 +3177,9 @@ function X() {
|
|
|
3179
3177
|
*/
|
|
3180
3178
|
decrypt: function(F, w, H, $) {
|
|
3181
3179
|
$ = this.cfg.extend($), w = this._parse(w, $.format);
|
|
3182
|
-
var
|
|
3183
|
-
$.iv =
|
|
3184
|
-
var O = g.decrypt.call(this, F, w,
|
|
3180
|
+
var z = $.kdf.execute(H, F.keySize, F.ivSize, w.salt, $.hasher);
|
|
3181
|
+
$.iv = z.iv;
|
|
3182
|
+
var O = g.decrypt.call(this, F, w, z.key, $);
|
|
3185
3183
|
return O;
|
|
3186
3184
|
}
|
|
3187
3185
|
});
|
|
@@ -3191,28 +3189,28 @@ function X() {
|
|
|
3191
3189
|
}
|
|
3192
3190
|
var G0 = { exports: {} }, Ut = G0.exports, xe;
|
|
3193
3191
|
function jt() {
|
|
3194
|
-
return xe || (xe = 1, (function(r,
|
|
3195
|
-
(function(t, e,
|
|
3192
|
+
return xe || (xe = 1, (function(r, u) {
|
|
3193
|
+
(function(t, e, d) {
|
|
3196
3194
|
r.exports = e(M(), X());
|
|
3197
3195
|
})(Ut, function(t) {
|
|
3198
3196
|
return t.mode.CFB = (function() {
|
|
3199
3197
|
var e = t.lib.BlockCipherMode.extend();
|
|
3200
3198
|
e.Encryptor = e.extend({
|
|
3201
|
-
processBlock: function(
|
|
3199
|
+
processBlock: function(p, m) {
|
|
3202
3200
|
var B = this._cipher, C = B.blockSize;
|
|
3203
|
-
|
|
3201
|
+
d.call(this, p, m, C, B), this._prevBlock = p.slice(m, m + C);
|
|
3204
3202
|
}
|
|
3205
3203
|
}), e.Decryptor = e.extend({
|
|
3206
|
-
processBlock: function(
|
|
3207
|
-
var B = this._cipher, C = B.blockSize, x =
|
|
3208
|
-
|
|
3204
|
+
processBlock: function(p, m) {
|
|
3205
|
+
var B = this._cipher, C = B.blockSize, x = p.slice(m, m + C);
|
|
3206
|
+
d.call(this, p, m, C, B), this._prevBlock = x;
|
|
3209
3207
|
}
|
|
3210
3208
|
});
|
|
3211
|
-
function
|
|
3209
|
+
function d(p, m, B, C) {
|
|
3212
3210
|
var x, n = this._iv;
|
|
3213
3211
|
n ? (x = n.slice(0), this._iv = void 0) : x = this._prevBlock, C.encryptBlock(x, 0);
|
|
3214
3212
|
for (var E = 0; E < B; E++)
|
|
3215
|
-
|
|
3213
|
+
p[m + E] ^= x[E];
|
|
3216
3214
|
}
|
|
3217
3215
|
return e;
|
|
3218
3216
|
})(), t.mode.CFB;
|
|
@@ -3221,35 +3219,35 @@ function jt() {
|
|
|
3221
3219
|
}
|
|
3222
3220
|
var K0 = { exports: {} }, Gt = K0.exports, ne;
|
|
3223
3221
|
function Kt() {
|
|
3224
|
-
return ne || (ne = 1, (function(r,
|
|
3225
|
-
(function(t, e,
|
|
3222
|
+
return ne || (ne = 1, (function(r, u) {
|
|
3223
|
+
(function(t, e, d) {
|
|
3226
3224
|
r.exports = e(M(), X());
|
|
3227
3225
|
})(Gt, function(t) {
|
|
3228
3226
|
return t.mode.CTR = (function() {
|
|
3229
|
-
var e = t.lib.BlockCipherMode.extend(),
|
|
3230
|
-
processBlock: function(
|
|
3227
|
+
var e = t.lib.BlockCipherMode.extend(), d = e.Encryptor = e.extend({
|
|
3228
|
+
processBlock: function(p, m) {
|
|
3231
3229
|
var B = this._cipher, C = B.blockSize, x = this._iv, n = this._counter;
|
|
3232
3230
|
x && (n = this._counter = x.slice(0), this._iv = void 0);
|
|
3233
3231
|
var E = n.slice(0);
|
|
3234
3232
|
B.encryptBlock(E, 0), n[C - 1] = n[C - 1] + 1 | 0;
|
|
3235
3233
|
for (var a = 0; a < C; a++)
|
|
3236
|
-
|
|
3234
|
+
p[m + a] ^= E[a];
|
|
3237
3235
|
}
|
|
3238
3236
|
});
|
|
3239
|
-
return e.Decryptor =
|
|
3237
|
+
return e.Decryptor = d, e;
|
|
3240
3238
|
})(), t.mode.CTR;
|
|
3241
3239
|
});
|
|
3242
3240
|
})(K0)), K0.exports;
|
|
3243
3241
|
}
|
|
3244
3242
|
var X0 = { exports: {} }, Xt = X0.exports, ae;
|
|
3245
|
-
function
|
|
3246
|
-
return ae || (ae = 1, (function(r,
|
|
3247
|
-
(function(t, e,
|
|
3243
|
+
function Yt() {
|
|
3244
|
+
return ae || (ae = 1, (function(r, u) {
|
|
3245
|
+
(function(t, e, d) {
|
|
3248
3246
|
r.exports = e(M(), X());
|
|
3249
3247
|
})(Xt, function(t) {
|
|
3250
3248
|
return t.mode.CTRGladman = (function() {
|
|
3251
3249
|
var e = t.lib.BlockCipherMode.extend();
|
|
3252
|
-
function
|
|
3250
|
+
function d(B) {
|
|
3253
3251
|
if ((B >> 24 & 255) === 255) {
|
|
3254
3252
|
var C = B >> 16 & 255, x = B >> 8 & 255, n = B & 255;
|
|
3255
3253
|
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;
|
|
@@ -3257,13 +3255,13 @@ function Zt() {
|
|
|
3257
3255
|
B += 1 << 24;
|
|
3258
3256
|
return B;
|
|
3259
3257
|
}
|
|
3260
|
-
function
|
|
3261
|
-
return (B[0] =
|
|
3258
|
+
function p(B) {
|
|
3259
|
+
return (B[0] = d(B[0])) === 0 && (B[1] = d(B[1])), B;
|
|
3262
3260
|
}
|
|
3263
3261
|
var m = e.Encryptor = e.extend({
|
|
3264
3262
|
processBlock: function(B, C) {
|
|
3265
3263
|
var x = this._cipher, n = x.blockSize, E = this._iv, a = this._counter;
|
|
3266
|
-
E && (a = this._counter = E.slice(0), this._iv = void 0),
|
|
3264
|
+
E && (a = this._counter = E.slice(0), this._iv = void 0), p(a);
|
|
3267
3265
|
var s = a.slice(0);
|
|
3268
3266
|
x.encryptBlock(s, 0);
|
|
3269
3267
|
for (var f = 0; f < n; f++)
|
|
@@ -3275,61 +3273,61 @@ function Zt() {
|
|
|
3275
3273
|
});
|
|
3276
3274
|
})(X0)), X0.exports;
|
|
3277
3275
|
}
|
|
3278
|
-
var
|
|
3276
|
+
var Y0 = { exports: {} }, Zt = Y0.exports, oe;
|
|
3279
3277
|
function Qt() {
|
|
3280
|
-
return oe || (oe = 1, (function(r,
|
|
3281
|
-
(function(t, e,
|
|
3278
|
+
return oe || (oe = 1, (function(r, u) {
|
|
3279
|
+
(function(t, e, d) {
|
|
3282
3280
|
r.exports = e(M(), X());
|
|
3283
|
-
})(
|
|
3281
|
+
})(Zt, function(t) {
|
|
3284
3282
|
return t.mode.OFB = (function() {
|
|
3285
|
-
var e = t.lib.BlockCipherMode.extend(),
|
|
3286
|
-
processBlock: function(
|
|
3283
|
+
var e = t.lib.BlockCipherMode.extend(), d = e.Encryptor = e.extend({
|
|
3284
|
+
processBlock: function(p, m) {
|
|
3287
3285
|
var B = this._cipher, C = B.blockSize, x = this._iv, n = this._keystream;
|
|
3288
3286
|
x && (n = this._keystream = x.slice(0), this._iv = void 0), B.encryptBlock(n, 0);
|
|
3289
3287
|
for (var E = 0; E < C; E++)
|
|
3290
|
-
|
|
3288
|
+
p[m + E] ^= n[E];
|
|
3291
3289
|
}
|
|
3292
3290
|
});
|
|
3293
|
-
return e.Decryptor =
|
|
3291
|
+
return e.Decryptor = d, e;
|
|
3294
3292
|
})(), t.mode.OFB;
|
|
3295
3293
|
});
|
|
3296
|
-
})(
|
|
3294
|
+
})(Y0)), Y0.exports;
|
|
3297
3295
|
}
|
|
3298
|
-
var
|
|
3296
|
+
var Z0 = { exports: {} }, Vt = Z0.exports, ie;
|
|
3299
3297
|
function Jt() {
|
|
3300
|
-
return ie || (ie = 1, (function(r,
|
|
3301
|
-
(function(t, e,
|
|
3298
|
+
return ie || (ie = 1, (function(r, u) {
|
|
3299
|
+
(function(t, e, d) {
|
|
3302
3300
|
r.exports = e(M(), X());
|
|
3303
3301
|
})(Vt, function(t) {
|
|
3304
3302
|
return t.mode.ECB = (function() {
|
|
3305
3303
|
var e = t.lib.BlockCipherMode.extend();
|
|
3306
3304
|
return e.Encryptor = e.extend({
|
|
3307
|
-
processBlock: function(
|
|
3308
|
-
this._cipher.encryptBlock(
|
|
3305
|
+
processBlock: function(d, p) {
|
|
3306
|
+
this._cipher.encryptBlock(d, p);
|
|
3309
3307
|
}
|
|
3310
3308
|
}), e.Decryptor = e.extend({
|
|
3311
|
-
processBlock: function(
|
|
3312
|
-
this._cipher.decryptBlock(
|
|
3309
|
+
processBlock: function(d, p) {
|
|
3310
|
+
this._cipher.decryptBlock(d, p);
|
|
3313
3311
|
}
|
|
3314
3312
|
}), e;
|
|
3315
3313
|
})(), t.mode.ECB;
|
|
3316
3314
|
});
|
|
3317
|
-
})(
|
|
3315
|
+
})(Z0)), Z0.exports;
|
|
3318
3316
|
}
|
|
3319
3317
|
var Q0 = { exports: {} }, rx = Q0.exports, se;
|
|
3320
3318
|
function ex() {
|
|
3321
|
-
return se || (se = 1, (function(r,
|
|
3322
|
-
(function(t, e,
|
|
3319
|
+
return se || (se = 1, (function(r, u) {
|
|
3320
|
+
(function(t, e, d) {
|
|
3323
3321
|
r.exports = e(M(), X());
|
|
3324
3322
|
})(rx, function(t) {
|
|
3325
3323
|
return t.pad.AnsiX923 = {
|
|
3326
|
-
pad: function(e,
|
|
3327
|
-
var
|
|
3324
|
+
pad: function(e, d) {
|
|
3325
|
+
var p = e.sigBytes, m = d * 4, B = m - p % m, C = p + B - 1;
|
|
3328
3326
|
e.clamp(), e.words[C >>> 2] |= B << 24 - C % 4 * 8, e.sigBytes += B;
|
|
3329
3327
|
},
|
|
3330
3328
|
unpad: function(e) {
|
|
3331
|
-
var
|
|
3332
|
-
e.sigBytes -=
|
|
3329
|
+
var d = e.words[e.sigBytes - 1 >>> 2] & 255;
|
|
3330
|
+
e.sigBytes -= d;
|
|
3333
3331
|
}
|
|
3334
3332
|
}, t.pad.Ansix923;
|
|
3335
3333
|
});
|
|
@@ -3337,18 +3335,18 @@ function ex() {
|
|
|
3337
3335
|
}
|
|
3338
3336
|
var V0 = { exports: {} }, tx = V0.exports, ce;
|
|
3339
3337
|
function xx() {
|
|
3340
|
-
return ce || (ce = 1, (function(r,
|
|
3341
|
-
(function(t, e,
|
|
3338
|
+
return ce || (ce = 1, (function(r, u) {
|
|
3339
|
+
(function(t, e, d) {
|
|
3342
3340
|
r.exports = e(M(), X());
|
|
3343
3341
|
})(tx, function(t) {
|
|
3344
3342
|
return t.pad.Iso10126 = {
|
|
3345
|
-
pad: function(e,
|
|
3346
|
-
var
|
|
3343
|
+
pad: function(e, d) {
|
|
3344
|
+
var p = d * 4, m = p - e.sigBytes % p;
|
|
3347
3345
|
e.concat(t.lib.WordArray.random(m - 1)).concat(t.lib.WordArray.create([m << 24], 1));
|
|
3348
3346
|
},
|
|
3349
3347
|
unpad: function(e) {
|
|
3350
|
-
var
|
|
3351
|
-
e.sigBytes -=
|
|
3348
|
+
var d = e.words[e.sigBytes - 1 >>> 2] & 255;
|
|
3349
|
+
e.sigBytes -= d;
|
|
3352
3350
|
}
|
|
3353
3351
|
}, t.pad.Iso10126;
|
|
3354
3352
|
});
|
|
@@ -3356,13 +3354,13 @@ function xx() {
|
|
|
3356
3354
|
}
|
|
3357
3355
|
var J0 = { exports: {} }, nx = J0.exports, fe;
|
|
3358
3356
|
function ax() {
|
|
3359
|
-
return fe || (fe = 1, (function(r,
|
|
3360
|
-
(function(t, e,
|
|
3357
|
+
return fe || (fe = 1, (function(r, u) {
|
|
3358
|
+
(function(t, e, d) {
|
|
3361
3359
|
r.exports = e(M(), X());
|
|
3362
3360
|
})(nx, function(t) {
|
|
3363
3361
|
return t.pad.Iso97971 = {
|
|
3364
|
-
pad: function(e,
|
|
3365
|
-
e.concat(t.lib.WordArray.create([2147483648], 1)), t.pad.ZeroPadding.pad(e,
|
|
3362
|
+
pad: function(e, d) {
|
|
3363
|
+
e.concat(t.lib.WordArray.create([2147483648], 1)), t.pad.ZeroPadding.pad(e, d);
|
|
3366
3364
|
},
|
|
3367
3365
|
unpad: function(e) {
|
|
3368
3366
|
t.pad.ZeroPadding.unpad(e), e.sigBytes--;
|
|
@@ -3371,21 +3369,21 @@ function ax() {
|
|
|
3371
3369
|
});
|
|
3372
3370
|
})(J0)), J0.exports;
|
|
3373
3371
|
}
|
|
3374
|
-
var rr = { exports: {} }, ox = rr.exports,
|
|
3372
|
+
var rr = { exports: {} }, ox = rr.exports, de;
|
|
3375
3373
|
function ix() {
|
|
3376
|
-
return
|
|
3377
|
-
(function(t, e,
|
|
3374
|
+
return de || (de = 1, (function(r, u) {
|
|
3375
|
+
(function(t, e, d) {
|
|
3378
3376
|
r.exports = e(M(), X());
|
|
3379
3377
|
})(ox, function(t) {
|
|
3380
3378
|
return t.pad.ZeroPadding = {
|
|
3381
|
-
pad: function(e,
|
|
3382
|
-
var
|
|
3383
|
-
e.clamp(), e.sigBytes +=
|
|
3379
|
+
pad: function(e, d) {
|
|
3380
|
+
var p = d * 4;
|
|
3381
|
+
e.clamp(), e.sigBytes += p - (e.sigBytes % p || p);
|
|
3384
3382
|
},
|
|
3385
3383
|
unpad: function(e) {
|
|
3386
|
-
for (var
|
|
3387
|
-
if (
|
|
3388
|
-
e.sigBytes =
|
|
3384
|
+
for (var d = e.words, p = e.sigBytes - 1, p = e.sigBytes - 1; p >= 0; p--)
|
|
3385
|
+
if (d[p >>> 2] >>> 24 - p % 4 * 8 & 255) {
|
|
3386
|
+
e.sigBytes = p + 1;
|
|
3389
3387
|
break;
|
|
3390
3388
|
}
|
|
3391
3389
|
}
|
|
@@ -3393,10 +3391,10 @@ function ix() {
|
|
|
3393
3391
|
});
|
|
3394
3392
|
})(rr)), rr.exports;
|
|
3395
3393
|
}
|
|
3396
|
-
var er = { exports: {} }, sx = er.exports,
|
|
3394
|
+
var er = { exports: {} }, sx = er.exports, ue;
|
|
3397
3395
|
function cx() {
|
|
3398
|
-
return
|
|
3399
|
-
(function(t, e,
|
|
3396
|
+
return ue || (ue = 1, (function(r, u) {
|
|
3397
|
+
(function(t, e, d) {
|
|
3400
3398
|
r.exports = e(M(), X());
|
|
3401
3399
|
})(sx, function(t) {
|
|
3402
3400
|
return t.pad.NoPadding = {
|
|
@@ -3409,13 +3407,13 @@ function cx() {
|
|
|
3409
3407
|
})(er)), er.exports;
|
|
3410
3408
|
}
|
|
3411
3409
|
var tr = { exports: {} }, fx = tr.exports, le;
|
|
3412
|
-
function
|
|
3413
|
-
return le || (le = 1, (function(r,
|
|
3414
|
-
(function(t, e,
|
|
3410
|
+
function dx() {
|
|
3411
|
+
return le || (le = 1, (function(r, u) {
|
|
3412
|
+
(function(t, e, d) {
|
|
3415
3413
|
r.exports = e(M(), X());
|
|
3416
3414
|
})(fx, function(t) {
|
|
3417
3415
|
return (function(e) {
|
|
3418
|
-
var
|
|
3416
|
+
var d = t, p = d.lib, m = p.CipherParams, B = d.enc, C = B.Hex, x = d.format;
|
|
3419
3417
|
x.Hex = {
|
|
3420
3418
|
/**
|
|
3421
3419
|
* Converts the ciphertext of a cipher params object to a hexadecimally encoded string.
|
|
@@ -3455,31 +3453,31 @@ function ux() {
|
|
|
3455
3453
|
});
|
|
3456
3454
|
})(tr)), tr.exports;
|
|
3457
3455
|
}
|
|
3458
|
-
var xr = { exports: {} },
|
|
3456
|
+
var xr = { exports: {} }, ux = xr.exports, he;
|
|
3459
3457
|
function lx() {
|
|
3460
|
-
return he || (he = 1, (function(r,
|
|
3461
|
-
(function(t, e,
|
|
3458
|
+
return he || (he = 1, (function(r, u) {
|
|
3459
|
+
(function(t, e, d) {
|
|
3462
3460
|
r.exports = e(M(), s0(), c0(), a0(), X());
|
|
3463
|
-
})(
|
|
3461
|
+
})(ux, function(t) {
|
|
3464
3462
|
return (function() {
|
|
3465
|
-
var e = t,
|
|
3463
|
+
var e = t, d = e.lib, p = d.BlockCipher, m = e.algo, B = [], C = [], x = [], n = [], E = [], a = [], s = [], f = [], v = [], h = [];
|
|
3466
3464
|
(function() {
|
|
3467
|
-
for (var o = [],
|
|
3468
|
-
|
|
3469
|
-
for (var b = 0, g = 0,
|
|
3465
|
+
for (var o = [], l = 0; l < 256; l++)
|
|
3466
|
+
l < 128 ? o[l] = l << 1 : o[l] = l << 1 ^ 283;
|
|
3467
|
+
for (var b = 0, g = 0, l = 0; l < 256; l++) {
|
|
3470
3468
|
var y = g ^ g << 1 ^ g << 2 ^ g << 3 ^ g << 4;
|
|
3471
3469
|
y = y >>> 8 ^ y & 255 ^ 99, B[b] = y, C[y] = b;
|
|
3472
3470
|
var k = o[b], R = o[k], F = o[R], w = o[y] * 257 ^ y * 16843008;
|
|
3473
3471
|
x[b] = w << 24 | w >>> 8, n[b] = w << 16 | w >>> 16, E[b] = w << 8 | w >>> 24, a[b] = w;
|
|
3474
3472
|
var w = F * 16843009 ^ R * 65537 ^ k * 257 ^ b * 16843008;
|
|
3475
|
-
s[y] = w << 24 | w >>> 8, f[y] = w << 16 | w >>> 16,
|
|
3473
|
+
s[y] = w << 24 | w >>> 8, f[y] = w << 16 | w >>> 16, v[y] = w << 8 | w >>> 24, h[y] = w, b ? (b = k ^ o[o[o[F ^ k]]], g ^= o[o[g]]) : b = g = 1;
|
|
3476
3474
|
}
|
|
3477
3475
|
})();
|
|
3478
|
-
var D = [0, 1, 2, 4, 8, 16, 32, 64, 128, 27, 54], i = m.AES =
|
|
3476
|
+
var D = [0, 1, 2, 4, 8, 16, 32, 64, 128, 27, 54], i = m.AES = p.extend({
|
|
3479
3477
|
_doReset: function() {
|
|
3480
3478
|
var o;
|
|
3481
3479
|
if (!(this._nRounds && this._keyPriorReset === this._key)) {
|
|
3482
|
-
for (var
|
|
3480
|
+
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++)
|
|
3483
3481
|
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);
|
|
3484
3482
|
for (var w = this._invKeySchedule = [], H = 0; H < k; H++) {
|
|
3485
3483
|
var F = k - H;
|
|
@@ -3487,42 +3485,42 @@ function lx() {
|
|
|
3487
3485
|
var o = R[F];
|
|
3488
3486
|
else
|
|
3489
3487
|
var o = R[F - 4];
|
|
3490
|
-
H < 4 || F <= 4 ? w[H] = o : w[H] = s[B[o >>> 24]] ^ f[B[o >>> 16 & 255]] ^
|
|
3488
|
+
H < 4 || F <= 4 ? w[H] = o : w[H] = s[B[o >>> 24]] ^ f[B[o >>> 16 & 255]] ^ v[B[o >>> 8 & 255]] ^ h[B[o & 255]];
|
|
3491
3489
|
}
|
|
3492
3490
|
}
|
|
3493
3491
|
},
|
|
3494
|
-
encryptBlock: function(o,
|
|
3495
|
-
this._doCryptBlock(o,
|
|
3492
|
+
encryptBlock: function(o, l) {
|
|
3493
|
+
this._doCryptBlock(o, l, this._keySchedule, x, n, E, a, B);
|
|
3496
3494
|
},
|
|
3497
|
-
decryptBlock: function(o,
|
|
3498
|
-
var b = o[
|
|
3499
|
-
o[
|
|
3500
|
-
var b = o[
|
|
3501
|
-
o[
|
|
3495
|
+
decryptBlock: function(o, l) {
|
|
3496
|
+
var b = o[l + 1];
|
|
3497
|
+
o[l + 1] = o[l + 3], o[l + 3] = b, this._doCryptBlock(o, l, this._invKeySchedule, s, f, v, h, C);
|
|
3498
|
+
var b = o[l + 1];
|
|
3499
|
+
o[l + 1] = o[l + 3], o[l + 3] = b;
|
|
3502
3500
|
},
|
|
3503
|
-
_doCryptBlock: function(o,
|
|
3504
|
-
for (var w = this._nRounds, H = o[
|
|
3505
|
-
var T = g[H >>> 24] ^ y[$ >>> 16 & 255] ^ k[
|
|
3506
|
-
H = T, $ = N,
|
|
3501
|
+
_doCryptBlock: function(o, l, b, g, y, k, R, F) {
|
|
3502
|
+
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++) {
|
|
3503
|
+
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++];
|
|
3504
|
+
H = T, $ = N, z = j, O = S;
|
|
3507
3505
|
}
|
|
3508
|
-
var T = (F[H >>> 24] << 24 | F[$ >>> 16 & 255] << 16 | F[
|
|
3509
|
-
o[
|
|
3506
|
+
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++];
|
|
3507
|
+
o[l] = T, o[l + 1] = N, o[l + 2] = j, o[l + 3] = S;
|
|
3510
3508
|
},
|
|
3511
3509
|
keySize: 256 / 32
|
|
3512
3510
|
});
|
|
3513
|
-
e.AES =
|
|
3511
|
+
e.AES = p._createHelper(i);
|
|
3514
3512
|
})(), t.AES;
|
|
3515
3513
|
});
|
|
3516
3514
|
})(xr)), xr.exports;
|
|
3517
3515
|
}
|
|
3518
3516
|
var nr = { exports: {} }, hx = nr.exports, ve;
|
|
3519
3517
|
function vx() {
|
|
3520
|
-
return ve || (ve = 1, (function(r,
|
|
3521
|
-
(function(t, e,
|
|
3518
|
+
return ve || (ve = 1, (function(r, u) {
|
|
3519
|
+
(function(t, e, d) {
|
|
3522
3520
|
r.exports = e(M(), s0(), c0(), a0(), X());
|
|
3523
3521
|
})(hx, function(t) {
|
|
3524
3522
|
return (function() {
|
|
3525
|
-
var e = t,
|
|
3523
|
+
var e = t, d = e.lib, p = d.WordArray, m = d.BlockCipher, B = e.algo, C = [
|
|
3526
3524
|
57,
|
|
3527
3525
|
49,
|
|
3528
3526
|
41,
|
|
@@ -4168,20 +4166,20 @@ function vx() {
|
|
|
4168
4166
|
2147483679
|
|
4169
4167
|
], s = B.DES = m.extend({
|
|
4170
4168
|
_doReset: function() {
|
|
4171
|
-
for (var D = this._key, i = D.words, o = [],
|
|
4172
|
-
var b = C[
|
|
4173
|
-
o[
|
|
4169
|
+
for (var D = this._key, i = D.words, o = [], l = 0; l < 56; l++) {
|
|
4170
|
+
var b = C[l] - 1;
|
|
4171
|
+
o[l] = i[b >>> 5] >>> 31 - b % 32 & 1;
|
|
4174
4172
|
}
|
|
4175
4173
|
for (var g = this._subKeys = [], y = 0; y < 16; y++) {
|
|
4176
|
-
for (var k = g[y] = [], R = n[y],
|
|
4177
|
-
k[
|
|
4174
|
+
for (var k = g[y] = [], R = n[y], l = 0; l < 24; l++)
|
|
4175
|
+
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;
|
|
4178
4176
|
k[0] = k[0] << 1 | k[0] >>> 31;
|
|
4179
|
-
for (var
|
|
4180
|
-
k[
|
|
4177
|
+
for (var l = 1; l < 7; l++)
|
|
4178
|
+
k[l] = k[l] >>> (l - 1) * 4 + 3;
|
|
4181
4179
|
k[7] = k[7] << 5 | k[7] >>> 27;
|
|
4182
4180
|
}
|
|
4183
|
-
for (var F = this._invSubKeys = [],
|
|
4184
|
-
F[
|
|
4181
|
+
for (var F = this._invSubKeys = [], l = 0; l < 16; l++)
|
|
4182
|
+
F[l] = g[15 - l];
|
|
4185
4183
|
},
|
|
4186
4184
|
encryptBlock: function(D, i) {
|
|
4187
4185
|
this._doCryptBlock(D, i, this._subKeys);
|
|
@@ -4190,14 +4188,14 @@ function vx() {
|
|
|
4190
4188
|
this._doCryptBlock(D, i, this._invSubKeys);
|
|
4191
4189
|
},
|
|
4192
4190
|
_doCryptBlock: function(D, i, o) {
|
|
4193
|
-
this._lBlock = D[i], this._rBlock = D[i + 1], f.call(this, 4, 252645135), f.call(this, 16, 65535),
|
|
4194
|
-
for (var
|
|
4195
|
-
for (var b = o[
|
|
4191
|
+
this._lBlock = D[i], this._rBlock = D[i + 1], f.call(this, 4, 252645135), f.call(this, 16, 65535), v.call(this, 2, 858993459), v.call(this, 8, 16711935), f.call(this, 1, 1431655765);
|
|
4192
|
+
for (var l = 0; l < 16; l++) {
|
|
4193
|
+
for (var b = o[l], g = this._lBlock, y = this._rBlock, k = 0, R = 0; R < 8; R++)
|
|
4196
4194
|
k |= E[R][((y ^ b[R]) & a[R]) >>> 0];
|
|
4197
4195
|
this._lBlock = y, this._rBlock = g ^ k;
|
|
4198
4196
|
}
|
|
4199
4197
|
var F = this._lBlock;
|
|
4200
|
-
this._lBlock = this._rBlock, this._rBlock = F, f.call(this, 1, 1431655765),
|
|
4198
|
+
this._lBlock = this._rBlock, this._rBlock = F, f.call(this, 1, 1431655765), v.call(this, 8, 16711935), v.call(this, 2, 858993459), f.call(this, 16, 65535), f.call(this, 4, 252645135), D[i] = this._lBlock, D[i + 1] = this._rBlock;
|
|
4201
4199
|
},
|
|
4202
4200
|
keySize: 64 / 32,
|
|
4203
4201
|
ivSize: 64 / 32,
|
|
@@ -4207,18 +4205,18 @@ function vx() {
|
|
|
4207
4205
|
var o = (this._lBlock >>> D ^ this._rBlock) & i;
|
|
4208
4206
|
this._rBlock ^= o, this._lBlock ^= o << D;
|
|
4209
4207
|
}
|
|
4210
|
-
function
|
|
4208
|
+
function v(D, i) {
|
|
4211
4209
|
var o = (this._rBlock >>> D ^ this._lBlock) & i;
|
|
4212
4210
|
this._lBlock ^= o, this._rBlock ^= o << D;
|
|
4213
4211
|
}
|
|
4214
4212
|
e.DES = m._createHelper(s);
|
|
4215
|
-
var
|
|
4213
|
+
var h = B.TripleDES = m.extend({
|
|
4216
4214
|
_doReset: function() {
|
|
4217
4215
|
var D = this._key, i = D.words;
|
|
4218
4216
|
if (i.length !== 2 && i.length !== 4 && i.length < 6)
|
|
4219
4217
|
throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");
|
|
4220
|
-
var o = i.slice(0, 2),
|
|
4221
|
-
this._des1 = s.createEncryptor(
|
|
4218
|
+
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);
|
|
4219
|
+
this._des1 = s.createEncryptor(p.create(o)), this._des2 = s.createEncryptor(p.create(l)), this._des3 = s.createEncryptor(p.create(b));
|
|
4222
4220
|
},
|
|
4223
4221
|
encryptBlock: function(D, i) {
|
|
4224
4222
|
this._des1.encryptBlock(D, i), this._des2.decryptBlock(D, i), this._des3.encryptBlock(D, i);
|
|
@@ -4230,27 +4228,27 @@ function vx() {
|
|
|
4230
4228
|
ivSize: 64 / 32,
|
|
4231
4229
|
blockSize: 64 / 32
|
|
4232
4230
|
});
|
|
4233
|
-
e.TripleDES = m._createHelper(
|
|
4231
|
+
e.TripleDES = m._createHelper(h);
|
|
4234
4232
|
})(), t.TripleDES;
|
|
4235
4233
|
});
|
|
4236
4234
|
})(nr)), nr.exports;
|
|
4237
4235
|
}
|
|
4238
4236
|
var ar = { exports: {} }, px = ar.exports, pe;
|
|
4239
4237
|
function Bx() {
|
|
4240
|
-
return pe || (pe = 1, (function(r,
|
|
4241
|
-
(function(t, e,
|
|
4238
|
+
return pe || (pe = 1, (function(r, u) {
|
|
4239
|
+
(function(t, e, d) {
|
|
4242
4240
|
r.exports = e(M(), s0(), c0(), a0(), X());
|
|
4243
4241
|
})(px, function(t) {
|
|
4244
4242
|
return (function() {
|
|
4245
|
-
var e = t,
|
|
4243
|
+
var e = t, d = e.lib, p = d.StreamCipher, m = e.algo, B = m.RC4 = p.extend({
|
|
4246
4244
|
_doReset: function() {
|
|
4247
4245
|
for (var n = this._key, E = n.words, a = n.sigBytes, s = this._S = [], f = 0; f < 256; f++)
|
|
4248
4246
|
s[f] = f;
|
|
4249
|
-
for (var f = 0,
|
|
4250
|
-
var
|
|
4251
|
-
|
|
4247
|
+
for (var f = 0, v = 0; f < 256; f++) {
|
|
4248
|
+
var h = f % a, D = E[h >>> 2] >>> 24 - h % 4 * 8 & 255;
|
|
4249
|
+
v = (v + s[f] + D) % 256;
|
|
4252
4250
|
var i = s[f];
|
|
4253
|
-
s[f] = s[
|
|
4251
|
+
s[f] = s[v], s[v] = i;
|
|
4254
4252
|
}
|
|
4255
4253
|
this._i = this._j = 0;
|
|
4256
4254
|
},
|
|
@@ -4263,12 +4261,12 @@ function Bx() {
|
|
|
4263
4261
|
function C() {
|
|
4264
4262
|
for (var n = this._S, E = this._i, a = this._j, s = 0, f = 0; f < 4; f++) {
|
|
4265
4263
|
E = (E + 1) % 256, a = (a + n[E]) % 256;
|
|
4266
|
-
var
|
|
4267
|
-
n[E] = n[a], n[a] =
|
|
4264
|
+
var v = n[E];
|
|
4265
|
+
n[E] = n[a], n[a] = v, s |= n[(n[E] + n[a]) % 256] << 24 - f * 8;
|
|
4268
4266
|
}
|
|
4269
4267
|
return this._i = E, this._j = a, s;
|
|
4270
4268
|
}
|
|
4271
|
-
e.RC4 =
|
|
4269
|
+
e.RC4 = p._createHelper(B);
|
|
4272
4270
|
var x = m.RC4Drop = B.extend({
|
|
4273
4271
|
/**
|
|
4274
4272
|
* Configuration options.
|
|
@@ -4284,23 +4282,23 @@ function Bx() {
|
|
|
4284
4282
|
C.call(this);
|
|
4285
4283
|
}
|
|
4286
4284
|
});
|
|
4287
|
-
e.RC4Drop =
|
|
4285
|
+
e.RC4Drop = p._createHelper(x);
|
|
4288
4286
|
})(), t.RC4;
|
|
4289
4287
|
});
|
|
4290
4288
|
})(ar)), ar.exports;
|
|
4291
4289
|
}
|
|
4292
4290
|
var or = { exports: {} }, Cx = or.exports, Be;
|
|
4293
4291
|
function Ex() {
|
|
4294
|
-
return Be || (Be = 1, (function(r,
|
|
4295
|
-
(function(t, e,
|
|
4292
|
+
return Be || (Be = 1, (function(r, u) {
|
|
4293
|
+
(function(t, e, d) {
|
|
4296
4294
|
r.exports = e(M(), s0(), c0(), a0(), X());
|
|
4297
4295
|
})(Cx, function(t) {
|
|
4298
4296
|
return (function() {
|
|
4299
|
-
var e = t,
|
|
4297
|
+
var e = t, d = e.lib, p = d.StreamCipher, m = e.algo, B = [], C = [], x = [], n = m.Rabbit = p.extend({
|
|
4300
4298
|
_doReset: function() {
|
|
4301
4299
|
for (var a = this._key.words, s = this.cfg.iv, f = 0; f < 4; f++)
|
|
4302
4300
|
a[f] = (a[f] << 8 | a[f] >>> 24) & 16711935 | (a[f] << 24 | a[f] >>> 8) & 4278255360;
|
|
4303
|
-
var
|
|
4301
|
+
var v = this._X = [
|
|
4304
4302
|
a[0],
|
|
4305
4303
|
a[3] << 16 | a[2] >>> 16,
|
|
4306
4304
|
a[1],
|
|
@@ -4309,7 +4307,7 @@ function Ex() {
|
|
|
4309
4307
|
a[1] << 16 | a[0] >>> 16,
|
|
4310
4308
|
a[3],
|
|
4311
4309
|
a[2] << 16 | a[1] >>> 16
|
|
4312
|
-
],
|
|
4310
|
+
], h = this._C = [
|
|
4313
4311
|
a[2] << 16 | a[2] >>> 16,
|
|
4314
4312
|
a[0] & 4294901760 | a[1] & 65535,
|
|
4315
4313
|
a[3] << 16 | a[3] >>> 16,
|
|
@@ -4323,10 +4321,10 @@ function Ex() {
|
|
|
4323
4321
|
for (var f = 0; f < 4; f++)
|
|
4324
4322
|
E.call(this);
|
|
4325
4323
|
for (var f = 0; f < 8; f++)
|
|
4326
|
-
|
|
4324
|
+
h[f] ^= v[f + 4 & 7];
|
|
4327
4325
|
if (s) {
|
|
4328
|
-
var D = s.words, i = D[0], o = D[1],
|
|
4329
|
-
|
|
4326
|
+
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;
|
|
4327
|
+
h[0] ^= l, h[1] ^= g, h[2] ^= b, h[3] ^= y, h[4] ^= l, h[5] ^= g, h[6] ^= b, h[7] ^= y;
|
|
4330
4328
|
for (var f = 0; f < 4; f++)
|
|
4331
4329
|
E.call(this);
|
|
4332
4330
|
}
|
|
@@ -4334,8 +4332,8 @@ function Ex() {
|
|
|
4334
4332
|
_doProcessBlock: function(a, s) {
|
|
4335
4333
|
var f = this._X;
|
|
4336
4334
|
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;
|
|
4337
|
-
for (var
|
|
4338
|
-
B[
|
|
4335
|
+
for (var v = 0; v < 4; v++)
|
|
4336
|
+
B[v] = (B[v] << 8 | B[v] >>> 24) & 16711935 | (B[v] << 24 | B[v] >>> 8) & 4278255360, a[s + v] ^= B[v];
|
|
4339
4337
|
},
|
|
4340
4338
|
blockSize: 128 / 32,
|
|
4341
4339
|
ivSize: 64 / 32
|
|
@@ -4345,24 +4343,24 @@ function Ex() {
|
|
|
4345
4343
|
C[f] = s[f];
|
|
4346
4344
|
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;
|
|
4347
4345
|
for (var f = 0; f < 8; f++) {
|
|
4348
|
-
var
|
|
4346
|
+
var v = a[f] + s[f], h = v & 65535, D = v >>> 16, i = ((h * h >>> 17) + h * D >>> 15) + D * D, o = ((v & 4294901760) * v | 0) + ((v & 65535) * v | 0);
|
|
4349
4347
|
x[f] = i ^ o;
|
|
4350
4348
|
}
|
|
4351
4349
|
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;
|
|
4352
4350
|
}
|
|
4353
|
-
e.Rabbit =
|
|
4351
|
+
e.Rabbit = p._createHelper(n);
|
|
4354
4352
|
})(), t.Rabbit;
|
|
4355
4353
|
});
|
|
4356
4354
|
})(or)), or.exports;
|
|
4357
4355
|
}
|
|
4358
4356
|
var ir = { exports: {} }, Ax = ir.exports, Ce;
|
|
4359
4357
|
function Fx() {
|
|
4360
|
-
return Ce || (Ce = 1, (function(r,
|
|
4361
|
-
(function(t, e,
|
|
4358
|
+
return Ce || (Ce = 1, (function(r, u) {
|
|
4359
|
+
(function(t, e, d) {
|
|
4362
4360
|
r.exports = e(M(), s0(), c0(), a0(), X());
|
|
4363
4361
|
})(Ax, function(t) {
|
|
4364
4362
|
return (function() {
|
|
4365
|
-
var e = t,
|
|
4363
|
+
var e = t, d = e.lib, p = d.StreamCipher, m = e.algo, B = [], C = [], x = [], n = m.RabbitLegacy = p.extend({
|
|
4366
4364
|
_doReset: function() {
|
|
4367
4365
|
var a = this._key.words, s = this.cfg.iv, f = this._X = [
|
|
4368
4366
|
a[0],
|
|
@@ -4373,7 +4371,7 @@ function Fx() {
|
|
|
4373
4371
|
a[1] << 16 | a[0] >>> 16,
|
|
4374
4372
|
a[3],
|
|
4375
4373
|
a[2] << 16 | a[1] >>> 16
|
|
4376
|
-
],
|
|
4374
|
+
], v = this._C = [
|
|
4377
4375
|
a[2] << 16 | a[2] >>> 16,
|
|
4378
4376
|
a[0] & 4294901760 | a[1] & 65535,
|
|
4379
4377
|
a[3] << 16 | a[3] >>> 16,
|
|
@@ -4384,22 +4382,22 @@ function Fx() {
|
|
|
4384
4382
|
a[3] & 4294901760 | a[0] & 65535
|
|
4385
4383
|
];
|
|
4386
4384
|
this._b = 0;
|
|
4387
|
-
for (var
|
|
4385
|
+
for (var h = 0; h < 4; h++)
|
|
4388
4386
|
E.call(this);
|
|
4389
|
-
for (var
|
|
4390
|
-
|
|
4387
|
+
for (var h = 0; h < 8; h++)
|
|
4388
|
+
v[h] ^= f[h + 4 & 7];
|
|
4391
4389
|
if (s) {
|
|
4392
|
-
var D = s.words, i = D[0], o = D[1],
|
|
4393
|
-
|
|
4394
|
-
for (var
|
|
4390
|
+
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;
|
|
4391
|
+
v[0] ^= l, v[1] ^= g, v[2] ^= b, v[3] ^= y, v[4] ^= l, v[5] ^= g, v[6] ^= b, v[7] ^= y;
|
|
4392
|
+
for (var h = 0; h < 4; h++)
|
|
4395
4393
|
E.call(this);
|
|
4396
4394
|
}
|
|
4397
4395
|
},
|
|
4398
4396
|
_doProcessBlock: function(a, s) {
|
|
4399
4397
|
var f = this._X;
|
|
4400
4398
|
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;
|
|
4401
|
-
for (var
|
|
4402
|
-
B[
|
|
4399
|
+
for (var v = 0; v < 4; v++)
|
|
4400
|
+
B[v] = (B[v] << 8 | B[v] >>> 24) & 16711935 | (B[v] << 24 | B[v] >>> 8) & 4278255360, a[s + v] ^= B[v];
|
|
4403
4401
|
},
|
|
4404
4402
|
blockSize: 128 / 32,
|
|
4405
4403
|
ivSize: 64 / 32
|
|
@@ -4409,24 +4407,24 @@ function Fx() {
|
|
|
4409
4407
|
C[f] = s[f];
|
|
4410
4408
|
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;
|
|
4411
4409
|
for (var f = 0; f < 8; f++) {
|
|
4412
|
-
var
|
|
4410
|
+
var v = a[f] + s[f], h = v & 65535, D = v >>> 16, i = ((h * h >>> 17) + h * D >>> 15) + D * D, o = ((v & 4294901760) * v | 0) + ((v & 65535) * v | 0);
|
|
4413
4411
|
x[f] = i ^ o;
|
|
4414
4412
|
}
|
|
4415
4413
|
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;
|
|
4416
4414
|
}
|
|
4417
|
-
e.RabbitLegacy =
|
|
4415
|
+
e.RabbitLegacy = p._createHelper(n);
|
|
4418
4416
|
})(), t.RabbitLegacy;
|
|
4419
4417
|
});
|
|
4420
4418
|
})(ir)), ir.exports;
|
|
4421
4419
|
}
|
|
4422
4420
|
var sr = { exports: {} }, gx = sr.exports, Ee;
|
|
4423
4421
|
function Dx() {
|
|
4424
|
-
return Ee || (Ee = 1, (function(r,
|
|
4425
|
-
(function(t, e,
|
|
4422
|
+
return Ee || (Ee = 1, (function(r, u) {
|
|
4423
|
+
(function(t, e, d) {
|
|
4426
4424
|
r.exports = e(M(), s0(), c0(), a0(), X());
|
|
4427
4425
|
})(gx, function(t) {
|
|
4428
4426
|
return (function() {
|
|
4429
|
-
var e = t,
|
|
4427
|
+
var e = t, d = e.lib, p = d.BlockCipher, m = e.algo;
|
|
4430
4428
|
const B = 16, C = [
|
|
4431
4429
|
608135816,
|
|
4432
4430
|
2242054355,
|
|
@@ -5484,68 +5482,68 @@ function Dx() {
|
|
|
5484
5482
|
pbox: [],
|
|
5485
5483
|
sbox: []
|
|
5486
5484
|
};
|
|
5487
|
-
function E(
|
|
5488
|
-
let i = D >> 24 & 255, o = D >> 16 & 255,
|
|
5489
|
-
return g = g ^
|
|
5485
|
+
function E(h, D) {
|
|
5486
|
+
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];
|
|
5487
|
+
return g = g ^ h.sbox[2][l], g = g + h.sbox[3][b], g;
|
|
5490
5488
|
}
|
|
5491
|
-
function a(
|
|
5492
|
-
let o = D,
|
|
5489
|
+
function a(h, D, i) {
|
|
5490
|
+
let o = D, l = i, b;
|
|
5493
5491
|
for (let g = 0; g < B; ++g)
|
|
5494
|
-
o = o ^
|
|
5495
|
-
return b = o, o =
|
|
5492
|
+
o = o ^ h.pbox[g], l = E(h, o) ^ l, b = o, o = l, l = b;
|
|
5493
|
+
return b = o, o = l, l = b, l = l ^ h.pbox[B], o = o ^ h.pbox[B + 1], { left: o, right: l };
|
|
5496
5494
|
}
|
|
5497
|
-
function s(
|
|
5498
|
-
let o = D,
|
|
5495
|
+
function s(h, D, i) {
|
|
5496
|
+
let o = D, l = i, b;
|
|
5499
5497
|
for (let g = B + 1; g > 1; --g)
|
|
5500
|
-
o = o ^
|
|
5501
|
-
return b = o, o =
|
|
5498
|
+
o = o ^ h.pbox[g], l = E(h, o) ^ l, b = o, o = l, l = b;
|
|
5499
|
+
return b = o, o = l, l = b, l = l ^ h.pbox[1], o = o ^ h.pbox[0], { left: o, right: l };
|
|
5502
5500
|
}
|
|
5503
|
-
function f(
|
|
5501
|
+
function f(h, D, i) {
|
|
5504
5502
|
for (let y = 0; y < 4; y++) {
|
|
5505
|
-
|
|
5503
|
+
h.sbox[y] = [];
|
|
5506
5504
|
for (let k = 0; k < 256; k++)
|
|
5507
|
-
|
|
5505
|
+
h.sbox[y][k] = x[y][k];
|
|
5508
5506
|
}
|
|
5509
5507
|
let o = 0;
|
|
5510
5508
|
for (let y = 0; y < B + 2; y++)
|
|
5511
|
-
|
|
5512
|
-
let
|
|
5509
|
+
h.pbox[y] = C[y] ^ D[o], o++, o >= i && (o = 0);
|
|
5510
|
+
let l = 0, b = 0, g = 0;
|
|
5513
5511
|
for (let y = 0; y < B + 2; y += 2)
|
|
5514
|
-
g = a(
|
|
5512
|
+
g = a(h, l, b), l = g.left, b = g.right, h.pbox[y] = l, h.pbox[y + 1] = b;
|
|
5515
5513
|
for (let y = 0; y < 4; y++)
|
|
5516
5514
|
for (let k = 0; k < 256; k += 2)
|
|
5517
|
-
g = a(
|
|
5515
|
+
g = a(h, l, b), l = g.left, b = g.right, h.sbox[y][k] = l, h.sbox[y][k + 1] = b;
|
|
5518
5516
|
return !0;
|
|
5519
5517
|
}
|
|
5520
|
-
var
|
|
5518
|
+
var v = m.Blowfish = p.extend({
|
|
5521
5519
|
_doReset: function() {
|
|
5522
5520
|
if (this._keyPriorReset !== this._key) {
|
|
5523
|
-
var
|
|
5521
|
+
var h = this._keyPriorReset = this._key, D = h.words, i = h.sigBytes / 4;
|
|
5524
5522
|
f(n, D, i);
|
|
5525
5523
|
}
|
|
5526
5524
|
},
|
|
5527
|
-
encryptBlock: function(
|
|
5528
|
-
var i = a(n,
|
|
5529
|
-
|
|
5525
|
+
encryptBlock: function(h, D) {
|
|
5526
|
+
var i = a(n, h[D], h[D + 1]);
|
|
5527
|
+
h[D] = i.left, h[D + 1] = i.right;
|
|
5530
5528
|
},
|
|
5531
|
-
decryptBlock: function(
|
|
5532
|
-
var i = s(n,
|
|
5533
|
-
|
|
5529
|
+
decryptBlock: function(h, D) {
|
|
5530
|
+
var i = s(n, h[D], h[D + 1]);
|
|
5531
|
+
h[D] = i.left, h[D + 1] = i.right;
|
|
5534
5532
|
},
|
|
5535
5533
|
blockSize: 64 / 32,
|
|
5536
5534
|
keySize: 128 / 32,
|
|
5537
5535
|
ivSize: 64 / 32
|
|
5538
5536
|
});
|
|
5539
|
-
e.Blowfish =
|
|
5537
|
+
e.Blowfish = p._createHelper(v);
|
|
5540
5538
|
})(), t.Blowfish;
|
|
5541
5539
|
});
|
|
5542
5540
|
})(sr)), sr.exports;
|
|
5543
5541
|
}
|
|
5544
5542
|
var bx = y0.exports, Ae;
|
|
5545
5543
|
function mx() {
|
|
5546
|
-
return Ae || (Ae = 1, (function(r,
|
|
5547
|
-
(function(t, e,
|
|
5548
|
-
r.exports = e(M(), dr(), Ft(), Dt(), s0(), _t(), c0(), ke(), Fr(), Ht(), Se(), Pt(),
|
|
5544
|
+
return Ae || (Ae = 1, (function(r, u) {
|
|
5545
|
+
(function(t, e, d) {
|
|
5546
|
+
r.exports = e(M(), dr(), Ft(), Dt(), s0(), _t(), c0(), ke(), Fr(), Ht(), Se(), Pt(), Wt(), Lt(), gr(), Tt(), a0(), X(), jt(), Kt(), Yt(), Qt(), Jt(), ex(), xx(), ax(), ix(), cx(), dx(), lx(), vx(), Bx(), Ex(), Fx(), Dx());
|
|
5549
5547
|
})(bx, function(t) {
|
|
5550
5548
|
return t;
|
|
5551
5549
|
});
|
|
@@ -5566,11 +5564,11 @@ function yx() {
|
|
|
5566
5564
|
};
|
|
5567
5565
|
}
|
|
5568
5566
|
function wx(r) {
|
|
5569
|
-
return `/sdk-workers/${(r.split("/").pop() || r).replace(/\.ts$/, ".js")}?v=1.1.
|
|
5567
|
+
return `/sdk-workers/${(r.split("/").pop() || r).replace(/\.ts$/, ".js")}?v=1.1.157`;
|
|
5570
5568
|
}
|
|
5571
|
-
function kx(r,
|
|
5569
|
+
function kx(r, u) {
|
|
5572
5570
|
const t = wx(r);
|
|
5573
|
-
return new Worker(t, { type: "module", ...
|
|
5571
|
+
return new Worker(t, { type: "module", ...u });
|
|
5574
5572
|
}
|
|
5575
5573
|
const Dr = () => {
|
|
5576
5574
|
try {
|
|
@@ -5582,47 +5580,47 @@ const Dr = () => {
|
|
|
5582
5580
|
Dr();
|
|
5583
5581
|
}, Fe = (...r) => {
|
|
5584
5582
|
Dr();
|
|
5585
|
-
}, ge = /* @__PURE__ */ new Map(),
|
|
5583
|
+
}, ge = /* @__PURE__ */ new Map(), Br = /* @__PURE__ */ new Map();
|
|
5586
5584
|
let Sx = 0;
|
|
5587
5585
|
function Hx(r) {
|
|
5588
|
-
const
|
|
5589
|
-
if (
|
|
5586
|
+
const u = ge.get(r);
|
|
5587
|
+
if (u) return u;
|
|
5590
5588
|
const t = kx("./deform.worker.ts");
|
|
5591
5589
|
try {
|
|
5592
5590
|
t.postMessage({ type: "SET_DEBUG", debugRender: Dr() });
|
|
5593
5591
|
} catch {
|
|
5594
5592
|
}
|
|
5595
|
-
t.onmessage = (
|
|
5596
|
-
const { id:
|
|
5597
|
-
m0(`[renderService] deform worker 响应 id=${
|
|
5593
|
+
t.onmessage = (d) => {
|
|
5594
|
+
const { id: p, imageBitmap: m, error: B, duration: C } = d.data ?? {}, x = C ? ` worker耗时=${Math.round(C)}ms` : "";
|
|
5595
|
+
m0(`[renderService] deform worker 响应 id=${p}${x}`, {
|
|
5598
5596
|
hasImageBitmap: !!m,
|
|
5599
5597
|
width: m?.width,
|
|
5600
5598
|
height: m?.height,
|
|
5601
5599
|
error: B
|
|
5602
5600
|
});
|
|
5603
|
-
const n =
|
|
5601
|
+
const n = Br.get(p);
|
|
5604
5602
|
if (n) {
|
|
5605
|
-
if (
|
|
5603
|
+
if (Br.delete(p), B) {
|
|
5606
5604
|
n.reject(new Error(B));
|
|
5607
5605
|
return;
|
|
5608
5606
|
}
|
|
5609
5607
|
n.resolve(m);
|
|
5610
5608
|
}
|
|
5611
|
-
}, t.onerror = (
|
|
5609
|
+
}, t.onerror = (d) => {
|
|
5612
5610
|
};
|
|
5613
5611
|
const e = () => {
|
|
5614
|
-
const
|
|
5612
|
+
const d = yx();
|
|
5615
5613
|
return m0("🔍 [workerManager] 检查 License Token:", {
|
|
5616
|
-
hasToken: !!
|
|
5617
|
-
tokenPreview:
|
|
5614
|
+
hasToken: !!d.token,
|
|
5615
|
+
tokenPreview: d.token ? d.token.substring(0, 20) + "..." : "undefined",
|
|
5618
5616
|
faceId: r,
|
|
5619
5617
|
source: "licenseStore模块"
|
|
5620
|
-
}),
|
|
5618
|
+
}), d.token ? (m0("📤 [workerManager] 发送 License 到新创建的 Worker", { faceId: r }), t.postMessage({
|
|
5621
5619
|
type: "SET_LICENSE",
|
|
5622
|
-
licenseToken:
|
|
5623
|
-
licenseApiUrl:
|
|
5624
|
-
deviceId:
|
|
5625
|
-
domain:
|
|
5620
|
+
licenseToken: d.token,
|
|
5621
|
+
licenseApiUrl: d.apiUrl,
|
|
5622
|
+
deviceId: d.deviceId,
|
|
5623
|
+
domain: d.domain
|
|
5626
5624
|
}), !0) : !1;
|
|
5627
5625
|
};
|
|
5628
5626
|
return e() || (m0("⏳ [workerManager] License Token 未设置,等待后重试...", { faceId: r }), setTimeout(() => {
|
|
@@ -5637,10 +5635,10 @@ function $x(r) {
|
|
|
5637
5635
|
type: r.type,
|
|
5638
5636
|
blendMode: r.blendMode,
|
|
5639
5637
|
transform: Array.isArray(r.transform) ? [...r.transform] : [],
|
|
5640
|
-
meshPoints: Array.isArray(r.meshPoints) ? r.meshPoints.map((
|
|
5641
|
-
x:
|
|
5642
|
-
y:
|
|
5643
|
-
type:
|
|
5638
|
+
meshPoints: Array.isArray(r.meshPoints) ? r.meshPoints.map((u) => ({
|
|
5639
|
+
x: u.x,
|
|
5640
|
+
y: u.y,
|
|
5641
|
+
type: u.type
|
|
5644
5642
|
})) : [],
|
|
5645
5643
|
bounds: r.bounds ? {
|
|
5646
5644
|
width: r.bounds.width,
|
|
@@ -5663,30 +5661,30 @@ function $x(r) {
|
|
|
5663
5661
|
layerOrder: r.layerOrder,
|
|
5664
5662
|
imagePath: r.imagePath,
|
|
5665
5663
|
vectorMask: r.vectorMask ? {
|
|
5666
|
-
paths: r.vectorMask.paths?.map((
|
|
5667
|
-
open:
|
|
5668
|
-
knots:
|
|
5664
|
+
paths: r.vectorMask.paths?.map((u) => ({
|
|
5665
|
+
open: u.open,
|
|
5666
|
+
knots: u.knots?.map((t) => ({
|
|
5669
5667
|
linked: t.linked,
|
|
5670
5668
|
points: [...t.points]
|
|
5671
5669
|
})),
|
|
5672
|
-
fillRule:
|
|
5673
|
-
operation:
|
|
5670
|
+
fillRule: u.fillRule,
|
|
5671
|
+
operation: u.operation
|
|
5674
5672
|
})),
|
|
5675
|
-
points: r.vectorMask.points?.map((
|
|
5676
|
-
x:
|
|
5677
|
-
y:
|
|
5678
|
-
type:
|
|
5673
|
+
points: r.vectorMask.points?.map((u) => ({
|
|
5674
|
+
x: u.x,
|
|
5675
|
+
y: u.y,
|
|
5676
|
+
type: u.type
|
|
5679
5677
|
})),
|
|
5680
5678
|
invert: r.vectorMask.invert,
|
|
5681
5679
|
notLink: r.vectorMask.notLink,
|
|
5682
5680
|
disable: r.vectorMask.disable,
|
|
5683
5681
|
fillStartsWithAllPixels: r.vectorMask.fillStartsWithAllPixels
|
|
5684
5682
|
} : void 0,
|
|
5685
|
-
filterList: r.filterList ? r.filterList.map((
|
|
5686
|
-
type:
|
|
5687
|
-
enabled:
|
|
5688
|
-
filter:
|
|
5689
|
-
puppetShapeList:
|
|
5683
|
+
filterList: r.filterList ? r.filterList.map((u) => ({
|
|
5684
|
+
type: u.type,
|
|
5685
|
+
enabled: u.enabled,
|
|
5686
|
+
filter: u.filter ? {
|
|
5687
|
+
puppetShapeList: u.filter.puppetShapeList?.map((t) => ({
|
|
5690
5688
|
originalVertexArray: t.originalVertexArray.map((e) => ({
|
|
5691
5689
|
x: e.x,
|
|
5692
5690
|
y: e.y
|
|
@@ -5703,33 +5701,33 @@ function $x(r) {
|
|
|
5703
5701
|
clipping: r.clipping
|
|
5704
5702
|
};
|
|
5705
5703
|
}
|
|
5706
|
-
function Rx(r,
|
|
5707
|
-
const
|
|
5704
|
+
function Rx(r, u, t, e) {
|
|
5705
|
+
const d = ++Sx, p = Hx(t);
|
|
5708
5706
|
return performance.now(), (/* @__PURE__ */ new Date()).toISOString(), new Promise((m, B) => {
|
|
5709
|
-
|
|
5707
|
+
Br.set(d, {
|
|
5710
5708
|
resolve: (x) => {
|
|
5711
5709
|
performance.now(), (/* @__PURE__ */ new Date()).toISOString(), m(x);
|
|
5712
5710
|
},
|
|
5713
5711
|
reject: B
|
|
5714
5712
|
});
|
|
5715
|
-
const C = $x(
|
|
5716
|
-
|
|
5713
|
+
const C = $x(u);
|
|
5714
|
+
p.postMessage({ id: d, designBitmap: r, layerData: C, canvasSize: e }, [
|
|
5717
5715
|
r
|
|
5718
5716
|
]);
|
|
5719
5717
|
});
|
|
5720
5718
|
}
|
|
5721
|
-
async function Px(r,
|
|
5722
|
-
const m = await
|
|
5719
|
+
async function Px(r, u, t = 0, e, d, p) {
|
|
5720
|
+
const m = await dt(r, d, p);
|
|
5723
5721
|
if (!m || m.width === 0 || m.height === 0)
|
|
5724
5722
|
throw new Error("图片无效:尺寸为 0");
|
|
5725
|
-
return await Rx(m,
|
|
5723
|
+
return await Rx(m, u, t, e);
|
|
5726
5724
|
}
|
|
5727
|
-
function l0(r,
|
|
5725
|
+
function l0(r, u) {
|
|
5728
5726
|
if (typeof OffscreenCanvas < "u" && typeof document > "u")
|
|
5729
|
-
return new OffscreenCanvas(r,
|
|
5727
|
+
return new OffscreenCanvas(r, u);
|
|
5730
5728
|
if (typeof document < "u") {
|
|
5731
5729
|
const t = document.createElement("canvas");
|
|
5732
|
-
return t.width = r, t.height =
|
|
5730
|
+
return t.width = r, t.height = u, t;
|
|
5733
5731
|
} else
|
|
5734
5732
|
throw new Error("无法创建 canvas:不在 Worker 或主线程环境中");
|
|
5735
5733
|
}
|
|
@@ -5737,13 +5735,13 @@ function F0(r) {
|
|
|
5737
5735
|
return r.getContext("2d");
|
|
5738
5736
|
}
|
|
5739
5737
|
function De(r) {
|
|
5740
|
-
const
|
|
5741
|
-
if (!
|
|
5738
|
+
const u = F0(r);
|
|
5739
|
+
if (!u)
|
|
5742
5740
|
throw new Error("无法创建 canvas context");
|
|
5743
|
-
return
|
|
5741
|
+
return u;
|
|
5744
5742
|
}
|
|
5745
|
-
async function
|
|
5746
|
-
const
|
|
5743
|
+
async function zx(r) {
|
|
5744
|
+
const u = performance.now(), t = () => {
|
|
5747
5745
|
try {
|
|
5748
5746
|
if (globalThis.__DEBUG_RENDER__ === !0 || typeof localStorage < "u" && localStorage.getItem("DEBUG_RENDER") === "1") return !0;
|
|
5749
5747
|
} catch {
|
|
@@ -5751,10 +5749,10 @@ async function Wx(r) {
|
|
|
5751
5749
|
return !1;
|
|
5752
5750
|
}, e = (...c) => {
|
|
5753
5751
|
t();
|
|
5754
|
-
},
|
|
5752
|
+
}, d = (...c) => {
|
|
5755
5753
|
t();
|
|
5756
5754
|
}, {
|
|
5757
|
-
psdJson:
|
|
5755
|
+
psdJson: p,
|
|
5758
5756
|
materialList: m,
|
|
5759
5757
|
fabricScreenshotList: B,
|
|
5760
5758
|
width: C,
|
|
@@ -5762,8 +5760,8 @@ async function Wx(r) {
|
|
|
5762
5760
|
baseUrl: n
|
|
5763
5761
|
} = r, E = r.maxImageSize;
|
|
5764
5762
|
e("[renderByJson] 接收到的数据:", {
|
|
5765
|
-
psdJsonLayerCount:
|
|
5766
|
-
psdJsonLayers:
|
|
5763
|
+
psdJsonLayerCount: p.layerList?.length || 0,
|
|
5764
|
+
psdJsonLayers: p.layerList?.map((c) => ({
|
|
5767
5765
|
name: c.name,
|
|
5768
5766
|
type: c.type,
|
|
5769
5767
|
id: c.id,
|
|
@@ -5789,7 +5787,7 @@ async function Wx(r) {
|
|
|
5789
5787
|
const _ = new URL(c, n).toString();
|
|
5790
5788
|
return !_.includes("http") && !_.startsWith("data:") && !_.startsWith("blob:") ? void 0 : _;
|
|
5791
5789
|
} catch (_) {
|
|
5792
|
-
|
|
5790
|
+
d(`[renderByJson] 解析图片 URL 失败: ${c}`, _);
|
|
5793
5791
|
return;
|
|
5794
5792
|
}
|
|
5795
5793
|
}, s = {}, f = /* @__PURE__ */ new Map();
|
|
@@ -5801,42 +5799,42 @@ async function Wx(r) {
|
|
|
5801
5799
|
url: c.url
|
|
5802
5800
|
}), f.set(c.layerName, c.url));
|
|
5803
5801
|
}
|
|
5804
|
-
const
|
|
5802
|
+
const v = /* @__PURE__ */ new Map();
|
|
5805
5803
|
for (const c of B)
|
|
5806
|
-
|
|
5807
|
-
e("[renderByJson] fabricScreenshotMap:", Array.from(
|
|
5804
|
+
v.set(c.id, c.url);
|
|
5805
|
+
e("[renderByJson] fabricScreenshotMap:", Array.from(v.entries())), e("[renderByJson] psdJson.layerList 结构:", p.layerList?.map((c) => ({
|
|
5808
5806
|
name: c.name,
|
|
5809
5807
|
type: c.type,
|
|
5810
5808
|
id: c.id,
|
|
5811
5809
|
hasChildren: !!c.children,
|
|
5812
5810
|
childrenCount: c.children?.length || 0
|
|
5813
5811
|
})));
|
|
5814
|
-
function
|
|
5812
|
+
function h(c, A) {
|
|
5815
5813
|
const _ = c.color || (c.name && ["粉", "白", "绿", "红", "蓝", "黄", "黑", "灰"].includes(c.name) ? c.name : A);
|
|
5816
5814
|
if (c.type === "Layer") {
|
|
5817
5815
|
if (c.imagePath) {
|
|
5818
|
-
const
|
|
5816
|
+
const W = m.find((P) => {
|
|
5819
5817
|
const L = P.sourceName || P.layerName;
|
|
5820
5818
|
return !L || !c.imagePath ? !1 : L === c.imagePath || L.endsWith(c.imagePath) || c.imagePath.endsWith(L);
|
|
5821
5819
|
});
|
|
5822
|
-
|
|
5823
|
-
url:
|
|
5820
|
+
W && (s[c.imagePath] = {
|
|
5821
|
+
url: W.url
|
|
5824
5822
|
});
|
|
5825
5823
|
}
|
|
5826
5824
|
if (c.name) {
|
|
5827
5825
|
if (_) {
|
|
5828
|
-
const
|
|
5826
|
+
const W = `${_}-${c.name}`, P = m.find((L) => {
|
|
5829
5827
|
const I = L.sourceName || L.layerName;
|
|
5830
5828
|
return I ? (I.split("/").pop() || I).replace(/\.(png|jpg|jpeg|gif|webp)$/i, "").startsWith(`${_}-${c.name}`) : !1;
|
|
5831
5829
|
});
|
|
5832
|
-
P && (s[
|
|
5830
|
+
P && (s[W] = {
|
|
5833
5831
|
url: P.url
|
|
5834
5832
|
});
|
|
5835
5833
|
}
|
|
5836
5834
|
if (c.imagePath && c.name) {
|
|
5837
|
-
const
|
|
5835
|
+
const W = c.imagePath.split("/").pop() || c.imagePath, P = m.find((L) => {
|
|
5838
5836
|
const I = L.sourceName || L.layerName;
|
|
5839
|
-
return I ? (I.split("/").pop() || I) ===
|
|
5837
|
+
return I ? (I.split("/").pop() || I) === W : !1;
|
|
5840
5838
|
});
|
|
5841
5839
|
P && (s[c.imagePath] = {
|
|
5842
5840
|
url: P.url
|
|
@@ -5845,37 +5843,37 @@ async function Wx(r) {
|
|
|
5845
5843
|
}
|
|
5846
5844
|
}
|
|
5847
5845
|
if (c.children)
|
|
5848
|
-
for (const
|
|
5849
|
-
|
|
5846
|
+
for (const W of c.children)
|
|
5847
|
+
W && h(W, _);
|
|
5850
5848
|
}
|
|
5851
5849
|
function D(c, A) {
|
|
5852
5850
|
const _ = c.id ?? A;
|
|
5853
5851
|
if (c.type === "Group" && _)
|
|
5854
|
-
if (e(`[renderByJson] processLayer 检查 Group: name="${c.name}", id=${_}, hasFabricScreenshot=${
|
|
5855
|
-
const
|
|
5856
|
-
if (e(`[renderByJson] ✅ 找到匹配的 fabricScreenshot: Group id=${_}, name="${c.name}", url=${
|
|
5852
|
+
if (e(`[renderByJson] processLayer 检查 Group: name="${c.name}", id=${_}, hasFabricScreenshot=${v.has(_)}`), v.has(_)) {
|
|
5853
|
+
const W = v.get(_);
|
|
5854
|
+
if (e(`[renderByJson] ✅ 找到匹配的 fabricScreenshot: Group id=${_}, name="${c.name}", url=${W.substring(0, 50)}...`), c.children) {
|
|
5857
5855
|
e(`[renderByJson] Group "${c.name}" 有 ${c.children.length} 个子图层`);
|
|
5858
5856
|
for (const P of c.children)
|
|
5859
5857
|
if (P && P.isSmartObject === !0) {
|
|
5860
5858
|
const L = P?.name || "";
|
|
5861
|
-
e(`[renderByJson] 找到智能对象: name="${L}"`), L && !s[L] && (s[L] = {}), L ? (s[L].designImage =
|
|
5859
|
+
e(`[renderByJson] 找到智能对象: name="${L}"`), L && !s[L] && (s[L] = {}), L ? (s[L].designImage = W, e(`[renderByJson] ✅ 为智能对象 "${L}" 设置 designImage: ${W.substring(0, 50)}...`)) : d("[renderByJson] ⚠️ 智能对象没有 name,无法设置 designImage");
|
|
5862
5860
|
}
|
|
5863
5861
|
} else
|
|
5864
|
-
|
|
5862
|
+
d(`[renderByJson] ⚠️ Group id=${_} 没有 children`);
|
|
5865
5863
|
} else
|
|
5866
5864
|
e(`[renderByJson] ⚠️ Group id=${_}, name="${c.name}" 没有匹配的 fabricScreenshot`);
|
|
5867
5865
|
if (c.children)
|
|
5868
|
-
for (const
|
|
5869
|
-
|
|
5866
|
+
for (const W of c.children)
|
|
5867
|
+
W && D(W, _);
|
|
5870
5868
|
}
|
|
5871
|
-
if (
|
|
5872
|
-
for (const c of
|
|
5873
|
-
c &&
|
|
5874
|
-
if (
|
|
5875
|
-
for (const c of
|
|
5869
|
+
if (p.layerList)
|
|
5870
|
+
for (const c of p.layerList)
|
|
5871
|
+
c && h(c);
|
|
5872
|
+
if (p.layerList)
|
|
5873
|
+
for (const c of p.layerList)
|
|
5876
5874
|
c && D(c);
|
|
5877
5875
|
const o = Je([{
|
|
5878
|
-
psdJson:
|
|
5876
|
+
psdJson: p,
|
|
5879
5877
|
layerExtrasByName: s
|
|
5880
5878
|
}], {
|
|
5881
5879
|
parts: [],
|
|
@@ -5883,59 +5881,59 @@ async function Wx(r) {
|
|
|
5883
5881
|
});
|
|
5884
5882
|
if (!o.models || o.models.length === 0)
|
|
5885
5883
|
throw new Error("无法解析 JSON 数据");
|
|
5886
|
-
const
|
|
5887
|
-
if (!
|
|
5884
|
+
const l = o.models[0];
|
|
5885
|
+
if (!l.psdPartData)
|
|
5888
5886
|
throw new Error("JSON 数据中没有 psdPartData");
|
|
5889
|
-
const b =
|
|
5887
|
+
const b = l.width, g = l.height, y = l0(b, g), k = De(y), R = [], F = (c) => {
|
|
5890
5888
|
if (c.url && s[c.url])
|
|
5891
5889
|
return s[c.url];
|
|
5892
5890
|
if (c.url) {
|
|
5893
5891
|
const A = c.url.split("/").pop() || c.url;
|
|
5894
5892
|
if (s[A])
|
|
5895
5893
|
return s[A];
|
|
5896
|
-
const _ = m.find((
|
|
5897
|
-
const P =
|
|
5894
|
+
const _ = m.find((W) => {
|
|
5895
|
+
const P = W.sourceName || W.layerName;
|
|
5898
5896
|
return !P || !c.url ? !1 : (P.split("/").pop() || P) === A || P === c.url || P.endsWith(c.url) || c.url.endsWith(P);
|
|
5899
5897
|
});
|
|
5900
5898
|
if (_) {
|
|
5901
|
-
const
|
|
5902
|
-
if (
|
|
5903
|
-
return s[
|
|
5899
|
+
const W = _.sourceName || _.layerName;
|
|
5900
|
+
if (W)
|
|
5901
|
+
return s[W] || { url: _.url };
|
|
5904
5902
|
}
|
|
5905
5903
|
}
|
|
5906
5904
|
};
|
|
5907
|
-
for (let c = 0; c <
|
|
5908
|
-
const A =
|
|
5905
|
+
for (let c = 0; c < l.psdPartData.length; c++) {
|
|
5906
|
+
const A = l.psdPartData[c], _ = F(A);
|
|
5909
5907
|
if (A.type === g0.Layer) {
|
|
5910
5908
|
if (!_ || !_.url) {
|
|
5911
|
-
|
|
5909
|
+
d(`图层 "${A.name}" 没有匹配的 material,跳过`);
|
|
5912
5910
|
continue;
|
|
5913
5911
|
}
|
|
5914
|
-
const
|
|
5912
|
+
const W = _.url, P = a(W);
|
|
5915
5913
|
if (!P) {
|
|
5916
|
-
|
|
5914
|
+
d(`图层 "${A.name}" 没有有效的 url,跳过`);
|
|
5917
5915
|
continue;
|
|
5918
5916
|
}
|
|
5919
5917
|
R.push({
|
|
5920
5918
|
index: c,
|
|
5921
5919
|
type: "layer",
|
|
5922
5920
|
partData: A,
|
|
5923
|
-
promise:
|
|
5921
|
+
promise: ut(P, E, n).catch((L) => null)
|
|
5924
5922
|
});
|
|
5925
5923
|
} else if (A.type === g0.Group) {
|
|
5926
5924
|
if (!A.smartObjects || A.smartObjects.length === 0)
|
|
5927
5925
|
continue;
|
|
5928
|
-
for (let
|
|
5929
|
-
const P = A.smartObjects[
|
|
5926
|
+
for (let W = 0; W < A.smartObjects.length; W++) {
|
|
5927
|
+
const P = A.smartObjects[W];
|
|
5930
5928
|
if (!P || !P.name)
|
|
5931
5929
|
continue;
|
|
5932
5930
|
let L = s[P.name] ?? _;
|
|
5933
5931
|
if (!L && P.imagePath && (L = s[P.imagePath], !L)) {
|
|
5934
5932
|
const K = P.imagePath.split("/").pop() || P.imagePath;
|
|
5935
5933
|
if (L = s[K], !L) {
|
|
5936
|
-
const G = m.find((
|
|
5937
|
-
const
|
|
5938
|
-
return !
|
|
5934
|
+
const G = m.find((Y) => {
|
|
5935
|
+
const e0 = Y.sourceName || Y.layerName;
|
|
5936
|
+
return !e0 || !P.imagePath ? !1 : (e0.split("/").pop() || e0) === K || e0 === P.imagePath || e0.endsWith(P.imagePath) || P.imagePath.endsWith(e0);
|
|
5939
5937
|
});
|
|
5940
5938
|
G && (L = { url: G.url });
|
|
5941
5939
|
}
|
|
@@ -5952,9 +5950,9 @@ async function Wx(r) {
|
|
|
5952
5950
|
continue;
|
|
5953
5951
|
I = G;
|
|
5954
5952
|
}
|
|
5955
|
-
const
|
|
5953
|
+
const Z = (A.partId ?? A.id) * 100 + W, Q = et(rt(P)), o0 = { width: b, height: g };
|
|
5956
5954
|
R.push({
|
|
5957
|
-
index: c +
|
|
5955
|
+
index: c + W * 0.01,
|
|
5958
5956
|
type: "group",
|
|
5959
5957
|
partData: A,
|
|
5960
5958
|
smartObject: P,
|
|
@@ -5962,7 +5960,7 @@ async function Wx(r) {
|
|
|
5962
5960
|
promise: Px(
|
|
5963
5961
|
I,
|
|
5964
5962
|
P,
|
|
5965
|
-
|
|
5963
|
+
Z,
|
|
5966
5964
|
o0,
|
|
5967
5965
|
E,
|
|
5968
5966
|
n
|
|
@@ -5975,75 +5973,75 @@ async function Wx(r) {
|
|
|
5975
5973
|
task: c,
|
|
5976
5974
|
imageBitmap: w[A]
|
|
5977
5975
|
})).sort((c, A) => {
|
|
5978
|
-
const _ = c.task.type === "group" && c.task.smartObject?.layerOrder !== void 0 ? c.task.smartObject.layerOrder : c.task.partData.layerOrder ?? c.task.index,
|
|
5979
|
-
return _ -
|
|
5976
|
+
const _ = 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;
|
|
5977
|
+
return _ - W;
|
|
5980
5978
|
});
|
|
5981
|
-
let $ = l0(b, g),
|
|
5979
|
+
let $ = l0(b, g), z = F0($), O = !1, q = "normal";
|
|
5982
5980
|
for (let c = 0; c < H.length; c++) {
|
|
5983
5981
|
const { task: A, imageBitmap: _ } = H[c];
|
|
5984
5982
|
if (!_) {
|
|
5985
|
-
|
|
5983
|
+
d(`[renderByJson] 图层 "${A.partData.name}" 没有 imageBitmap,跳过`);
|
|
5986
5984
|
continue;
|
|
5987
5985
|
}
|
|
5988
|
-
const { partData:
|
|
5986
|
+
const { partData: W } = A, P = W.bounds;
|
|
5989
5987
|
let L;
|
|
5990
|
-
A.type === "group" && A.smartObject ? L = A.smartObject.opacity ??
|
|
5988
|
+
A.type === "group" && A.smartObject ? L = A.smartObject.opacity ?? W.opacity : L = W.opacity, (typeof L != "number" || isNaN(L)) && (L = 1);
|
|
5991
5989
|
let I;
|
|
5992
|
-
A.type === "group" && A.smartObject ? I = A.smartObject.clipping ??
|
|
5993
|
-
const
|
|
5990
|
+
A.type === "group" && A.smartObject ? I = A.smartObject.clipping ?? W.clipping === !0 : I = W.clipping === !0;
|
|
5991
|
+
const Z = H[c + 1];
|
|
5994
5992
|
let Q = !1;
|
|
5995
|
-
if (
|
|
5996
|
-
const K =
|
|
5997
|
-
|
|
5993
|
+
if (Z) {
|
|
5994
|
+
const K = Z.task.partData;
|
|
5995
|
+
Z.task.type === "group" && Z.task.smartObject ? Q = Z.task.smartObject.clipping ?? K.clipping === !0 : Q = K.clipping === !0;
|
|
5998
5996
|
}
|
|
5999
|
-
const o0 = A.type === "group" && A.smartObject && A.smartObject.name ? A.smartObject.name :
|
|
5997
|
+
const o0 = A.type === "group" && A.smartObject && A.smartObject.name ? A.smartObject.name : W?.name || "未命名图层";
|
|
6000
5998
|
if (e(`[renderByJson] 绘制图层 "${o0}"`, {
|
|
6001
5999
|
type: A.type,
|
|
6002
6000
|
bitmapSize: { width: _.width, height: _.height },
|
|
6003
6001
|
bounds: P,
|
|
6004
6002
|
hasMask: !!A.maskData,
|
|
6005
|
-
blendMode:
|
|
6003
|
+
blendMode: W.blendMode,
|
|
6006
6004
|
opacity: L,
|
|
6007
6005
|
clipping: I
|
|
6008
6006
|
}), !I && Q) {
|
|
6009
|
-
if (O = !0, q =
|
|
6010
|
-
if (
|
|
6007
|
+
if (O = !0, q = W.blendMode || "normal", z) {
|
|
6008
|
+
if (z.clearRect(0, 0, b, g), z.globalCompositeOperation = "source-over", z.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6011
6009
|
if (A.maskData) {
|
|
6012
6010
|
const K = l0(b, g), G = F0(K);
|
|
6013
|
-
G && (G.drawImage(_, 0, 0),
|
|
6011
|
+
G && (G.drawImage(_, 0, 0), lr(G, A.maskData), z.drawImage(K, 0, 0));
|
|
6014
6012
|
} else
|
|
6015
|
-
|
|
6016
|
-
else A.type === "layer" && (P ?
|
|
6013
|
+
z.drawImage(_, 0, 0);
|
|
6014
|
+
else A.type === "layer" && (P ? z.drawImage(
|
|
6017
6015
|
_,
|
|
6018
6016
|
P.left,
|
|
6019
6017
|
P.top,
|
|
6020
6018
|
P.width,
|
|
6021
6019
|
P.height
|
|
6022
|
-
) :
|
|
6023
|
-
|
|
6020
|
+
) : z.drawImage(_, 0, 0));
|
|
6021
|
+
z.globalAlpha = 1;
|
|
6024
6022
|
}
|
|
6025
6023
|
} else if (I) {
|
|
6026
|
-
if (
|
|
6027
|
-
if (
|
|
6024
|
+
if (z) {
|
|
6025
|
+
if (z.globalCompositeOperation = "source-atop", z.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6028
6026
|
if (A.maskData) {
|
|
6029
6027
|
const K = l0(b, g), G = F0(K);
|
|
6030
|
-
G && (G.drawImage(_, 0, 0),
|
|
6028
|
+
G && (G.drawImage(_, 0, 0), lr(G, A.maskData), z.drawImage(K, 0, 0));
|
|
6031
6029
|
} else
|
|
6032
|
-
|
|
6033
|
-
else A.type === "layer" && (P ?
|
|
6030
|
+
z.drawImage(_, 0, 0);
|
|
6031
|
+
else A.type === "layer" && (P ? z.drawImage(
|
|
6034
6032
|
_,
|
|
6035
6033
|
P.left,
|
|
6036
6034
|
P.top,
|
|
6037
6035
|
P.width,
|
|
6038
6036
|
P.height
|
|
6039
|
-
) :
|
|
6040
|
-
|
|
6037
|
+
) : z.drawImage(_, 0, 0));
|
|
6038
|
+
z.globalAlpha = 1, z.globalCompositeOperation = "source-over";
|
|
6041
6039
|
}
|
|
6042
6040
|
} else {
|
|
6043
|
-
if (k.globalCompositeOperation = Lr(
|
|
6041
|
+
if (k.globalCompositeOperation = Lr(W.blendMode), k.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6044
6042
|
if (A.maskData) {
|
|
6045
6043
|
const K = l0(b, g), G = F0(K);
|
|
6046
|
-
G && (G.drawImage(_, 0, 0),
|
|
6044
|
+
G && (G.drawImage(_, 0, 0), lr(G, A.maskData), k.drawImage(K, 0, 0));
|
|
6047
6045
|
} else
|
|
6048
6046
|
k.drawImage(_, 0, 0);
|
|
6049
6047
|
else A.type === "layer" && (P ? k.drawImage(
|
|
@@ -6057,7 +6055,7 @@ async function Wx(r) {
|
|
|
6057
6055
|
}
|
|
6058
6056
|
O && !Q && (k.globalCompositeOperation = Lr(q), k.drawImage($, 0, 0), k.globalCompositeOperation = "source-over", O = !1);
|
|
6059
6057
|
}
|
|
6060
|
-
$ = null,
|
|
6058
|
+
$ = null, z = null;
|
|
6061
6059
|
let U = y, T = b, N = g;
|
|
6062
6060
|
if (C !== void 0 || x !== void 0) {
|
|
6063
6061
|
if (C !== void 0 && x !== void 0)
|
|
@@ -6073,49 +6071,49 @@ async function Wx(r) {
|
|
|
6073
6071
|
const c = De(U);
|
|
6074
6072
|
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}`);
|
|
6075
6073
|
}
|
|
6076
|
-
const S = performance.now() -
|
|
6074
|
+
const S = performance.now() - u;
|
|
6077
6075
|
return e(`[renderByJson] 绘制完成,总渲染时间: ${Math.round(S)}ms`), {
|
|
6078
6076
|
canvas: U,
|
|
6079
6077
|
width: T,
|
|
6080
6078
|
height: N
|
|
6081
6079
|
};
|
|
6082
6080
|
}
|
|
6083
|
-
const
|
|
6084
|
-
const t = (await
|
|
6081
|
+
const ze = async (r) => {
|
|
6082
|
+
const t = (await zx(r)).canvas;
|
|
6085
6083
|
return t ? createImageBitmap(t) : null;
|
|
6086
6084
|
};
|
|
6087
|
-
let i0 = null,
|
|
6088
|
-
const
|
|
6089
|
-
if (!
|
|
6090
|
-
|
|
6085
|
+
let i0 = null, vr = !1;
|
|
6086
|
+
const We = async () => {
|
|
6087
|
+
if (!vr) {
|
|
6088
|
+
vr = !0;
|
|
6091
6089
|
try {
|
|
6092
6090
|
for (; i0; ) {
|
|
6093
6091
|
const r = i0;
|
|
6094
6092
|
i0 = null;
|
|
6095
6093
|
try {
|
|
6096
|
-
const
|
|
6094
|
+
const u = await ze(r.renderData);
|
|
6097
6095
|
if (i0) {
|
|
6098
|
-
|
|
6096
|
+
u?.close?.();
|
|
6099
6097
|
continue;
|
|
6100
6098
|
}
|
|
6101
|
-
self.postMessage({ id: r.id, bitmap:
|
|
6102
|
-
} catch (
|
|
6099
|
+
self.postMessage({ id: r.id, bitmap: u }, u ? [u] : []);
|
|
6100
|
+
} catch (u) {
|
|
6103
6101
|
if (i0) continue;
|
|
6104
6102
|
self.postMessage({
|
|
6105
6103
|
id: r.id,
|
|
6106
|
-
error:
|
|
6104
|
+
error: u instanceof Error ? u.message : String(u)
|
|
6107
6105
|
});
|
|
6108
6106
|
}
|
|
6109
6107
|
}
|
|
6110
6108
|
} finally {
|
|
6111
|
-
|
|
6109
|
+
vr = !1, i0 && We();
|
|
6112
6110
|
}
|
|
6113
6111
|
}
|
|
6114
6112
|
};
|
|
6115
6113
|
self.onmessage = async (r) => {
|
|
6116
|
-
const
|
|
6117
|
-
if (
|
|
6118
|
-
const e =
|
|
6114
|
+
const u = r.data;
|
|
6115
|
+
if (u && typeof u == "object" && "type" in u && u.type === "SET_LICENSE") {
|
|
6116
|
+
const e = u;
|
|
6119
6117
|
_x({
|
|
6120
6118
|
token: e.licenseToken,
|
|
6121
6119
|
apiUrl: e.licenseApiUrl,
|
|
@@ -6124,13 +6122,13 @@ self.onmessage = async (r) => {
|
|
|
6124
6122
|
});
|
|
6125
6123
|
return;
|
|
6126
6124
|
}
|
|
6127
|
-
const t =
|
|
6125
|
+
const t = u;
|
|
6128
6126
|
if (t.coalesce === !0) {
|
|
6129
|
-
i0 = { id: t.id, renderData: t.renderData },
|
|
6127
|
+
i0 = { id: t.id, renderData: t.renderData }, We();
|
|
6130
6128
|
return;
|
|
6131
6129
|
}
|
|
6132
6130
|
try {
|
|
6133
|
-
const e = await
|
|
6131
|
+
const e = await ze(t.renderData);
|
|
6134
6132
|
self.postMessage({ id: t.id, bitmap: e }, e ? [e] : []);
|
|
6135
6133
|
} catch (e) {
|
|
6136
6134
|
self.postMessage({
|