| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266 |
- "use strict";
- var CryptoJS = CryptoJS || function(u, l) {
- var d = {}, n = d.lib = {}, p = function() {
- }, s = n.Base = {
- extend: function(a) {
- p.prototype = this;
- var c = new p();
- a && c.mixIn(a);
- c.hasOwnProperty("init") || (c.init = function() {
- c.$super.init.apply(this, arguments);
- });
- c.init.prototype = c;
- c.$super = this;
- return c;
- },
- create: function() {
- var a = this.extend();
- a.init.apply(a, arguments);
- return a;
- },
- init: function() {
- },
- mixIn: function(a) {
- for (var c in a)
- a.hasOwnProperty(c) && (this[c] = a[c]);
- a.hasOwnProperty("toString") && (this.toString = a.toString);
- },
- clone: function() {
- return this.init.prototype.extend(this);
- }
- }, q = n.WordArray = s.extend({
- init: function(a, c) {
- a = this.words = a || [];
- this.sigBytes = c != l ? c : 4 * a.length;
- },
- toString: function(a) {
- return (a || v).stringify(this);
- },
- concat: function(a) {
- var c = this.words, m = a.words, f = this.sigBytes;
- a = a.sigBytes;
- this.clamp();
- if (f % 4)
- for (var t = 0; t < a; t++)
- c[f + t >>> 2] |= (m[t >>> 2] >>> 24 - 8 * (t % 4) & 255) << 24 - 8 * ((f + t) % 4);
- else if (65535 < m.length)
- for (t = 0; t < a; t += 4)
- c[f + t >>> 2] = m[t >>> 2];
- else
- c.push.apply(c, m);
- this.sigBytes += a;
- return this;
- },
- clamp: function() {
- var a = this.words, c = this.sigBytes;
- a[c >>> 2] &= 4294967295 << 32 - 8 * (c % 4);
- a.length = u.ceil(c / 4);
- },
- clone: function() {
- var a = s.clone.call(this);
- a.words = this.words.slice(0);
- return a;
- },
- random: function(a) {
- for (var c = [], m = 0; m < a; m += 4)
- c.push(4294967296 * u.random() | 0);
- return new q.init(c, a);
- }
- }), w = d.enc = {}, v = w.Hex = {
- stringify: function(a) {
- var c = a.words;
- a = a.sigBytes;
- for (var m = [], f = 0; f < a; f++) {
- var t = c[f >>> 2] >>> 24 - 8 * (f % 4) & 255;
- m.push((t >>> 4).toString(16));
- m.push((t & 15).toString(16));
- }
- return m.join("");
- },
- parse: function(a) {
- for (var c = a.length, m = [], f = 0; f < c; f += 2)
- m[f >>> 3] |= parseInt(a.substr(
- f,
- 2
- ), 16) << 24 - 4 * (f % 8);
- return new q.init(m, c / 2);
- }
- }, b = w.Latin1 = {
- stringify: function(a) {
- var c = a.words;
- a = a.sigBytes;
- for (var m = [], f = 0; f < a; f++)
- m.push(String.fromCharCode(c[f >>> 2] >>> 24 - 8 * (f % 4) & 255));
- return m.join("");
- },
- parse: function(a) {
- for (var c = a.length, m = [], f = 0; f < c; f++)
- m[f >>> 2] |= (a.charCodeAt(f) & 255) << 24 - 8 * (f % 4);
- return new q.init(m, c);
- }
- }, x = w.Utf8 = {
- stringify: function(a) {
- try {
- return decodeURIComponent(escape(b.stringify(a)));
- } catch (c) {
- throw Error("Malformed UTF-8 data");
- }
- },
- parse: function(a) {
- return b.parse(unescape(encodeURIComponent(a)));
- }
- }, r = n.BufferedBlockAlgorithm = s.extend({
- reset: function() {
- this._data = new q.init();
- this._nDataBytes = 0;
- },
- _append: function(a) {
- "string" == typeof a && (a = x.parse(a));
- this._data.concat(a);
- this._nDataBytes += a.sigBytes;
- },
- _process: function(a) {
- var c = this._data, m = c.words, f = c.sigBytes, t = this.blockSize, b2 = f / (4 * t), b2 = a ? u.ceil(b2) : u.max((b2 | 0) - this._minBufferSize, 0);
- a = b2 * t;
- f = u.min(4 * a, f);
- if (a) {
- for (var e2 = 0; e2 < a; e2 += t)
- this._doProcessBlock(m, e2);
- e2 = m.splice(0, a);
- c.sigBytes -= f;
- }
- return new q.init(e2, f);
- },
- clone: function() {
- var a = s.clone.call(this);
- a._data = this._data.clone();
- return a;
- },
- _minBufferSize: 0
- });
- n.Hasher = r.extend({
- cfg: s.extend(),
- init: function(a) {
- this.cfg = this.cfg.extend(a);
- this.reset();
- },
- reset: function() {
- r.reset.call(this);
- this._doReset();
- },
- update: function(a) {
- this._append(a);
- this._process();
- return this;
- },
- finalize: function(a) {
- a && this._append(a);
- return this._doFinalize();
- },
- blockSize: 16,
- _createHelper: function(a) {
- return function(c, m) {
- return new a.init(m).finalize(c);
- };
- },
- _createHmacHelper: function(a) {
- return function(c, m) {
- return new e.HMAC.init(
- a,
- m
- ).finalize(c);
- };
- }
- });
- var e = d.algo = {};
- return d;
- }(Math);
- (function() {
- var u = CryptoJS, l = u.lib.WordArray;
- u.enc.Base64 = {
- stringify: function(d) {
- var n = d.words, l2 = d.sigBytes, s = this._map;
- d.clamp();
- d = [];
- for (var q = 0; q < l2; q += 3)
- for (var w = (n[q >>> 2] >>> 24 - 8 * (q % 4) & 255) << 16 | (n[q + 1 >>> 2] >>> 24 - 8 * ((q + 1) % 4) & 255) << 8 | n[q + 2 >>> 2] >>> 24 - 8 * ((q + 2) % 4) & 255, v = 0; 4 > v && q + 0.75 * v < l2; v++)
- d.push(s.charAt(w >>> 6 * (3 - v) & 63));
- if (n = s.charAt(64))
- for (; d.length % 4; )
- d.push(n);
- return d.join("");
- },
- parse: function(d) {
- var n = d.length, p = this._map, s = p.charAt(64);
- s && (s = d.indexOf(s), -1 != s && (n = s));
- for (var s = [], q = 0, w = 0; w < n; w++)
- if (w % 4) {
- var v = p.indexOf(d.charAt(w - 1)) << 2 * (w % 4), b = p.indexOf(d.charAt(w)) >>> 6 - 2 * (w % 4);
- s[q >>> 2] |= (v | b) << 24 - 8 * (q % 4);
- q++;
- }
- return l.create(s, q);
- },
- _map: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="
- };
- })();
- (function(u) {
- function l(b2, e, a, c, m, f, t) {
- b2 = b2 + (e & a | ~e & c) + m + t;
- return (b2 << f | b2 >>> 32 - f) + e;
- }
- function d(b2, e, a, c, m, f, t) {
- b2 = b2 + (e & c | a & ~c) + m + t;
- return (b2 << f | b2 >>> 32 - f) + e;
- }
- function n(b2, e, a, c, m, f, t) {
- b2 = b2 + (e ^ a ^ c) + m + t;
- return (b2 << f | b2 >>> 32 - f) + e;
- }
- function p(b2, e, a, c, m, f, t) {
- b2 = b2 + (a ^ (e | ~c)) + m + t;
- return (b2 << f | b2 >>> 32 - f) + e;
- }
- for (var s = CryptoJS, q = s.lib, w = q.WordArray, v = q.Hasher, q = s.algo, b = [], x = 0; 64 > x; x++)
- b[x] = 4294967296 * u.abs(u.sin(x + 1)) | 0;
- q = q.MD5 = v.extend({
- _doReset: function() {
- this._hash = new w.init([1732584193, 4023233417, 2562383102, 271733878]);
- },
- _doProcessBlock: function(r, e) {
- for (var a = 0; 16 > a; a++) {
- var c = e + a, m = r[c];
- r[c] = (m << 8 | m >>> 24) & 16711935 | (m << 24 | m >>> 8) & 4278255360;
- }
- var a = this._hash.words, c = r[e + 0], m = r[e + 1], f = r[e + 2], t = r[e + 3], y = r[e + 4], q2 = r[e + 5], s2 = r[e + 6], w2 = r[e + 7], v2 = r[e + 8], u2 = r[e + 9], x2 = r[e + 10], z = r[e + 11], A = r[e + 12], B = r[e + 13], C = r[e + 14], D = r[e + 15], g = a[0], h = a[1], j = a[2], k = a[3], g = l(g, h, j, k, c, 7, b[0]), k = l(k, g, h, j, m, 12, b[1]), j = l(j, k, g, h, f, 17, b[2]), h = l(h, j, k, g, t, 22, b[3]), g = l(g, h, j, k, y, 7, b[4]), k = l(k, g, h, j, q2, 12, b[5]), j = l(j, k, g, h, s2, 17, b[6]), h = l(h, j, k, g, w2, 22, b[7]), g = l(g, h, j, k, v2, 7, b[8]), k = l(k, g, h, j, u2, 12, b[9]), j = l(j, k, g, h, x2, 17, b[10]), h = l(h, j, k, g, z, 22, b[11]), g = l(g, h, j, k, A, 7, b[12]), k = l(k, g, h, j, B, 12, b[13]), j = l(j, k, g, h, C, 17, b[14]), h = l(h, j, k, g, D, 22, b[15]), g = d(g, h, j, k, m, 5, b[16]), k = d(k, g, h, j, s2, 9, b[17]), j = d(j, k, g, h, z, 14, b[18]), h = d(h, j, k, g, c, 20, b[19]), g = d(g, h, j, k, q2, 5, b[20]), k = d(k, g, h, j, x2, 9, b[21]), j = d(j, k, g, h, D, 14, b[22]), h = d(h, j, k, g, y, 20, b[23]), g = d(g, h, j, k, u2, 5, b[24]), k = d(k, g, h, j, C, 9, b[25]), j = d(j, k, g, h, t, 14, b[26]), h = d(h, j, k, g, v2, 20, b[27]), g = d(g, h, j, k, B, 5, b[28]), k = d(
- k,
- g,
- h,
- j,
- f,
- 9,
- b[29]
- ), j = d(j, k, g, h, w2, 14, b[30]), h = d(h, j, k, g, A, 20, b[31]), g = n(g, h, j, k, q2, 4, b[32]), k = n(k, g, h, j, v2, 11, b[33]), j = n(j, k, g, h, z, 16, b[34]), h = n(h, j, k, g, C, 23, b[35]), g = n(g, h, j, k, m, 4, b[36]), k = n(k, g, h, j, y, 11, b[37]), j = n(j, k, g, h, w2, 16, b[38]), h = n(h, j, k, g, x2, 23, b[39]), g = n(g, h, j, k, B, 4, b[40]), k = n(k, g, h, j, c, 11, b[41]), j = n(j, k, g, h, t, 16, b[42]), h = n(h, j, k, g, s2, 23, b[43]), g = n(g, h, j, k, u2, 4, b[44]), k = n(k, g, h, j, A, 11, b[45]), j = n(j, k, g, h, D, 16, b[46]), h = n(h, j, k, g, f, 23, b[47]), g = p(g, h, j, k, c, 6, b[48]), k = p(k, g, h, j, w2, 10, b[49]), j = p(
- j,
- k,
- g,
- h,
- C,
- 15,
- b[50]
- ), h = p(h, j, k, g, q2, 21, b[51]), g = p(g, h, j, k, A, 6, b[52]), k = p(k, g, h, j, t, 10, b[53]), j = p(j, k, g, h, x2, 15, b[54]), h = p(h, j, k, g, m, 21, b[55]), g = p(g, h, j, k, v2, 6, b[56]), k = p(k, g, h, j, D, 10, b[57]), j = p(j, k, g, h, s2, 15, b[58]), h = p(h, j, k, g, B, 21, b[59]), g = p(g, h, j, k, y, 6, b[60]), k = p(k, g, h, j, z, 10, b[61]), j = p(j, k, g, h, f, 15, b[62]), h = p(h, j, k, g, u2, 21, b[63]);
- a[0] = a[0] + g | 0;
- a[1] = a[1] + h | 0;
- a[2] = a[2] + j | 0;
- a[3] = a[3] + k | 0;
- },
- _doFinalize: function() {
- var b2 = this._data, e = b2.words, a = 8 * this._nDataBytes, c = 8 * b2.sigBytes;
- e[c >>> 5] |= 128 << 24 - c % 32;
- var m = u.floor(a / 4294967296);
- e[(c + 64 >>> 9 << 4) + 15] = (m << 8 | m >>> 24) & 16711935 | (m << 24 | m >>> 8) & 4278255360;
- e[(c + 64 >>> 9 << 4) + 14] = (a << 8 | a >>> 24) & 16711935 | (a << 24 | a >>> 8) & 4278255360;
- b2.sigBytes = 4 * (e.length + 1);
- this._process();
- b2 = this._hash;
- e = b2.words;
- for (a = 0; 4 > a; a++)
- c = e[a], e[a] = (c << 8 | c >>> 24) & 16711935 | (c << 24 | c >>> 8) & 4278255360;
- return b2;
- },
- clone: function() {
- var b2 = v.clone.call(this);
- b2._hash = this._hash.clone();
- return b2;
- }
- });
- s.MD5 = v._createHelper(q);
- s.HmacMD5 = v._createHmacHelper(q);
- })(Math);
- (function() {
- var u = CryptoJS, l = u.lib, d = l.Base, n = l.WordArray, l = u.algo, p = l.EvpKDF = d.extend({
- cfg: d.extend({
- keySize: 4,
- hasher: l.MD5,
- iterations: 1
- }),
- init: function(d2) {
- this.cfg = this.cfg.extend(d2);
- },
- compute: function(d2, l2) {
- for (var p2 = this.cfg, v = p2.hasher.create(), b = n.create(), u2 = b.words, r = p2.keySize, p2 = p2.iterations; u2.length < r; ) {
- e && v.update(e);
- var e = v.update(d2).finalize(l2);
- v.reset();
- for (var a = 1; a < p2; a++)
- e = v.finalize(e), v.reset();
- b.concat(e);
- }
- b.sigBytes = 4 * r;
- return b;
- }
- });
- u.EvpKDF = function(d2, l2, n2) {
- return p.create(n2).compute(
- d2,
- l2
- );
- };
- })();
- CryptoJS.lib.Cipher || function(u) {
- var l = CryptoJS, d = l.lib, n = d.Base, p = d.WordArray, s = d.BufferedBlockAlgorithm, q = l.enc.Base64, w = l.algo.EvpKDF, v = d.Cipher = s.extend({
- cfg: n.extend(),
- createEncryptor: function(m, a2) {
- return this.create(this._ENC_XFORM_MODE, m, a2);
- },
- createDecryptor: function(m, a2) {
- return this.create(this._DEC_XFORM_MODE, m, a2);
- },
- init: function(m, a2, b2) {
- this.cfg = this.cfg.extend(b2);
- this._xformMode = m;
- this._key = a2;
- this.reset();
- },
- reset: function() {
- s.reset.call(this);
- this._doReset();
- },
- process: function(a2) {
- this._append(a2);
- return this._process();
- },
- finalize: function(a2) {
- a2 && this._append(a2);
- return this._doFinalize();
- },
- keySize: 4,
- ivSize: 4,
- _ENC_XFORM_MODE: 1,
- _DEC_XFORM_MODE: 2,
- _createHelper: function(m) {
- return {
- encrypt: function(f, b2, e2) {
- return ("string" == typeof b2 ? c : a).encrypt(m, f, b2, e2);
- },
- decrypt: function(f, b2, e2) {
- return ("string" == typeof b2 ? c : a).decrypt(m, f, b2, e2);
- }
- };
- }
- });
- d.StreamCipher = v.extend({
- _doFinalize: function() {
- return this._process(true);
- },
- blockSize: 1
- });
- var b = l.mode = {}, x = function(a2, f, b2) {
- var c2 = this._iv;
- c2 ? this._iv = u : c2 = this._prevBlock;
- for (var e2 = 0; e2 < b2; e2++)
- a2[f + e2] ^= c2[e2];
- }, r = (d.BlockCipherMode = n.extend({
- createEncryptor: function(a2, f) {
- return this.Encryptor.create(a2, f);
- },
- createDecryptor: function(a2, f) {
- return this.Decryptor.create(a2, f);
- },
- init: function(a2, f) {
- this._cipher = a2;
- this._iv = f;
- }
- })).extend();
- r.Encryptor = r.extend({
- processBlock: function(a2, f) {
- var b2 = this._cipher, c2 = b2.blockSize;
- x.call(this, a2, f, c2);
- b2.encryptBlock(a2, f);
- this._prevBlock = a2.slice(f, f + c2);
- }
- });
- r.Decryptor = r.extend({
- processBlock: function(a2, b2) {
- var c2 = this._cipher, e2 = c2.blockSize, d2 = a2.slice(b2, b2 + e2);
- c2.decryptBlock(a2, b2);
- x.call(
- this,
- a2,
- b2,
- e2
- );
- this._prevBlock = d2;
- }
- });
- b = b.CBC = r;
- r = (l.pad = {}).Pkcs7 = {
- pad: function(a2, b2) {
- for (var c2 = 4 * b2, c2 = c2 - a2.sigBytes % c2, e2 = c2 << 24 | c2 << 16 | c2 << 8 | c2, d2 = [], l2 = 0; l2 < c2; l2 += 4)
- d2.push(e2);
- c2 = p.create(d2, c2);
- a2.concat(c2);
- },
- unpad: function(a2) {
- a2.sigBytes -= a2.words[a2.sigBytes - 1 >>> 2] & 255;
- }
- };
- d.BlockCipher = v.extend({
- cfg: v.cfg.extend({
- mode: b,
- padding: r
- }),
- reset: function() {
- v.reset.call(this);
- var a2 = this.cfg, c2 = a2.iv, a2 = a2.mode;
- if (this._xformMode == this._ENC_XFORM_MODE)
- var b2 = a2.createEncryptor;
- else
- b2 = a2.createDecryptor, this._minBufferSize = 1;
- this._mode = b2.call(
- a2,
- this,
- c2 && c2.words
- );
- },
- _doProcessBlock: function(a2, c2) {
- this._mode.processBlock(a2, c2);
- },
- _doFinalize: function() {
- var a2 = this.cfg.padding;
- if (this._xformMode == this._ENC_XFORM_MODE) {
- a2.pad(this._data, this.blockSize);
- var c2 = this._process(true);
- } else
- c2 = this._process(true), a2.unpad(c2);
- return c2;
- },
- blockSize: 4
- });
- var e = d.CipherParams = n.extend({
- init: function(a2) {
- this.mixIn(a2);
- },
- toString: function(a2) {
- return (a2 || this.formatter).stringify(this);
- }
- }), b = (l.format = {}).OpenSSL = {
- stringify: function(a2) {
- var c2 = a2.ciphertext;
- a2 = a2.salt;
- return (a2 ? p.create([
- 1398893684,
- 1701076831
- ]).concat(a2).concat(c2) : c2).toString(q);
- },
- parse: function(a2) {
- a2 = q.parse(a2);
- var c2 = a2.words;
- if (1398893684 == c2[0] && 1701076831 == c2[1]) {
- var b2 = p.create(c2.slice(2, 4));
- c2.splice(0, 4);
- a2.sigBytes -= 16;
- }
- return e.create({
- ciphertext: a2,
- salt: b2
- });
- }
- }, a = d.SerializableCipher = n.extend({
- cfg: n.extend({
- format: b
- }),
- encrypt: function(a2, c2, b2, d2) {
- d2 = this.cfg.extend(d2);
- var l2 = a2.createEncryptor(b2, d2);
- c2 = l2.finalize(c2);
- l2 = l2.cfg;
- return e.create({
- ciphertext: c2,
- key: b2,
- iv: l2.iv,
- algorithm: a2,
- mode: l2.mode,
- padding: l2.padding,
- blockSize: a2.blockSize,
- formatter: d2.format
- });
- },
- decrypt: function(a2, c2, b2, e2) {
- e2 = this.cfg.extend(e2);
- c2 = this._parse(c2, e2.format);
- return a2.createDecryptor(b2, e2).finalize(c2.ciphertext);
- },
- _parse: function(a2, c2) {
- return "string" == typeof a2 ? c2.parse(a2, this) : a2;
- }
- }), l = (l.kdf = {}).OpenSSL = {
- execute: function(a2, c2, b2, d2) {
- d2 || (d2 = p.random(8));
- a2 = w.create({
- keySize: c2 + b2
- }).compute(a2, d2);
- b2 = p.create(a2.words.slice(c2), 4 * b2);
- a2.sigBytes = 4 * c2;
- return e.create({
- key: a2,
- iv: b2,
- salt: d2
- });
- }
- }, c = d.PasswordBasedCipher = a.extend({
- cfg: a.cfg.extend({
- kdf: l
- }),
- encrypt: function(c2, b2, e2, d2) {
- d2 = this.cfg.extend(d2);
- e2 = d2.kdf.execute(
- e2,
- c2.keySize,
- c2.ivSize
- );
- d2.iv = e2.iv;
- c2 = a.encrypt.call(this, c2, b2, e2.key, d2);
- c2.mixIn(e2);
- return c2;
- },
- decrypt: function(c2, b2, e2, d2) {
- d2 = this.cfg.extend(d2);
- b2 = this._parse(b2, d2.format);
- e2 = d2.kdf.execute(e2, c2.keySize, c2.ivSize, b2.salt);
- d2.iv = e2.iv;
- return a.decrypt.call(this, c2, b2, e2.key, d2);
- }
- });
- }();
- (function() {
- function u(b2, a) {
- var c = (this._lBlock >>> b2 ^ this._rBlock) & a;
- this._rBlock ^= c;
- this._lBlock ^= c << b2;
- }
- function l(b2, a) {
- var c = (this._rBlock >>> b2 ^ this._lBlock) & a;
- this._lBlock ^= c;
- this._rBlock ^= c << b2;
- }
- var d = CryptoJS, n = d.lib, p = n.WordArray, n = n.BlockCipher, s = d.algo, q = [
- 57,
- 49,
- 41,
- 33,
- 25,
- 17,
- 9,
- 1,
- 58,
- 50,
- 42,
- 34,
- 26,
- 18,
- 10,
- 2,
- 59,
- 51,
- 43,
- 35,
- 27,
- 19,
- 11,
- 3,
- 60,
- 52,
- 44,
- 36,
- 63,
- 55,
- 47,
- 39,
- 31,
- 23,
- 15,
- 7,
- 62,
- 54,
- 46,
- 38,
- 30,
- 22,
- 14,
- 6,
- 61,
- 53,
- 45,
- 37,
- 29,
- 21,
- 13,
- 5,
- 28,
- 20,
- 12,
- 4
- ], w = [
- 14,
- 17,
- 11,
- 24,
- 1,
- 5,
- 3,
- 28,
- 15,
- 6,
- 21,
- 10,
- 23,
- 19,
- 12,
- 4,
- 26,
- 8,
- 16,
- 7,
- 27,
- 20,
- 13,
- 2,
- 41,
- 52,
- 31,
- 37,
- 47,
- 55,
- 30,
- 40,
- 51,
- 45,
- 33,
- 48,
- 44,
- 49,
- 39,
- 56,
- 34,
- 53,
- 46,
- 42,
- 50,
- 36,
- 29,
- 32
- ], v = [1, 2, 4, 6, 8, 10, 12, 14, 15, 17, 19, 21, 23, 25, 27, 28], b = [{
- "0": 8421888,
- 268435456: 32768,
- 536870912: 8421378,
- 805306368: 2,
- 1073741824: 512,
- 1342177280: 8421890,
- 1610612736: 8389122,
- 1879048192: 8388608,
- 2147483648: 514,
- 2415919104: 8389120,
- 2684354560: 33280,
- 2952790016: 8421376,
- 3221225472: 32770,
- 3489660928: 8388610,
- 3758096384: 0,
- 4026531840: 33282,
- 134217728: 0,
- 402653184: 8421890,
- 671088640: 33282,
- 939524096: 32768,
- 1207959552: 8421888,
- 1476395008: 512,
- 1744830464: 8421378,
- 2013265920: 2,
- 2281701376: 8389120,
- 2550136832: 33280,
- 2818572288: 8421376,
- 3087007744: 8389122,
- 3355443200: 8388610,
- 3623878656: 32770,
- 3892314112: 514,
- 4160749568: 8388608,
- 1: 32768,
- 268435457: 2,
- 536870913: 8421888,
- 805306369: 8388608,
- 1073741825: 8421378,
- 1342177281: 33280,
- 1610612737: 512,
- 1879048193: 8389122,
- 2147483649: 8421890,
- 2415919105: 8421376,
- 2684354561: 8388610,
- 2952790017: 33282,
- 3221225473: 514,
- 3489660929: 8389120,
- 3758096385: 32770,
- 4026531841: 0,
- 134217729: 8421890,
- 402653185: 8421376,
- 671088641: 8388608,
- 939524097: 512,
- 1207959553: 32768,
- 1476395009: 8388610,
- 1744830465: 2,
- 2013265921: 33282,
- 2281701377: 32770,
- 2550136833: 8389122,
- 2818572289: 514,
- 3087007745: 8421888,
- 3355443201: 8389120,
- 3623878657: 0,
- 3892314113: 33280,
- 4160749569: 8421378
- }, {
- "0": 1074282512,
- 16777216: 16384,
- 33554432: 524288,
- 50331648: 1074266128,
- 67108864: 1073741840,
- 83886080: 1074282496,
- 100663296: 1073758208,
- 117440512: 16,
- 134217728: 540672,
- 150994944: 1073758224,
- 167772160: 1073741824,
- 184549376: 540688,
- 201326592: 524304,
- 218103808: 0,
- 234881024: 16400,
- 251658240: 1074266112,
- 8388608: 1073758208,
- 25165824: 540688,
- 41943040: 16,
- 58720256: 1073758224,
- 75497472: 1074282512,
- 92274688: 1073741824,
- 109051904: 524288,
- 125829120: 1074266128,
- 142606336: 524304,
- 159383552: 0,
- 176160768: 16384,
- 192937984: 1074266112,
- 209715200: 1073741840,
- 226492416: 540672,
- 243269632: 1074282496,
- 260046848: 16400,
- 268435456: 0,
- 285212672: 1074266128,
- 301989888: 1073758224,
- 318767104: 1074282496,
- 335544320: 1074266112,
- 352321536: 16,
- 369098752: 540688,
- 385875968: 16384,
- 402653184: 16400,
- 419430400: 524288,
- 436207616: 524304,
- 452984832: 1073741840,
- 469762048: 540672,
- 486539264: 1073758208,
- 503316480: 1073741824,
- 520093696: 1074282512,
- 276824064: 540688,
- 293601280: 524288,
- 310378496: 1074266112,
- 327155712: 16384,
- 343932928: 1073758208,
- 360710144: 1074282512,
- 377487360: 16,
- 394264576: 1073741824,
- 411041792: 1074282496,
- 427819008: 1073741840,
- 444596224: 1073758224,
- 461373440: 524304,
- 478150656: 0,
- 494927872: 16400,
- 511705088: 1074266128,
- 528482304: 540672
- }, {
- "0": 260,
- 1048576: 0,
- 2097152: 67109120,
- 3145728: 65796,
- 4194304: 65540,
- 5242880: 67108868,
- 6291456: 67174660,
- 7340032: 67174400,
- 8388608: 67108864,
- 9437184: 67174656,
- 10485760: 65792,
- 11534336: 67174404,
- 12582912: 67109124,
- 13631488: 65536,
- 14680064: 4,
- 15728640: 256,
- 524288: 67174656,
- 1572864: 67174404,
- 2621440: 0,
- 3670016: 67109120,
- 4718592: 67108868,
- 5767168: 65536,
- 6815744: 65540,
- 7864320: 260,
- 8912896: 4,
- 9961472: 256,
- 11010048: 67174400,
- 12058624: 65796,
- 13107200: 65792,
- 14155776: 67109124,
- 15204352: 67174660,
- 16252928: 67108864,
- 16777216: 67174656,
- 17825792: 65540,
- 18874368: 65536,
- 19922944: 67109120,
- 20971520: 256,
- 22020096: 67174660,
- 23068672: 67108868,
- 24117248: 0,
- 25165824: 67109124,
- 26214400: 67108864,
- 27262976: 4,
- 28311552: 65792,
- 29360128: 67174400,
- 30408704: 260,
- 31457280: 65796,
- 32505856: 67174404,
- 17301504: 67108864,
- 18350080: 260,
- 19398656: 67174656,
- 20447232: 0,
- 21495808: 65540,
- 22544384: 67109120,
- 23592960: 256,
- 24641536: 67174404,
- 25690112: 65536,
- 26738688: 67174660,
- 27787264: 65796,
- 28835840: 67108868,
- 29884416: 67109124,
- 30932992: 67174400,
- 31981568: 4,
- 33030144: 65792
- }, {
- "0": 2151682048,
- 65536: 2147487808,
- 131072: 4198464,
- 196608: 2151677952,
- 262144: 0,
- 327680: 4198400,
- 393216: 2147483712,
- 458752: 4194368,
- 524288: 2147483648,
- 589824: 4194304,
- 655360: 64,
- 720896: 2147487744,
- 786432: 2151678016,
- 851968: 4160,
- 917504: 4096,
- 983040: 2151682112,
- 32768: 2147487808,
- 98304: 64,
- 163840: 2151678016,
- 229376: 2147487744,
- 294912: 4198400,
- 360448: 2151682112,
- 425984: 0,
- 491520: 2151677952,
- 557056: 4096,
- 622592: 2151682048,
- 688128: 4194304,
- 753664: 4160,
- 819200: 2147483648,
- 884736: 4194368,
- 950272: 4198464,
- 1015808: 2147483712,
- 1048576: 4194368,
- 1114112: 4198400,
- 1179648: 2147483712,
- 1245184: 0,
- 1310720: 4160,
- 1376256: 2151678016,
- 1441792: 2151682048,
- 1507328: 2147487808,
- 1572864: 2151682112,
- 1638400: 2147483648,
- 1703936: 2151677952,
- 1769472: 4198464,
- 1835008: 2147487744,
- 1900544: 4194304,
- 1966080: 64,
- 2031616: 4096,
- 1081344: 2151677952,
- 1146880: 2151682112,
- 1212416: 0,
- 1277952: 4198400,
- 1343488: 4194368,
- 1409024: 2147483648,
- 1474560: 2147487808,
- 1540096: 64,
- 1605632: 2147483712,
- 1671168: 4096,
- 1736704: 2147487744,
- 1802240: 2151678016,
- 1867776: 4160,
- 1933312: 2151682048,
- 1998848: 4194304,
- 2064384: 4198464
- }, {
- "0": 128,
- 4096: 17039360,
- 8192: 262144,
- 12288: 536870912,
- 16384: 537133184,
- 20480: 16777344,
- 24576: 553648256,
- 28672: 262272,
- 32768: 16777216,
- 36864: 537133056,
- 40960: 536871040,
- 45056: 553910400,
- 49152: 553910272,
- 53248: 0,
- 57344: 17039488,
- 61440: 553648128,
- 2048: 17039488,
- 6144: 553648256,
- 10240: 128,
- 14336: 17039360,
- 18432: 262144,
- 22528: 537133184,
- 26624: 553910272,
- 30720: 536870912,
- 34816: 537133056,
- 38912: 0,
- 43008: 553910400,
- 47104: 16777344,
- 51200: 536871040,
- 55296: 553648128,
- 59392: 16777216,
- 63488: 262272,
- 65536: 262144,
- 69632: 128,
- 73728: 536870912,
- 77824: 553648256,
- 81920: 16777344,
- 86016: 553910272,
- 90112: 537133184,
- 94208: 16777216,
- 98304: 553910400,
- 102400: 553648128,
- 106496: 17039360,
- 110592: 537133056,
- 114688: 262272,
- 118784: 536871040,
- 122880: 0,
- 126976: 17039488,
- 67584: 553648256,
- 71680: 16777216,
- 75776: 17039360,
- 79872: 537133184,
- 83968: 536870912,
- 88064: 17039488,
- 92160: 128,
- 96256: 553910272,
- 100352: 262272,
- 104448: 553910400,
- 108544: 0,
- 112640: 553648128,
- 116736: 16777344,
- 120832: 262144,
- 124928: 537133056,
- 129024: 536871040
- }, {
- "0": 268435464,
- 256: 8192,
- 512: 270532608,
- 768: 270540808,
- 1024: 268443648,
- 1280: 2097152,
- 1536: 2097160,
- 1792: 268435456,
- 2048: 0,
- 2304: 268443656,
- 2560: 2105344,
- 2816: 8,
- 3072: 270532616,
- 3328: 2105352,
- 3584: 8200,
- 3840: 270540800,
- 128: 270532608,
- 384: 270540808,
- 640: 8,
- 896: 2097152,
- 1152: 2105352,
- 1408: 268435464,
- 1664: 268443648,
- 1920: 8200,
- 2176: 2097160,
- 2432: 8192,
- 2688: 268443656,
- 2944: 270532616,
- 3200: 0,
- 3456: 270540800,
- 3712: 2105344,
- 3968: 268435456,
- 4096: 268443648,
- 4352: 270532616,
- 4608: 270540808,
- 4864: 8200,
- 5120: 2097152,
- 5376: 268435456,
- 5632: 268435464,
- 5888: 2105344,
- 6144: 2105352,
- 6400: 0,
- 6656: 8,
- 6912: 270532608,
- 7168: 8192,
- 7424: 268443656,
- 7680: 270540800,
- 7936: 2097160,
- 4224: 8,
- 4480: 2105344,
- 4736: 2097152,
- 4992: 268435464,
- 5248: 268443648,
- 5504: 8200,
- 5760: 270540808,
- 6016: 270532608,
- 6272: 270540800,
- 6528: 270532616,
- 6784: 8192,
- 7040: 2105352,
- 7296: 2097160,
- 7552: 0,
- 7808: 268435456,
- 8064: 268443656
- }, {
- "0": 1048576,
- 16: 33555457,
- 32: 1024,
- 48: 1049601,
- 64: 34604033,
- 80: 0,
- 96: 1,
- 112: 34603009,
- 128: 33555456,
- 144: 1048577,
- 160: 33554433,
- 176: 34604032,
- 192: 34603008,
- 208: 1025,
- 224: 1049600,
- 240: 33554432,
- 8: 34603009,
- 24: 0,
- 40: 33555457,
- 56: 34604032,
- 72: 1048576,
- 88: 33554433,
- 104: 33554432,
- 120: 1025,
- 136: 1049601,
- 152: 33555456,
- 168: 34603008,
- 184: 1048577,
- 200: 1024,
- 216: 34604033,
- 232: 1,
- 248: 1049600,
- 256: 33554432,
- 272: 1048576,
- 288: 33555457,
- 304: 34603009,
- 320: 1048577,
- 336: 33555456,
- 352: 34604032,
- 368: 1049601,
- 384: 1025,
- 400: 34604033,
- 416: 1049600,
- 432: 1,
- 448: 0,
- 464: 34603008,
- 480: 33554433,
- 496: 1024,
- 264: 1049600,
- 280: 33555457,
- 296: 34603009,
- 312: 1,
- 328: 33554432,
- 344: 1048576,
- 360: 1025,
- 376: 34604032,
- 392: 33554433,
- 408: 34603008,
- 424: 0,
- 440: 34604033,
- 456: 1049601,
- 472: 1024,
- 488: 33555456,
- 504: 1048577
- }, {
- "0": 134219808,
- 1: 131072,
- 2: 134217728,
- 3: 32,
- 4: 131104,
- 5: 134350880,
- 6: 134350848,
- 7: 2048,
- 8: 134348800,
- 9: 134219776,
- 10: 133120,
- 11: 134348832,
- 12: 2080,
- 13: 0,
- 14: 134217760,
- 15: 133152,
- 2147483648: 2048,
- 2147483649: 134350880,
- 2147483650: 134219808,
- 2147483651: 134217728,
- 2147483652: 134348800,
- 2147483653: 133120,
- 2147483654: 133152,
- 2147483655: 32,
- 2147483656: 134217760,
- 2147483657: 2080,
- 2147483658: 131104,
- 2147483659: 134350848,
- 2147483660: 0,
- 2147483661: 134348832,
- 2147483662: 134219776,
- 2147483663: 131072,
- 16: 133152,
- 17: 134350848,
- 18: 32,
- 19: 2048,
- 20: 134219776,
- 21: 134217760,
- 22: 134348832,
- 23: 131072,
- 24: 0,
- 25: 131104,
- 26: 134348800,
- 27: 134219808,
- 28: 134350880,
- 29: 133120,
- 30: 2080,
- 31: 134217728,
- 2147483664: 131072,
- 2147483665: 2048,
- 2147483666: 134348832,
- 2147483667: 133152,
- 2147483668: 32,
- 2147483669: 134348800,
- 2147483670: 134217728,
- 2147483671: 134219808,
- 2147483672: 134350880,
- 2147483673: 134217760,
- 2147483674: 134219776,
- 2147483675: 0,
- 2147483676: 133120,
- 2147483677: 2080,
- 2147483678: 131104,
- 2147483679: 134350848
- }], x = [4160749569, 528482304, 33030144, 2064384, 129024, 8064, 504, 2147483679], r = s.DES = n.extend({
- _doReset: function() {
- for (var b2 = this._key.words, a = [], c = 0; 56 > c; c++) {
- var d2 = q[c] - 1;
- a[c] = b2[d2 >>> 5] >>> 31 - d2 % 32 & 1;
- }
- b2 = this._subKeys = [];
- for (d2 = 0; 16 > d2; d2++) {
- for (var f = b2[d2] = [], l2 = v[d2], c = 0; 24 > c; c++)
- f[c / 6 | 0] |= a[(w[c] - 1 + l2) % 28] << 31 - c % 6, f[4 + (c / 6 | 0)] |= a[28 + (w[c + 24] - 1 + l2) % 28] << 31 - c % 6;
- f[0] = f[0] << 1 | f[0] >>> 31;
- for (c = 1; 7 > c; c++)
- f[c] >>>= 4 * (c - 1) + 3;
- f[7] = f[7] << 5 | f[7] >>> 27;
- }
- a = this._invSubKeys = [];
- for (c = 0; 16 > c; c++)
- a[c] = b2[15 - c];
- },
- encryptBlock: function(b2, a) {
- this._doCryptBlock(b2, a, this._subKeys);
- },
- decryptBlock: function(b2, a) {
- this._doCryptBlock(b2, a, this._invSubKeys);
- },
- _doCryptBlock: function(e, a, c) {
- this._lBlock = e[a];
- this._rBlock = e[a + 1];
- u.call(this, 4, 252645135);
- u.call(this, 16, 65535);
- l.call(this, 2, 858993459);
- l.call(this, 8, 16711935);
- u.call(this, 1, 1431655765);
- for (var d2 = 0; 16 > d2; d2++) {
- for (var f = c[d2], n2 = this._lBlock, p2 = this._rBlock, q2 = 0, r2 = 0; 8 > r2; r2++)
- q2 |= b[r2][((p2 ^ f[r2]) & x[r2]) >>> 0];
- this._lBlock = p2;
- this._rBlock = n2 ^ q2;
- }
- c = this._lBlock;
- this._lBlock = this._rBlock;
- this._rBlock = c;
- u.call(this, 1, 1431655765);
- l.call(this, 8, 16711935);
- l.call(this, 2, 858993459);
- u.call(this, 16, 65535);
- u.call(this, 4, 252645135);
- e[a] = this._lBlock;
- e[a + 1] = this._rBlock;
- },
- keySize: 2,
- ivSize: 2,
- blockSize: 2
- });
- d.DES = n._createHelper(r);
- s = s.TripleDES = n.extend({
- _doReset: function() {
- var b2 = this._key.words;
- this._des1 = r.createEncryptor(p.create(b2.slice(0, 2)));
- this._des2 = r.createEncryptor(p.create(b2.slice(2, 4)));
- this._des3 = r.createEncryptor(p.create(b2.slice(4, 6)));
- },
- encryptBlock: function(b2, a) {
- this._des1.encryptBlock(b2, a);
- this._des2.decryptBlock(b2, a);
- this._des3.encryptBlock(b2, a);
- },
- decryptBlock: function(b2, a) {
- this._des3.decryptBlock(b2, a);
- this._des2.encryptBlock(b2, a);
- this._des1.decryptBlock(b2, a);
- },
- keySize: 6,
- ivSize: 2,
- blockSize: 2
- });
- d.TripleDES = n._createHelper(s);
- })();
- CryptoJS.mode.ECB = function() {
- var ECB = CryptoJS.lib.BlockCipherMode.extend();
- ECB.Encryptor = ECB.extend({
- processBlock: function(words, offset) {
- this._cipher.encryptBlock(words, offset);
- }
- });
- ECB.Decryptor = ECB.extend({
- processBlock: function(words, offset) {
- this._cipher.decryptBlock(words, offset);
- }
- });
- return ECB;
- }();
- exports.CryptoJS = CryptoJS;
- //# sourceMappingURL=../../.sourcemap/mp-alipay/utils/crypto-js.min.js.map
|