@jieyin/editor-sdk-test 1.1.143 → 1.1.144
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 +4382 -4368
- package/dist/renderWorker.js +625 -630
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/renderWorker.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var F0 = /* @__PURE__ */ ((r) => (r[r.Group = 0] = "Group", r[r.Layer = 1] = "Layer", r))(F0 || {});
|
|
2
2
|
function Ge(r) {
|
|
3
|
-
let
|
|
3
|
+
let h = r;
|
|
4
4
|
return () => {
|
|
5
|
-
const t =
|
|
6
|
-
return
|
|
5
|
+
const t = h;
|
|
6
|
+
return h += 1, t;
|
|
7
7
|
};
|
|
8
8
|
}
|
|
9
|
-
function Ke(r,
|
|
9
|
+
function Ke(r, h) {
|
|
10
10
|
return {
|
|
11
11
|
name: r.name || "",
|
|
12
12
|
type: r.type || "Layer",
|
|
@@ -23,19 +23,19 @@ function Ke(r, v) {
|
|
|
23
23
|
quiltSliceY: r.quiltSliceY,
|
|
24
24
|
layerOrder: r.layerOrder,
|
|
25
25
|
imagePath: r.imagePath,
|
|
26
|
-
vectorMask: r.vectorMask ??
|
|
26
|
+
vectorMask: r.vectorMask ?? h,
|
|
27
27
|
filterList: r.filterList,
|
|
28
28
|
opacity: r.opacity,
|
|
29
29
|
clipping: r.clipping
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
function Xe(r,
|
|
33
|
-
let u = r.name || "",
|
|
34
|
-
if (r.type === "Group" && m === void 0 && (!
|
|
35
|
-
const x = r.children[0].name, n =
|
|
36
|
-
(E !== void 0 || n?.id !== void 0) && (u = x,
|
|
32
|
+
function Xe(r, h, t, e) {
|
|
33
|
+
let u = r.name || "", v = h[u], m = v?.partId ?? (r.type === "Group" ? t.get(u) : void 0);
|
|
34
|
+
if (r.type === "Group" && m === void 0 && (!v || v.id === void 0) && r.children && r.children.length === 1) {
|
|
35
|
+
const x = r.children[0].name, n = h[x], E = n?.partId ?? t.get(x);
|
|
36
|
+
(E !== void 0 || n?.id !== void 0) && (u = x, v = n, m = E);
|
|
37
37
|
}
|
|
38
|
-
const B = r.id ??
|
|
38
|
+
const B = r.id ?? v?.id ?? e();
|
|
39
39
|
if (r.type === "Group")
|
|
40
40
|
return {
|
|
41
41
|
id: B,
|
|
@@ -51,7 +51,7 @@ function Xe(r, v, t, e) {
|
|
|
51
51
|
clipping: r.clipping,
|
|
52
52
|
layerOrder: r.layerOrder
|
|
53
53
|
};
|
|
54
|
-
let C =
|
|
54
|
+
let C = v?.url;
|
|
55
55
|
return !C && r.imagePath && (C = r.imagePath), {
|
|
56
56
|
id: B,
|
|
57
57
|
name: r.name || "",
|
|
@@ -64,26 +64,26 @@ function Xe(r, v, t, e) {
|
|
|
64
64
|
layerOrder: r.layerOrder
|
|
65
65
|
};
|
|
66
66
|
}
|
|
67
|
-
function Ye(r,
|
|
68
|
-
const t = new Map(
|
|
67
|
+
function Ye(r, h) {
|
|
68
|
+
const t = new Map(h.parts.map((u) => [u.name, u.id])), e = Ge(h.defaultIdStart ?? 1);
|
|
69
69
|
return {
|
|
70
|
-
parts:
|
|
70
|
+
parts: h.parts,
|
|
71
71
|
models: r.map((u) => {
|
|
72
|
-
const
|
|
72
|
+
const v = u.layerExtrasByName ?? {}, m = u.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
77
|
for (const p of s)
|
|
78
78
|
if (p.type === "Group" && p.children) {
|
|
79
|
-
const l = [],
|
|
80
|
-
const b = o.layerOrder ?? 0,
|
|
81
|
-
return b -
|
|
79
|
+
const l = [], g = [], i = [...p.children].sort((o, d) => {
|
|
80
|
+
const b = o.layerOrder ?? 0, D = d.layerOrder ?? 0;
|
|
81
|
+
return b - D;
|
|
82
82
|
});
|
|
83
83
|
for (const o of i)
|
|
84
|
-
o.isSmartObject === !0 ? l.push(o) :
|
|
85
|
-
if (
|
|
86
|
-
const o = n(
|
|
84
|
+
o.isSmartObject === !0 ? l.push(o) : g.push(o);
|
|
85
|
+
if (g.length > 0) {
|
|
86
|
+
const o = n(g);
|
|
87
87
|
f.push(...o);
|
|
88
88
|
}
|
|
89
89
|
l.length > 0 && f.push({
|
|
@@ -94,7 +94,7 @@ function Ye(r, v) {
|
|
|
94
94
|
f.push(p);
|
|
95
95
|
return f;
|
|
96
96
|
}, a = n(B).map(
|
|
97
|
-
(s) => Xe(s,
|
|
97
|
+
(s) => Xe(s, v, t, e)
|
|
98
98
|
);
|
|
99
99
|
return {
|
|
100
100
|
width: C,
|
|
@@ -110,44 +110,44 @@ function Ze(r) {
|
|
|
110
110
|
function Qe(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((h) => ({
|
|
114
|
+
open: !!h.open,
|
|
115
|
+
knots: h.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((h) => ({
|
|
123
|
+
x: h.x,
|
|
124
|
+
y: h.y,
|
|
125
|
+
type: h.type
|
|
126
126
|
}))
|
|
127
127
|
} : null : null;
|
|
128
128
|
}
|
|
129
|
-
function lr(r,
|
|
130
|
-
if (
|
|
131
|
-
if (r.globalCompositeOperation = "destination-in", r.beginPath(),
|
|
132
|
-
|
|
129
|
+
function lr(r, h) {
|
|
130
|
+
if (h) {
|
|
131
|
+
if (r.globalCompositeOperation = "destination-in", r.beginPath(), h.type === "bezier" && Array.isArray(h.paths))
|
|
132
|
+
h.paths.forEach((t) => {
|
|
133
133
|
const e = t.knots;
|
|
134
134
|
if (!e || e.length < 2) return;
|
|
135
135
|
const u = e[0];
|
|
136
136
|
r.moveTo(u.points[2], u.points[3]);
|
|
137
|
-
for (let
|
|
138
|
-
const m = e[
|
|
139
|
-
let B = (
|
|
140
|
-
if (!t.open &&
|
|
137
|
+
for (let v = 0; v < e.length; v++) {
|
|
138
|
+
const m = e[v];
|
|
139
|
+
let B = (v + 1) % e.length;
|
|
140
|
+
if (!t.open && v === e.length - 1)
|
|
141
141
|
B = 0;
|
|
142
|
-
else if (t.open &&
|
|
142
|
+
else if (t.open && v === 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 (h.type === "simple" && Array.isArray(h.points)) {
|
|
150
|
+
const t = h.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 h0 {
|
|
|
161
161
|
/**
|
|
162
162
|
* 获取存储项
|
|
163
163
|
*/
|
|
164
|
-
static getItem(
|
|
164
|
+
static getItem(h) {
|
|
165
165
|
if (!this.hasStorage) return null;
|
|
166
166
|
try {
|
|
167
|
-
return localStorage.getItem(
|
|
167
|
+
return localStorage.getItem(h);
|
|
168
168
|
} catch {
|
|
169
169
|
return null;
|
|
170
170
|
}
|
|
@@ -172,10 +172,10 @@ class h0 {
|
|
|
172
172
|
/**
|
|
173
173
|
* 设置存储项
|
|
174
174
|
*/
|
|
175
|
-
static setItem(
|
|
175
|
+
static setItem(h, t) {
|
|
176
176
|
if (!this.hasStorage) return !1;
|
|
177
177
|
try {
|
|
178
|
-
return localStorage.setItem(
|
|
178
|
+
return localStorage.setItem(h, t), !0;
|
|
179
179
|
} catch {
|
|
180
180
|
return !1;
|
|
181
181
|
}
|
|
@@ -183,10 +183,10 @@ class h0 {
|
|
|
183
183
|
/**
|
|
184
184
|
* 移除存储项
|
|
185
185
|
*/
|
|
186
|
-
static removeItem(
|
|
186
|
+
static removeItem(h) {
|
|
187
187
|
if (!this.hasStorage) return !1;
|
|
188
188
|
try {
|
|
189
|
-
return localStorage.removeItem(
|
|
189
|
+
return localStorage.removeItem(h), !0;
|
|
190
190
|
} catch {
|
|
191
191
|
return !1;
|
|
192
192
|
}
|
|
@@ -209,7 +209,7 @@ class h0 {
|
|
|
209
209
|
return this.hasStorage;
|
|
210
210
|
}
|
|
211
211
|
}
|
|
212
|
-
class
|
|
212
|
+
class cr {
|
|
213
213
|
/**
|
|
214
214
|
* 是否在浏览器环境
|
|
215
215
|
*/
|
|
@@ -251,10 +251,10 @@ class l0 {
|
|
|
251
251
|
/**
|
|
252
252
|
* 安全地解析 URL
|
|
253
253
|
*/
|
|
254
|
-
static parse(
|
|
254
|
+
static parse(h) {
|
|
255
255
|
try {
|
|
256
|
-
const t =
|
|
257
|
-
return new URL(
|
|
256
|
+
const t = cr.getOrigin();
|
|
257
|
+
return new URL(h, t);
|
|
258
258
|
} catch {
|
|
259
259
|
return null;
|
|
260
260
|
}
|
|
@@ -262,209 +262,204 @@ class l0 {
|
|
|
262
262
|
/**
|
|
263
263
|
* 添加查询参数
|
|
264
264
|
*/
|
|
265
|
-
static addParam(
|
|
266
|
-
const u = this.parse(
|
|
267
|
-
return !u || u.searchParams.has(t) ?
|
|
265
|
+
static addParam(h, t, e) {
|
|
266
|
+
const u = this.parse(h);
|
|
267
|
+
return !u || u.searchParams.has(t) ? h : (u.searchParams.set(t, e), this.formatUrl(h, u));
|
|
268
268
|
}
|
|
269
269
|
/**
|
|
270
270
|
* 移除查询参数
|
|
271
271
|
*/
|
|
272
|
-
static removeParam(
|
|
273
|
-
const e = this.parse(
|
|
274
|
-
return !e || !e.searchParams.has(t) ?
|
|
272
|
+
static removeParam(h, t) {
|
|
273
|
+
const e = this.parse(h);
|
|
274
|
+
return !e || !e.searchParams.has(t) ? h : (e.searchParams.delete(t), this.formatUrl(h, e));
|
|
275
275
|
}
|
|
276
276
|
/**
|
|
277
277
|
* 检查是否有指定参数
|
|
278
278
|
*/
|
|
279
|
-
static hasParam(
|
|
280
|
-
return this.parse(
|
|
279
|
+
static hasParam(h, t) {
|
|
280
|
+
return this.parse(h)?.searchParams.has(t) ?? !1;
|
|
281
281
|
}
|
|
282
282
|
/**
|
|
283
283
|
* 格式化 URL(保持原始格式)
|
|
284
284
|
*/
|
|
285
|
-
static formatUrl(
|
|
286
|
-
const e = /^(https?:)?\/\//i.test(
|
|
285
|
+
static formatUrl(h, t) {
|
|
286
|
+
const e = /^(https?:)?\/\//i.test(h), u = h.startsWith("//");
|
|
287
287
|
return e ? t.toString() : u ? t.toString().replace(/^https?:/, "") : `${t.pathname}${t.search}${t.hash}`;
|
|
288
288
|
}
|
|
289
289
|
/**
|
|
290
290
|
* 检查是否为数据 URL
|
|
291
291
|
*/
|
|
292
|
-
static isDataUrl(
|
|
293
|
-
return
|
|
292
|
+
static isDataUrl(h) {
|
|
293
|
+
return h?.startsWith("data:") ?? !1;
|
|
294
294
|
}
|
|
295
295
|
/**
|
|
296
296
|
* 检查是否为 Blob URL
|
|
297
297
|
*/
|
|
298
|
-
static isBlobUrl(
|
|
299
|
-
return
|
|
298
|
+
static isBlobUrl(h) {
|
|
299
|
+
return h?.startsWith("blob:") ?? !1;
|
|
300
300
|
}
|
|
301
301
|
}
|
|
302
|
-
const
|
|
303
|
-
(function(r,
|
|
304
|
-
const t =
|
|
302
|
+
const n0 = fr;
|
|
303
|
+
(function(r, h) {
|
|
304
|
+
const t = fr, e = r();
|
|
305
305
|
for (; ; )
|
|
306
306
|
try {
|
|
307
|
-
if (parseInt(t(
|
|
307
|
+
if (parseInt(t(408)) / 1 * (parseInt(t(412)) / 2) + -parseInt(t(414)) / 3 * (-parseInt(t(409)) / 4) + parseInt(t(404)) / 5 + parseInt(t(424)) / 6 * (-parseInt(t(431)) / 7) + parseInt(t(392)) / 8 + parseInt(t(425)) / 9 + -parseInt(t(423)) / 10 * (parseInt(t(415)) / 11) === h) break;
|
|
308
308
|
e.push(e.shift());
|
|
309
309
|
} catch {
|
|
310
310
|
e.push(e.shift());
|
|
311
311
|
}
|
|
312
|
-
})(
|
|
312
|
+
})(sr, 361575);
|
|
313
313
|
const E0 = /* @__PURE__ */ (function() {
|
|
314
314
|
let r = !0;
|
|
315
|
-
return function(
|
|
315
|
+
return function(h, t) {
|
|
316
316
|
const e = r ? function() {
|
|
317
|
-
const u =
|
|
317
|
+
const u = fr;
|
|
318
318
|
if (t) {
|
|
319
|
-
const
|
|
320
|
-
return t = null,
|
|
319
|
+
const v = t[u(416)](h, arguments);
|
|
320
|
+
return t = null, v;
|
|
321
321
|
}
|
|
322
322
|
} : function() {
|
|
323
323
|
};
|
|
324
324
|
return r = !1, e;
|
|
325
325
|
};
|
|
326
326
|
})(), Ve = E0(void 0, function() {
|
|
327
|
-
const r =
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
const m = E0["const" + r(495) + "r"].prototype.bind(E0), B = u[h], C = e[B] || m;
|
|
339
|
-
m[r(496) + "to__"] = E0.bind(E0), m.toString = C["toStr" + r(486)].bind(C), e[B] = m;
|
|
327
|
+
const r = fr;
|
|
328
|
+
let h;
|
|
329
|
+
try {
|
|
330
|
+
h = Function("return (functio" + r(394) + (r(417) + "nstructor(" + r(429) + "rn th" + r(403) + " )") + ");")();
|
|
331
|
+
} catch {
|
|
332
|
+
h = window;
|
|
333
|
+
}
|
|
334
|
+
const t = h.console = h.console || {}, e = [r(395), "warn", "info", r(419), "exception", "table", "trace"];
|
|
335
|
+
for (let u = -9316 + -17 * -548; u < e.length; u++) {
|
|
336
|
+
const v = E0[r(405) + "ructor"].prototype.bind(E0), m = e[u], B = t[m] || v;
|
|
337
|
+
v["__pro" + r(413)] = E0.bind(E0), v["toStr" + r(393)] = B[r(427) + r(393)].bind(B), t[m] = v;
|
|
340
338
|
}
|
|
341
339
|
});
|
|
342
340
|
Ve();
|
|
343
|
-
|
|
341
|
+
function sr() {
|
|
342
|
+
const r = ["6540nlCOlm", "638aeAUzr", "apply", "{}.co", "ame", "error", "code", "fetch", "des", "103090PLdlbb", "2290482cGKTtG", "4376907RWUelP", "FileT", "toStr", "data", '"retu', "remov", "7aVQqdP", "1244112vpOnjC", "ing", "n() ", "log", "parse", "addPa", "aUrl", "isDat", "inclu", "token", "okenR", 'is")(', "2541665llVvbz", "const", "efres", "ram", "2edApmi", "124vimFBu", "file_", "isBro", "123494DBNnrN", "to__"];
|
|
343
|
+
return sr = function() {
|
|
344
|
+
return r;
|
|
345
|
+
}, sr();
|
|
346
|
+
}
|
|
347
|
+
const Br = "file_token", Cr = n0(410) + "token_expire_time", Je = (9383 + 5 * -1519 + -1728) * (9494 + -5678 * -1 + 6 * -2362);
|
|
344
348
|
function vr() {
|
|
345
349
|
return h0.getItem(Br);
|
|
346
350
|
}
|
|
347
|
-
function g0(r, v) {
|
|
348
|
-
return r = r - (-4070 + -2 * -314 + 1 * 3911), cr()[r];
|
|
349
|
-
}
|
|
350
351
|
function rt(r = Je) {
|
|
351
|
-
const v = J;
|
|
352
352
|
if (!vr()) return !0;
|
|
353
|
-
const
|
|
354
|
-
if (!
|
|
355
|
-
const
|
|
356
|
-
return Date.now() + r >
|
|
353
|
+
const t = h0.getItem(Cr);
|
|
354
|
+
if (!t) return !1;
|
|
355
|
+
const e = Number(t);
|
|
356
|
+
return Date.now() + r > e;
|
|
357
357
|
}
|
|
358
|
-
function et(r,
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
h0[t(479) + "em"](Cr, String(e));
|
|
358
|
+
function et(r, h) {
|
|
359
|
+
if (h0.setItem(Br, r), typeof h == "number" && h > 0) {
|
|
360
|
+
const t = Date.now() + h * 1e3;
|
|
361
|
+
h0.setItem(Cr, String(t));
|
|
363
362
|
}
|
|
364
363
|
}
|
|
365
|
-
function cr() {
|
|
366
|
-
const r = ["isBro", "token", "apply", "getIt", "ing", "numbe", "trace", "pathn", "39ZFVgQJ", "_expi", "file_", "oken", "n() ", "ructo", "__pro", "1025227dbIUQn", "470630UUqfLg", "re_ti", "42542xqwVIm", "inclu", "remov", "code", "147983sckYzK", "/file", '"retu', "1020936AdlqcR", "wser", "hasPa", "FileT", "976293XXekms", "parse", "data", "now", "24AHlqrk", "excep", "setIt", "644696uuWxhN", "des"];
|
|
367
|
-
return cr = function() {
|
|
368
|
-
return r;
|
|
369
|
-
}, cr();
|
|
370
|
-
}
|
|
371
364
|
function tt() {
|
|
372
|
-
const r =
|
|
373
|
-
h0
|
|
365
|
+
const r = n0;
|
|
366
|
+
h0[r(430) + "eItem"](Br), h0[r(430) + "eItem"](Cr);
|
|
374
367
|
}
|
|
375
368
|
async function Pr(r) {
|
|
376
|
-
const
|
|
377
|
-
return t?.
|
|
369
|
+
const h = n0, t = await r(), e = t?.[h(428)]?.[h(428)];
|
|
370
|
+
return t?.data?.[h(420)] === 7759 + -3 * -2425 + -14834 && e?.[h(410) + h(401)] ? (et(e[h(410) + "token"], e.expires_in), e["file_" + h(401)]) : null;
|
|
378
371
|
}
|
|
379
372
|
let xt = null;
|
|
373
|
+
function fr(r, h) {
|
|
374
|
+
return r = r - (786 + -4 * 1622 + 6094), sr()[r];
|
|
375
|
+
}
|
|
380
376
|
function zr() {
|
|
381
|
-
return
|
|
377
|
+
return cr.isBrowser() ? xt : null;
|
|
382
378
|
}
|
|
383
|
-
async function
|
|
384
|
-
const r =
|
|
385
|
-
if (!
|
|
386
|
-
const
|
|
387
|
-
if (
|
|
379
|
+
async function De() {
|
|
380
|
+
const r = n0;
|
|
381
|
+
if (!cr.isBrowser()) return vr();
|
|
382
|
+
const h = vr();
|
|
383
|
+
if (h && !rt()) return h;
|
|
388
384
|
try {
|
|
389
385
|
const t = await zr();
|
|
390
|
-
if (
|
|
391
|
-
const e = await Pr(t["
|
|
386
|
+
if (h && t?.["fetchFileTokenRefresh"]) {
|
|
387
|
+
const e = await Pr(t[r(421) + "FileT" + r(402) + r(406) + "h"]);
|
|
392
388
|
if (e) return e;
|
|
393
389
|
}
|
|
394
390
|
} catch {
|
|
395
391
|
}
|
|
396
392
|
try {
|
|
397
393
|
const t = zr();
|
|
398
|
-
return t?.["
|
|
394
|
+
return t?.["fetch" + r(426) + "oken"] ? await Pr(t.fetchFileToken) : null;
|
|
399
395
|
} catch {
|
|
400
396
|
return null;
|
|
401
397
|
}
|
|
402
398
|
}
|
|
403
|
-
function
|
|
404
|
-
const
|
|
405
|
-
if (!r || l0
|
|
406
|
-
const t = l0[
|
|
407
|
-
return t ? t[
|
|
399
|
+
function ge(r) {
|
|
400
|
+
const h = n0;
|
|
401
|
+
if (!r || l0[h(399) + h(398)](r) || l0.isBlobUrl(r)) return !1;
|
|
402
|
+
const t = l0[h(396)](r);
|
|
403
|
+
return t ? t["pathn" + h(418)][h(400) + "des"]("/files/") && !l0.hasParam(r, "fileToken") : r.includes("/files/") && !r[h(400) + h(422)]("fileToken=");
|
|
408
404
|
}
|
|
409
|
-
function be(r,
|
|
410
|
-
const t =
|
|
411
|
-
return !
|
|
405
|
+
function be(r, h) {
|
|
406
|
+
const t = n0;
|
|
407
|
+
return !h || !ge(r) ? r : l0[t(397) + t(407)](r, "fileToken", h);
|
|
412
408
|
}
|
|
413
409
|
function nt(r) {
|
|
414
|
-
|
|
415
|
-
return l0.removeParam(r, "fileT" + v(493));
|
|
410
|
+
return l0[n0(430) + "eParam"](r, "fileToken");
|
|
416
411
|
}
|
|
417
412
|
async function at(r) {
|
|
418
|
-
if (!
|
|
419
|
-
const
|
|
420
|
-
return be(r,
|
|
413
|
+
if (!ge(r)) return r;
|
|
414
|
+
const h = await De();
|
|
415
|
+
return be(r, h);
|
|
421
416
|
}
|
|
422
|
-
async function me(r,
|
|
423
|
-
if (!
|
|
424
|
-
const e = nt(r), u = await at(e),
|
|
425
|
-
if (
|
|
417
|
+
async function me(r, h) {
|
|
418
|
+
if (!cr[n0(411) + "wser"]()) return fetch(r, h);
|
|
419
|
+
const e = nt(r), u = await at(e), v = await fetch(u, h);
|
|
420
|
+
if (v.status !== -11238 + 1 * 11639) return v;
|
|
426
421
|
tt();
|
|
427
|
-
const m = await
|
|
428
|
-
return fetch(B,
|
|
422
|
+
const m = await De(), B = be(e, m);
|
|
423
|
+
return fetch(B, h);
|
|
429
424
|
}
|
|
430
|
-
const _e = (r,
|
|
425
|
+
const _e = (r, h) => {
|
|
431
426
|
if (!r) return r;
|
|
432
|
-
const t = (
|
|
427
|
+
const t = (h || "").replace(/\/$/, "");
|
|
433
428
|
if (t && r.startsWith(t))
|
|
434
429
|
return r;
|
|
435
430
|
if (typeof window < "u") {
|
|
436
431
|
const u = window.location.hostname;
|
|
437
432
|
if (u === "localhost" || u === "127.0.0.1")
|
|
438
433
|
try {
|
|
439
|
-
const
|
|
434
|
+
const v = new URL(r);
|
|
440
435
|
if (t)
|
|
441
436
|
try {
|
|
442
437
|
const m = new URL(t).origin;
|
|
443
|
-
if (
|
|
438
|
+
if (v.origin === m)
|
|
444
439
|
return r;
|
|
445
440
|
} catch {
|
|
446
441
|
}
|
|
447
|
-
if (
|
|
448
|
-
return t ? `${t}${
|
|
442
|
+
if (v.pathname.startsWith("/files/"))
|
|
443
|
+
return t ? `${t}${v.pathname}${v.search}${v.hash}` : `${v.pathname}${v.search}${v.hash}`;
|
|
449
444
|
} catch {
|
|
450
445
|
}
|
|
451
446
|
}
|
|
452
447
|
if (typeof window < "u" && window.location.hostname !== "localhost") return r;
|
|
453
448
|
const e = r.match(/^https?:\/\/([^/]+\.oss[^/]*\.aliyuncs\.com)(.*)$/);
|
|
454
449
|
return e ? `/oss${e[2]}` : r;
|
|
455
|
-
}, ot = (r,
|
|
450
|
+
}, ot = (r, h) => {
|
|
456
451
|
if (typeof OffscreenCanvas < "u" && typeof document > "u")
|
|
457
|
-
return new OffscreenCanvas(r,
|
|
452
|
+
return new OffscreenCanvas(r, h);
|
|
458
453
|
const t = document.createElement("canvas");
|
|
459
|
-
return t.width = r, t.height =
|
|
460
|
-
},
|
|
461
|
-
if (!
|
|
454
|
+
return t.width = r, t.height = h, t;
|
|
455
|
+
}, m0 = async (r, h) => {
|
|
456
|
+
if (!h || h <= 0) return r;
|
|
462
457
|
const t = Math.max(r.width, r.height);
|
|
463
|
-
if (t <=
|
|
464
|
-
const e =
|
|
465
|
-
return B ? (B.drawImage(r, 0, 0, u,
|
|
458
|
+
if (t <= h) return r;
|
|
459
|
+
const e = h / t, u = Math.max(1, Math.round(r.width * e)), v = Math.max(1, Math.round(r.height * e)), m = ot(u, v), B = m.getContext("2d");
|
|
460
|
+
return B ? (B.drawImage(r, 0, 0, u, v), r.close?.(), await createImageBitmap(m)) : r;
|
|
466
461
|
};
|
|
467
|
-
async function it(r,
|
|
462
|
+
async function it(r, h, t) {
|
|
468
463
|
if (typeof r == "string")
|
|
469
464
|
try {
|
|
470
465
|
const e = _e(r, t), u = await me(e);
|
|
@@ -472,12 +467,12 @@ async function it(r, v, t) {
|
|
|
472
467
|
const m = u.status === 404 ? `图片不存在 (404): ${r}` : `加载图片失败 (${u.status} ${u.statusText}): ${r}`;
|
|
473
468
|
throw new Error(m);
|
|
474
469
|
}
|
|
475
|
-
const
|
|
476
|
-
if (!
|
|
470
|
+
const v = await u.blob();
|
|
471
|
+
if (!v.type.startsWith("image/") && v.size === 0)
|
|
477
472
|
throw new Error(`图片数据无效: URL=${r}`);
|
|
478
473
|
try {
|
|
479
|
-
const m = await createImageBitmap(
|
|
480
|
-
return await
|
|
474
|
+
const m = await createImageBitmap(v);
|
|
475
|
+
return await m0(m, h);
|
|
481
476
|
} catch (m) {
|
|
482
477
|
throw new Error(`图片解码失败: URL=${r}, 错误=${m instanceof Error ? m.message : m}`);
|
|
483
478
|
}
|
|
@@ -491,7 +486,7 @@ async function it(r, v, t) {
|
|
|
491
486
|
throw new Error(`图片尺寸无效: src=${r.src}, width=${r.naturalWidth}, height=${r.naturalHeight}`);
|
|
492
487
|
try {
|
|
493
488
|
const e = await createImageBitmap(r);
|
|
494
|
-
return await
|
|
489
|
+
return await m0(e, h);
|
|
495
490
|
} catch (e) {
|
|
496
491
|
throw new Error(`图片解码失败: src=${r.src}, 错误=${e instanceof Error ? e.message : e}`);
|
|
497
492
|
}
|
|
@@ -499,23 +494,23 @@ async function it(r, v, t) {
|
|
|
499
494
|
if (r instanceof ImageBitmap) {
|
|
500
495
|
if (r.width === 0 || r.height === 0)
|
|
501
496
|
throw new Error(`ImageBitmap 尺寸无效: width=${r.width}, height=${r.height}`);
|
|
502
|
-
return await
|
|
497
|
+
return await m0(r, h);
|
|
503
498
|
}
|
|
504
499
|
throw new Error("不支持的图片类型");
|
|
505
500
|
}
|
|
506
|
-
async function st(r,
|
|
501
|
+
async function st(r, h, t) {
|
|
507
502
|
try {
|
|
508
503
|
const e = _e(r, t), u = await me(e);
|
|
509
504
|
if (!u.ok) {
|
|
510
505
|
const m = u.status === 404 ? `图片不存在 (404): ${r}` : `加载图片失败 (${u.status} ${u.statusText}): ${r}`;
|
|
511
506
|
throw new Error(m);
|
|
512
507
|
}
|
|
513
|
-
const
|
|
514
|
-
if (!
|
|
508
|
+
const v = await u.blob();
|
|
509
|
+
if (!v.type.startsWith("image/") && v.size === 0)
|
|
515
510
|
throw new Error(`图片数据无效: URL=${r}`);
|
|
516
511
|
try {
|
|
517
|
-
const m = await createImageBitmap(
|
|
518
|
-
return await
|
|
512
|
+
const m = await createImageBitmap(v);
|
|
513
|
+
return await m0(m, h);
|
|
519
514
|
} catch (m) {
|
|
520
515
|
throw new Error(`图片解码失败: URL=${r}, 错误=${m instanceof Error ? m.message : m}`);
|
|
521
516
|
}
|
|
@@ -525,7 +520,7 @@ async function st(r, v, t) {
|
|
|
525
520
|
}
|
|
526
521
|
function Wr(r) {
|
|
527
522
|
if (!r) return "source-over";
|
|
528
|
-
const
|
|
523
|
+
const h = r.trim().toLowerCase();
|
|
529
524
|
return {
|
|
530
525
|
normal: "source-over",
|
|
531
526
|
multiply: "multiply",
|
|
@@ -551,22 +546,22 @@ function Wr(r) {
|
|
|
551
546
|
"linear dodge": "lighter",
|
|
552
547
|
lighter: "lighter",
|
|
553
548
|
"pass-through": "source-over"
|
|
554
|
-
}[
|
|
549
|
+
}[h] || "source-over";
|
|
555
550
|
}
|
|
556
551
|
var hr = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
557
552
|
function ct(r) {
|
|
558
553
|
if (Object.prototype.hasOwnProperty.call(r, "__esModule")) return r;
|
|
559
|
-
var
|
|
560
|
-
if (typeof
|
|
554
|
+
var h = r.default;
|
|
555
|
+
if (typeof h == "function") {
|
|
561
556
|
var t = function e() {
|
|
562
557
|
var u = !1;
|
|
563
558
|
try {
|
|
564
559
|
u = this instanceof e;
|
|
565
560
|
} catch {
|
|
566
561
|
}
|
|
567
|
-
return u ? Reflect.construct(
|
|
562
|
+
return u ? Reflect.construct(h, arguments, this.constructor) : h.apply(this, arguments);
|
|
568
563
|
};
|
|
569
|
-
t.prototype =
|
|
564
|
+
t.prototype = h.prototype;
|
|
570
565
|
} else t = {};
|
|
571
566
|
return Object.defineProperty(t, "__esModule", { value: !0 }), Object.keys(r).forEach(function(e) {
|
|
572
567
|
var u = Object.getOwnPropertyDescriptor(r, e);
|
|
@@ -578,36 +573,36 @@ function ct(r) {
|
|
|
578
573
|
});
|
|
579
574
|
}), t;
|
|
580
575
|
}
|
|
581
|
-
var
|
|
576
|
+
var _0 = { exports: {} };
|
|
582
577
|
function ft(r) {
|
|
583
578
|
throw new Error('Could not dynamically require "' + r + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
584
579
|
}
|
|
585
|
-
var
|
|
580
|
+
var y0 = { exports: {} }, ut = {}, dt = /* @__PURE__ */ Object.freeze({
|
|
586
581
|
__proto__: null,
|
|
587
582
|
default: ut
|
|
588
|
-
}), lt = /* @__PURE__ */ ct(dt), ht =
|
|
583
|
+
}), lt = /* @__PURE__ */ ct(dt), ht = y0.exports, Ir;
|
|
589
584
|
function M() {
|
|
590
|
-
return Ir || (Ir = 1, (function(r,
|
|
585
|
+
return Ir || (Ir = 1, (function(r, h) {
|
|
591
586
|
(function(t, e) {
|
|
592
587
|
r.exports = e();
|
|
593
588
|
})(ht, function() {
|
|
594
589
|
var t = t || (function(e, u) {
|
|
595
|
-
var
|
|
596
|
-
if (typeof window < "u" && window.crypto && (
|
|
590
|
+
var v;
|
|
591
|
+
if (typeof window < "u" && window.crypto && (v = window.crypto), typeof self < "u" && self.crypto && (v = self.crypto), typeof globalThis < "u" && globalThis.crypto && (v = globalThis.crypto), !v && typeof window < "u" && window.msCrypto && (v = window.msCrypto), !v && typeof hr < "u" && hr.crypto && (v = hr.crypto), !v && typeof ft == "function")
|
|
597
592
|
try {
|
|
598
|
-
|
|
593
|
+
v = lt;
|
|
599
594
|
} catch {
|
|
600
595
|
}
|
|
601
596
|
var m = function() {
|
|
602
|
-
if (
|
|
603
|
-
if (typeof
|
|
597
|
+
if (v) {
|
|
598
|
+
if (typeof v.getRandomValues == "function")
|
|
604
599
|
try {
|
|
605
|
-
return
|
|
600
|
+
return v.getRandomValues(new Uint32Array(1))[0];
|
|
606
601
|
} catch {
|
|
607
602
|
}
|
|
608
|
-
if (typeof
|
|
603
|
+
if (typeof v.randomBytes == "function")
|
|
609
604
|
try {
|
|
610
|
-
return
|
|
605
|
+
return v.randomBytes(4).readInt32LE();
|
|
611
606
|
} catch {
|
|
612
607
|
}
|
|
613
608
|
}
|
|
@@ -748,16 +743,16 @@ function M() {
|
|
|
748
743
|
* wordArray1.concat(wordArray2);
|
|
749
744
|
*/
|
|
750
745
|
concat: function(i) {
|
|
751
|
-
var o = this.words, d = i.words, b = this.sigBytes,
|
|
746
|
+
var o = this.words, d = i.words, b = this.sigBytes, D = i.sigBytes;
|
|
752
747
|
if (this.clamp(), b % 4)
|
|
753
|
-
for (var y = 0; y <
|
|
748
|
+
for (var y = 0; y < D; y++) {
|
|
754
749
|
var k = d[y >>> 2] >>> 24 - y % 4 * 8 & 255;
|
|
755
750
|
o[b + y >>> 2] |= k << 24 - (b + y) % 4 * 8;
|
|
756
751
|
}
|
|
757
752
|
else
|
|
758
|
-
for (var R = 0; R <
|
|
753
|
+
for (var R = 0; R < D; R += 4)
|
|
759
754
|
o[b + R >>> 2] = d[R >>> 2];
|
|
760
|
-
return this.sigBytes +=
|
|
755
|
+
return this.sigBytes += D, this;
|
|
761
756
|
},
|
|
762
757
|
/**
|
|
763
758
|
* Removes insignificant bits.
|
|
@@ -816,8 +811,8 @@ function M() {
|
|
|
816
811
|
* var hexString = CryptoJS.enc.Hex.stringify(wordArray);
|
|
817
812
|
*/
|
|
818
813
|
stringify: function(i) {
|
|
819
|
-
for (var o = i.words, d = i.sigBytes, b = [],
|
|
820
|
-
var y = o[
|
|
814
|
+
for (var o = i.words, d = i.sigBytes, b = [], D = 0; D < d; D++) {
|
|
815
|
+
var y = o[D >>> 2] >>> 24 - D % 4 * 8 & 255;
|
|
821
816
|
b.push((y >>> 4).toString(16)), b.push((y & 15).toString(16));
|
|
822
817
|
}
|
|
823
818
|
return b.join("");
|
|
@@ -855,8 +850,8 @@ function M() {
|
|
|
855
850
|
* var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);
|
|
856
851
|
*/
|
|
857
852
|
stringify: function(i) {
|
|
858
|
-
for (var o = i.words, d = i.sigBytes, b = [],
|
|
859
|
-
var y = o[
|
|
853
|
+
for (var o = i.words, d = i.sigBytes, b = [], D = 0; D < d; D++) {
|
|
854
|
+
var y = o[D >>> 2] >>> 24 - D % 4 * 8 & 255;
|
|
860
855
|
b.push(String.fromCharCode(y));
|
|
861
856
|
}
|
|
862
857
|
return b.join("");
|
|
@@ -955,9 +950,9 @@ function M() {
|
|
|
955
950
|
* var processedData = bufferedBlockAlgorithm._process(!!'flush');
|
|
956
951
|
*/
|
|
957
952
|
_process: function(i) {
|
|
958
|
-
var o, d = this._data, b = d.words,
|
|
953
|
+
var o, d = this._data, b = d.words, D = d.sigBytes, y = this.blockSize, k = y * 4, R = D / k;
|
|
959
954
|
i ? R = e.ceil(R) : R = e.max((R | 0) - this._minBufferSize, 0);
|
|
960
|
-
var F = R * y, w = e.min(F * 4,
|
|
955
|
+
var F = R * y, w = e.min(F * 4, D);
|
|
961
956
|
if (F) {
|
|
962
957
|
for (var H = 0; H < F; H += y)
|
|
963
958
|
this._doProcessBlock(b, H);
|
|
@@ -1075,25 +1070,25 @@ function M() {
|
|
|
1075
1070
|
*/
|
|
1076
1071
|
_createHmacHelper: function(i) {
|
|
1077
1072
|
return function(o, d) {
|
|
1078
|
-
return new
|
|
1073
|
+
return new g.HMAC.init(i, d).finalize(o);
|
|
1079
1074
|
};
|
|
1080
1075
|
}
|
|
1081
1076
|
});
|
|
1082
|
-
var
|
|
1077
|
+
var g = C.algo = {};
|
|
1083
1078
|
return C;
|
|
1084
1079
|
})(Math);
|
|
1085
1080
|
return t;
|
|
1086
1081
|
});
|
|
1087
|
-
})(
|
|
1082
|
+
})(y0)), y0.exports;
|
|
1088
1083
|
}
|
|
1089
|
-
var
|
|
1084
|
+
var w0 = { exports: {} }, vt = w0.exports, Lr;
|
|
1090
1085
|
function ur() {
|
|
1091
|
-
return Lr || (Lr = 1, (function(r,
|
|
1086
|
+
return Lr || (Lr = 1, (function(r, h) {
|
|
1092
1087
|
(function(t, e) {
|
|
1093
1088
|
r.exports = e(M());
|
|
1094
1089
|
})(vt, function(t) {
|
|
1095
1090
|
return (function(e) {
|
|
1096
|
-
var u = t,
|
|
1091
|
+
var u = t, v = u.lib, m = v.Base, B = v.WordArray, C = u.x64 = {};
|
|
1097
1092
|
C.Word = m.extend({
|
|
1098
1093
|
/**
|
|
1099
1094
|
* Initializes a newly created 64-bit word.
|
|
@@ -1314,17 +1309,17 @@ function ur() {
|
|
|
1314
1309
|
});
|
|
1315
1310
|
})(), t;
|
|
1316
1311
|
});
|
|
1317
|
-
})(
|
|
1312
|
+
})(w0)), w0.exports;
|
|
1318
1313
|
}
|
|
1319
|
-
var
|
|
1314
|
+
var k0 = { exports: {} }, pt = k0.exports, Or;
|
|
1320
1315
|
function Bt() {
|
|
1321
|
-
return Or || (Or = 1, (function(r,
|
|
1316
|
+
return Or || (Or = 1, (function(r, h) {
|
|
1322
1317
|
(function(t, e) {
|
|
1323
1318
|
r.exports = e(M());
|
|
1324
1319
|
})(pt, function(t) {
|
|
1325
1320
|
return (function() {
|
|
1326
1321
|
if (typeof ArrayBuffer == "function") {
|
|
1327
|
-
var e = t, u = e.lib,
|
|
1322
|
+
var e = t, u = e.lib, v = u.WordArray, m = v.init, B = v.init = function(C) {
|
|
1328
1323
|
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) {
|
|
1329
1324
|
for (var x = C.byteLength, n = [], E = 0; E < x; E++)
|
|
1330
1325
|
n[E >>> 2] |= C[E] << 24 - E % 4 * 8;
|
|
@@ -1332,20 +1327,20 @@ function Bt() {
|
|
|
1332
1327
|
} else
|
|
1333
1328
|
m.apply(this, arguments);
|
|
1334
1329
|
};
|
|
1335
|
-
B.prototype =
|
|
1330
|
+
B.prototype = v;
|
|
1336
1331
|
}
|
|
1337
1332
|
})(), t.lib.WordArray;
|
|
1338
1333
|
});
|
|
1339
|
-
})(
|
|
1334
|
+
})(k0)), k0.exports;
|
|
1340
1335
|
}
|
|
1341
|
-
var
|
|
1336
|
+
var S0 = { exports: {} }, Ct = S0.exports, qr;
|
|
1342
1337
|
function Et() {
|
|
1343
|
-
return qr || (qr = 1, (function(r,
|
|
1338
|
+
return qr || (qr = 1, (function(r, h) {
|
|
1344
1339
|
(function(t, e) {
|
|
1345
1340
|
r.exports = e(M());
|
|
1346
1341
|
})(Ct, function(t) {
|
|
1347
1342
|
return (function() {
|
|
1348
|
-
var e = t, u = e.lib,
|
|
1343
|
+
var e = t, u = e.lib, v = u.WordArray, m = e.enc;
|
|
1349
1344
|
m.Utf16 = m.Utf16BE = {
|
|
1350
1345
|
/**
|
|
1351
1346
|
* Converts a word array to a UTF-16 BE string.
|
|
@@ -1383,7 +1378,7 @@ function Et() {
|
|
|
1383
1378
|
parse: function(C) {
|
|
1384
1379
|
for (var x = C.length, n = [], E = 0; E < x; E++)
|
|
1385
1380
|
n[E >>> 1] |= C.charCodeAt(E) << 16 - E % 2 * 16;
|
|
1386
|
-
return
|
|
1381
|
+
return v.create(n, x * 2);
|
|
1387
1382
|
}
|
|
1388
1383
|
}, m.Utf16LE = {
|
|
1389
1384
|
/**
|
|
@@ -1422,7 +1417,7 @@ function Et() {
|
|
|
1422
1417
|
parse: function(C) {
|
|
1423
1418
|
for (var x = C.length, n = [], E = 0; E < x; E++)
|
|
1424
1419
|
n[E >>> 1] |= B(C.charCodeAt(E) << 16 - E % 2 * 16);
|
|
1425
|
-
return
|
|
1420
|
+
return v.create(n, x * 2);
|
|
1426
1421
|
}
|
|
1427
1422
|
};
|
|
1428
1423
|
function B(C) {
|
|
@@ -1430,16 +1425,16 @@ function Et() {
|
|
|
1430
1425
|
}
|
|
1431
1426
|
})(), t.enc.Utf16;
|
|
1432
1427
|
});
|
|
1433
|
-
})(
|
|
1428
|
+
})(S0)), S0.exports;
|
|
1434
1429
|
}
|
|
1435
|
-
var
|
|
1430
|
+
var H0 = { exports: {} }, At = H0.exports, Tr;
|
|
1436
1431
|
function i0() {
|
|
1437
|
-
return Tr || (Tr = 1, (function(r,
|
|
1432
|
+
return Tr || (Tr = 1, (function(r, h) {
|
|
1438
1433
|
(function(t, e) {
|
|
1439
1434
|
r.exports = e(M());
|
|
1440
1435
|
})(At, function(t) {
|
|
1441
1436
|
return (function() {
|
|
1442
|
-
var e = t, u = e.lib,
|
|
1437
|
+
var e = t, u = e.lib, v = u.WordArray, m = e.enc;
|
|
1443
1438
|
m.Base64 = {
|
|
1444
1439
|
/**
|
|
1445
1440
|
* Converts a word array to a Base64 string.
|
|
@@ -1458,8 +1453,8 @@ function i0() {
|
|
|
1458
1453
|
var x = C.words, n = C.sigBytes, E = this._map;
|
|
1459
1454
|
C.clamp();
|
|
1460
1455
|
for (var a = [], s = 0; s < n; s += 3)
|
|
1461
|
-
for (var f = x[s >>> 2] >>> 24 - s % 4 * 8 & 255, p = x[s + 1 >>> 2] >>> 24 - (s + 1) % 4 * 8 & 255, l = x[s + 2 >>> 2] >>> 24 - (s + 2) % 4 * 8 & 255,
|
|
1462
|
-
a.push(E.charAt(
|
|
1456
|
+
for (var f = x[s >>> 2] >>> 24 - s % 4 * 8 & 255, p = x[s + 1 >>> 2] >>> 24 - (s + 1) % 4 * 8 & 255, l = x[s + 2 >>> 2] >>> 24 - (s + 2) % 4 * 8 & 255, g = f << 16 | p << 8 | l, i = 0; i < 4 && s + i * 0.75 < n; i++)
|
|
1457
|
+
a.push(E.charAt(g >>> 6 * (3 - i) & 63));
|
|
1463
1458
|
var o = E.charAt(64);
|
|
1464
1459
|
if (o)
|
|
1465
1460
|
for (; a.length % 4; )
|
|
@@ -1501,20 +1496,20 @@ function i0() {
|
|
|
1501
1496
|
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2, p = n[C.charCodeAt(s)] >>> 6 - s % 4 * 2, l = f | p;
|
|
1502
1497
|
E[a >>> 2] |= l << 24 - a % 4 * 8, a++;
|
|
1503
1498
|
}
|
|
1504
|
-
return
|
|
1499
|
+
return v.create(E, a);
|
|
1505
1500
|
}
|
|
1506
1501
|
})(), t.enc.Base64;
|
|
1507
1502
|
});
|
|
1508
|
-
})(
|
|
1503
|
+
})(H0)), H0.exports;
|
|
1509
1504
|
}
|
|
1510
|
-
var
|
|
1511
|
-
function
|
|
1512
|
-
return Mr || (Mr = 1, (function(r,
|
|
1505
|
+
var $0 = { exports: {} }, Ft = $0.exports, Mr;
|
|
1506
|
+
function Dt() {
|
|
1507
|
+
return Mr || (Mr = 1, (function(r, h) {
|
|
1513
1508
|
(function(t, e) {
|
|
1514
1509
|
r.exports = e(M());
|
|
1515
1510
|
})(Ft, function(t) {
|
|
1516
1511
|
return (function() {
|
|
1517
|
-
var e = t, u = e.lib,
|
|
1512
|
+
var e = t, u = e.lib, v = u.WordArray, m = e.enc;
|
|
1518
1513
|
m.Base64url = {
|
|
1519
1514
|
/**
|
|
1520
1515
|
* Converts a word array to a Base64url string.
|
|
@@ -1536,7 +1531,7 @@ function gt() {
|
|
|
1536
1531
|
var n = C.words, E = C.sigBytes, a = x ? this._safe_map : this._map;
|
|
1537
1532
|
C.clamp();
|
|
1538
1533
|
for (var s = [], f = 0; f < E; f += 3)
|
|
1539
|
-
for (var p = n[f >>> 2] >>> 24 - f % 4 * 8 & 255, l = n[f + 1 >>> 2] >>> 24 - (f + 1) % 4 * 8 & 255,
|
|
1534
|
+
for (var p = n[f >>> 2] >>> 24 - f % 4 * 8 & 255, l = n[f + 1 >>> 2] >>> 24 - (f + 1) % 4 * 8 & 255, g = n[f + 2 >>> 2] >>> 24 - (f + 2) % 4 * 8 & 255, i = p << 16 | l << 8 | g, o = 0; o < 4 && f + o * 0.75 < E; o++)
|
|
1540
1535
|
s.push(a.charAt(i >>> 6 * (3 - o) & 63));
|
|
1541
1536
|
var d = a.charAt(64);
|
|
1542
1537
|
if (d)
|
|
@@ -1583,20 +1578,20 @@ function gt() {
|
|
|
1583
1578
|
var f = n[C.charCodeAt(s - 1)] << s % 4 * 2, p = n[C.charCodeAt(s)] >>> 6 - s % 4 * 2, l = f | p;
|
|
1584
1579
|
E[a >>> 2] |= l << 24 - a % 4 * 8, a++;
|
|
1585
1580
|
}
|
|
1586
|
-
return
|
|
1581
|
+
return v.create(E, a);
|
|
1587
1582
|
}
|
|
1588
1583
|
})(), t.enc.Base64url;
|
|
1589
1584
|
});
|
|
1590
|
-
})(
|
|
1585
|
+
})($0)), $0.exports;
|
|
1591
1586
|
}
|
|
1592
|
-
var
|
|
1587
|
+
var R0 = { exports: {} }, gt = R0.exports, Nr;
|
|
1593
1588
|
function s0() {
|
|
1594
|
-
return Nr || (Nr = 1, (function(r,
|
|
1589
|
+
return Nr || (Nr = 1, (function(r, h) {
|
|
1595
1590
|
(function(t, e) {
|
|
1596
1591
|
r.exports = e(M());
|
|
1597
|
-
})(
|
|
1592
|
+
})(gt, function(t) {
|
|
1598
1593
|
return (function(e) {
|
|
1599
|
-
var u = t,
|
|
1594
|
+
var u = t, v = u.lib, m = v.WordArray, B = v.Hasher, C = u.algo, x = [];
|
|
1600
1595
|
(function() {
|
|
1601
1596
|
for (var p = 0; p < 64; p++)
|
|
1602
1597
|
x[p] = e.abs(e.sin(p + 1)) * 4294967296 | 0;
|
|
@@ -1611,21 +1606,21 @@ function s0() {
|
|
|
1611
1606
|
]);
|
|
1612
1607
|
},
|
|
1613
1608
|
_doProcessBlock: function(p, l) {
|
|
1614
|
-
for (var
|
|
1615
|
-
var i = l +
|
|
1609
|
+
for (var g = 0; g < 16; g++) {
|
|
1610
|
+
var i = l + g, o = p[i];
|
|
1616
1611
|
p[i] = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360;
|
|
1617
1612
|
}
|
|
1618
|
-
var d = this._hash.words, b = p[l + 0],
|
|
1619
|
-
S = E(S, c, A, _, b, 7, x[0]), _ = E(_, S, c, A,
|
|
1613
|
+
var d = this._hash.words, b = p[l + 0], D = p[l + 1], y = p[l + 2], k = p[l + 3], R = p[l + 4], F = p[l + 5], w = p[l + 6], H = p[l + 7], $ = p[l + 8], z = p[l + 9], O = p[l + 10], q = p[l + 11], U = p[l + 12], T = p[l + 13], N = p[l + 14], j = p[l + 15], S = d[0], c = d[1], A = d[2], _ = d[3];
|
|
1614
|
+
S = E(S, c, A, _, b, 7, x[0]), _ = E(_, S, c, A, D, 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, _, D, 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, _, D, 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, D, 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]), d[0] = d[0] + S | 0, d[1] = d[1] + c | 0, d[2] = d[2] + A | 0, d[3] = d[3] + _ | 0;
|
|
1620
1615
|
},
|
|
1621
1616
|
_doFinalize: function() {
|
|
1622
|
-
var p = this._data, l = p.words,
|
|
1617
|
+
var p = this._data, l = p.words, g = this._nDataBytes * 8, i = p.sigBytes * 8;
|
|
1623
1618
|
l[i >>> 5] |= 128 << 24 - i % 32;
|
|
1624
|
-
var o = e.floor(
|
|
1619
|
+
var o = e.floor(g / 4294967296), d = g;
|
|
1625
1620
|
l[(i + 64 >>> 9 << 4) + 15] = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360, l[(i + 64 >>> 9 << 4) + 14] = (d << 8 | d >>> 24) & 16711935 | (d << 24 | d >>> 8) & 4278255360, p.sigBytes = (l.length + 1) * 4, this._process();
|
|
1626
|
-
for (var b = this._hash,
|
|
1627
|
-
var k =
|
|
1628
|
-
|
|
1621
|
+
for (var b = this._hash, D = b.words, y = 0; y < 4; y++) {
|
|
1622
|
+
var k = D[y];
|
|
1623
|
+
D[y] = (k << 8 | k >>> 24) & 16711935 | (k << 24 | k >>> 8) & 4278255360;
|
|
1629
1624
|
}
|
|
1630
1625
|
return b;
|
|
1631
1626
|
},
|
|
@@ -1634,37 +1629,37 @@ function s0() {
|
|
|
1634
1629
|
return p._hash = this._hash.clone(), p;
|
|
1635
1630
|
}
|
|
1636
1631
|
});
|
|
1637
|
-
function E(p, l,
|
|
1638
|
-
var
|
|
1639
|
-
return (
|
|
1632
|
+
function E(p, l, g, i, o, d, b) {
|
|
1633
|
+
var D = p + (l & g | ~l & i) + o + b;
|
|
1634
|
+
return (D << d | D >>> 32 - d) + l;
|
|
1640
1635
|
}
|
|
1641
|
-
function a(p, l,
|
|
1642
|
-
var
|
|
1643
|
-
return (
|
|
1636
|
+
function a(p, l, g, i, o, d, b) {
|
|
1637
|
+
var D = p + (l & i | g & ~i) + o + b;
|
|
1638
|
+
return (D << d | D >>> 32 - d) + l;
|
|
1644
1639
|
}
|
|
1645
|
-
function s(p, l,
|
|
1646
|
-
var
|
|
1647
|
-
return (
|
|
1640
|
+
function s(p, l, g, i, o, d, b) {
|
|
1641
|
+
var D = p + (l ^ g ^ i) + o + b;
|
|
1642
|
+
return (D << d | D >>> 32 - d) + l;
|
|
1648
1643
|
}
|
|
1649
|
-
function f(p, l,
|
|
1650
|
-
var
|
|
1651
|
-
return (
|
|
1644
|
+
function f(p, l, g, i, o, d, b) {
|
|
1645
|
+
var D = p + (g ^ (l | ~i)) + o + b;
|
|
1646
|
+
return (D << d | D >>> 32 - d) + l;
|
|
1652
1647
|
}
|
|
1653
1648
|
u.MD5 = B._createHelper(n), u.HmacMD5 = B._createHmacHelper(n);
|
|
1654
1649
|
})(Math), t.MD5;
|
|
1655
1650
|
});
|
|
1656
|
-
})(
|
|
1651
|
+
})(R0)), R0.exports;
|
|
1657
1652
|
}
|
|
1658
|
-
var
|
|
1653
|
+
var P0 = { exports: {} }, bt = P0.exports, Ur;
|
|
1659
1654
|
function ye() {
|
|
1660
|
-
return Ur || (Ur = 1, (function(r,
|
|
1655
|
+
return Ur || (Ur = 1, (function(r, h) {
|
|
1661
1656
|
(function(t, e) {
|
|
1662
1657
|
r.exports = e(M());
|
|
1663
1658
|
})(bt, function(t) {
|
|
1664
1659
|
return (function() {
|
|
1665
|
-
var e = t, u = e.lib,
|
|
1660
|
+
var e = t, u = e.lib, v = u.WordArray, m = u.Hasher, B = e.algo, C = [], x = B.SHA1 = m.extend({
|
|
1666
1661
|
_doReset: function() {
|
|
1667
|
-
this._hash = new
|
|
1662
|
+
this._hash = new v.init([
|
|
1668
1663
|
1732584193,
|
|
1669
1664
|
4023233417,
|
|
1670
1665
|
2562383102,
|
|
@@ -1673,17 +1668,17 @@ function ye() {
|
|
|
1673
1668
|
]);
|
|
1674
1669
|
},
|
|
1675
1670
|
_doProcessBlock: function(n, E) {
|
|
1676
|
-
for (var a = this._hash.words, s = a[0], f = a[1], p = a[2], l = a[3],
|
|
1671
|
+
for (var a = this._hash.words, s = a[0], f = a[1], p = a[2], l = a[3], g = a[4], i = 0; i < 80; i++) {
|
|
1677
1672
|
if (i < 16)
|
|
1678
1673
|
C[i] = n[E + i] | 0;
|
|
1679
1674
|
else {
|
|
1680
1675
|
var o = C[i - 3] ^ C[i - 8] ^ C[i - 14] ^ C[i - 16];
|
|
1681
1676
|
C[i] = o << 1 | o >>> 31;
|
|
1682
1677
|
}
|
|
1683
|
-
var d = (s << 5 | s >>> 27) +
|
|
1684
|
-
i < 20 ? d += (f & p | ~f & l) + 1518500249 : i < 40 ? d += (f ^ p ^ l) + 1859775393 : i < 60 ? d += (f & p | f & l | p & l) - 1894007588 : d += (f ^ p ^ l) - 899497514,
|
|
1678
|
+
var d = (s << 5 | s >>> 27) + g + C[i];
|
|
1679
|
+
i < 20 ? d += (f & p | ~f & l) + 1518500249 : i < 40 ? d += (f ^ p ^ l) + 1859775393 : i < 60 ? d += (f & p | f & l | p & l) - 1894007588 : d += (f ^ p ^ l) - 899497514, g = l, l = p, p = f << 30 | f >>> 2, f = s, s = d;
|
|
1685
1680
|
}
|
|
1686
|
-
a[0] = a[0] + s | 0, a[1] = a[1] + f | 0, a[2] = a[2] + p | 0, a[3] = a[3] + l | 0, a[4] = a[4] +
|
|
1681
|
+
a[0] = a[0] + s | 0, a[1] = a[1] + f | 0, a[2] = a[2] + p | 0, a[3] = a[3] + l | 0, a[4] = a[4] + g | 0;
|
|
1687
1682
|
},
|
|
1688
1683
|
_doFinalize: function() {
|
|
1689
1684
|
var n = this._data, E = n.words, a = this._nDataBytes * 8, s = n.sigBytes * 8;
|
|
@@ -1697,25 +1692,25 @@ function ye() {
|
|
|
1697
1692
|
e.SHA1 = m._createHelper(x), e.HmacSHA1 = m._createHmacHelper(x);
|
|
1698
1693
|
})(), t.SHA1;
|
|
1699
1694
|
});
|
|
1700
|
-
})(
|
|
1695
|
+
})(P0)), P0.exports;
|
|
1701
1696
|
}
|
|
1702
|
-
var
|
|
1697
|
+
var z0 = { exports: {} }, mt = z0.exports, jr;
|
|
1703
1698
|
function Er() {
|
|
1704
|
-
return jr || (jr = 1, (function(r,
|
|
1699
|
+
return jr || (jr = 1, (function(r, h) {
|
|
1705
1700
|
(function(t, e) {
|
|
1706
1701
|
r.exports = e(M());
|
|
1707
1702
|
})(mt, function(t) {
|
|
1708
1703
|
return (function(e) {
|
|
1709
|
-
var u = t,
|
|
1704
|
+
var u = t, v = u.lib, m = v.WordArray, B = v.Hasher, C = u.algo, x = [], n = [];
|
|
1710
1705
|
(function() {
|
|
1711
|
-
function s(
|
|
1712
|
-
for (var i = e.sqrt(
|
|
1713
|
-
if (!(
|
|
1706
|
+
function s(g) {
|
|
1707
|
+
for (var i = e.sqrt(g), o = 2; o <= i; o++)
|
|
1708
|
+
if (!(g % o))
|
|
1714
1709
|
return !1;
|
|
1715
1710
|
return !0;
|
|
1716
1711
|
}
|
|
1717
|
-
function f(
|
|
1718
|
-
return (
|
|
1712
|
+
function f(g) {
|
|
1713
|
+
return (g - (g | 0)) * 4294967296 | 0;
|
|
1719
1714
|
}
|
|
1720
1715
|
for (var p = 2, l = 0; l < 64; )
|
|
1721
1716
|
s(p) && (l < 8 && (x[l] = f(e.pow(p, 1 / 2))), n[l] = f(e.pow(p, 1 / 3)), l++), p++;
|
|
@@ -1725,17 +1720,17 @@ function Er() {
|
|
|
1725
1720
|
this._hash = new m.init(x.slice(0));
|
|
1726
1721
|
},
|
|
1727
1722
|
_doProcessBlock: function(s, f) {
|
|
1728
|
-
for (var p = this._hash.words, l = p[0],
|
|
1723
|
+
for (var p = this._hash.words, l = p[0], g = p[1], i = p[2], o = p[3], d = p[4], b = p[5], D = p[6], y = p[7], k = 0; k < 64; k++) {
|
|
1729
1724
|
if (k < 16)
|
|
1730
1725
|
E[k] = s[f + k] | 0;
|
|
1731
1726
|
else {
|
|
1732
1727
|
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;
|
|
1733
1728
|
E[k] = F + E[k - 7] + H + E[k - 16];
|
|
1734
1729
|
}
|
|
1735
|
-
var $ = d & b ^ ~d &
|
|
1736
|
-
y =
|
|
1730
|
+
var $ = d & b ^ ~d & D, z = l & g ^ l & i ^ g & i, O = (l << 30 | l >>> 2) ^ (l << 19 | l >>> 13) ^ (l << 10 | l >>> 22), q = (d << 26 | d >>> 6) ^ (d << 21 | d >>> 11) ^ (d << 7 | d >>> 25), U = y + q + $ + n[k] + E[k], T = O + z;
|
|
1731
|
+
y = D, D = b, b = d, d = o + U | 0, o = i, i = g, g = l, l = U + T | 0;
|
|
1737
1732
|
}
|
|
1738
|
-
p[0] = p[0] + l | 0, p[1] = p[1] +
|
|
1733
|
+
p[0] = p[0] + l | 0, p[1] = p[1] + g | 0, p[2] = p[2] + i | 0, p[3] = p[3] + o | 0, p[4] = p[4] + d | 0, p[5] = p[5] + b | 0, p[6] = p[6] + D | 0, p[7] = p[7] + y | 0;
|
|
1739
1734
|
},
|
|
1740
1735
|
_doFinalize: function() {
|
|
1741
1736
|
var s = this._data, f = s.words, p = this._nDataBytes * 8, l = s.sigBytes * 8;
|
|
@@ -1749,18 +1744,18 @@ function Er() {
|
|
|
1749
1744
|
u.SHA256 = B._createHelper(a), u.HmacSHA256 = B._createHmacHelper(a);
|
|
1750
1745
|
})(Math), t.SHA256;
|
|
1751
1746
|
});
|
|
1752
|
-
})(
|
|
1747
|
+
})(z0)), z0.exports;
|
|
1753
1748
|
}
|
|
1754
|
-
var
|
|
1749
|
+
var W0 = { exports: {} }, _t = W0.exports, Gr;
|
|
1755
1750
|
function yt() {
|
|
1756
|
-
return Gr || (Gr = 1, (function(r,
|
|
1751
|
+
return Gr || (Gr = 1, (function(r, h) {
|
|
1757
1752
|
(function(t, e, u) {
|
|
1758
1753
|
r.exports = e(M(), Er());
|
|
1759
1754
|
})(_t, function(t) {
|
|
1760
1755
|
return (function() {
|
|
1761
|
-
var e = t, u = e.lib,
|
|
1756
|
+
var e = t, u = e.lib, v = u.WordArray, m = e.algo, B = m.SHA256, C = m.SHA224 = B.extend({
|
|
1762
1757
|
_doReset: function() {
|
|
1763
|
-
this._hash = new
|
|
1758
|
+
this._hash = new v.init([
|
|
1764
1759
|
3238371032,
|
|
1765
1760
|
914150663,
|
|
1766
1761
|
812702999,
|
|
@@ -1779,16 +1774,16 @@ function yt() {
|
|
|
1779
1774
|
e.SHA224 = B._createHelper(C), e.HmacSHA224 = B._createHmacHelper(C);
|
|
1780
1775
|
})(), t.SHA224;
|
|
1781
1776
|
});
|
|
1782
|
-
})(
|
|
1777
|
+
})(W0)), W0.exports;
|
|
1783
1778
|
}
|
|
1784
|
-
var
|
|
1779
|
+
var I0 = { exports: {} }, wt = I0.exports, Kr;
|
|
1785
1780
|
function we() {
|
|
1786
|
-
return Kr || (Kr = 1, (function(r,
|
|
1781
|
+
return Kr || (Kr = 1, (function(r, h) {
|
|
1787
1782
|
(function(t, e, u) {
|
|
1788
1783
|
r.exports = e(M(), ur());
|
|
1789
1784
|
})(wt, function(t) {
|
|
1790
1785
|
return (function() {
|
|
1791
|
-
var e = t, u = e.lib,
|
|
1786
|
+
var e = t, u = e.lib, v = u.Hasher, m = e.x64, B = m.Word, C = m.WordArray, x = e.algo;
|
|
1792
1787
|
function n() {
|
|
1793
1788
|
return B.create.apply(B, arguments);
|
|
1794
1789
|
}
|
|
@@ -1878,7 +1873,7 @@ function we() {
|
|
|
1878
1873
|
for (var f = 0; f < 80; f++)
|
|
1879
1874
|
a[f] = n();
|
|
1880
1875
|
})();
|
|
1881
|
-
var s = x.SHA512 =
|
|
1876
|
+
var s = x.SHA512 = v.extend({
|
|
1882
1877
|
_doReset: function() {
|
|
1883
1878
|
this._hash = new C.init([
|
|
1884
1879
|
new B.init(1779033703, 4089235720),
|
|
@@ -1892,54 +1887,54 @@ function we() {
|
|
|
1892
1887
|
]);
|
|
1893
1888
|
},
|
|
1894
1889
|
_doProcessBlock: function(f, p) {
|
|
1895
|
-
for (var l = this._hash.words,
|
|
1896
|
-
var
|
|
1897
|
-
if (
|
|
1898
|
-
|
|
1890
|
+
for (var l = this._hash.words, g = l[0], i = l[1], o = l[2], d = l[3], b = l[4], D = l[5], y = l[6], k = l[7], R = g.high, F = g.low, w = i.high, H = i.low, $ = o.high, z = o.low, O = d.high, q = d.low, U = b.high, T = b.low, N = D.high, j = D.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, r0 = N, c0 = j, D0 = S, v0 = c, dr = A, p0 = _, e0 = 0; e0 < 80; e0++) {
|
|
1891
|
+
var J, t0, g0 = a[e0];
|
|
1892
|
+
if (e0 < 16)
|
|
1893
|
+
t0 = g0.high = f[p + e0 * 2] | 0, J = g0.low = f[p + e0 * 2 + 1] | 0;
|
|
1899
1894
|
else {
|
|
1900
|
-
var
|
|
1901
|
-
|
|
1895
|
+
var Dr = a[e0 - 15], f0 = Dr.high, B0 = Dr.low, Re = (f0 >>> 1 | B0 << 31) ^ (f0 >>> 8 | B0 << 24) ^ f0 >>> 7, gr = (B0 >>> 1 | f0 << 31) ^ (B0 >>> 8 | f0 << 24) ^ (B0 >>> 7 | f0 << 25), br = a[e0 - 2], u0 = br.high, C0 = br.low, Pe = (u0 >>> 19 | C0 << 13) ^ (u0 << 3 | C0 >>> 29) ^ u0 >>> 6, mr = (C0 >>> 19 | u0 << 13) ^ (C0 << 3 | u0 >>> 29) ^ (C0 >>> 6 | u0 << 26), _r = a[e0 - 7], ze = _r.high, We = _r.low, yr = a[e0 - 16], Ie = yr.high, wr = yr.low;
|
|
1896
|
+
J = gr + We, t0 = Re + ze + (J >>> 0 < gr >>> 0 ? 1 : 0), J = J + mr, t0 = t0 + Pe + (J >>> 0 < mr >>> 0 ? 1 : 0), J = J + wr, t0 = t0 + Ie + (J >>> 0 < wr >>> 0 ? 1 : 0), g0.high = t0, g0.low = J;
|
|
1902
1897
|
}
|
|
1903
|
-
var Le = G &
|
|
1904
|
-
dr = D0, p0 = v0, D0 =
|
|
1898
|
+
var Le = G & r0 ^ ~G & D0, kr = Y & c0 ^ ~Y & v0, Oe = W & L ^ W & Z ^ L & Z, qe = P & I ^ P & Q ^ I & Q, Te = (W >>> 28 | P << 4) ^ (W << 30 | P >>> 2) ^ (W << 25 | P >>> 7), Sr = (P >>> 28 | W << 4) ^ (P << 30 | W >>> 2) ^ (P << 25 | W >>> 7), Me = (G >>> 14 | Y << 18) ^ (G >>> 18 | Y << 14) ^ (G << 23 | Y >>> 9), Ne = (Y >>> 14 | G << 18) ^ (Y >>> 18 | G << 14) ^ (Y << 23 | G >>> 9), Hr = E[e0], Ue = Hr.high, $r = Hr.low, V = p0 + Ne, x0 = dr + Me + (V >>> 0 < p0 >>> 0 ? 1 : 0), V = V + kr, x0 = x0 + Le + (V >>> 0 < kr >>> 0 ? 1 : 0), V = V + $r, x0 = x0 + Ue + (V >>> 0 < $r >>> 0 ? 1 : 0), V = V + J, x0 = x0 + t0 + (V >>> 0 < J >>> 0 ? 1 : 0), Rr = Sr + qe, je = Te + Oe + (Rr >>> 0 < Sr >>> 0 ? 1 : 0);
|
|
1899
|
+
dr = D0, p0 = v0, D0 = r0, v0 = c0, r0 = G, c0 = Y, Y = K + V | 0, G = o0 + x0 + (Y >>> 0 < K >>> 0 ? 1 : 0) | 0, o0 = Z, K = Q, Z = L, Q = I, L = W, I = P, P = V + Rr | 0, W = x0 + je + (P >>> 0 < V >>> 0 ? 1 : 0) | 0;
|
|
1905
1900
|
}
|
|
1906
|
-
F =
|
|
1901
|
+
F = g.low = F + P, g.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 = d.low = q + K, d.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 = D.low = j + c0, D.high = N + r0 + (j >>> 0 < c0 >>> 0 ? 1 : 0), c = y.low = c + v0, y.high = S + D0 + (c >>> 0 < v0 >>> 0 ? 1 : 0), _ = k.low = _ + p0, k.high = A + dr + (_ >>> 0 < p0 >>> 0 ? 1 : 0);
|
|
1907
1902
|
},
|
|
1908
1903
|
_doFinalize: function() {
|
|
1909
|
-
var f = this._data, p = f.words, l = this._nDataBytes * 8,
|
|
1910
|
-
p[
|
|
1904
|
+
var f = this._data, p = f.words, l = this._nDataBytes * 8, g = f.sigBytes * 8;
|
|
1905
|
+
p[g >>> 5] |= 128 << 24 - g % 32, p[(g + 128 >>> 10 << 5) + 30] = Math.floor(l / 4294967296), p[(g + 128 >>> 10 << 5) + 31] = l, f.sigBytes = p.length * 4, this._process();
|
|
1911
1906
|
var i = this._hash.toX32();
|
|
1912
1907
|
return i;
|
|
1913
1908
|
},
|
|
1914
1909
|
clone: function() {
|
|
1915
|
-
var f =
|
|
1910
|
+
var f = v.clone.call(this);
|
|
1916
1911
|
return f._hash = this._hash.clone(), f;
|
|
1917
1912
|
},
|
|
1918
1913
|
blockSize: 1024 / 32
|
|
1919
1914
|
});
|
|
1920
|
-
e.SHA512 =
|
|
1915
|
+
e.SHA512 = v._createHelper(s), e.HmacSHA512 = v._createHmacHelper(s);
|
|
1921
1916
|
})(), t.SHA512;
|
|
1922
1917
|
});
|
|
1923
|
-
})(
|
|
1918
|
+
})(I0)), I0.exports;
|
|
1924
1919
|
}
|
|
1925
|
-
var
|
|
1920
|
+
var L0 = { exports: {} }, kt = L0.exports, Xr;
|
|
1926
1921
|
function St() {
|
|
1927
|
-
return Xr || (Xr = 1, (function(r,
|
|
1922
|
+
return Xr || (Xr = 1, (function(r, h) {
|
|
1928
1923
|
(function(t, e, u) {
|
|
1929
1924
|
r.exports = e(M(), ur(), we());
|
|
1930
1925
|
})(kt, function(t) {
|
|
1931
1926
|
return (function() {
|
|
1932
|
-
var e = t, u = e.x64,
|
|
1927
|
+
var e = t, u = e.x64, v = u.Word, m = u.WordArray, B = e.algo, C = B.SHA512, x = B.SHA384 = C.extend({
|
|
1933
1928
|
_doReset: function() {
|
|
1934
1929
|
this._hash = new m.init([
|
|
1935
|
-
new
|
|
1936
|
-
new
|
|
1937
|
-
new
|
|
1938
|
-
new
|
|
1939
|
-
new
|
|
1940
|
-
new
|
|
1941
|
-
new
|
|
1942
|
-
new
|
|
1930
|
+
new v.init(3418070365, 3238371032),
|
|
1931
|
+
new v.init(1654270250, 914150663),
|
|
1932
|
+
new v.init(2438529370, 812702999),
|
|
1933
|
+
new v.init(355462360, 4144912697),
|
|
1934
|
+
new v.init(1731405415, 4290775857),
|
|
1935
|
+
new v.init(2394180231, 1750603025),
|
|
1936
|
+
new v.init(3675008525, 1694076839),
|
|
1937
|
+
new v.init(1203062813, 3204075428)
|
|
1943
1938
|
]);
|
|
1944
1939
|
},
|
|
1945
1940
|
_doFinalize: function() {
|
|
@@ -1950,26 +1945,26 @@ function St() {
|
|
|
1950
1945
|
e.SHA384 = C._createHelper(x), e.HmacSHA384 = C._createHmacHelper(x);
|
|
1951
1946
|
})(), t.SHA384;
|
|
1952
1947
|
});
|
|
1953
|
-
})(
|
|
1948
|
+
})(L0)), L0.exports;
|
|
1954
1949
|
}
|
|
1955
|
-
var
|
|
1950
|
+
var O0 = { exports: {} }, Ht = O0.exports, Yr;
|
|
1956
1951
|
function $t() {
|
|
1957
|
-
return Yr || (Yr = 1, (function(r,
|
|
1952
|
+
return Yr || (Yr = 1, (function(r, h) {
|
|
1958
1953
|
(function(t, e, u) {
|
|
1959
1954
|
r.exports = e(M(), ur());
|
|
1960
1955
|
})(Ht, function(t) {
|
|
1961
1956
|
return (function(e) {
|
|
1962
|
-
var u = t,
|
|
1957
|
+
var u = t, v = u.lib, m = v.WordArray, B = v.Hasher, C = u.x64, x = C.Word, n = u.algo, E = [], a = [], s = [];
|
|
1963
1958
|
(function() {
|
|
1964
|
-
for (var l = 1,
|
|
1965
|
-
E[l + 5 *
|
|
1966
|
-
var o =
|
|
1967
|
-
l = o,
|
|
1959
|
+
for (var l = 1, g = 0, i = 0; i < 24; i++) {
|
|
1960
|
+
E[l + 5 * g] = (i + 1) * (i + 2) / 2 % 64;
|
|
1961
|
+
var o = g % 5, d = (2 * l + 3 * g) % 5;
|
|
1962
|
+
l = o, g = d;
|
|
1968
1963
|
}
|
|
1969
1964
|
for (var l = 0; l < 5; l++)
|
|
1970
|
-
for (var
|
|
1971
|
-
a[l + 5 *
|
|
1972
|
-
for (var b = 1,
|
|
1965
|
+
for (var g = 0; g < 5; g++)
|
|
1966
|
+
a[l + 5 * g] = g + (2 * l + 3 * g) % 5 * 5;
|
|
1967
|
+
for (var b = 1, D = 0; D < 24; D++) {
|
|
1973
1968
|
for (var y = 0, k = 0, R = 0; R < 7; R++) {
|
|
1974
1969
|
if (b & 1) {
|
|
1975
1970
|
var F = (1 << R) - 1;
|
|
@@ -1977,7 +1972,7 @@ function $t() {
|
|
|
1977
1972
|
}
|
|
1978
1973
|
b & 128 ? b = b << 1 ^ 113 : b <<= 1;
|
|
1979
1974
|
}
|
|
1980
|
-
s[
|
|
1975
|
+
s[D] = x.create(y, k);
|
|
1981
1976
|
}
|
|
1982
1977
|
})();
|
|
1983
1978
|
var f = [];
|
|
@@ -1998,16 +1993,16 @@ function $t() {
|
|
|
1998
1993
|
outputLength: 512
|
|
1999
1994
|
}),
|
|
2000
1995
|
_doReset: function() {
|
|
2001
|
-
for (var l = this._state = [],
|
|
2002
|
-
l[
|
|
1996
|
+
for (var l = this._state = [], g = 0; g < 25; g++)
|
|
1997
|
+
l[g] = new x.init();
|
|
2003
1998
|
this.blockSize = (1600 - 2 * this.cfg.outputLength) / 32;
|
|
2004
1999
|
},
|
|
2005
|
-
_doProcessBlock: function(l,
|
|
2000
|
+
_doProcessBlock: function(l, g) {
|
|
2006
2001
|
for (var i = this._state, o = this.blockSize / 2, d = 0; d < o; d++) {
|
|
2007
|
-
var b = l[
|
|
2008
|
-
b = (b << 8 | b >>> 24) & 16711935 | (b << 24 | b >>> 8) & 4278255360,
|
|
2002
|
+
var b = l[g + 2 * d], D = l[g + 2 * d + 1];
|
|
2003
|
+
b = (b << 8 | b >>> 24) & 16711935 | (b << 24 | b >>> 8) & 4278255360, D = (D << 8 | D >>> 24) & 16711935 | (D << 24 | D >>> 8) & 4278255360;
|
|
2009
2004
|
var y = i[d];
|
|
2010
|
-
y.high ^=
|
|
2005
|
+
y.high ^= D, y.low ^= b;
|
|
2011
2006
|
}
|
|
2012
2007
|
for (var k = 0; k < 24; k++) {
|
|
2013
2008
|
for (var R = 0; R < 5; R++) {
|
|
@@ -2041,35 +2036,35 @@ function $t() {
|
|
|
2041
2036
|
}
|
|
2042
2037
|
},
|
|
2043
2038
|
_doFinalize: function() {
|
|
2044
|
-
var l = this._data,
|
|
2039
|
+
var l = this._data, g = l.words;
|
|
2045
2040
|
this._nDataBytes * 8;
|
|
2046
2041
|
var i = l.sigBytes * 8, o = this.blockSize * 32;
|
|
2047
|
-
|
|
2048
|
-
for (var d = this._state, b = this.cfg.outputLength / 8,
|
|
2042
|
+
g[i >>> 5] |= 1 << 24 - i % 32, g[(e.ceil((i + 1) / o) * o >>> 5) - 1] |= 128, l.sigBytes = g.length * 4, this._process();
|
|
2043
|
+
for (var d = this._state, b = this.cfg.outputLength / 8, D = b / 8, y = [], k = 0; k < D; k++) {
|
|
2049
2044
|
var R = d[k], F = R.high, w = R.low;
|
|
2050
2045
|
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);
|
|
2051
2046
|
}
|
|
2052
2047
|
return new m.init(y, b);
|
|
2053
2048
|
},
|
|
2054
2049
|
clone: function() {
|
|
2055
|
-
for (var l = B.clone.call(this),
|
|
2056
|
-
|
|
2050
|
+
for (var l = B.clone.call(this), g = l._state = this._state.slice(0), i = 0; i < 25; i++)
|
|
2051
|
+
g[i] = g[i].clone();
|
|
2057
2052
|
return l;
|
|
2058
2053
|
}
|
|
2059
2054
|
});
|
|
2060
2055
|
u.SHA3 = B._createHelper(p), u.HmacSHA3 = B._createHmacHelper(p);
|
|
2061
2056
|
})(Math), t.SHA3;
|
|
2062
2057
|
});
|
|
2063
|
-
})(
|
|
2058
|
+
})(O0)), O0.exports;
|
|
2064
2059
|
}
|
|
2065
|
-
var
|
|
2060
|
+
var q0 = { exports: {} }, Rt = q0.exports, Zr;
|
|
2066
2061
|
function Pt() {
|
|
2067
|
-
return Zr || (Zr = 1, (function(r,
|
|
2062
|
+
return Zr || (Zr = 1, (function(r, h) {
|
|
2068
2063
|
(function(t, e) {
|
|
2069
2064
|
r.exports = e(M());
|
|
2070
2065
|
})(Rt, function(t) {
|
|
2071
2066
|
return (function(e) {
|
|
2072
|
-
var u = t,
|
|
2067
|
+
var u = t, v = u.lib, m = v.WordArray, B = v.Hasher, C = u.algo, x = m.create([
|
|
2073
2068
|
0,
|
|
2074
2069
|
1,
|
|
2075
2070
|
2,
|
|
@@ -2397,20 +2392,20 @@ function Pt() {
|
|
|
2397
2392
|
_doReset: function() {
|
|
2398
2393
|
this._hash = m.create([1732584193, 4023233417, 2562383102, 271733878, 3285377520]);
|
|
2399
2394
|
},
|
|
2400
|
-
_doProcessBlock: function(
|
|
2395
|
+
_doProcessBlock: function(D, y) {
|
|
2401
2396
|
for (var k = 0; k < 16; k++) {
|
|
2402
|
-
var R = y + k, F =
|
|
2403
|
-
|
|
2397
|
+
var R = y + k, F = D[R];
|
|
2398
|
+
D[R] = (F << 8 | F >>> 24) & 16711935 | (F << 24 | F >>> 8) & 4278255360;
|
|
2404
2399
|
}
|
|
2405
2400
|
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;
|
|
2406
2401
|
A = T = w[0], _ = N = w[1], W = j = w[2], P = S = w[3], L = c = w[4];
|
|
2407
2402
|
for (var I, k = 0; k < 80; k += 1)
|
|
2408
|
-
I = T +
|
|
2403
|
+
I = T + D[y + z[k]] | 0, k < 16 ? I += l(N, j, S) + H[0] : k < 32 ? I += g(N, j, S) + H[1] : k < 48 ? I += i(N, j, S) + H[2] : k < 64 ? I += o(N, j, S) + H[3] : I += d(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 + D[y + O[k]] | 0, k < 16 ? I += d(_, W, P) + $[0] : k < 32 ? I += o(_, W, P) + $[1] : k < 48 ? I += i(_, W, P) + $[2] : k < 64 ? I += g(_, W, P) + $[3] : I += l(_, 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;
|
|
2409
2404
|
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;
|
|
2410
2405
|
},
|
|
2411
2406
|
_doFinalize: function() {
|
|
2412
|
-
var
|
|
2413
|
-
y[R >>> 5] |= 128 << 24 - R % 32, y[(R + 64 >>> 9 << 4) + 14] = (k << 8 | k >>> 24) & 16711935 | (k << 24 | k >>> 8) & 4278255360,
|
|
2407
|
+
var D = this._data, y = D.words, k = this._nDataBytes * 8, R = D.sigBytes * 8;
|
|
2408
|
+
y[R >>> 5] |= 128 << 24 - R % 32, y[(R + 64 >>> 9 << 4) + 14] = (k << 8 | k >>> 24) & 16711935 | (k << 24 | k >>> 8) & 4278255360, D.sigBytes = (y.length + 1) * 4, this._process();
|
|
2414
2409
|
for (var F = this._hash, w = F.words, H = 0; H < 5; H++) {
|
|
2415
2410
|
var $ = w[H];
|
|
2416
2411
|
w[H] = ($ << 8 | $ >>> 24) & 16711935 | ($ << 24 | $ >>> 8) & 4278255360;
|
|
@@ -2418,42 +2413,42 @@ function Pt() {
|
|
|
2418
2413
|
return F;
|
|
2419
2414
|
},
|
|
2420
2415
|
clone: function() {
|
|
2421
|
-
var
|
|
2422
|
-
return
|
|
2416
|
+
var D = B.clone.call(this);
|
|
2417
|
+
return D._hash = this._hash.clone(), D;
|
|
2423
2418
|
}
|
|
2424
2419
|
});
|
|
2425
|
-
function l(
|
|
2426
|
-
return
|
|
2420
|
+
function l(D, y, k) {
|
|
2421
|
+
return D ^ y ^ k;
|
|
2427
2422
|
}
|
|
2428
|
-
function D
|
|
2429
|
-
return
|
|
2423
|
+
function g(D, y, k) {
|
|
2424
|
+
return D & y | ~D & k;
|
|
2430
2425
|
}
|
|
2431
|
-
function i(
|
|
2432
|
-
return (
|
|
2426
|
+
function i(D, y, k) {
|
|
2427
|
+
return (D | ~y) ^ k;
|
|
2433
2428
|
}
|
|
2434
|
-
function o(
|
|
2435
|
-
return
|
|
2429
|
+
function o(D, y, k) {
|
|
2430
|
+
return D & k | y & ~k;
|
|
2436
2431
|
}
|
|
2437
|
-
function d(
|
|
2438
|
-
return
|
|
2432
|
+
function d(D, y, k) {
|
|
2433
|
+
return D ^ (y | ~k);
|
|
2439
2434
|
}
|
|
2440
|
-
function b(
|
|
2441
|
-
return
|
|
2435
|
+
function b(D, y) {
|
|
2436
|
+
return D << y | D >>> 32 - y;
|
|
2442
2437
|
}
|
|
2443
2438
|
u.RIPEMD160 = B._createHelper(p), u.HmacRIPEMD160 = B._createHmacHelper(p);
|
|
2444
2439
|
})(), t.RIPEMD160;
|
|
2445
2440
|
});
|
|
2446
|
-
})(
|
|
2441
|
+
})(q0)), q0.exports;
|
|
2447
2442
|
}
|
|
2448
|
-
var
|
|
2443
|
+
var T0 = { exports: {} }, zt = T0.exports, Qr;
|
|
2449
2444
|
function Ar() {
|
|
2450
|
-
return Qr || (Qr = 1, (function(r,
|
|
2445
|
+
return Qr || (Qr = 1, (function(r, h) {
|
|
2451
2446
|
(function(t, e) {
|
|
2452
2447
|
r.exports = e(M());
|
|
2453
2448
|
})(zt, function(t) {
|
|
2454
2449
|
(function() {
|
|
2455
|
-
var e = t, u = e.lib,
|
|
2456
|
-
C.HMAC =
|
|
2450
|
+
var e = t, u = e.lib, v = u.Base, m = e.enc, B = m.Utf8, C = e.algo;
|
|
2451
|
+
C.HMAC = v.extend({
|
|
2457
2452
|
/**
|
|
2458
2453
|
* Initializes a newly created HMAC.
|
|
2459
2454
|
*
|
|
@@ -2468,8 +2463,8 @@ function Ar() {
|
|
|
2468
2463
|
x = this._hasher = new x.init(), typeof n == "string" && (n = B.parse(n));
|
|
2469
2464
|
var E = x.blockSize, a = E * 4;
|
|
2470
2465
|
n.sigBytes > a && (n = x.finalize(n)), n.clamp();
|
|
2471
|
-
for (var s = this._oKey = n.clone(), f = this._iKey = n.clone(), p = s.words, l = f.words,
|
|
2472
|
-
p[
|
|
2466
|
+
for (var s = this._oKey = n.clone(), f = this._iKey = n.clone(), p = s.words, l = f.words, g = 0; g < E; g++)
|
|
2467
|
+
p[g] ^= 1549556828, l[g] ^= 909522486;
|
|
2473
2468
|
s.sigBytes = f.sigBytes = a, this.reset();
|
|
2474
2469
|
},
|
|
2475
2470
|
/**
|
|
@@ -2521,16 +2516,16 @@ function Ar() {
|
|
|
2521
2516
|
});
|
|
2522
2517
|
})();
|
|
2523
2518
|
});
|
|
2524
|
-
})(
|
|
2519
|
+
})(T0)), T0.exports;
|
|
2525
2520
|
}
|
|
2526
|
-
var
|
|
2521
|
+
var M0 = { exports: {} }, Wt = M0.exports, Vr;
|
|
2527
2522
|
function It() {
|
|
2528
|
-
return Vr || (Vr = 1, (function(r,
|
|
2523
|
+
return Vr || (Vr = 1, (function(r, h) {
|
|
2529
2524
|
(function(t, e, u) {
|
|
2530
2525
|
r.exports = e(M(), Er(), Ar());
|
|
2531
2526
|
})(Wt, function(t) {
|
|
2532
2527
|
return (function() {
|
|
2533
|
-
var e = t, u = e.lib,
|
|
2528
|
+
var e = t, u = e.lib, v = u.Base, m = u.WordArray, B = e.algo, C = B.SHA256, x = B.HMAC, n = B.PBKDF2 = v.extend({
|
|
2534
2529
|
/**
|
|
2535
2530
|
* Configuration options.
|
|
2536
2531
|
*
|
|
@@ -2538,7 +2533,7 @@ function It() {
|
|
|
2538
2533
|
* @property {Hasher} hasher The hasher to use. Default: SHA256
|
|
2539
2534
|
* @property {number} iterations The number of iterations to perform. Default: 250000
|
|
2540
2535
|
*/
|
|
2541
|
-
cfg:
|
|
2536
|
+
cfg: v.extend({
|
|
2542
2537
|
keySize: 128 / 32,
|
|
2543
2538
|
hasher: C,
|
|
2544
2539
|
iterations: 25e4
|
|
@@ -2570,13 +2565,13 @@ function It() {
|
|
|
2570
2565
|
* var key = kdf.compute(password, salt);
|
|
2571
2566
|
*/
|
|
2572
2567
|
compute: function(E, a) {
|
|
2573
|
-
for (var s = this.cfg, f = x.create(s.hasher, E), p = m.create(), l = m.create([1]),
|
|
2568
|
+
for (var s = this.cfg, f = x.create(s.hasher, E), p = m.create(), l = m.create([1]), g = p.words, i = l.words, o = s.keySize, d = s.iterations; g.length < o; ) {
|
|
2574
2569
|
var b = f.update(a).finalize(l);
|
|
2575
2570
|
f.reset();
|
|
2576
|
-
for (var
|
|
2571
|
+
for (var D = b.words, y = D.length, k = b, R = 1; R < d; R++) {
|
|
2577
2572
|
k = f.finalize(k), f.reset();
|
|
2578
2573
|
for (var F = k.words, w = 0; w < y; w++)
|
|
2579
|
-
|
|
2574
|
+
D[w] ^= F[w];
|
|
2580
2575
|
}
|
|
2581
2576
|
p.concat(b), i[0]++;
|
|
2582
2577
|
}
|
|
@@ -2588,16 +2583,16 @@ function It() {
|
|
|
2588
2583
|
};
|
|
2589
2584
|
})(), t.PBKDF2;
|
|
2590
2585
|
});
|
|
2591
|
-
})(
|
|
2586
|
+
})(M0)), M0.exports;
|
|
2592
2587
|
}
|
|
2593
|
-
var
|
|
2588
|
+
var N0 = { exports: {} }, Lt = N0.exports, Jr;
|
|
2594
2589
|
function a0() {
|
|
2595
|
-
return Jr || (Jr = 1, (function(r,
|
|
2590
|
+
return Jr || (Jr = 1, (function(r, h) {
|
|
2596
2591
|
(function(t, e, u) {
|
|
2597
2592
|
r.exports = e(M(), ye(), Ar());
|
|
2598
2593
|
})(Lt, function(t) {
|
|
2599
2594
|
return (function() {
|
|
2600
|
-
var e = t, u = e.lib,
|
|
2595
|
+
var e = t, u = e.lib, v = u.Base, m = u.WordArray, B = e.algo, C = B.MD5, x = B.EvpKDF = v.extend({
|
|
2601
2596
|
/**
|
|
2602
2597
|
* Configuration options.
|
|
2603
2598
|
*
|
|
@@ -2605,7 +2600,7 @@ function a0() {
|
|
|
2605
2600
|
* @property {Hasher} hasher The hash algorithm to use. Default: MD5
|
|
2606
2601
|
* @property {number} iterations The number of iterations to perform. Default: 1
|
|
2607
2602
|
*/
|
|
2608
|
-
cfg:
|
|
2603
|
+
cfg: v.extend({
|
|
2609
2604
|
keySize: 128 / 32,
|
|
2610
2605
|
hasher: C,
|
|
2611
2606
|
iterations: 1
|
|
@@ -2637,13 +2632,13 @@ function a0() {
|
|
|
2637
2632
|
* var key = kdf.compute(password, salt);
|
|
2638
2633
|
*/
|
|
2639
2634
|
compute: function(n, E) {
|
|
2640
|
-
for (var a, s = this.cfg, f = s.hasher.create(), p = m.create(), l = p.words,
|
|
2635
|
+
for (var a, s = this.cfg, f = s.hasher.create(), p = m.create(), l = p.words, g = s.keySize, i = s.iterations; l.length < g; ) {
|
|
2641
2636
|
a && f.update(a), a = f.update(n).finalize(E), f.reset();
|
|
2642
2637
|
for (var o = 1; o < i; o++)
|
|
2643
2638
|
a = f.finalize(a), f.reset();
|
|
2644
2639
|
p.concat(a);
|
|
2645
2640
|
}
|
|
2646
|
-
return p.sigBytes =
|
|
2641
|
+
return p.sigBytes = g * 4, p;
|
|
2647
2642
|
}
|
|
2648
2643
|
});
|
|
2649
2644
|
e.EvpKDF = function(n, E, a) {
|
|
@@ -2651,18 +2646,18 @@ function a0() {
|
|
|
2651
2646
|
};
|
|
2652
2647
|
})(), t.EvpKDF;
|
|
2653
2648
|
});
|
|
2654
|
-
})(
|
|
2649
|
+
})(N0)), N0.exports;
|
|
2655
2650
|
}
|
|
2656
|
-
var
|
|
2651
|
+
var U0 = { exports: {} }, Ot = U0.exports, re;
|
|
2657
2652
|
function X() {
|
|
2658
|
-
return re || (re = 1, (function(r,
|
|
2653
|
+
return re || (re = 1, (function(r, h) {
|
|
2659
2654
|
(function(t, e, u) {
|
|
2660
2655
|
r.exports = e(M(), a0());
|
|
2661
2656
|
})(Ot, function(t) {
|
|
2662
2657
|
t.lib.Cipher || (function(e) {
|
|
2663
|
-
var u = t,
|
|
2658
|
+
var u = t, v = u.lib, m = v.Base, B = v.WordArray, C = v.BufferedBlockAlgorithm, x = u.enc;
|
|
2664
2659
|
x.Utf8;
|
|
2665
|
-
var n = x.Base64, E = u.algo, a = E.EvpKDF, s =
|
|
2660
|
+
var n = x.Base64, E = u.algo, a = E.EvpKDF, s = v.Cipher = C.extend({
|
|
2666
2661
|
/**
|
|
2667
2662
|
* Configuration options.
|
|
2668
2663
|
*
|
|
@@ -2780,7 +2775,7 @@ function X() {
|
|
|
2780
2775
|
*/
|
|
2781
2776
|
_createHelper: /* @__PURE__ */ (function() {
|
|
2782
2777
|
function F(w) {
|
|
2783
|
-
return typeof w == "string" ? R :
|
|
2778
|
+
return typeof w == "string" ? R : D;
|
|
2784
2779
|
}
|
|
2785
2780
|
return function(w) {
|
|
2786
2781
|
return {
|
|
@@ -2794,14 +2789,14 @@ function X() {
|
|
|
2794
2789
|
};
|
|
2795
2790
|
})()
|
|
2796
2791
|
});
|
|
2797
|
-
|
|
2792
|
+
v.StreamCipher = s.extend({
|
|
2798
2793
|
_doFinalize: function() {
|
|
2799
2794
|
var F = this._process(!0);
|
|
2800
2795
|
return F;
|
|
2801
2796
|
},
|
|
2802
2797
|
blockSize: 1
|
|
2803
2798
|
});
|
|
2804
|
-
var f = u.mode = {}, p =
|
|
2799
|
+
var f = u.mode = {}, p = v.BlockCipherMode = m.extend({
|
|
2805
2800
|
/**
|
|
2806
2801
|
* Creates this mode for encryption.
|
|
2807
2802
|
*
|
|
@@ -2885,7 +2880,7 @@ function X() {
|
|
|
2885
2880
|
H[$ + U] ^= O[U];
|
|
2886
2881
|
}
|
|
2887
2882
|
return F;
|
|
2888
|
-
})(),
|
|
2883
|
+
})(), g = u.pad = {}, i = g.Pkcs7 = {
|
|
2889
2884
|
/**
|
|
2890
2885
|
* Pads data using the algorithm defined in PKCS #5/7.
|
|
2891
2886
|
*
|
|
@@ -2920,7 +2915,7 @@ function X() {
|
|
|
2920
2915
|
F.sigBytes -= w;
|
|
2921
2916
|
}
|
|
2922
2917
|
};
|
|
2923
|
-
|
|
2918
|
+
v.BlockCipher = s.extend({
|
|
2924
2919
|
/**
|
|
2925
2920
|
* Configuration options.
|
|
2926
2921
|
*
|
|
@@ -2946,7 +2941,7 @@ function X() {
|
|
|
2946
2941
|
},
|
|
2947
2942
|
blockSize: 128 / 32
|
|
2948
2943
|
});
|
|
2949
|
-
var o =
|
|
2944
|
+
var o = v.CipherParams = m.extend({
|
|
2950
2945
|
/**
|
|
2951
2946
|
* Initializes a newly created cipher params object.
|
|
2952
2947
|
*
|
|
@@ -3022,7 +3017,7 @@ function X() {
|
|
|
3022
3017
|
var w, H = n.parse(F), $ = H.words;
|
|
3023
3018
|
return $[0] == 1398893684 && $[1] == 1701076831 && (w = B.create($.slice(2, 4)), $.splice(0, 4), H.sigBytes -= 16), o.create({ ciphertext: H, salt: w });
|
|
3024
3019
|
}
|
|
3025
|
-
},
|
|
3020
|
+
}, D = v.SerializableCipher = m.extend({
|
|
3026
3021
|
/**
|
|
3027
3022
|
* Configuration options.
|
|
3028
3023
|
*
|
|
@@ -3129,13 +3124,13 @@ function X() {
|
|
|
3129
3124
|
var q = B.create(O.words.slice(w), H * 4);
|
|
3130
3125
|
return O.sigBytes = w * 4, o.create({ key: O, iv: q, salt: $ });
|
|
3131
3126
|
}
|
|
3132
|
-
}, R =
|
|
3127
|
+
}, R = v.PasswordBasedCipher = D.extend({
|
|
3133
3128
|
/**
|
|
3134
3129
|
* Configuration options.
|
|
3135
3130
|
*
|
|
3136
3131
|
* @property {KDF} kdf The key derivation function to use to generate a key and IV from a password. Default: OpenSSL
|
|
3137
3132
|
*/
|
|
3138
|
-
cfg:
|
|
3133
|
+
cfg: D.cfg.extend({
|
|
3139
3134
|
kdf: k
|
|
3140
3135
|
}),
|
|
3141
3136
|
/**
|
|
@@ -3159,7 +3154,7 @@ function X() {
|
|
|
3159
3154
|
$ = this.cfg.extend($);
|
|
3160
3155
|
var z = $.kdf.execute(H, F.keySize, F.ivSize, $.salt, $.hasher);
|
|
3161
3156
|
$.iv = z.iv;
|
|
3162
|
-
var O =
|
|
3157
|
+
var O = D.encrypt.call(this, F, w, z.key, $);
|
|
3163
3158
|
return O.mixIn(z), O;
|
|
3164
3159
|
},
|
|
3165
3160
|
/**
|
|
@@ -3183,69 +3178,69 @@ function X() {
|
|
|
3183
3178
|
$ = this.cfg.extend($), w = this._parse(w, $.format);
|
|
3184
3179
|
var z = $.kdf.execute(H, F.keySize, F.ivSize, w.salt, $.hasher);
|
|
3185
3180
|
$.iv = z.iv;
|
|
3186
|
-
var O =
|
|
3181
|
+
var O = D.decrypt.call(this, F, w, z.key, $);
|
|
3187
3182
|
return O;
|
|
3188
3183
|
}
|
|
3189
3184
|
});
|
|
3190
3185
|
})();
|
|
3191
3186
|
});
|
|
3192
|
-
})(
|
|
3187
|
+
})(U0)), U0.exports;
|
|
3193
3188
|
}
|
|
3194
|
-
var
|
|
3189
|
+
var j0 = { exports: {} }, qt = j0.exports, ee;
|
|
3195
3190
|
function Tt() {
|
|
3196
|
-
return ee || (ee = 1, (function(r,
|
|
3191
|
+
return ee || (ee = 1, (function(r, h) {
|
|
3197
3192
|
(function(t, e, u) {
|
|
3198
3193
|
r.exports = e(M(), X());
|
|
3199
3194
|
})(qt, function(t) {
|
|
3200
3195
|
return t.mode.CFB = (function() {
|
|
3201
3196
|
var e = t.lib.BlockCipherMode.extend();
|
|
3202
3197
|
e.Encryptor = e.extend({
|
|
3203
|
-
processBlock: function(
|
|
3198
|
+
processBlock: function(v, m) {
|
|
3204
3199
|
var B = this._cipher, C = B.blockSize;
|
|
3205
|
-
u.call(this,
|
|
3200
|
+
u.call(this, v, m, C, B), this._prevBlock = v.slice(m, m + C);
|
|
3206
3201
|
}
|
|
3207
3202
|
}), e.Decryptor = e.extend({
|
|
3208
|
-
processBlock: function(
|
|
3209
|
-
var B = this._cipher, C = B.blockSize, x =
|
|
3210
|
-
u.call(this,
|
|
3203
|
+
processBlock: function(v, m) {
|
|
3204
|
+
var B = this._cipher, C = B.blockSize, x = v.slice(m, m + C);
|
|
3205
|
+
u.call(this, v, m, C, B), this._prevBlock = x;
|
|
3211
3206
|
}
|
|
3212
3207
|
});
|
|
3213
|
-
function u(
|
|
3208
|
+
function u(v, m, B, C) {
|
|
3214
3209
|
var x, n = this._iv;
|
|
3215
3210
|
n ? (x = n.slice(0), this._iv = void 0) : x = this._prevBlock, C.encryptBlock(x, 0);
|
|
3216
3211
|
for (var E = 0; E < B; E++)
|
|
3217
|
-
|
|
3212
|
+
v[m + E] ^= x[E];
|
|
3218
3213
|
}
|
|
3219
3214
|
return e;
|
|
3220
3215
|
})(), t.mode.CFB;
|
|
3221
3216
|
});
|
|
3222
|
-
})(
|
|
3217
|
+
})(j0)), j0.exports;
|
|
3223
3218
|
}
|
|
3224
|
-
var
|
|
3219
|
+
var G0 = { exports: {} }, Mt = G0.exports, te;
|
|
3225
3220
|
function Nt() {
|
|
3226
|
-
return te || (te = 1, (function(r,
|
|
3221
|
+
return te || (te = 1, (function(r, h) {
|
|
3227
3222
|
(function(t, e, u) {
|
|
3228
3223
|
r.exports = e(M(), X());
|
|
3229
3224
|
})(Mt, function(t) {
|
|
3230
3225
|
return t.mode.CTR = (function() {
|
|
3231
3226
|
var e = t.lib.BlockCipherMode.extend(), u = e.Encryptor = e.extend({
|
|
3232
|
-
processBlock: function(
|
|
3227
|
+
processBlock: function(v, m) {
|
|
3233
3228
|
var B = this._cipher, C = B.blockSize, x = this._iv, n = this._counter;
|
|
3234
3229
|
x && (n = this._counter = x.slice(0), this._iv = void 0);
|
|
3235
3230
|
var E = n.slice(0);
|
|
3236
3231
|
B.encryptBlock(E, 0), n[C - 1] = n[C - 1] + 1 | 0;
|
|
3237
3232
|
for (var a = 0; a < C; a++)
|
|
3238
|
-
|
|
3233
|
+
v[m + a] ^= E[a];
|
|
3239
3234
|
}
|
|
3240
3235
|
});
|
|
3241
3236
|
return e.Decryptor = u, e;
|
|
3242
3237
|
})(), t.mode.CTR;
|
|
3243
3238
|
});
|
|
3244
|
-
})(
|
|
3239
|
+
})(G0)), G0.exports;
|
|
3245
3240
|
}
|
|
3246
|
-
var
|
|
3241
|
+
var K0 = { exports: {} }, Ut = K0.exports, xe;
|
|
3247
3242
|
function jt() {
|
|
3248
|
-
return xe || (xe = 1, (function(r,
|
|
3243
|
+
return xe || (xe = 1, (function(r, h) {
|
|
3249
3244
|
(function(t, e, u) {
|
|
3250
3245
|
r.exports = e(M(), X());
|
|
3251
3246
|
})(Ut, function(t) {
|
|
@@ -3259,13 +3254,13 @@ function jt() {
|
|
|
3259
3254
|
B += 1 << 24;
|
|
3260
3255
|
return B;
|
|
3261
3256
|
}
|
|
3262
|
-
function
|
|
3257
|
+
function v(B) {
|
|
3263
3258
|
return (B[0] = u(B[0])) === 0 && (B[1] = u(B[1])), B;
|
|
3264
3259
|
}
|
|
3265
3260
|
var m = e.Encryptor = e.extend({
|
|
3266
3261
|
processBlock: function(B, C) {
|
|
3267
3262
|
var x = this._cipher, n = x.blockSize, E = this._iv, a = this._counter;
|
|
3268
|
-
E && (a = this._counter = E.slice(0), this._iv = void 0),
|
|
3263
|
+
E && (a = this._counter = E.slice(0), this._iv = void 0), v(a);
|
|
3269
3264
|
var s = a.slice(0);
|
|
3270
3265
|
x.encryptBlock(s, 0);
|
|
3271
3266
|
for (var f = 0; f < n; f++)
|
|
@@ -3275,58 +3270,58 @@ function jt() {
|
|
|
3275
3270
|
return e.Decryptor = m, e;
|
|
3276
3271
|
})(), t.mode.CTRGladman;
|
|
3277
3272
|
});
|
|
3278
|
-
})(
|
|
3273
|
+
})(K0)), K0.exports;
|
|
3279
3274
|
}
|
|
3280
|
-
var
|
|
3275
|
+
var X0 = { exports: {} }, Gt = X0.exports, ne;
|
|
3281
3276
|
function Kt() {
|
|
3282
|
-
return ne || (ne = 1, (function(r,
|
|
3277
|
+
return ne || (ne = 1, (function(r, h) {
|
|
3283
3278
|
(function(t, e, u) {
|
|
3284
3279
|
r.exports = e(M(), X());
|
|
3285
3280
|
})(Gt, function(t) {
|
|
3286
3281
|
return t.mode.OFB = (function() {
|
|
3287
3282
|
var e = t.lib.BlockCipherMode.extend(), u = e.Encryptor = e.extend({
|
|
3288
|
-
processBlock: function(
|
|
3283
|
+
processBlock: function(v, m) {
|
|
3289
3284
|
var B = this._cipher, C = B.blockSize, x = this._iv, n = this._keystream;
|
|
3290
3285
|
x && (n = this._keystream = x.slice(0), this._iv = void 0), B.encryptBlock(n, 0);
|
|
3291
3286
|
for (var E = 0; E < C; E++)
|
|
3292
|
-
|
|
3287
|
+
v[m + E] ^= n[E];
|
|
3293
3288
|
}
|
|
3294
3289
|
});
|
|
3295
3290
|
return e.Decryptor = u, e;
|
|
3296
3291
|
})(), t.mode.OFB;
|
|
3297
3292
|
});
|
|
3298
|
-
})(
|
|
3293
|
+
})(X0)), X0.exports;
|
|
3299
3294
|
}
|
|
3300
|
-
var
|
|
3295
|
+
var Y0 = { exports: {} }, Xt = Y0.exports, ae;
|
|
3301
3296
|
function Yt() {
|
|
3302
|
-
return ae || (ae = 1, (function(r,
|
|
3297
|
+
return ae || (ae = 1, (function(r, h) {
|
|
3303
3298
|
(function(t, e, u) {
|
|
3304
3299
|
r.exports = e(M(), X());
|
|
3305
3300
|
})(Xt, function(t) {
|
|
3306
3301
|
return t.mode.ECB = (function() {
|
|
3307
3302
|
var e = t.lib.BlockCipherMode.extend();
|
|
3308
3303
|
return e.Encryptor = e.extend({
|
|
3309
|
-
processBlock: function(u,
|
|
3310
|
-
this._cipher.encryptBlock(u,
|
|
3304
|
+
processBlock: function(u, v) {
|
|
3305
|
+
this._cipher.encryptBlock(u, v);
|
|
3311
3306
|
}
|
|
3312
3307
|
}), e.Decryptor = e.extend({
|
|
3313
|
-
processBlock: function(u,
|
|
3314
|
-
this._cipher.decryptBlock(u,
|
|
3308
|
+
processBlock: function(u, v) {
|
|
3309
|
+
this._cipher.decryptBlock(u, v);
|
|
3315
3310
|
}
|
|
3316
3311
|
}), e;
|
|
3317
3312
|
})(), t.mode.ECB;
|
|
3318
3313
|
});
|
|
3319
|
-
})(
|
|
3314
|
+
})(Y0)), Y0.exports;
|
|
3320
3315
|
}
|
|
3321
|
-
var
|
|
3316
|
+
var Z0 = { exports: {} }, Zt = Z0.exports, oe;
|
|
3322
3317
|
function Qt() {
|
|
3323
|
-
return oe || (oe = 1, (function(r,
|
|
3318
|
+
return oe || (oe = 1, (function(r, h) {
|
|
3324
3319
|
(function(t, e, u) {
|
|
3325
3320
|
r.exports = e(M(), X());
|
|
3326
3321
|
})(Zt, function(t) {
|
|
3327
3322
|
return t.pad.AnsiX923 = {
|
|
3328
3323
|
pad: function(e, u) {
|
|
3329
|
-
var
|
|
3324
|
+
var v = e.sigBytes, m = u * 4, B = m - v % m, C = v + B - 1;
|
|
3330
3325
|
e.clamp(), e.words[C >>> 2] |= B << 24 - C % 4 * 8, e.sigBytes += B;
|
|
3331
3326
|
},
|
|
3332
3327
|
unpad: function(e) {
|
|
@@ -3335,17 +3330,17 @@ function Qt() {
|
|
|
3335
3330
|
}
|
|
3336
3331
|
}, t.pad.Ansix923;
|
|
3337
3332
|
});
|
|
3338
|
-
})(
|
|
3333
|
+
})(Z0)), Z0.exports;
|
|
3339
3334
|
}
|
|
3340
|
-
var
|
|
3335
|
+
var Q0 = { exports: {} }, Vt = Q0.exports, ie;
|
|
3341
3336
|
function Jt() {
|
|
3342
|
-
return ie || (ie = 1, (function(r,
|
|
3337
|
+
return ie || (ie = 1, (function(r, h) {
|
|
3343
3338
|
(function(t, e, u) {
|
|
3344
3339
|
r.exports = e(M(), X());
|
|
3345
3340
|
})(Vt, function(t) {
|
|
3346
3341
|
return t.pad.Iso10126 = {
|
|
3347
3342
|
pad: function(e, u) {
|
|
3348
|
-
var
|
|
3343
|
+
var v = u * 4, m = v - e.sigBytes % v;
|
|
3349
3344
|
e.concat(t.lib.WordArray.random(m - 1)).concat(t.lib.WordArray.create([m << 24], 1));
|
|
3350
3345
|
},
|
|
3351
3346
|
unpad: function(e) {
|
|
@@ -3354,11 +3349,11 @@ function Jt() {
|
|
|
3354
3349
|
}
|
|
3355
3350
|
}, t.pad.Iso10126;
|
|
3356
3351
|
});
|
|
3357
|
-
})(
|
|
3352
|
+
})(Q0)), Q0.exports;
|
|
3358
3353
|
}
|
|
3359
|
-
var
|
|
3354
|
+
var V0 = { exports: {} }, rx = V0.exports, se;
|
|
3360
3355
|
function ex() {
|
|
3361
|
-
return se || (se = 1, (function(r,
|
|
3356
|
+
return se || (se = 1, (function(r, h) {
|
|
3362
3357
|
(function(t, e, u) {
|
|
3363
3358
|
r.exports = e(M(), X());
|
|
3364
3359
|
})(rx, function(t) {
|
|
@@ -3371,33 +3366,33 @@ function ex() {
|
|
|
3371
3366
|
}
|
|
3372
3367
|
}, t.pad.Iso97971;
|
|
3373
3368
|
});
|
|
3374
|
-
})(
|
|
3369
|
+
})(V0)), V0.exports;
|
|
3375
3370
|
}
|
|
3376
|
-
var
|
|
3371
|
+
var J0 = { exports: {} }, tx = J0.exports, ce;
|
|
3377
3372
|
function xx() {
|
|
3378
|
-
return ce || (ce = 1, (function(r,
|
|
3373
|
+
return ce || (ce = 1, (function(r, h) {
|
|
3379
3374
|
(function(t, e, u) {
|
|
3380
3375
|
r.exports = e(M(), X());
|
|
3381
3376
|
})(tx, function(t) {
|
|
3382
3377
|
return t.pad.ZeroPadding = {
|
|
3383
3378
|
pad: function(e, u) {
|
|
3384
|
-
var
|
|
3385
|
-
e.clamp(), e.sigBytes +=
|
|
3379
|
+
var v = u * 4;
|
|
3380
|
+
e.clamp(), e.sigBytes += v - (e.sigBytes % v || v);
|
|
3386
3381
|
},
|
|
3387
3382
|
unpad: function(e) {
|
|
3388
|
-
for (var u = e.words,
|
|
3389
|
-
if (u[
|
|
3390
|
-
e.sigBytes =
|
|
3383
|
+
for (var u = e.words, v = e.sigBytes - 1, v = e.sigBytes - 1; v >= 0; v--)
|
|
3384
|
+
if (u[v >>> 2] >>> 24 - v % 4 * 8 & 255) {
|
|
3385
|
+
e.sigBytes = v + 1;
|
|
3391
3386
|
break;
|
|
3392
3387
|
}
|
|
3393
3388
|
}
|
|
3394
3389
|
}, t.pad.ZeroPadding;
|
|
3395
3390
|
});
|
|
3396
|
-
})(
|
|
3391
|
+
})(J0)), J0.exports;
|
|
3397
3392
|
}
|
|
3398
|
-
var
|
|
3393
|
+
var rr = { exports: {} }, nx = rr.exports, fe;
|
|
3399
3394
|
function ax() {
|
|
3400
|
-
return fe || (fe = 1, (function(r,
|
|
3395
|
+
return fe || (fe = 1, (function(r, h) {
|
|
3401
3396
|
(function(t, e, u) {
|
|
3402
3397
|
r.exports = e(M(), X());
|
|
3403
3398
|
})(nx, function(t) {
|
|
@@ -3408,16 +3403,16 @@ function ax() {
|
|
|
3408
3403
|
}
|
|
3409
3404
|
}, t.pad.NoPadding;
|
|
3410
3405
|
});
|
|
3411
|
-
})(
|
|
3406
|
+
})(rr)), rr.exports;
|
|
3412
3407
|
}
|
|
3413
|
-
var
|
|
3408
|
+
var er = { exports: {} }, ox = er.exports, ue;
|
|
3414
3409
|
function ix() {
|
|
3415
|
-
return ue || (ue = 1, (function(r,
|
|
3410
|
+
return ue || (ue = 1, (function(r, h) {
|
|
3416
3411
|
(function(t, e, u) {
|
|
3417
3412
|
r.exports = e(M(), X());
|
|
3418
3413
|
})(ox, function(t) {
|
|
3419
3414
|
return (function(e) {
|
|
3420
|
-
var u = t,
|
|
3415
|
+
var u = t, v = u.lib, m = v.CipherParams, B = u.enc, C = B.Hex, x = u.format;
|
|
3421
3416
|
x.Hex = {
|
|
3422
3417
|
/**
|
|
3423
3418
|
* Converts the ciphertext of a cipher params object to a hexadecimally encoded string.
|
|
@@ -3455,34 +3450,34 @@ function ix() {
|
|
|
3455
3450
|
};
|
|
3456
3451
|
})(), t.format.Hex;
|
|
3457
3452
|
});
|
|
3458
|
-
})(
|
|
3453
|
+
})(er)), er.exports;
|
|
3459
3454
|
}
|
|
3460
|
-
var
|
|
3455
|
+
var tr = { exports: {} }, sx = tr.exports, de;
|
|
3461
3456
|
function cx() {
|
|
3462
|
-
return de || (de = 1, (function(r,
|
|
3457
|
+
return de || (de = 1, (function(r, h) {
|
|
3463
3458
|
(function(t, e, u) {
|
|
3464
3459
|
r.exports = e(M(), i0(), s0(), a0(), X());
|
|
3465
3460
|
})(sx, function(t) {
|
|
3466
3461
|
return (function() {
|
|
3467
|
-
var e = t, u = e.lib,
|
|
3462
|
+
var e = t, u = e.lib, v = u.BlockCipher, m = e.algo, B = [], C = [], x = [], n = [], E = [], a = [], s = [], f = [], p = [], l = [];
|
|
3468
3463
|
(function() {
|
|
3469
3464
|
for (var o = [], d = 0; d < 256; d++)
|
|
3470
3465
|
d < 128 ? o[d] = d << 1 : o[d] = d << 1 ^ 283;
|
|
3471
|
-
for (var b = 0,
|
|
3472
|
-
var y =
|
|
3466
|
+
for (var b = 0, D = 0, d = 0; d < 256; d++) {
|
|
3467
|
+
var y = D ^ D << 1 ^ D << 2 ^ D << 3 ^ D << 4;
|
|
3473
3468
|
y = y >>> 8 ^ y & 255 ^ 99, B[b] = y, C[y] = b;
|
|
3474
3469
|
var k = o[b], R = o[k], F = o[R], w = o[y] * 257 ^ y * 16843008;
|
|
3475
3470
|
x[b] = w << 24 | w >>> 8, n[b] = w << 16 | w >>> 16, E[b] = w << 8 | w >>> 24, a[b] = w;
|
|
3476
3471
|
var w = F * 16843009 ^ R * 65537 ^ k * 257 ^ b * 16843008;
|
|
3477
|
-
s[y] = w << 24 | w >>> 8, f[y] = w << 16 | w >>> 16, p[y] = w << 8 | w >>> 24, l[y] = w, b ? (b = k ^ o[o[o[F ^ k]]],
|
|
3472
|
+
s[y] = w << 24 | w >>> 8, f[y] = w << 16 | w >>> 16, p[y] = w << 8 | w >>> 24, l[y] = w, b ? (b = k ^ o[o[o[F ^ k]]], D ^= o[o[D]]) : b = D = 1;
|
|
3478
3473
|
}
|
|
3479
3474
|
})();
|
|
3480
|
-
var
|
|
3475
|
+
var g = [0, 1, 2, 4, 8, 16, 32, 64, 128, 27, 54], i = m.AES = v.extend({
|
|
3481
3476
|
_doReset: function() {
|
|
3482
3477
|
var o;
|
|
3483
3478
|
if (!(this._nRounds && this._keyPriorReset === this._key)) {
|
|
3484
|
-
for (var d = this._keyPriorReset = this._key, b = d.words,
|
|
3485
|
-
F <
|
|
3479
|
+
for (var d = this._keyPriorReset = this._key, b = d.words, D = d.sigBytes / 4, y = this._nRounds = D + 6, k = (y + 1) * 4, R = this._keySchedule = [], F = 0; F < k; F++)
|
|
3480
|
+
F < D ? R[F] = b[F] : (o = R[F - 1], F % D ? D > 6 && F % D == 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 ^= g[F / D | 0] << 24), R[F] = R[F - D] ^ o);
|
|
3486
3481
|
for (var w = this._invKeySchedule = [], H = 0; H < k; H++) {
|
|
3487
3482
|
var F = k - H;
|
|
3488
3483
|
if (H % 4)
|
|
@@ -3502,9 +3497,9 @@ function cx() {
|
|
|
3502
3497
|
var b = o[d + 1];
|
|
3503
3498
|
o[d + 1] = o[d + 3], o[d + 3] = b;
|
|
3504
3499
|
},
|
|
3505
|
-
_doCryptBlock: function(o, d, b,
|
|
3500
|
+
_doCryptBlock: function(o, d, b, D, y, k, R, F) {
|
|
3506
3501
|
for (var w = this._nRounds, H = o[d] ^ b[0], $ = o[d + 1] ^ b[1], z = o[d + 2] ^ b[2], O = o[d + 3] ^ b[3], q = 4, U = 1; U < w; U++) {
|
|
3507
|
-
var T =
|
|
3502
|
+
var T = D[H >>> 24] ^ y[$ >>> 16 & 255] ^ k[z >>> 8 & 255] ^ R[O & 255] ^ b[q++], N = D[$ >>> 24] ^ y[z >>> 16 & 255] ^ k[O >>> 8 & 255] ^ R[H & 255] ^ b[q++], j = D[z >>> 24] ^ y[O >>> 16 & 255] ^ k[H >>> 8 & 255] ^ R[$ & 255] ^ b[q++], S = D[O >>> 24] ^ y[H >>> 16 & 255] ^ k[$ >>> 8 & 255] ^ R[z & 255] ^ b[q++];
|
|
3508
3503
|
H = T, $ = N, z = j, O = S;
|
|
3509
3504
|
}
|
|
3510
3505
|
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++];
|
|
@@ -3512,19 +3507,19 @@ function cx() {
|
|
|
3512
3507
|
},
|
|
3513
3508
|
keySize: 256 / 32
|
|
3514
3509
|
});
|
|
3515
|
-
e.AES =
|
|
3510
|
+
e.AES = v._createHelper(i);
|
|
3516
3511
|
})(), t.AES;
|
|
3517
3512
|
});
|
|
3518
|
-
})(
|
|
3513
|
+
})(tr)), tr.exports;
|
|
3519
3514
|
}
|
|
3520
|
-
var
|
|
3515
|
+
var xr = { exports: {} }, fx = xr.exports, le;
|
|
3521
3516
|
function ux() {
|
|
3522
|
-
return le || (le = 1, (function(r,
|
|
3517
|
+
return le || (le = 1, (function(r, h) {
|
|
3523
3518
|
(function(t, e, u) {
|
|
3524
3519
|
r.exports = e(M(), i0(), s0(), a0(), X());
|
|
3525
3520
|
})(fx, function(t) {
|
|
3526
3521
|
return (function() {
|
|
3527
|
-
var e = t, u = e.lib,
|
|
3522
|
+
var e = t, u = e.lib, v = u.WordArray, m = u.BlockCipher, B = e.algo, C = [
|
|
3528
3523
|
57,
|
|
3529
3524
|
49,
|
|
3530
3525
|
41,
|
|
@@ -4170,12 +4165,12 @@ function ux() {
|
|
|
4170
4165
|
2147483679
|
|
4171
4166
|
], s = B.DES = m.extend({
|
|
4172
4167
|
_doReset: function() {
|
|
4173
|
-
for (var
|
|
4168
|
+
for (var g = this._key, i = g.words, o = [], d = 0; d < 56; d++) {
|
|
4174
4169
|
var b = C[d] - 1;
|
|
4175
4170
|
o[d] = i[b >>> 5] >>> 31 - b % 32 & 1;
|
|
4176
4171
|
}
|
|
4177
|
-
for (var
|
|
4178
|
-
for (var k =
|
|
4172
|
+
for (var D = this._subKeys = [], y = 0; y < 16; y++) {
|
|
4173
|
+
for (var k = D[y] = [], R = n[y], d = 0; d < 24; d++)
|
|
4179
4174
|
k[d / 6 | 0] |= o[(x[d] - 1 + R) % 28] << 31 - d % 6, k[4 + (d / 6 | 0)] |= o[28 + (x[d + 24] - 1 + R) % 28] << 31 - d % 6;
|
|
4180
4175
|
k[0] = k[0] << 1 | k[0] >>> 31;
|
|
4181
4176
|
for (var d = 1; d < 7; d++)
|
|
@@ -4183,50 +4178,50 @@ function ux() {
|
|
|
4183
4178
|
k[7] = k[7] << 5 | k[7] >>> 27;
|
|
4184
4179
|
}
|
|
4185
4180
|
for (var F = this._invSubKeys = [], d = 0; d < 16; d++)
|
|
4186
|
-
F[d] =
|
|
4181
|
+
F[d] = D[15 - d];
|
|
4187
4182
|
},
|
|
4188
|
-
encryptBlock: function(
|
|
4189
|
-
this._doCryptBlock(
|
|
4183
|
+
encryptBlock: function(g, i) {
|
|
4184
|
+
this._doCryptBlock(g, i, this._subKeys);
|
|
4190
4185
|
},
|
|
4191
|
-
decryptBlock: function(
|
|
4192
|
-
this._doCryptBlock(
|
|
4186
|
+
decryptBlock: function(g, i) {
|
|
4187
|
+
this._doCryptBlock(g, i, this._invSubKeys);
|
|
4193
4188
|
},
|
|
4194
|
-
_doCryptBlock: function(
|
|
4195
|
-
this._lBlock =
|
|
4189
|
+
_doCryptBlock: function(g, i, o) {
|
|
4190
|
+
this._lBlock = g[i], this._rBlock = g[i + 1], f.call(this, 4, 252645135), f.call(this, 16, 65535), p.call(this, 2, 858993459), p.call(this, 8, 16711935), f.call(this, 1, 1431655765);
|
|
4196
4191
|
for (var d = 0; d < 16; d++) {
|
|
4197
|
-
for (var b = o[d],
|
|
4192
|
+
for (var b = o[d], D = this._lBlock, y = this._rBlock, k = 0, R = 0; R < 8; R++)
|
|
4198
4193
|
k |= E[R][((y ^ b[R]) & a[R]) >>> 0];
|
|
4199
|
-
this._lBlock = y, this._rBlock =
|
|
4194
|
+
this._lBlock = y, this._rBlock = D ^ k;
|
|
4200
4195
|
}
|
|
4201
4196
|
var F = this._lBlock;
|
|
4202
|
-
this._lBlock = this._rBlock, this._rBlock = F, f.call(this, 1, 1431655765), p.call(this, 8, 16711935), p.call(this, 2, 858993459), f.call(this, 16, 65535), f.call(this, 4, 252645135),
|
|
4197
|
+
this._lBlock = this._rBlock, this._rBlock = F, f.call(this, 1, 1431655765), p.call(this, 8, 16711935), p.call(this, 2, 858993459), f.call(this, 16, 65535), f.call(this, 4, 252645135), g[i] = this._lBlock, g[i + 1] = this._rBlock;
|
|
4203
4198
|
},
|
|
4204
4199
|
keySize: 64 / 32,
|
|
4205
4200
|
ivSize: 64 / 32,
|
|
4206
4201
|
blockSize: 64 / 32
|
|
4207
4202
|
});
|
|
4208
|
-
function f(
|
|
4209
|
-
var o = (this._lBlock >>>
|
|
4210
|
-
this._rBlock ^= o, this._lBlock ^= o <<
|
|
4203
|
+
function f(g, i) {
|
|
4204
|
+
var o = (this._lBlock >>> g ^ this._rBlock) & i;
|
|
4205
|
+
this._rBlock ^= o, this._lBlock ^= o << g;
|
|
4211
4206
|
}
|
|
4212
|
-
function p(
|
|
4213
|
-
var o = (this._rBlock >>>
|
|
4214
|
-
this._lBlock ^= o, this._rBlock ^= o <<
|
|
4207
|
+
function p(g, i) {
|
|
4208
|
+
var o = (this._rBlock >>> g ^ this._lBlock) & i;
|
|
4209
|
+
this._lBlock ^= o, this._rBlock ^= o << g;
|
|
4215
4210
|
}
|
|
4216
4211
|
e.DES = m._createHelper(s);
|
|
4217
4212
|
var l = B.TripleDES = m.extend({
|
|
4218
4213
|
_doReset: function() {
|
|
4219
|
-
var
|
|
4214
|
+
var g = this._key, i = g.words;
|
|
4220
4215
|
if (i.length !== 2 && i.length !== 4 && i.length < 6)
|
|
4221
4216
|
throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");
|
|
4222
4217
|
var o = i.slice(0, 2), d = i.length < 4 ? i.slice(0, 2) : i.slice(2, 4), b = i.length < 6 ? i.slice(0, 2) : i.slice(4, 6);
|
|
4223
|
-
this._des1 = s.createEncryptor(
|
|
4218
|
+
this._des1 = s.createEncryptor(v.create(o)), this._des2 = s.createEncryptor(v.create(d)), this._des3 = s.createEncryptor(v.create(b));
|
|
4224
4219
|
},
|
|
4225
|
-
encryptBlock: function(
|
|
4226
|
-
this._des1.encryptBlock(
|
|
4220
|
+
encryptBlock: function(g, i) {
|
|
4221
|
+
this._des1.encryptBlock(g, i), this._des2.decryptBlock(g, i), this._des3.encryptBlock(g, i);
|
|
4227
4222
|
},
|
|
4228
|
-
decryptBlock: function(
|
|
4229
|
-
this._des3.decryptBlock(
|
|
4223
|
+
decryptBlock: function(g, i) {
|
|
4224
|
+
this._des3.decryptBlock(g, i), this._des2.encryptBlock(g, i), this._des1.decryptBlock(g, i);
|
|
4230
4225
|
},
|
|
4231
4226
|
keySize: 192 / 32,
|
|
4232
4227
|
ivSize: 64 / 32,
|
|
@@ -4235,22 +4230,22 @@ function ux() {
|
|
|
4235
4230
|
e.TripleDES = m._createHelper(l);
|
|
4236
4231
|
})(), t.TripleDES;
|
|
4237
4232
|
});
|
|
4238
|
-
})(
|
|
4233
|
+
})(xr)), xr.exports;
|
|
4239
4234
|
}
|
|
4240
|
-
var
|
|
4235
|
+
var nr = { exports: {} }, dx = nr.exports, he;
|
|
4241
4236
|
function lx() {
|
|
4242
|
-
return he || (he = 1, (function(r,
|
|
4237
|
+
return he || (he = 1, (function(r, h) {
|
|
4243
4238
|
(function(t, e, u) {
|
|
4244
4239
|
r.exports = e(M(), i0(), s0(), a0(), X());
|
|
4245
4240
|
})(dx, function(t) {
|
|
4246
4241
|
return (function() {
|
|
4247
|
-
var e = t, u = e.lib,
|
|
4242
|
+
var e = t, u = e.lib, v = u.StreamCipher, m = e.algo, B = m.RC4 = v.extend({
|
|
4248
4243
|
_doReset: function() {
|
|
4249
4244
|
for (var n = this._key, E = n.words, a = n.sigBytes, s = this._S = [], f = 0; f < 256; f++)
|
|
4250
4245
|
s[f] = f;
|
|
4251
4246
|
for (var f = 0, p = 0; f < 256; f++) {
|
|
4252
|
-
var l = f % a,
|
|
4253
|
-
p = (p + s[f] +
|
|
4247
|
+
var l = f % a, g = E[l >>> 2] >>> 24 - l % 4 * 8 & 255;
|
|
4248
|
+
p = (p + s[f] + g) % 256;
|
|
4254
4249
|
var i = s[f];
|
|
4255
4250
|
s[f] = s[p], s[p] = i;
|
|
4256
4251
|
}
|
|
@@ -4270,7 +4265,7 @@ function lx() {
|
|
|
4270
4265
|
}
|
|
4271
4266
|
return this._i = E, this._j = a, s;
|
|
4272
4267
|
}
|
|
4273
|
-
e.RC4 =
|
|
4268
|
+
e.RC4 = v._createHelper(B);
|
|
4274
4269
|
var x = m.RC4Drop = B.extend({
|
|
4275
4270
|
/**
|
|
4276
4271
|
* Configuration options.
|
|
@@ -4286,19 +4281,19 @@ function lx() {
|
|
|
4286
4281
|
C.call(this);
|
|
4287
4282
|
}
|
|
4288
4283
|
});
|
|
4289
|
-
e.RC4Drop =
|
|
4284
|
+
e.RC4Drop = v._createHelper(x);
|
|
4290
4285
|
})(), t.RC4;
|
|
4291
4286
|
});
|
|
4292
|
-
})(
|
|
4287
|
+
})(nr)), nr.exports;
|
|
4293
4288
|
}
|
|
4294
|
-
var
|
|
4289
|
+
var ar = { exports: {} }, hx = ar.exports, ve;
|
|
4295
4290
|
function vx() {
|
|
4296
|
-
return ve || (ve = 1, (function(r,
|
|
4291
|
+
return ve || (ve = 1, (function(r, h) {
|
|
4297
4292
|
(function(t, e, u) {
|
|
4298
4293
|
r.exports = e(M(), i0(), s0(), a0(), X());
|
|
4299
4294
|
})(hx, function(t) {
|
|
4300
4295
|
return (function() {
|
|
4301
|
-
var e = t, u = e.lib,
|
|
4296
|
+
var e = t, u = e.lib, v = u.StreamCipher, m = e.algo, B = [], C = [], x = [], n = m.Rabbit = v.extend({
|
|
4302
4297
|
_doReset: function() {
|
|
4303
4298
|
for (var a = this._key.words, s = this.cfg.iv, f = 0; f < 4; f++)
|
|
4304
4299
|
a[f] = (a[f] << 8 | a[f] >>> 24) & 16711935 | (a[f] << 24 | a[f] >>> 8) & 4278255360;
|
|
@@ -4327,8 +4322,8 @@ function vx() {
|
|
|
4327
4322
|
for (var f = 0; f < 8; f++)
|
|
4328
4323
|
l[f] ^= p[f + 4 & 7];
|
|
4329
4324
|
if (s) {
|
|
4330
|
-
var
|
|
4331
|
-
l[0] ^= d, l[1] ^=
|
|
4325
|
+
var g = s.words, i = g[0], o = g[1], d = (i << 8 | i >>> 24) & 16711935 | (i << 24 | i >>> 8) & 4278255360, b = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360, D = d >>> 16 | b & 4294901760, y = b << 16 | d & 65535;
|
|
4326
|
+
l[0] ^= d, l[1] ^= D, l[2] ^= b, l[3] ^= y, l[4] ^= d, l[5] ^= D, l[6] ^= b, l[7] ^= y;
|
|
4332
4327
|
for (var f = 0; f < 4; f++)
|
|
4333
4328
|
E.call(this);
|
|
4334
4329
|
}
|
|
@@ -4347,24 +4342,24 @@ function vx() {
|
|
|
4347
4342
|
C[f] = s[f];
|
|
4348
4343
|
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;
|
|
4349
4344
|
for (var f = 0; f < 8; f++) {
|
|
4350
|
-
var p = a[f] + s[f], l = p & 65535,
|
|
4345
|
+
var p = a[f] + s[f], l = p & 65535, g = p >>> 16, i = ((l * l >>> 17) + l * g >>> 15) + g * g, o = ((p & 4294901760) * p | 0) + ((p & 65535) * p | 0);
|
|
4351
4346
|
x[f] = i ^ o;
|
|
4352
4347
|
}
|
|
4353
4348
|
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;
|
|
4354
4349
|
}
|
|
4355
|
-
e.Rabbit =
|
|
4350
|
+
e.Rabbit = v._createHelper(n);
|
|
4356
4351
|
})(), t.Rabbit;
|
|
4357
4352
|
});
|
|
4358
|
-
})(
|
|
4353
|
+
})(ar)), ar.exports;
|
|
4359
4354
|
}
|
|
4360
|
-
var
|
|
4355
|
+
var or = { exports: {} }, px = or.exports, pe;
|
|
4361
4356
|
function Bx() {
|
|
4362
|
-
return pe || (pe = 1, (function(r,
|
|
4357
|
+
return pe || (pe = 1, (function(r, h) {
|
|
4363
4358
|
(function(t, e, u) {
|
|
4364
4359
|
r.exports = e(M(), i0(), s0(), a0(), X());
|
|
4365
4360
|
})(px, function(t) {
|
|
4366
4361
|
return (function() {
|
|
4367
|
-
var e = t, u = e.lib,
|
|
4362
|
+
var e = t, u = e.lib, v = u.StreamCipher, m = e.algo, B = [], C = [], x = [], n = m.RabbitLegacy = v.extend({
|
|
4368
4363
|
_doReset: function() {
|
|
4369
4364
|
var a = this._key.words, s = this.cfg.iv, f = this._X = [
|
|
4370
4365
|
a[0],
|
|
@@ -4391,8 +4386,8 @@ function Bx() {
|
|
|
4391
4386
|
for (var l = 0; l < 8; l++)
|
|
4392
4387
|
p[l] ^= f[l + 4 & 7];
|
|
4393
4388
|
if (s) {
|
|
4394
|
-
var
|
|
4395
|
-
p[0] ^= d, p[1] ^=
|
|
4389
|
+
var g = s.words, i = g[0], o = g[1], d = (i << 8 | i >>> 24) & 16711935 | (i << 24 | i >>> 8) & 4278255360, b = (o << 8 | o >>> 24) & 16711935 | (o << 24 | o >>> 8) & 4278255360, D = d >>> 16 | b & 4294901760, y = b << 16 | d & 65535;
|
|
4390
|
+
p[0] ^= d, p[1] ^= D, p[2] ^= b, p[3] ^= y, p[4] ^= d, p[5] ^= D, p[6] ^= b, p[7] ^= y;
|
|
4396
4391
|
for (var l = 0; l < 4; l++)
|
|
4397
4392
|
E.call(this);
|
|
4398
4393
|
}
|
|
@@ -4411,24 +4406,24 @@ function Bx() {
|
|
|
4411
4406
|
C[f] = s[f];
|
|
4412
4407
|
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;
|
|
4413
4408
|
for (var f = 0; f < 8; f++) {
|
|
4414
|
-
var p = a[f] + s[f], l = p & 65535,
|
|
4409
|
+
var p = a[f] + s[f], l = p & 65535, g = p >>> 16, i = ((l * l >>> 17) + l * g >>> 15) + g * g, o = ((p & 4294901760) * p | 0) + ((p & 65535) * p | 0);
|
|
4415
4410
|
x[f] = i ^ o;
|
|
4416
4411
|
}
|
|
4417
4412
|
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;
|
|
4418
4413
|
}
|
|
4419
|
-
e.RabbitLegacy =
|
|
4414
|
+
e.RabbitLegacy = v._createHelper(n);
|
|
4420
4415
|
})(), t.RabbitLegacy;
|
|
4421
4416
|
});
|
|
4422
|
-
})(
|
|
4417
|
+
})(or)), or.exports;
|
|
4423
4418
|
}
|
|
4424
|
-
var
|
|
4419
|
+
var ir = { exports: {} }, Cx = ir.exports, Be;
|
|
4425
4420
|
function Ex() {
|
|
4426
|
-
return Be || (Be = 1, (function(r,
|
|
4421
|
+
return Be || (Be = 1, (function(r, h) {
|
|
4427
4422
|
(function(t, e, u) {
|
|
4428
4423
|
r.exports = e(M(), i0(), s0(), a0(), X());
|
|
4429
4424
|
})(Cx, function(t) {
|
|
4430
4425
|
return (function() {
|
|
4431
|
-
var e = t, u = e.lib,
|
|
4426
|
+
var e = t, u = e.lib, v = u.BlockCipher, m = e.algo;
|
|
4432
4427
|
const B = 16, C = [
|
|
4433
4428
|
608135816,
|
|
4434
4429
|
2242054355,
|
|
@@ -5486,23 +5481,23 @@ function Ex() {
|
|
|
5486
5481
|
pbox: [],
|
|
5487
5482
|
sbox: []
|
|
5488
5483
|
};
|
|
5489
|
-
function E(l,
|
|
5490
|
-
let i =
|
|
5491
|
-
return
|
|
5484
|
+
function E(l, g) {
|
|
5485
|
+
let i = g >> 24 & 255, o = g >> 16 & 255, d = g >> 8 & 255, b = g & 255, D = l.sbox[0][i] + l.sbox[1][o];
|
|
5486
|
+
return D = D ^ l.sbox[2][d], D = D + l.sbox[3][b], D;
|
|
5492
5487
|
}
|
|
5493
|
-
function a(l,
|
|
5494
|
-
let o =
|
|
5495
|
-
for (let
|
|
5496
|
-
o = o ^ l.pbox[
|
|
5488
|
+
function a(l, g, i) {
|
|
5489
|
+
let o = g, d = i, b;
|
|
5490
|
+
for (let D = 0; D < B; ++D)
|
|
5491
|
+
o = o ^ l.pbox[D], d = E(l, o) ^ d, b = o, o = d, d = b;
|
|
5497
5492
|
return b = o, o = d, d = b, d = d ^ l.pbox[B], o = o ^ l.pbox[B + 1], { left: o, right: d };
|
|
5498
5493
|
}
|
|
5499
|
-
function s(l,
|
|
5500
|
-
let o =
|
|
5501
|
-
for (let
|
|
5502
|
-
o = o ^ l.pbox[
|
|
5494
|
+
function s(l, g, i) {
|
|
5495
|
+
let o = g, d = i, b;
|
|
5496
|
+
for (let D = B + 1; D > 1; --D)
|
|
5497
|
+
o = o ^ l.pbox[D], d = E(l, o) ^ d, b = o, o = d, d = b;
|
|
5503
5498
|
return b = o, o = d, d = b, d = d ^ l.pbox[1], o = o ^ l.pbox[0], { left: o, right: d };
|
|
5504
5499
|
}
|
|
5505
|
-
function f(l,
|
|
5500
|
+
function f(l, g, i) {
|
|
5506
5501
|
for (let y = 0; y < 4; y++) {
|
|
5507
5502
|
l.sbox[y] = [];
|
|
5508
5503
|
for (let k = 0; k < 256; k++)
|
|
@@ -5510,56 +5505,56 @@ function Ex() {
|
|
|
5510
5505
|
}
|
|
5511
5506
|
let o = 0;
|
|
5512
5507
|
for (let y = 0; y < B + 2; y++)
|
|
5513
|
-
l.pbox[y] = C[y] ^
|
|
5514
|
-
let d = 0, b = 0,
|
|
5508
|
+
l.pbox[y] = C[y] ^ g[o], o++, o >= i && (o = 0);
|
|
5509
|
+
let d = 0, b = 0, D = 0;
|
|
5515
5510
|
for (let y = 0; y < B + 2; y += 2)
|
|
5516
|
-
|
|
5511
|
+
D = a(l, d, b), d = D.left, b = D.right, l.pbox[y] = d, l.pbox[y + 1] = b;
|
|
5517
5512
|
for (let y = 0; y < 4; y++)
|
|
5518
5513
|
for (let k = 0; k < 256; k += 2)
|
|
5519
|
-
|
|
5514
|
+
D = a(l, d, b), d = D.left, b = D.right, l.sbox[y][k] = d, l.sbox[y][k + 1] = b;
|
|
5520
5515
|
return !0;
|
|
5521
5516
|
}
|
|
5522
|
-
var p = m.Blowfish =
|
|
5517
|
+
var p = m.Blowfish = v.extend({
|
|
5523
5518
|
_doReset: function() {
|
|
5524
5519
|
if (this._keyPriorReset !== this._key) {
|
|
5525
|
-
var l = this._keyPriorReset = this._key,
|
|
5526
|
-
f(n,
|
|
5520
|
+
var l = this._keyPriorReset = this._key, g = l.words, i = l.sigBytes / 4;
|
|
5521
|
+
f(n, g, i);
|
|
5527
5522
|
}
|
|
5528
5523
|
},
|
|
5529
|
-
encryptBlock: function(l,
|
|
5530
|
-
var i = a(n, l[
|
|
5531
|
-
l[
|
|
5524
|
+
encryptBlock: function(l, g) {
|
|
5525
|
+
var i = a(n, l[g], l[g + 1]);
|
|
5526
|
+
l[g] = i.left, l[g + 1] = i.right;
|
|
5532
5527
|
},
|
|
5533
|
-
decryptBlock: function(l,
|
|
5534
|
-
var i = s(n, l[
|
|
5535
|
-
l[
|
|
5528
|
+
decryptBlock: function(l, g) {
|
|
5529
|
+
var i = s(n, l[g], l[g + 1]);
|
|
5530
|
+
l[g] = i.left, l[g + 1] = i.right;
|
|
5536
5531
|
},
|
|
5537
5532
|
blockSize: 64 / 32,
|
|
5538
5533
|
keySize: 128 / 32,
|
|
5539
5534
|
ivSize: 64 / 32
|
|
5540
5535
|
});
|
|
5541
|
-
e.Blowfish =
|
|
5536
|
+
e.Blowfish = v._createHelper(p);
|
|
5542
5537
|
})(), t.Blowfish;
|
|
5543
5538
|
});
|
|
5544
|
-
})(
|
|
5539
|
+
})(ir)), ir.exports;
|
|
5545
5540
|
}
|
|
5546
|
-
var Ax =
|
|
5541
|
+
var Ax = _0.exports, Ce;
|
|
5547
5542
|
function Fx() {
|
|
5548
|
-
return Ce || (Ce = 1, (function(r,
|
|
5543
|
+
return Ce || (Ce = 1, (function(r, h) {
|
|
5549
5544
|
(function(t, e, u) {
|
|
5550
|
-
r.exports = e(M(), ur(), Bt(), Et(), i0(),
|
|
5545
|
+
r.exports = e(M(), ur(), Bt(), Et(), i0(), Dt(), s0(), ye(), Er(), yt(), we(), St(), $t(), Pt(), Ar(), It(), a0(), X(), Tt(), Nt(), jt(), Kt(), Yt(), Qt(), Jt(), ex(), xx(), ax(), ix(), cx(), ux(), lx(), vx(), Bx(), Ex());
|
|
5551
5546
|
})(Ax, function(t) {
|
|
5552
5547
|
return t;
|
|
5553
5548
|
});
|
|
5554
|
-
})(
|
|
5549
|
+
})(_0)), _0.exports;
|
|
5555
5550
|
}
|
|
5556
5551
|
Fx();
|
|
5557
5552
|
let ke = null, Se = null, He = null, $e = null;
|
|
5558
5553
|
Math.random().toString(36).substring(7);
|
|
5559
|
-
function
|
|
5554
|
+
function Dx(r) {
|
|
5560
5555
|
ke = r.token, Se = r.apiUrl, He = r.deviceId, $e = r.domain;
|
|
5561
5556
|
}
|
|
5562
|
-
function
|
|
5557
|
+
function gx() {
|
|
5563
5558
|
return {
|
|
5564
5559
|
token: ke,
|
|
5565
5560
|
apiUrl: Se,
|
|
@@ -5568,11 +5563,11 @@ function Dx() {
|
|
|
5568
5563
|
};
|
|
5569
5564
|
}
|
|
5570
5565
|
function bx(r) {
|
|
5571
|
-
return `/sdk-workers/${(r.split("/").pop() || r).replace(/\.ts$/, ".js")}?v=1.1.
|
|
5566
|
+
return `/sdk-workers/${(r.split("/").pop() || r).replace(/\.ts$/, ".js")}?v=1.1.144`;
|
|
5572
5567
|
}
|
|
5573
|
-
function mx(r,
|
|
5568
|
+
function mx(r, h) {
|
|
5574
5569
|
const t = bx(r);
|
|
5575
|
-
return new Worker(t, { type: "module", ...
|
|
5570
|
+
return new Worker(t, { type: "module", ...h });
|
|
5576
5571
|
}
|
|
5577
5572
|
const Fr = () => {
|
|
5578
5573
|
try {
|
|
@@ -5580,31 +5575,31 @@ const Fr = () => {
|
|
|
5580
5575
|
} catch {
|
|
5581
5576
|
}
|
|
5582
5577
|
return !1;
|
|
5583
|
-
},
|
|
5578
|
+
}, b0 = (...r) => {
|
|
5584
5579
|
Fr();
|
|
5585
5580
|
}, Ee = (...r) => {
|
|
5586
5581
|
Fr();
|
|
5587
5582
|
}, Ae = /* @__PURE__ */ new Map(), pr = /* @__PURE__ */ new Map();
|
|
5588
5583
|
let _x = 0;
|
|
5589
5584
|
function yx(r) {
|
|
5590
|
-
const
|
|
5591
|
-
if (
|
|
5585
|
+
const h = Ae.get(r);
|
|
5586
|
+
if (h) return h;
|
|
5592
5587
|
const t = mx("./deform.worker.ts");
|
|
5593
5588
|
try {
|
|
5594
5589
|
t.postMessage({ type: "SET_DEBUG", debugRender: Fr() });
|
|
5595
5590
|
} catch {
|
|
5596
5591
|
}
|
|
5597
5592
|
t.onmessage = (u) => {
|
|
5598
|
-
const { id:
|
|
5599
|
-
|
|
5593
|
+
const { id: v, imageBitmap: m, error: B, duration: C } = u.data ?? {}, x = C ? ` worker耗时=${Math.round(C)}ms` : "";
|
|
5594
|
+
b0(`[renderService] deform worker 响应 id=${v}${x}`, {
|
|
5600
5595
|
hasImageBitmap: !!m,
|
|
5601
5596
|
width: m?.width,
|
|
5602
5597
|
height: m?.height,
|
|
5603
5598
|
error: B
|
|
5604
5599
|
});
|
|
5605
|
-
const n = pr.get(
|
|
5600
|
+
const n = pr.get(v);
|
|
5606
5601
|
if (n) {
|
|
5607
|
-
if (pr.delete(
|
|
5602
|
+
if (pr.delete(v), B) {
|
|
5608
5603
|
n.reject(new Error(B));
|
|
5609
5604
|
return;
|
|
5610
5605
|
}
|
|
@@ -5613,13 +5608,13 @@ function yx(r) {
|
|
|
5613
5608
|
}, t.onerror = (u) => {
|
|
5614
5609
|
};
|
|
5615
5610
|
const e = () => {
|
|
5616
|
-
const u =
|
|
5617
|
-
return
|
|
5611
|
+
const u = gx();
|
|
5612
|
+
return b0("🔍 [workerManager] 检查 License Token:", {
|
|
5618
5613
|
hasToken: !!u.token,
|
|
5619
5614
|
tokenPreview: u.token ? u.token.substring(0, 20) + "..." : "undefined",
|
|
5620
5615
|
faceId: r,
|
|
5621
5616
|
source: "licenseStore模块"
|
|
5622
|
-
}), u.token ? (
|
|
5617
|
+
}), u.token ? (b0("📤 [workerManager] 发送 License 到新创建的 Worker", { faceId: r }), t.postMessage({
|
|
5623
5618
|
type: "SET_LICENSE",
|
|
5624
5619
|
licenseToken: u.token,
|
|
5625
5620
|
licenseApiUrl: u.apiUrl,
|
|
@@ -5627,7 +5622,7 @@ function yx(r) {
|
|
|
5627
5622
|
domain: u.domain
|
|
5628
5623
|
}), !0) : !1;
|
|
5629
5624
|
};
|
|
5630
|
-
return e() || (
|
|
5625
|
+
return e() || (b0("⏳ [workerManager] License Token 未设置,等待后重试...", { faceId: r }), setTimeout(() => {
|
|
5631
5626
|
e() || Ee("⚠️ [workerManager] 等待后 License Token 仍未设置", { faceId: r });
|
|
5632
5627
|
}, 200), setTimeout(() => {
|
|
5633
5628
|
e() || Ee("⚠️ [workerManager] 第二次等待后 License Token 仍未设置", { faceId: r });
|
|
@@ -5639,10 +5634,10 @@ function wx(r) {
|
|
|
5639
5634
|
type: r.type,
|
|
5640
5635
|
blendMode: r.blendMode,
|
|
5641
5636
|
transform: Array.isArray(r.transform) ? [...r.transform] : [],
|
|
5642
|
-
meshPoints: Array.isArray(r.meshPoints) ? r.meshPoints.map((
|
|
5643
|
-
x:
|
|
5644
|
-
y:
|
|
5645
|
-
type:
|
|
5637
|
+
meshPoints: Array.isArray(r.meshPoints) ? r.meshPoints.map((h) => ({
|
|
5638
|
+
x: h.x,
|
|
5639
|
+
y: h.y,
|
|
5640
|
+
type: h.type
|
|
5646
5641
|
})) : [],
|
|
5647
5642
|
bounds: r.bounds ? {
|
|
5648
5643
|
width: r.bounds.width,
|
|
@@ -5665,30 +5660,30 @@ function wx(r) {
|
|
|
5665
5660
|
layerOrder: r.layerOrder,
|
|
5666
5661
|
imagePath: r.imagePath,
|
|
5667
5662
|
vectorMask: r.vectorMask ? {
|
|
5668
|
-
paths: r.vectorMask.paths?.map((
|
|
5669
|
-
open:
|
|
5670
|
-
knots:
|
|
5663
|
+
paths: r.vectorMask.paths?.map((h) => ({
|
|
5664
|
+
open: h.open,
|
|
5665
|
+
knots: h.knots?.map((t) => ({
|
|
5671
5666
|
linked: t.linked,
|
|
5672
5667
|
points: [...t.points]
|
|
5673
5668
|
})),
|
|
5674
|
-
fillRule:
|
|
5675
|
-
operation:
|
|
5669
|
+
fillRule: h.fillRule,
|
|
5670
|
+
operation: h.operation
|
|
5676
5671
|
})),
|
|
5677
|
-
points: r.vectorMask.points?.map((
|
|
5678
|
-
x:
|
|
5679
|
-
y:
|
|
5680
|
-
type:
|
|
5672
|
+
points: r.vectorMask.points?.map((h) => ({
|
|
5673
|
+
x: h.x,
|
|
5674
|
+
y: h.y,
|
|
5675
|
+
type: h.type
|
|
5681
5676
|
})),
|
|
5682
5677
|
invert: r.vectorMask.invert,
|
|
5683
5678
|
notLink: r.vectorMask.notLink,
|
|
5684
5679
|
disable: r.vectorMask.disable,
|
|
5685
5680
|
fillStartsWithAllPixels: r.vectorMask.fillStartsWithAllPixels
|
|
5686
5681
|
} : void 0,
|
|
5687
|
-
filterList: r.filterList ? r.filterList.map((
|
|
5688
|
-
type:
|
|
5689
|
-
enabled:
|
|
5690
|
-
filter:
|
|
5691
|
-
puppetShapeList:
|
|
5682
|
+
filterList: r.filterList ? r.filterList.map((h) => ({
|
|
5683
|
+
type: h.type,
|
|
5684
|
+
enabled: h.enabled,
|
|
5685
|
+
filter: h.filter ? {
|
|
5686
|
+
puppetShapeList: h.filter.puppetShapeList?.map((t) => ({
|
|
5692
5687
|
originalVertexArray: t.originalVertexArray.map((e) => ({
|
|
5693
5688
|
x: e.x,
|
|
5694
5689
|
y: e.y
|
|
@@ -5705,8 +5700,8 @@ function wx(r) {
|
|
|
5705
5700
|
clipping: r.clipping
|
|
5706
5701
|
};
|
|
5707
5702
|
}
|
|
5708
|
-
function kx(r,
|
|
5709
|
-
const u = ++_x,
|
|
5703
|
+
function kx(r, h, t, e) {
|
|
5704
|
+
const u = ++_x, v = yx(t);
|
|
5710
5705
|
return performance.now(), (/* @__PURE__ */ new Date()).toISOString(), new Promise((m, B) => {
|
|
5711
5706
|
pr.set(u, {
|
|
5712
5707
|
resolve: (x) => {
|
|
@@ -5714,24 +5709,24 @@ function kx(r, v, t, e) {
|
|
|
5714
5709
|
},
|
|
5715
5710
|
reject: B
|
|
5716
5711
|
});
|
|
5717
|
-
const C = wx(
|
|
5718
|
-
|
|
5712
|
+
const C = wx(h);
|
|
5713
|
+
v.postMessage({ id: u, designBitmap: r, layerData: C, canvasSize: e }, [
|
|
5719
5714
|
r
|
|
5720
5715
|
]);
|
|
5721
5716
|
});
|
|
5722
5717
|
}
|
|
5723
|
-
async function Sx(r,
|
|
5724
|
-
const m = await it(r, u,
|
|
5718
|
+
async function Sx(r, h, t = 0, e, u, v) {
|
|
5719
|
+
const m = await it(r, u, v);
|
|
5725
5720
|
if (!m || m.width === 0 || m.height === 0)
|
|
5726
5721
|
throw new Error("图片无效:尺寸为 0");
|
|
5727
|
-
return await kx(m,
|
|
5722
|
+
return await kx(m, h, t, e);
|
|
5728
5723
|
}
|
|
5729
|
-
function d0(r,
|
|
5724
|
+
function d0(r, h) {
|
|
5730
5725
|
if (typeof OffscreenCanvas < "u" && typeof document > "u")
|
|
5731
|
-
return new OffscreenCanvas(r,
|
|
5726
|
+
return new OffscreenCanvas(r, h);
|
|
5732
5727
|
if (typeof document < "u") {
|
|
5733
5728
|
const t = document.createElement("canvas");
|
|
5734
|
-
return t.width = r, t.height =
|
|
5729
|
+
return t.width = r, t.height = h, t;
|
|
5735
5730
|
} else
|
|
5736
5731
|
throw new Error("无法创建 canvas:不在 Worker 或主线程环境中");
|
|
5737
5732
|
}
|
|
@@ -5739,13 +5734,13 @@ function A0(r) {
|
|
|
5739
5734
|
return r.getContext("2d");
|
|
5740
5735
|
}
|
|
5741
5736
|
function Fe(r) {
|
|
5742
|
-
const
|
|
5743
|
-
if (!
|
|
5737
|
+
const h = A0(r);
|
|
5738
|
+
if (!h)
|
|
5744
5739
|
throw new Error("无法创建 canvas context");
|
|
5745
|
-
return
|
|
5740
|
+
return h;
|
|
5746
5741
|
}
|
|
5747
5742
|
async function Hx(r) {
|
|
5748
|
-
const
|
|
5743
|
+
const h = performance.now(), t = () => {
|
|
5749
5744
|
try {
|
|
5750
5745
|
if (globalThis.__DEBUG_RENDER__ === !0 || typeof localStorage < "u" && localStorage.getItem("DEBUG_RENDER") === "1") return !0;
|
|
5751
5746
|
} catch {
|
|
@@ -5756,7 +5751,7 @@ async function Hx(r) {
|
|
|
5756
5751
|
}, u = (...c) => {
|
|
5757
5752
|
t();
|
|
5758
5753
|
}, {
|
|
5759
|
-
psdJson:
|
|
5754
|
+
psdJson: v,
|
|
5760
5755
|
materialList: m,
|
|
5761
5756
|
fabricScreenshotList: B,
|
|
5762
5757
|
width: C,
|
|
@@ -5764,8 +5759,8 @@ async function Hx(r) {
|
|
|
5764
5759
|
baseUrl: n
|
|
5765
5760
|
} = r, E = r.maxImageSize;
|
|
5766
5761
|
e("[renderByJson] 接收到的数据:", {
|
|
5767
|
-
psdJsonLayerCount:
|
|
5768
|
-
psdJsonLayers:
|
|
5762
|
+
psdJsonLayerCount: v.layerList?.length || 0,
|
|
5763
|
+
psdJsonLayers: v.layerList?.map((c) => ({
|
|
5769
5764
|
name: c.name,
|
|
5770
5765
|
type: c.type,
|
|
5771
5766
|
id: c.id,
|
|
@@ -5806,7 +5801,7 @@ async function Hx(r) {
|
|
|
5806
5801
|
const p = /* @__PURE__ */ new Map();
|
|
5807
5802
|
for (const c of B)
|
|
5808
5803
|
p.set(c.id, c.url);
|
|
5809
|
-
e("[renderByJson] fabricScreenshotMap:", Array.from(p.entries())), e("[renderByJson] psdJson.layerList 结构:",
|
|
5804
|
+
e("[renderByJson] fabricScreenshotMap:", Array.from(p.entries())), e("[renderByJson] psdJson.layerList 结构:", v.layerList?.map((c) => ({
|
|
5810
5805
|
name: c.name,
|
|
5811
5806
|
type: c.type,
|
|
5812
5807
|
id: c.id,
|
|
@@ -5850,7 +5845,7 @@ async function Hx(r) {
|
|
|
5850
5845
|
for (const W of c.children)
|
|
5851
5846
|
W && l(W, _);
|
|
5852
5847
|
}
|
|
5853
|
-
function
|
|
5848
|
+
function g(c, A) {
|
|
5854
5849
|
const _ = c.id ?? A;
|
|
5855
5850
|
if (c.type === "Group" && _)
|
|
5856
5851
|
if (e(`[renderByJson] processLayer 检查 Group: name="${c.name}", id=${_}, hasFabricScreenshot=${p.has(_)}`), p.has(_)) {
|
|
@@ -5868,16 +5863,16 @@ async function Hx(r) {
|
|
|
5868
5863
|
e(`[renderByJson] ⚠️ Group id=${_}, name="${c.name}" 没有匹配的 fabricScreenshot`);
|
|
5869
5864
|
if (c.children)
|
|
5870
5865
|
for (const W of c.children)
|
|
5871
|
-
W &&
|
|
5866
|
+
W && g(W, _);
|
|
5872
5867
|
}
|
|
5873
|
-
if (
|
|
5874
|
-
for (const c of
|
|
5868
|
+
if (v.layerList)
|
|
5869
|
+
for (const c of v.layerList)
|
|
5875
5870
|
c && l(c);
|
|
5876
|
-
if (
|
|
5877
|
-
for (const c of
|
|
5878
|
-
c &&
|
|
5871
|
+
if (v.layerList)
|
|
5872
|
+
for (const c of v.layerList)
|
|
5873
|
+
c && g(c);
|
|
5879
5874
|
const o = Ye([{
|
|
5880
|
-
psdJson:
|
|
5875
|
+
psdJson: v,
|
|
5881
5876
|
layerExtrasByName: s
|
|
5882
5877
|
}], {
|
|
5883
5878
|
parts: [],
|
|
@@ -5888,7 +5883,7 @@ async function Hx(r) {
|
|
|
5888
5883
|
const d = o.models[0];
|
|
5889
5884
|
if (!d.psdPartData)
|
|
5890
5885
|
throw new Error("JSON 数据中没有 psdPartData");
|
|
5891
|
-
const b = d.width,
|
|
5886
|
+
const b = d.width, D = d.height, y = d0(b, D), k = Fe(y), R = [], F = (c) => {
|
|
5892
5887
|
if (c.url && s[c.url])
|
|
5893
5888
|
return s[c.url];
|
|
5894
5889
|
if (c.url) {
|
|
@@ -5936,8 +5931,8 @@ async function Hx(r) {
|
|
|
5936
5931
|
const K = P.imagePath.split("/").pop() || P.imagePath;
|
|
5937
5932
|
if (L = s[K], !L) {
|
|
5938
5933
|
const G = m.find((Y) => {
|
|
5939
|
-
const
|
|
5940
|
-
return !
|
|
5934
|
+
const r0 = Y.sourceName || Y.layerName;
|
|
5935
|
+
return !r0 || !P.imagePath ? !1 : (r0.split("/").pop() || r0) === K || r0 === P.imagePath || r0.endsWith(P.imagePath) || P.imagePath.endsWith(r0);
|
|
5941
5936
|
});
|
|
5942
5937
|
G && (L = { url: G.url });
|
|
5943
5938
|
}
|
|
@@ -5954,7 +5949,7 @@ async function Hx(r) {
|
|
|
5954
5949
|
continue;
|
|
5955
5950
|
I = G;
|
|
5956
5951
|
}
|
|
5957
|
-
const Z = (A.partId ?? A.id) * 100 + W, Q = Qe(Ze(P)), o0 = { width: b, height:
|
|
5952
|
+
const Z = (A.partId ?? A.id) * 100 + W, Q = Qe(Ze(P)), o0 = { width: b, height: D };
|
|
5958
5953
|
R.push({
|
|
5959
5954
|
index: c + W * 0.01,
|
|
5960
5955
|
type: "group",
|
|
@@ -5980,7 +5975,7 @@ async function Hx(r) {
|
|
|
5980
5975
|
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;
|
|
5981
5976
|
return _ - W;
|
|
5982
5977
|
});
|
|
5983
|
-
let $ = d0(b,
|
|
5978
|
+
let $ = d0(b, D), z = A0($), O = !1, q = "normal";
|
|
5984
5979
|
for (let c = 0; c < H.length; c++) {
|
|
5985
5980
|
const { task: A, imageBitmap: _ } = H[c];
|
|
5986
5981
|
if (!_) {
|
|
@@ -6009,9 +6004,9 @@ async function Hx(r) {
|
|
|
6009
6004
|
clipping: I
|
|
6010
6005
|
}), !I && Q) {
|
|
6011
6006
|
if (O = !0, q = W.blendMode || "normal", z) {
|
|
6012
|
-
if (z.clearRect(0, 0, b,
|
|
6007
|
+
if (z.clearRect(0, 0, b, D), z.globalCompositeOperation = "source-over", z.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6013
6008
|
if (A.maskData) {
|
|
6014
|
-
const K = d0(b,
|
|
6009
|
+
const K = d0(b, D), G = A0(K);
|
|
6015
6010
|
G && (G.drawImage(_, 0, 0), lr(G, A.maskData), z.drawImage(K, 0, 0));
|
|
6016
6011
|
} else
|
|
6017
6012
|
z.drawImage(_, 0, 0);
|
|
@@ -6028,7 +6023,7 @@ async function Hx(r) {
|
|
|
6028
6023
|
if (z) {
|
|
6029
6024
|
if (z.globalCompositeOperation = "source-atop", z.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6030
6025
|
if (A.maskData) {
|
|
6031
|
-
const K = d0(b,
|
|
6026
|
+
const K = d0(b, D), G = A0(K);
|
|
6032
6027
|
G && (G.drawImage(_, 0, 0), lr(G, A.maskData), z.drawImage(K, 0, 0));
|
|
6033
6028
|
} else
|
|
6034
6029
|
z.drawImage(_, 0, 0);
|
|
@@ -6044,7 +6039,7 @@ async function Hx(r) {
|
|
|
6044
6039
|
} else {
|
|
6045
6040
|
if (k.globalCompositeOperation = Wr(W.blendMode), k.globalAlpha = L, A.type === "group" && A.smartObject)
|
|
6046
6041
|
if (A.maskData) {
|
|
6047
|
-
const K = d0(b,
|
|
6042
|
+
const K = d0(b, D), G = A0(K);
|
|
6048
6043
|
G && (G.drawImage(_, 0, 0), lr(G, A.maskData), k.drawImage(K, 0, 0));
|
|
6049
6044
|
} else
|
|
6050
6045
|
k.drawImage(_, 0, 0);
|
|
@@ -6060,22 +6055,22 @@ async function Hx(r) {
|
|
|
6060
6055
|
O && !Q && (k.globalCompositeOperation = Wr(q), k.drawImage($, 0, 0), k.globalCompositeOperation = "source-over", O = !1);
|
|
6061
6056
|
}
|
|
6062
6057
|
$ = null, z = null;
|
|
6063
|
-
let U = y, T = b, N =
|
|
6058
|
+
let U = y, T = b, N = D;
|
|
6064
6059
|
if (C !== void 0 || x !== void 0) {
|
|
6065
6060
|
if (C !== void 0 && x !== void 0)
|
|
6066
6061
|
T = C, N = x;
|
|
6067
6062
|
else if (C !== void 0) {
|
|
6068
6063
|
const A = C / b;
|
|
6069
|
-
T = C, N = Math.round(
|
|
6064
|
+
T = C, N = Math.round(D * A);
|
|
6070
6065
|
} else if (x !== void 0) {
|
|
6071
|
-
const A = x /
|
|
6066
|
+
const A = x / D;
|
|
6072
6067
|
T = Math.round(b * A), N = x;
|
|
6073
6068
|
}
|
|
6074
6069
|
U = d0(T, N);
|
|
6075
6070
|
const c = Fe(U);
|
|
6076
|
-
c.imageSmoothingEnabled = !0, c.imageSmoothingQuality = "high", c.drawImage(y, 0, 0, b,
|
|
6071
|
+
c.imageSmoothingEnabled = !0, c.imageSmoothingQuality = "high", c.drawImage(y, 0, 0, b, D, 0, 0, T, N), e(`[renderByJson] 已缩放结果: ${b}x${D} -> ${T}x${N}`);
|
|
6077
6072
|
}
|
|
6078
|
-
const S = performance.now() -
|
|
6073
|
+
const S = performance.now() - h;
|
|
6079
6074
|
return e(`[renderByJson] 绘制完成,总渲染时间: ${Math.round(S)}ms`), {
|
|
6080
6075
|
canvas: U,
|
|
6081
6076
|
width: T,
|
|
@@ -6087,10 +6082,10 @@ const $x = async (r) => {
|
|
|
6087
6082
|
return t ? createImageBitmap(t) : null;
|
|
6088
6083
|
};
|
|
6089
6084
|
self.onmessage = async (r) => {
|
|
6090
|
-
const
|
|
6091
|
-
if (
|
|
6092
|
-
const e =
|
|
6093
|
-
|
|
6085
|
+
const h = r.data;
|
|
6086
|
+
if (h && typeof h == "object" && "type" in h && h.type === "SET_LICENSE") {
|
|
6087
|
+
const e = h;
|
|
6088
|
+
Dx({
|
|
6094
6089
|
token: e.licenseToken,
|
|
6095
6090
|
apiUrl: e.licenseApiUrl,
|
|
6096
6091
|
deviceId: e.deviceId,
|
|
@@ -6098,7 +6093,7 @@ self.onmessage = async (r) => {
|
|
|
6098
6093
|
});
|
|
6099
6094
|
return;
|
|
6100
6095
|
}
|
|
6101
|
-
const t =
|
|
6096
|
+
const t = h;
|
|
6102
6097
|
try {
|
|
6103
6098
|
const e = await $x(t.renderData);
|
|
6104
6099
|
self.postMessage({ id: t.id, bitmap: e }, e ? [e] : []);
|