@ccci/micro-server 1.0.157 → 1.0.158
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/index.d.ts +1 -0
- package/dist/index.js +1857 -124
- package/dist/utils/BaseAuthenticatorModel.d.ts +0 -2
- package/dist/utils/DatabaseConnector.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -18231,7 +18231,7 @@ var require_mime = __commonJS((exports, module) => {
|
|
|
18231
18231
|
module.exports = mime;
|
|
18232
18232
|
});
|
|
18233
18233
|
|
|
18234
|
-
// node_modules/
|
|
18234
|
+
// node_modules/ms/index.js
|
|
18235
18235
|
var require_ms2 = __commonJS((exports, module) => {
|
|
18236
18236
|
var parse = function(str) {
|
|
18237
18237
|
str = String(str);
|
|
@@ -77288,120 +77288,10 @@ var require_metadata = __commonJS((exports, module) => {
|
|
|
77288
77288
|
});
|
|
77289
77289
|
});
|
|
77290
77290
|
|
|
77291
|
-
// node_modules/ms/index.js
|
|
77292
|
-
var require_ms4 = __commonJS((exports, module) => {
|
|
77293
|
-
var parse = function(str) {
|
|
77294
|
-
str = String(str);
|
|
77295
|
-
if (str.length > 100) {
|
|
77296
|
-
return;
|
|
77297
|
-
}
|
|
77298
|
-
var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(str);
|
|
77299
|
-
if (!match) {
|
|
77300
|
-
return;
|
|
77301
|
-
}
|
|
77302
|
-
var n = parseFloat(match[1]);
|
|
77303
|
-
var type = (match[2] || "ms").toLowerCase();
|
|
77304
|
-
switch (type) {
|
|
77305
|
-
case "years":
|
|
77306
|
-
case "year":
|
|
77307
|
-
case "yrs":
|
|
77308
|
-
case "yr":
|
|
77309
|
-
case "y":
|
|
77310
|
-
return n * y;
|
|
77311
|
-
case "weeks":
|
|
77312
|
-
case "week":
|
|
77313
|
-
case "w":
|
|
77314
|
-
return n * w;
|
|
77315
|
-
case "days":
|
|
77316
|
-
case "day":
|
|
77317
|
-
case "d":
|
|
77318
|
-
return n * d;
|
|
77319
|
-
case "hours":
|
|
77320
|
-
case "hour":
|
|
77321
|
-
case "hrs":
|
|
77322
|
-
case "hr":
|
|
77323
|
-
case "h":
|
|
77324
|
-
return n * h;
|
|
77325
|
-
case "minutes":
|
|
77326
|
-
case "minute":
|
|
77327
|
-
case "mins":
|
|
77328
|
-
case "min":
|
|
77329
|
-
case "m":
|
|
77330
|
-
return n * m;
|
|
77331
|
-
case "seconds":
|
|
77332
|
-
case "second":
|
|
77333
|
-
case "secs":
|
|
77334
|
-
case "sec":
|
|
77335
|
-
case "s":
|
|
77336
|
-
return n * s;
|
|
77337
|
-
case "milliseconds":
|
|
77338
|
-
case "millisecond":
|
|
77339
|
-
case "msecs":
|
|
77340
|
-
case "msec":
|
|
77341
|
-
case "ms":
|
|
77342
|
-
return n;
|
|
77343
|
-
default:
|
|
77344
|
-
return;
|
|
77345
|
-
}
|
|
77346
|
-
};
|
|
77347
|
-
var fmtShort = function(ms) {
|
|
77348
|
-
var msAbs = Math.abs(ms);
|
|
77349
|
-
if (msAbs >= d) {
|
|
77350
|
-
return Math.round(ms / d) + "d";
|
|
77351
|
-
}
|
|
77352
|
-
if (msAbs >= h) {
|
|
77353
|
-
return Math.round(ms / h) + "h";
|
|
77354
|
-
}
|
|
77355
|
-
if (msAbs >= m) {
|
|
77356
|
-
return Math.round(ms / m) + "m";
|
|
77357
|
-
}
|
|
77358
|
-
if (msAbs >= s) {
|
|
77359
|
-
return Math.round(ms / s) + "s";
|
|
77360
|
-
}
|
|
77361
|
-
return ms + "ms";
|
|
77362
|
-
};
|
|
77363
|
-
var fmtLong = function(ms) {
|
|
77364
|
-
var msAbs = Math.abs(ms);
|
|
77365
|
-
if (msAbs >= d) {
|
|
77366
|
-
return plural(ms, msAbs, d, "day");
|
|
77367
|
-
}
|
|
77368
|
-
if (msAbs >= h) {
|
|
77369
|
-
return plural(ms, msAbs, h, "hour");
|
|
77370
|
-
}
|
|
77371
|
-
if (msAbs >= m) {
|
|
77372
|
-
return plural(ms, msAbs, m, "minute");
|
|
77373
|
-
}
|
|
77374
|
-
if (msAbs >= s) {
|
|
77375
|
-
return plural(ms, msAbs, s, "second");
|
|
77376
|
-
}
|
|
77377
|
-
return ms + " ms";
|
|
77378
|
-
};
|
|
77379
|
-
var plural = function(ms, msAbs, n, name) {
|
|
77380
|
-
var isPlural = msAbs >= n * 1.5;
|
|
77381
|
-
return Math.round(ms / n) + " " + name + (isPlural ? "s" : "");
|
|
77382
|
-
};
|
|
77383
|
-
var s = 1000;
|
|
77384
|
-
var m = s * 60;
|
|
77385
|
-
var h = m * 60;
|
|
77386
|
-
var d = h * 24;
|
|
77387
|
-
var w = d * 7;
|
|
77388
|
-
var y = d * 365.25;
|
|
77389
|
-
module.exports = function(val2, options) {
|
|
77390
|
-
options = options || {};
|
|
77391
|
-
var type = typeof val2;
|
|
77392
|
-
if (type === "string" && val2.length > 0) {
|
|
77393
|
-
return parse(val2);
|
|
77394
|
-
} else if (type === "number" && isFinite(val2)) {
|
|
77395
|
-
return options.long ? fmtLong(val2) : fmtShort(val2);
|
|
77396
|
-
}
|
|
77397
|
-
throw new Error("val is not a non-empty string or a valid number. val=" + JSON.stringify(val2));
|
|
77398
|
-
};
|
|
77399
|
-
});
|
|
77400
|
-
|
|
77401
77291
|
// node_modules/logform/ms.js
|
|
77402
|
-
var
|
|
77292
|
+
var require_ms4 = __commonJS((exports, module) => {
|
|
77403
77293
|
var format = require_format();
|
|
77404
|
-
var ms =
|
|
77294
|
+
var ms = require_ms2();
|
|
77405
77295
|
module.exports = format((info) => {
|
|
77406
77296
|
const curr = +new Date;
|
|
77407
77297
|
exports.diff = curr - (exports.prevTime || curr);
|
|
@@ -78006,7 +77896,7 @@ var require_logform = __commonJS((exports) => {
|
|
|
78006
77896
|
return require_metadata();
|
|
78007
77897
|
});
|
|
78008
77898
|
exposeFormat("ms", function() {
|
|
78009
|
-
return
|
|
77899
|
+
return require_ms4();
|
|
78010
77900
|
});
|
|
78011
77901
|
exposeFormat("padLevels", function() {
|
|
78012
77902
|
return require_pad_levels();
|
|
@@ -86039,7 +85929,7 @@ var require_TokenExpiredError = __commonJS((exports, module) => {
|
|
|
86039
85929
|
|
|
86040
85930
|
// node_modules/jsonwebtoken/lib/timespan.js
|
|
86041
85931
|
var require_timespan = __commonJS((exports, module) => {
|
|
86042
|
-
var ms =
|
|
85932
|
+
var ms = require_ms2();
|
|
86043
85933
|
module.exports = function(time, iat) {
|
|
86044
85934
|
var timestamp2 = iat || Math.floor(Date.now() / 1000);
|
|
86045
85935
|
if (typeof time === "string") {
|
|
@@ -117986,7 +117876,7 @@ var require_TokenExpiredError2 = __commonJS((exports, module) => {
|
|
|
117986
117876
|
|
|
117987
117877
|
// node_modules/firebase-admin/node_modules/jsonwebtoken/lib/timespan.js
|
|
117988
117878
|
var require_timespan2 = __commonJS((exports, module) => {
|
|
117989
|
-
var ms =
|
|
117879
|
+
var ms = require_ms2();
|
|
117990
117880
|
module.exports = function(time, iat) {
|
|
117991
117881
|
var timestamp2 = iat || Math.floor(Date.now() / 1000);
|
|
117992
117882
|
if (typeof time === "string") {
|
|
@@ -140540,7 +140430,7 @@ var require_token_generator = __commonJS((exports) => {
|
|
|
140540
140430
|
});
|
|
140541
140431
|
|
|
140542
140432
|
// node_modules/jwks-rsa/node_modules/debug/node_modules/ms/index.js
|
|
140543
|
-
var
|
|
140433
|
+
var require_ms5 = __commonJS((exports, module) => {
|
|
140544
140434
|
var parse = function(str) {
|
|
140545
140435
|
str = String(str);
|
|
140546
140436
|
if (str.length > 100) {
|
|
@@ -140658,7 +140548,7 @@ var require_common3 = __commonJS((exports, module) => {
|
|
|
140658
140548
|
createDebug.disable = disable;
|
|
140659
140549
|
createDebug.enable = enable;
|
|
140660
140550
|
createDebug.enabled = enabled;
|
|
140661
|
-
createDebug.humanize =
|
|
140551
|
+
createDebug.humanize = require_ms5();
|
|
140662
140552
|
createDebug.destroy = destroy;
|
|
140663
140553
|
Object.keys(env2).forEach((key) => {
|
|
140664
140554
|
createDebug[key] = env2[key];
|
|
@@ -170025,7 +169915,7 @@ var require_interceptor2 = __commonJS((exports) => {
|
|
|
170025
169915
|
});
|
|
170026
169916
|
|
|
170027
169917
|
// node_modules/https-proxy-agent/node_modules/debug/node_modules/ms/index.js
|
|
170028
|
-
var
|
|
169918
|
+
var require_ms6 = __commonJS((exports, module) => {
|
|
170029
169919
|
var parse = function(str) {
|
|
170030
169920
|
str = String(str);
|
|
170031
169921
|
if (str.length > 100) {
|
|
@@ -170143,7 +170033,7 @@ var require_common5 = __commonJS((exports, module) => {
|
|
|
170143
170033
|
createDebug.disable = disable;
|
|
170144
170034
|
createDebug.enable = enable;
|
|
170145
170035
|
createDebug.enabled = enabled;
|
|
170146
|
-
createDebug.humanize =
|
|
170036
|
+
createDebug.humanize = require_ms6();
|
|
170147
170037
|
createDebug.destroy = destroy;
|
|
170148
170038
|
Object.keys(env2).forEach((key) => {
|
|
170149
170039
|
createDebug[key] = env2[key];
|
|
@@ -180245,7 +180135,7 @@ var require_dist7 = __commonJS((exports) => {
|
|
|
180245
180135
|
});
|
|
180246
180136
|
|
|
180247
180137
|
// node_modules/http-proxy-agent/node_modules/debug/node_modules/ms/index.js
|
|
180248
|
-
var
|
|
180138
|
+
var require_ms7 = __commonJS((exports, module) => {
|
|
180249
180139
|
var parse = function(str) {
|
|
180250
180140
|
str = String(str);
|
|
180251
180141
|
if (str.length > 100) {
|
|
@@ -180363,7 +180253,7 @@ var require_common6 = __commonJS((exports, module) => {
|
|
|
180363
180253
|
createDebug.disable = disable;
|
|
180364
180254
|
createDebug.enable = enable;
|
|
180365
180255
|
createDebug.enabled = enabled;
|
|
180366
|
-
createDebug.humanize =
|
|
180256
|
+
createDebug.humanize = require_ms7();
|
|
180367
180257
|
createDebug.destroy = destroy;
|
|
180368
180258
|
Object.keys(env2).forEach((key) => {
|
|
180369
180259
|
createDebug[key] = env2[key];
|
|
@@ -181221,7 +181111,7 @@ var require_dist9 = __commonJS((exports, module) => {
|
|
|
181221
181111
|
});
|
|
181222
181112
|
|
|
181223
181113
|
// node_modules/teeny-request/node_modules/https-proxy-agent/node_modules/debug/node_modules/ms/index.js
|
|
181224
|
-
var
|
|
181114
|
+
var require_ms8 = __commonJS((exports, module) => {
|
|
181225
181115
|
var parse = function(str) {
|
|
181226
181116
|
str = String(str);
|
|
181227
181117
|
if (str.length > 100) {
|
|
@@ -181339,7 +181229,7 @@ var require_common7 = __commonJS((exports, module) => {
|
|
|
181339
181229
|
createDebug.disable = disable;
|
|
181340
181230
|
createDebug.enable = enable;
|
|
181341
181231
|
createDebug.enabled = enabled;
|
|
181342
|
-
createDebug.humanize =
|
|
181232
|
+
createDebug.humanize = require_ms8();
|
|
181343
181233
|
createDebug.destroy = destroy;
|
|
181344
181234
|
Object.keys(env2).forEach((key) => {
|
|
181345
181235
|
createDebug[key] = env2[key];
|
|
@@ -294343,6 +294233,1816 @@ var require_kafkajs = __commonJS((exports, module) => {
|
|
|
294343
294233
|
};
|
|
294344
294234
|
});
|
|
294345
294235
|
|
|
294236
|
+
// node_modules/bcryptjs/dist/bcrypt.js
|
|
294237
|
+
var require_bcrypt = __commonJS((exports, module) => {
|
|
294238
|
+
(function(global2, factory) {
|
|
294239
|
+
if (typeof define === "function" && define["amd"])
|
|
294240
|
+
define([], factory);
|
|
294241
|
+
else if (typeof require === "function" && typeof module === "object" && module && exports)
|
|
294242
|
+
module["exports"] = factory();
|
|
294243
|
+
else
|
|
294244
|
+
(global2["dcodeIO"] = global2["dcodeIO"] || {})["bcrypt"] = factory();
|
|
294245
|
+
})(exports, function() {
|
|
294246
|
+
var bcrypt = {};
|
|
294247
|
+
var randomFallback = null;
|
|
294248
|
+
function random(len) {
|
|
294249
|
+
if (typeof module !== "undefined" && module && module["exports"])
|
|
294250
|
+
try {
|
|
294251
|
+
return __require("crypto")["randomBytes"](len);
|
|
294252
|
+
} catch (e) {
|
|
294253
|
+
}
|
|
294254
|
+
try {
|
|
294255
|
+
var a;
|
|
294256
|
+
(self["crypto"] || self["msCrypto"])["getRandomValues"](a = new Uint32Array(len));
|
|
294257
|
+
return Array.prototype.slice.call(a);
|
|
294258
|
+
} catch (e) {
|
|
294259
|
+
}
|
|
294260
|
+
if (!randomFallback)
|
|
294261
|
+
throw Error("Neither WebCryptoAPI nor a crypto module is available. Use bcrypt.setRandomFallback to set an alternative");
|
|
294262
|
+
return randomFallback(len);
|
|
294263
|
+
}
|
|
294264
|
+
var randomAvailable = false;
|
|
294265
|
+
try {
|
|
294266
|
+
random(1);
|
|
294267
|
+
randomAvailable = true;
|
|
294268
|
+
} catch (e) {
|
|
294269
|
+
}
|
|
294270
|
+
randomFallback = null;
|
|
294271
|
+
bcrypt.setRandomFallback = function(random2) {
|
|
294272
|
+
randomFallback = random2;
|
|
294273
|
+
};
|
|
294274
|
+
bcrypt.genSaltSync = function(rounds, seed_length) {
|
|
294275
|
+
rounds = rounds || GENSALT_DEFAULT_LOG2_ROUNDS;
|
|
294276
|
+
if (typeof rounds !== "number")
|
|
294277
|
+
throw Error("Illegal arguments: " + typeof rounds + ", " + typeof seed_length);
|
|
294278
|
+
if (rounds < 4)
|
|
294279
|
+
rounds = 4;
|
|
294280
|
+
else if (rounds > 31)
|
|
294281
|
+
rounds = 31;
|
|
294282
|
+
var salt = [];
|
|
294283
|
+
salt.push("$2a$");
|
|
294284
|
+
if (rounds < 10)
|
|
294285
|
+
salt.push("0");
|
|
294286
|
+
salt.push(rounds.toString());
|
|
294287
|
+
salt.push("$");
|
|
294288
|
+
salt.push(base64_encode(random(BCRYPT_SALT_LEN), BCRYPT_SALT_LEN));
|
|
294289
|
+
return salt.join("");
|
|
294290
|
+
};
|
|
294291
|
+
bcrypt.genSalt = function(rounds, seed_length, callback) {
|
|
294292
|
+
if (typeof seed_length === "function")
|
|
294293
|
+
callback = seed_length, seed_length = undefined;
|
|
294294
|
+
if (typeof rounds === "function")
|
|
294295
|
+
callback = rounds, rounds = undefined;
|
|
294296
|
+
if (typeof rounds === "undefined")
|
|
294297
|
+
rounds = GENSALT_DEFAULT_LOG2_ROUNDS;
|
|
294298
|
+
else if (typeof rounds !== "number")
|
|
294299
|
+
throw Error("illegal arguments: " + typeof rounds);
|
|
294300
|
+
function _async(callback2) {
|
|
294301
|
+
nextTick(function() {
|
|
294302
|
+
try {
|
|
294303
|
+
callback2(null, bcrypt.genSaltSync(rounds));
|
|
294304
|
+
} catch (err) {
|
|
294305
|
+
callback2(err);
|
|
294306
|
+
}
|
|
294307
|
+
});
|
|
294308
|
+
}
|
|
294309
|
+
if (callback) {
|
|
294310
|
+
if (typeof callback !== "function")
|
|
294311
|
+
throw Error("Illegal callback: " + typeof callback);
|
|
294312
|
+
_async(callback);
|
|
294313
|
+
} else
|
|
294314
|
+
return new Promise(function(resolve, reject) {
|
|
294315
|
+
_async(function(err, res) {
|
|
294316
|
+
if (err) {
|
|
294317
|
+
reject(err);
|
|
294318
|
+
return;
|
|
294319
|
+
}
|
|
294320
|
+
resolve(res);
|
|
294321
|
+
});
|
|
294322
|
+
});
|
|
294323
|
+
};
|
|
294324
|
+
bcrypt.hashSync = function(s, salt) {
|
|
294325
|
+
if (typeof salt === "undefined")
|
|
294326
|
+
salt = GENSALT_DEFAULT_LOG2_ROUNDS;
|
|
294327
|
+
if (typeof salt === "number")
|
|
294328
|
+
salt = bcrypt.genSaltSync(salt);
|
|
294329
|
+
if (typeof s !== "string" || typeof salt !== "string")
|
|
294330
|
+
throw Error("Illegal arguments: " + typeof s + ", " + typeof salt);
|
|
294331
|
+
return _hash(s, salt);
|
|
294332
|
+
};
|
|
294333
|
+
bcrypt.hash = function(s, salt, callback, progressCallback) {
|
|
294334
|
+
function _async(callback2) {
|
|
294335
|
+
if (typeof s === "string" && typeof salt === "number")
|
|
294336
|
+
bcrypt.genSalt(salt, function(err, salt2) {
|
|
294337
|
+
_hash(s, salt2, callback2, progressCallback);
|
|
294338
|
+
});
|
|
294339
|
+
else if (typeof s === "string" && typeof salt === "string")
|
|
294340
|
+
_hash(s, salt, callback2, progressCallback);
|
|
294341
|
+
else
|
|
294342
|
+
nextTick(callback2.bind(this, Error("Illegal arguments: " + typeof s + ", " + typeof salt)));
|
|
294343
|
+
}
|
|
294344
|
+
if (callback) {
|
|
294345
|
+
if (typeof callback !== "function")
|
|
294346
|
+
throw Error("Illegal callback: " + typeof callback);
|
|
294347
|
+
_async(callback);
|
|
294348
|
+
} else
|
|
294349
|
+
return new Promise(function(resolve, reject) {
|
|
294350
|
+
_async(function(err, res) {
|
|
294351
|
+
if (err) {
|
|
294352
|
+
reject(err);
|
|
294353
|
+
return;
|
|
294354
|
+
}
|
|
294355
|
+
resolve(res);
|
|
294356
|
+
});
|
|
294357
|
+
});
|
|
294358
|
+
};
|
|
294359
|
+
function safeStringCompare(known, unknown) {
|
|
294360
|
+
var right = 0, wrong = 0;
|
|
294361
|
+
for (var i = 0, k = known.length;i < k; ++i) {
|
|
294362
|
+
if (known.charCodeAt(i) === unknown.charCodeAt(i))
|
|
294363
|
+
++right;
|
|
294364
|
+
else
|
|
294365
|
+
++wrong;
|
|
294366
|
+
}
|
|
294367
|
+
if (right < 0)
|
|
294368
|
+
return false;
|
|
294369
|
+
return wrong === 0;
|
|
294370
|
+
}
|
|
294371
|
+
bcrypt.compareSync = function(s, hash) {
|
|
294372
|
+
if (typeof s !== "string" || typeof hash !== "string")
|
|
294373
|
+
throw Error("Illegal arguments: " + typeof s + ", " + typeof hash);
|
|
294374
|
+
if (hash.length !== 60)
|
|
294375
|
+
return false;
|
|
294376
|
+
return safeStringCompare(bcrypt.hashSync(s, hash.substr(0, hash.length - 31)), hash);
|
|
294377
|
+
};
|
|
294378
|
+
bcrypt.compare = function(s, hash, callback, progressCallback) {
|
|
294379
|
+
function _async(callback2) {
|
|
294380
|
+
if (typeof s !== "string" || typeof hash !== "string") {
|
|
294381
|
+
nextTick(callback2.bind(this, Error("Illegal arguments: " + typeof s + ", " + typeof hash)));
|
|
294382
|
+
return;
|
|
294383
|
+
}
|
|
294384
|
+
if (hash.length !== 60) {
|
|
294385
|
+
nextTick(callback2.bind(this, null, false));
|
|
294386
|
+
return;
|
|
294387
|
+
}
|
|
294388
|
+
bcrypt.hash(s, hash.substr(0, 29), function(err, comp) {
|
|
294389
|
+
if (err)
|
|
294390
|
+
callback2(err);
|
|
294391
|
+
else
|
|
294392
|
+
callback2(null, safeStringCompare(comp, hash));
|
|
294393
|
+
}, progressCallback);
|
|
294394
|
+
}
|
|
294395
|
+
if (callback) {
|
|
294396
|
+
if (typeof callback !== "function")
|
|
294397
|
+
throw Error("Illegal callback: " + typeof callback);
|
|
294398
|
+
_async(callback);
|
|
294399
|
+
} else
|
|
294400
|
+
return new Promise(function(resolve, reject) {
|
|
294401
|
+
_async(function(err, res) {
|
|
294402
|
+
if (err) {
|
|
294403
|
+
reject(err);
|
|
294404
|
+
return;
|
|
294405
|
+
}
|
|
294406
|
+
resolve(res);
|
|
294407
|
+
});
|
|
294408
|
+
});
|
|
294409
|
+
};
|
|
294410
|
+
bcrypt.getRounds = function(hash) {
|
|
294411
|
+
if (typeof hash !== "string")
|
|
294412
|
+
throw Error("Illegal arguments: " + typeof hash);
|
|
294413
|
+
return parseInt(hash.split("$")[2], 10);
|
|
294414
|
+
};
|
|
294415
|
+
bcrypt.getSalt = function(hash) {
|
|
294416
|
+
if (typeof hash !== "string")
|
|
294417
|
+
throw Error("Illegal arguments: " + typeof hash);
|
|
294418
|
+
if (hash.length !== 60)
|
|
294419
|
+
throw Error("Illegal hash length: " + hash.length + " != 60");
|
|
294420
|
+
return hash.substring(0, 29);
|
|
294421
|
+
};
|
|
294422
|
+
var nextTick = typeof process !== "undefined" && process && typeof process.nextTick === "function" ? typeof setImmediate === "function" ? setImmediate : process.nextTick : setTimeout;
|
|
294423
|
+
function stringToBytes(str) {
|
|
294424
|
+
var out = [], i = 0;
|
|
294425
|
+
utfx.encodeUTF16toUTF8(function() {
|
|
294426
|
+
if (i >= str.length)
|
|
294427
|
+
return null;
|
|
294428
|
+
return str.charCodeAt(i++);
|
|
294429
|
+
}, function(b) {
|
|
294430
|
+
out.push(b);
|
|
294431
|
+
});
|
|
294432
|
+
return out;
|
|
294433
|
+
}
|
|
294434
|
+
var BASE64_CODE = "./ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split("");
|
|
294435
|
+
var BASE64_INDEX = [
|
|
294436
|
+
-1,
|
|
294437
|
+
-1,
|
|
294438
|
+
-1,
|
|
294439
|
+
-1,
|
|
294440
|
+
-1,
|
|
294441
|
+
-1,
|
|
294442
|
+
-1,
|
|
294443
|
+
-1,
|
|
294444
|
+
-1,
|
|
294445
|
+
-1,
|
|
294446
|
+
-1,
|
|
294447
|
+
-1,
|
|
294448
|
+
-1,
|
|
294449
|
+
-1,
|
|
294450
|
+
-1,
|
|
294451
|
+
-1,
|
|
294452
|
+
-1,
|
|
294453
|
+
-1,
|
|
294454
|
+
-1,
|
|
294455
|
+
-1,
|
|
294456
|
+
-1,
|
|
294457
|
+
-1,
|
|
294458
|
+
-1,
|
|
294459
|
+
-1,
|
|
294460
|
+
-1,
|
|
294461
|
+
-1,
|
|
294462
|
+
-1,
|
|
294463
|
+
-1,
|
|
294464
|
+
-1,
|
|
294465
|
+
-1,
|
|
294466
|
+
-1,
|
|
294467
|
+
-1,
|
|
294468
|
+
-1,
|
|
294469
|
+
-1,
|
|
294470
|
+
-1,
|
|
294471
|
+
-1,
|
|
294472
|
+
-1,
|
|
294473
|
+
-1,
|
|
294474
|
+
-1,
|
|
294475
|
+
-1,
|
|
294476
|
+
-1,
|
|
294477
|
+
-1,
|
|
294478
|
+
-1,
|
|
294479
|
+
-1,
|
|
294480
|
+
-1,
|
|
294481
|
+
-1,
|
|
294482
|
+
0,
|
|
294483
|
+
1,
|
|
294484
|
+
54,
|
|
294485
|
+
55,
|
|
294486
|
+
56,
|
|
294487
|
+
57,
|
|
294488
|
+
58,
|
|
294489
|
+
59,
|
|
294490
|
+
60,
|
|
294491
|
+
61,
|
|
294492
|
+
62,
|
|
294493
|
+
63,
|
|
294494
|
+
-1,
|
|
294495
|
+
-1,
|
|
294496
|
+
-1,
|
|
294497
|
+
-1,
|
|
294498
|
+
-1,
|
|
294499
|
+
-1,
|
|
294500
|
+
-1,
|
|
294501
|
+
2,
|
|
294502
|
+
3,
|
|
294503
|
+
4,
|
|
294504
|
+
5,
|
|
294505
|
+
6,
|
|
294506
|
+
7,
|
|
294507
|
+
8,
|
|
294508
|
+
9,
|
|
294509
|
+
10,
|
|
294510
|
+
11,
|
|
294511
|
+
12,
|
|
294512
|
+
13,
|
|
294513
|
+
14,
|
|
294514
|
+
15,
|
|
294515
|
+
16,
|
|
294516
|
+
17,
|
|
294517
|
+
18,
|
|
294518
|
+
19,
|
|
294519
|
+
20,
|
|
294520
|
+
21,
|
|
294521
|
+
22,
|
|
294522
|
+
23,
|
|
294523
|
+
24,
|
|
294524
|
+
25,
|
|
294525
|
+
26,
|
|
294526
|
+
27,
|
|
294527
|
+
-1,
|
|
294528
|
+
-1,
|
|
294529
|
+
-1,
|
|
294530
|
+
-1,
|
|
294531
|
+
-1,
|
|
294532
|
+
-1,
|
|
294533
|
+
28,
|
|
294534
|
+
29,
|
|
294535
|
+
30,
|
|
294536
|
+
31,
|
|
294537
|
+
32,
|
|
294538
|
+
33,
|
|
294539
|
+
34,
|
|
294540
|
+
35,
|
|
294541
|
+
36,
|
|
294542
|
+
37,
|
|
294543
|
+
38,
|
|
294544
|
+
39,
|
|
294545
|
+
40,
|
|
294546
|
+
41,
|
|
294547
|
+
42,
|
|
294548
|
+
43,
|
|
294549
|
+
44,
|
|
294550
|
+
45,
|
|
294551
|
+
46,
|
|
294552
|
+
47,
|
|
294553
|
+
48,
|
|
294554
|
+
49,
|
|
294555
|
+
50,
|
|
294556
|
+
51,
|
|
294557
|
+
52,
|
|
294558
|
+
53,
|
|
294559
|
+
-1,
|
|
294560
|
+
-1,
|
|
294561
|
+
-1,
|
|
294562
|
+
-1,
|
|
294563
|
+
-1
|
|
294564
|
+
];
|
|
294565
|
+
var stringFromCharCode = String.fromCharCode;
|
|
294566
|
+
function base64_encode(b, len) {
|
|
294567
|
+
var off = 0, rs = [], c1, c2;
|
|
294568
|
+
if (len <= 0 || len > b.length)
|
|
294569
|
+
throw Error("Illegal len: " + len);
|
|
294570
|
+
while (off < len) {
|
|
294571
|
+
c1 = b[off++] & 255;
|
|
294572
|
+
rs.push(BASE64_CODE[c1 >> 2 & 63]);
|
|
294573
|
+
c1 = (c1 & 3) << 4;
|
|
294574
|
+
if (off >= len) {
|
|
294575
|
+
rs.push(BASE64_CODE[c1 & 63]);
|
|
294576
|
+
break;
|
|
294577
|
+
}
|
|
294578
|
+
c2 = b[off++] & 255;
|
|
294579
|
+
c1 |= c2 >> 4 & 15;
|
|
294580
|
+
rs.push(BASE64_CODE[c1 & 63]);
|
|
294581
|
+
c1 = (c2 & 15) << 2;
|
|
294582
|
+
if (off >= len) {
|
|
294583
|
+
rs.push(BASE64_CODE[c1 & 63]);
|
|
294584
|
+
break;
|
|
294585
|
+
}
|
|
294586
|
+
c2 = b[off++] & 255;
|
|
294587
|
+
c1 |= c2 >> 6 & 3;
|
|
294588
|
+
rs.push(BASE64_CODE[c1 & 63]);
|
|
294589
|
+
rs.push(BASE64_CODE[c2 & 63]);
|
|
294590
|
+
}
|
|
294591
|
+
return rs.join("");
|
|
294592
|
+
}
|
|
294593
|
+
function base64_decode(s, len) {
|
|
294594
|
+
var off = 0, slen = s.length, olen = 0, rs = [], c1, c2, c3, c4, o, code;
|
|
294595
|
+
if (len <= 0)
|
|
294596
|
+
throw Error("Illegal len: " + len);
|
|
294597
|
+
while (off < slen - 1 && olen < len) {
|
|
294598
|
+
code = s.charCodeAt(off++);
|
|
294599
|
+
c1 = code < BASE64_INDEX.length ? BASE64_INDEX[code] : -1;
|
|
294600
|
+
code = s.charCodeAt(off++);
|
|
294601
|
+
c2 = code < BASE64_INDEX.length ? BASE64_INDEX[code] : -1;
|
|
294602
|
+
if (c1 == -1 || c2 == -1)
|
|
294603
|
+
break;
|
|
294604
|
+
o = c1 << 2 >>> 0;
|
|
294605
|
+
o |= (c2 & 48) >> 4;
|
|
294606
|
+
rs.push(stringFromCharCode(o));
|
|
294607
|
+
if (++olen >= len || off >= slen)
|
|
294608
|
+
break;
|
|
294609
|
+
code = s.charCodeAt(off++);
|
|
294610
|
+
c3 = code < BASE64_INDEX.length ? BASE64_INDEX[code] : -1;
|
|
294611
|
+
if (c3 == -1)
|
|
294612
|
+
break;
|
|
294613
|
+
o = (c2 & 15) << 4 >>> 0;
|
|
294614
|
+
o |= (c3 & 60) >> 2;
|
|
294615
|
+
rs.push(stringFromCharCode(o));
|
|
294616
|
+
if (++olen >= len || off >= slen)
|
|
294617
|
+
break;
|
|
294618
|
+
code = s.charCodeAt(off++);
|
|
294619
|
+
c4 = code < BASE64_INDEX.length ? BASE64_INDEX[code] : -1;
|
|
294620
|
+
o = (c3 & 3) << 6 >>> 0;
|
|
294621
|
+
o |= c4;
|
|
294622
|
+
rs.push(stringFromCharCode(o));
|
|
294623
|
+
++olen;
|
|
294624
|
+
}
|
|
294625
|
+
var res = [];
|
|
294626
|
+
for (off = 0;off < olen; off++)
|
|
294627
|
+
res.push(rs[off].charCodeAt(0));
|
|
294628
|
+
return res;
|
|
294629
|
+
}
|
|
294630
|
+
var utfx = function() {
|
|
294631
|
+
var utfx2 = {};
|
|
294632
|
+
utfx2.MAX_CODEPOINT = 1114111;
|
|
294633
|
+
utfx2.encodeUTF8 = function(src, dst) {
|
|
294634
|
+
var cp = null;
|
|
294635
|
+
if (typeof src === "number")
|
|
294636
|
+
cp = src, src = function() {
|
|
294637
|
+
return null;
|
|
294638
|
+
};
|
|
294639
|
+
while (cp !== null || (cp = src()) !== null) {
|
|
294640
|
+
if (cp < 128)
|
|
294641
|
+
dst(cp & 127);
|
|
294642
|
+
else if (cp < 2048)
|
|
294643
|
+
dst(cp >> 6 & 31 | 192), dst(cp & 63 | 128);
|
|
294644
|
+
else if (cp < 65536)
|
|
294645
|
+
dst(cp >> 12 & 15 | 224), dst(cp >> 6 & 63 | 128), dst(cp & 63 | 128);
|
|
294646
|
+
else
|
|
294647
|
+
dst(cp >> 18 & 7 | 240), dst(cp >> 12 & 63 | 128), dst(cp >> 6 & 63 | 128), dst(cp & 63 | 128);
|
|
294648
|
+
cp = null;
|
|
294649
|
+
}
|
|
294650
|
+
};
|
|
294651
|
+
utfx2.decodeUTF8 = function(src, dst) {
|
|
294652
|
+
var a, b, c, d, fail = function(b2) {
|
|
294653
|
+
b2 = b2.slice(0, b2.indexOf(null));
|
|
294654
|
+
var err = Error(b2.toString());
|
|
294655
|
+
err.name = "TruncatedError";
|
|
294656
|
+
err["bytes"] = b2;
|
|
294657
|
+
throw err;
|
|
294658
|
+
};
|
|
294659
|
+
while ((a = src()) !== null) {
|
|
294660
|
+
if ((a & 128) === 0)
|
|
294661
|
+
dst(a);
|
|
294662
|
+
else if ((a & 224) === 192)
|
|
294663
|
+
(b = src()) === null && fail([a, b]), dst((a & 31) << 6 | b & 63);
|
|
294664
|
+
else if ((a & 240) === 224)
|
|
294665
|
+
((b = src()) === null || (c = src()) === null) && fail([a, b, c]), dst((a & 15) << 12 | (b & 63) << 6 | c & 63);
|
|
294666
|
+
else if ((a & 248) === 240)
|
|
294667
|
+
((b = src()) === null || (c = src()) === null || (d = src()) === null) && fail([a, b, c, d]), dst((a & 7) << 18 | (b & 63) << 12 | (c & 63) << 6 | d & 63);
|
|
294668
|
+
else
|
|
294669
|
+
throw RangeError("Illegal starting byte: " + a);
|
|
294670
|
+
}
|
|
294671
|
+
};
|
|
294672
|
+
utfx2.UTF16toUTF8 = function(src, dst) {
|
|
294673
|
+
var c1, c2 = null;
|
|
294674
|
+
while (true) {
|
|
294675
|
+
if ((c1 = c2 !== null ? c2 : src()) === null)
|
|
294676
|
+
break;
|
|
294677
|
+
if (c1 >= 55296 && c1 <= 57343) {
|
|
294678
|
+
if ((c2 = src()) !== null) {
|
|
294679
|
+
if (c2 >= 56320 && c2 <= 57343) {
|
|
294680
|
+
dst((c1 - 55296) * 1024 + c2 - 56320 + 65536);
|
|
294681
|
+
c2 = null;
|
|
294682
|
+
continue;
|
|
294683
|
+
}
|
|
294684
|
+
}
|
|
294685
|
+
}
|
|
294686
|
+
dst(c1);
|
|
294687
|
+
}
|
|
294688
|
+
if (c2 !== null)
|
|
294689
|
+
dst(c2);
|
|
294690
|
+
};
|
|
294691
|
+
utfx2.UTF8toUTF16 = function(src, dst) {
|
|
294692
|
+
var cp = null;
|
|
294693
|
+
if (typeof src === "number")
|
|
294694
|
+
cp = src, src = function() {
|
|
294695
|
+
return null;
|
|
294696
|
+
};
|
|
294697
|
+
while (cp !== null || (cp = src()) !== null) {
|
|
294698
|
+
if (cp <= 65535)
|
|
294699
|
+
dst(cp);
|
|
294700
|
+
else
|
|
294701
|
+
cp -= 65536, dst((cp >> 10) + 55296), dst(cp % 1024 + 56320);
|
|
294702
|
+
cp = null;
|
|
294703
|
+
}
|
|
294704
|
+
};
|
|
294705
|
+
utfx2.encodeUTF16toUTF8 = function(src, dst) {
|
|
294706
|
+
utfx2.UTF16toUTF8(src, function(cp) {
|
|
294707
|
+
utfx2.encodeUTF8(cp, dst);
|
|
294708
|
+
});
|
|
294709
|
+
};
|
|
294710
|
+
utfx2.decodeUTF8toUTF16 = function(src, dst) {
|
|
294711
|
+
utfx2.decodeUTF8(src, function(cp) {
|
|
294712
|
+
utfx2.UTF8toUTF16(cp, dst);
|
|
294713
|
+
});
|
|
294714
|
+
};
|
|
294715
|
+
utfx2.calculateCodePoint = function(cp) {
|
|
294716
|
+
return cp < 128 ? 1 : cp < 2048 ? 2 : cp < 65536 ? 3 : 4;
|
|
294717
|
+
};
|
|
294718
|
+
utfx2.calculateUTF8 = function(src) {
|
|
294719
|
+
var cp, l = 0;
|
|
294720
|
+
while ((cp = src()) !== null)
|
|
294721
|
+
l += utfx2.calculateCodePoint(cp);
|
|
294722
|
+
return l;
|
|
294723
|
+
};
|
|
294724
|
+
utfx2.calculateUTF16asUTF8 = function(src) {
|
|
294725
|
+
var n = 0, l = 0;
|
|
294726
|
+
utfx2.UTF16toUTF8(src, function(cp) {
|
|
294727
|
+
++n;
|
|
294728
|
+
l += utfx2.calculateCodePoint(cp);
|
|
294729
|
+
});
|
|
294730
|
+
return [n, l];
|
|
294731
|
+
};
|
|
294732
|
+
return utfx2;
|
|
294733
|
+
}();
|
|
294734
|
+
Date.now = Date.now || function() {
|
|
294735
|
+
return +new Date;
|
|
294736
|
+
};
|
|
294737
|
+
var BCRYPT_SALT_LEN = 16;
|
|
294738
|
+
var GENSALT_DEFAULT_LOG2_ROUNDS = 10;
|
|
294739
|
+
var BLOWFISH_NUM_ROUNDS = 16;
|
|
294740
|
+
var MAX_EXECUTION_TIME = 100;
|
|
294741
|
+
var P_ORIG = [
|
|
294742
|
+
608135816,
|
|
294743
|
+
2242054355,
|
|
294744
|
+
320440878,
|
|
294745
|
+
57701188,
|
|
294746
|
+
2752067618,
|
|
294747
|
+
698298832,
|
|
294748
|
+
137296536,
|
|
294749
|
+
3964562569,
|
|
294750
|
+
1160258022,
|
|
294751
|
+
953160567,
|
|
294752
|
+
3193202383,
|
|
294753
|
+
887688300,
|
|
294754
|
+
3232508343,
|
|
294755
|
+
3380367581,
|
|
294756
|
+
1065670069,
|
|
294757
|
+
3041331479,
|
|
294758
|
+
2450970073,
|
|
294759
|
+
2306472731
|
|
294760
|
+
];
|
|
294761
|
+
var S_ORIG = [
|
|
294762
|
+
3509652390,
|
|
294763
|
+
2564797868,
|
|
294764
|
+
805139163,
|
|
294765
|
+
3491422135,
|
|
294766
|
+
3101798381,
|
|
294767
|
+
1780907670,
|
|
294768
|
+
3128725573,
|
|
294769
|
+
4046225305,
|
|
294770
|
+
614570311,
|
|
294771
|
+
3012652279,
|
|
294772
|
+
134345442,
|
|
294773
|
+
2240740374,
|
|
294774
|
+
1667834072,
|
|
294775
|
+
1901547113,
|
|
294776
|
+
2757295779,
|
|
294777
|
+
4103290238,
|
|
294778
|
+
227898511,
|
|
294779
|
+
1921955416,
|
|
294780
|
+
1904987480,
|
|
294781
|
+
2182433518,
|
|
294782
|
+
2069144605,
|
|
294783
|
+
3260701109,
|
|
294784
|
+
2620446009,
|
|
294785
|
+
720527379,
|
|
294786
|
+
3318853667,
|
|
294787
|
+
677414384,
|
|
294788
|
+
3393288472,
|
|
294789
|
+
3101374703,
|
|
294790
|
+
2390351024,
|
|
294791
|
+
1614419982,
|
|
294792
|
+
1822297739,
|
|
294793
|
+
2954791486,
|
|
294794
|
+
3608508353,
|
|
294795
|
+
3174124327,
|
|
294796
|
+
2024746970,
|
|
294797
|
+
1432378464,
|
|
294798
|
+
3864339955,
|
|
294799
|
+
2857741204,
|
|
294800
|
+
1464375394,
|
|
294801
|
+
1676153920,
|
|
294802
|
+
1439316330,
|
|
294803
|
+
715854006,
|
|
294804
|
+
3033291828,
|
|
294805
|
+
289532110,
|
|
294806
|
+
2706671279,
|
|
294807
|
+
2087905683,
|
|
294808
|
+
3018724369,
|
|
294809
|
+
1668267050,
|
|
294810
|
+
732546397,
|
|
294811
|
+
1947742710,
|
|
294812
|
+
3462151702,
|
|
294813
|
+
2609353502,
|
|
294814
|
+
2950085171,
|
|
294815
|
+
1814351708,
|
|
294816
|
+
2050118529,
|
|
294817
|
+
680887927,
|
|
294818
|
+
999245976,
|
|
294819
|
+
1800124847,
|
|
294820
|
+
3300911131,
|
|
294821
|
+
1713906067,
|
|
294822
|
+
1641548236,
|
|
294823
|
+
4213287313,
|
|
294824
|
+
1216130144,
|
|
294825
|
+
1575780402,
|
|
294826
|
+
4018429277,
|
|
294827
|
+
3917837745,
|
|
294828
|
+
3693486850,
|
|
294829
|
+
3949271944,
|
|
294830
|
+
596196993,
|
|
294831
|
+
3549867205,
|
|
294832
|
+
258830323,
|
|
294833
|
+
2213823033,
|
|
294834
|
+
772490370,
|
|
294835
|
+
2760122372,
|
|
294836
|
+
1774776394,
|
|
294837
|
+
2652871518,
|
|
294838
|
+
566650946,
|
|
294839
|
+
4142492826,
|
|
294840
|
+
1728879713,
|
|
294841
|
+
2882767088,
|
|
294842
|
+
1783734482,
|
|
294843
|
+
3629395816,
|
|
294844
|
+
2517608232,
|
|
294845
|
+
2874225571,
|
|
294846
|
+
1861159788,
|
|
294847
|
+
326777828,
|
|
294848
|
+
3124490320,
|
|
294849
|
+
2130389656,
|
|
294850
|
+
2716951837,
|
|
294851
|
+
967770486,
|
|
294852
|
+
1724537150,
|
|
294853
|
+
2185432712,
|
|
294854
|
+
2364442137,
|
|
294855
|
+
1164943284,
|
|
294856
|
+
2105845187,
|
|
294857
|
+
998989502,
|
|
294858
|
+
3765401048,
|
|
294859
|
+
2244026483,
|
|
294860
|
+
1075463327,
|
|
294861
|
+
1455516326,
|
|
294862
|
+
1322494562,
|
|
294863
|
+
910128902,
|
|
294864
|
+
469688178,
|
|
294865
|
+
1117454909,
|
|
294866
|
+
936433444,
|
|
294867
|
+
3490320968,
|
|
294868
|
+
3675253459,
|
|
294869
|
+
1240580251,
|
|
294870
|
+
122909385,
|
|
294871
|
+
2157517691,
|
|
294872
|
+
634681816,
|
|
294873
|
+
4142456567,
|
|
294874
|
+
3825094682,
|
|
294875
|
+
3061402683,
|
|
294876
|
+
2540495037,
|
|
294877
|
+
79693498,
|
|
294878
|
+
3249098678,
|
|
294879
|
+
1084186820,
|
|
294880
|
+
1583128258,
|
|
294881
|
+
426386531,
|
|
294882
|
+
1761308591,
|
|
294883
|
+
1047286709,
|
|
294884
|
+
322548459,
|
|
294885
|
+
995290223,
|
|
294886
|
+
1845252383,
|
|
294887
|
+
2603652396,
|
|
294888
|
+
3431023940,
|
|
294889
|
+
2942221577,
|
|
294890
|
+
3202600964,
|
|
294891
|
+
3727903485,
|
|
294892
|
+
1712269319,
|
|
294893
|
+
422464435,
|
|
294894
|
+
3234572375,
|
|
294895
|
+
1170764815,
|
|
294896
|
+
3523960633,
|
|
294897
|
+
3117677531,
|
|
294898
|
+
1434042557,
|
|
294899
|
+
442511882,
|
|
294900
|
+
3600875718,
|
|
294901
|
+
1076654713,
|
|
294902
|
+
1738483198,
|
|
294903
|
+
4213154764,
|
|
294904
|
+
2393238008,
|
|
294905
|
+
3677496056,
|
|
294906
|
+
1014306527,
|
|
294907
|
+
4251020053,
|
|
294908
|
+
793779912,
|
|
294909
|
+
2902807211,
|
|
294910
|
+
842905082,
|
|
294911
|
+
4246964064,
|
|
294912
|
+
1395751752,
|
|
294913
|
+
1040244610,
|
|
294914
|
+
2656851899,
|
|
294915
|
+
3396308128,
|
|
294916
|
+
445077038,
|
|
294917
|
+
3742853595,
|
|
294918
|
+
3577915638,
|
|
294919
|
+
679411651,
|
|
294920
|
+
2892444358,
|
|
294921
|
+
2354009459,
|
|
294922
|
+
1767581616,
|
|
294923
|
+
3150600392,
|
|
294924
|
+
3791627101,
|
|
294925
|
+
3102740896,
|
|
294926
|
+
284835224,
|
|
294927
|
+
4246832056,
|
|
294928
|
+
1258075500,
|
|
294929
|
+
768725851,
|
|
294930
|
+
2589189241,
|
|
294931
|
+
3069724005,
|
|
294932
|
+
3532540348,
|
|
294933
|
+
1274779536,
|
|
294934
|
+
3789419226,
|
|
294935
|
+
2764799539,
|
|
294936
|
+
1660621633,
|
|
294937
|
+
3471099624,
|
|
294938
|
+
4011903706,
|
|
294939
|
+
913787905,
|
|
294940
|
+
3497959166,
|
|
294941
|
+
737222580,
|
|
294942
|
+
2514213453,
|
|
294943
|
+
2928710040,
|
|
294944
|
+
3937242737,
|
|
294945
|
+
1804850592,
|
|
294946
|
+
3499020752,
|
|
294947
|
+
2949064160,
|
|
294948
|
+
2386320175,
|
|
294949
|
+
2390070455,
|
|
294950
|
+
2415321851,
|
|
294951
|
+
4061277028,
|
|
294952
|
+
2290661394,
|
|
294953
|
+
2416832540,
|
|
294954
|
+
1336762016,
|
|
294955
|
+
1754252060,
|
|
294956
|
+
3520065937,
|
|
294957
|
+
3014181293,
|
|
294958
|
+
791618072,
|
|
294959
|
+
3188594551,
|
|
294960
|
+
3933548030,
|
|
294961
|
+
2332172193,
|
|
294962
|
+
3852520463,
|
|
294963
|
+
3043980520,
|
|
294964
|
+
413987798,
|
|
294965
|
+
3465142937,
|
|
294966
|
+
3030929376,
|
|
294967
|
+
4245938359,
|
|
294968
|
+
2093235073,
|
|
294969
|
+
3534596313,
|
|
294970
|
+
375366246,
|
|
294971
|
+
2157278981,
|
|
294972
|
+
2479649556,
|
|
294973
|
+
555357303,
|
|
294974
|
+
3870105701,
|
|
294975
|
+
2008414854,
|
|
294976
|
+
3344188149,
|
|
294977
|
+
4221384143,
|
|
294978
|
+
3956125452,
|
|
294979
|
+
2067696032,
|
|
294980
|
+
3594591187,
|
|
294981
|
+
2921233993,
|
|
294982
|
+
2428461,
|
|
294983
|
+
544322398,
|
|
294984
|
+
577241275,
|
|
294985
|
+
1471733935,
|
|
294986
|
+
610547355,
|
|
294987
|
+
4027169054,
|
|
294988
|
+
1432588573,
|
|
294989
|
+
1507829418,
|
|
294990
|
+
2025931657,
|
|
294991
|
+
3646575487,
|
|
294992
|
+
545086370,
|
|
294993
|
+
48609733,
|
|
294994
|
+
2200306550,
|
|
294995
|
+
1653985193,
|
|
294996
|
+
298326376,
|
|
294997
|
+
1316178497,
|
|
294998
|
+
3007786442,
|
|
294999
|
+
2064951626,
|
|
295000
|
+
458293330,
|
|
295001
|
+
2589141269,
|
|
295002
|
+
3591329599,
|
|
295003
|
+
3164325604,
|
|
295004
|
+
727753846,
|
|
295005
|
+
2179363840,
|
|
295006
|
+
146436021,
|
|
295007
|
+
1461446943,
|
|
295008
|
+
4069977195,
|
|
295009
|
+
705550613,
|
|
295010
|
+
3059967265,
|
|
295011
|
+
3887724982,
|
|
295012
|
+
4281599278,
|
|
295013
|
+
3313849956,
|
|
295014
|
+
1404054877,
|
|
295015
|
+
2845806497,
|
|
295016
|
+
146425753,
|
|
295017
|
+
1854211946,
|
|
295018
|
+
1266315497,
|
|
295019
|
+
3048417604,
|
|
295020
|
+
3681880366,
|
|
295021
|
+
3289982499,
|
|
295022
|
+
2909710000,
|
|
295023
|
+
1235738493,
|
|
295024
|
+
2632868024,
|
|
295025
|
+
2414719590,
|
|
295026
|
+
3970600049,
|
|
295027
|
+
1771706367,
|
|
295028
|
+
1449415276,
|
|
295029
|
+
3266420449,
|
|
295030
|
+
422970021,
|
|
295031
|
+
1963543593,
|
|
295032
|
+
2690192192,
|
|
295033
|
+
3826793022,
|
|
295034
|
+
1062508698,
|
|
295035
|
+
1531092325,
|
|
295036
|
+
1804592342,
|
|
295037
|
+
2583117782,
|
|
295038
|
+
2714934279,
|
|
295039
|
+
4024971509,
|
|
295040
|
+
1294809318,
|
|
295041
|
+
4028980673,
|
|
295042
|
+
1289560198,
|
|
295043
|
+
2221992742,
|
|
295044
|
+
1669523910,
|
|
295045
|
+
35572830,
|
|
295046
|
+
157838143,
|
|
295047
|
+
1052438473,
|
|
295048
|
+
1016535060,
|
|
295049
|
+
1802137761,
|
|
295050
|
+
1753167236,
|
|
295051
|
+
1386275462,
|
|
295052
|
+
3080475397,
|
|
295053
|
+
2857371447,
|
|
295054
|
+
1040679964,
|
|
295055
|
+
2145300060,
|
|
295056
|
+
2390574316,
|
|
295057
|
+
1461121720,
|
|
295058
|
+
2956646967,
|
|
295059
|
+
4031777805,
|
|
295060
|
+
4028374788,
|
|
295061
|
+
33600511,
|
|
295062
|
+
2920084762,
|
|
295063
|
+
1018524850,
|
|
295064
|
+
629373528,
|
|
295065
|
+
3691585981,
|
|
295066
|
+
3515945977,
|
|
295067
|
+
2091462646,
|
|
295068
|
+
2486323059,
|
|
295069
|
+
586499841,
|
|
295070
|
+
988145025,
|
|
295071
|
+
935516892,
|
|
295072
|
+
3367335476,
|
|
295073
|
+
2599673255,
|
|
295074
|
+
2839830854,
|
|
295075
|
+
265290510,
|
|
295076
|
+
3972581182,
|
|
295077
|
+
2759138881,
|
|
295078
|
+
3795373465,
|
|
295079
|
+
1005194799,
|
|
295080
|
+
847297441,
|
|
295081
|
+
406762289,
|
|
295082
|
+
1314163512,
|
|
295083
|
+
1332590856,
|
|
295084
|
+
1866599683,
|
|
295085
|
+
4127851711,
|
|
295086
|
+
750260880,
|
|
295087
|
+
613907577,
|
|
295088
|
+
1450815602,
|
|
295089
|
+
3165620655,
|
|
295090
|
+
3734664991,
|
|
295091
|
+
3650291728,
|
|
295092
|
+
3012275730,
|
|
295093
|
+
3704569646,
|
|
295094
|
+
1427272223,
|
|
295095
|
+
778793252,
|
|
295096
|
+
1343938022,
|
|
295097
|
+
2676280711,
|
|
295098
|
+
2052605720,
|
|
295099
|
+
1946737175,
|
|
295100
|
+
3164576444,
|
|
295101
|
+
3914038668,
|
|
295102
|
+
3967478842,
|
|
295103
|
+
3682934266,
|
|
295104
|
+
1661551462,
|
|
295105
|
+
3294938066,
|
|
295106
|
+
4011595847,
|
|
295107
|
+
840292616,
|
|
295108
|
+
3712170807,
|
|
295109
|
+
616741398,
|
|
295110
|
+
312560963,
|
|
295111
|
+
711312465,
|
|
295112
|
+
1351876610,
|
|
295113
|
+
322626781,
|
|
295114
|
+
1910503582,
|
|
295115
|
+
271666773,
|
|
295116
|
+
2175563734,
|
|
295117
|
+
1594956187,
|
|
295118
|
+
70604529,
|
|
295119
|
+
3617834859,
|
|
295120
|
+
1007753275,
|
|
295121
|
+
1495573769,
|
|
295122
|
+
4069517037,
|
|
295123
|
+
2549218298,
|
|
295124
|
+
2663038764,
|
|
295125
|
+
504708206,
|
|
295126
|
+
2263041392,
|
|
295127
|
+
3941167025,
|
|
295128
|
+
2249088522,
|
|
295129
|
+
1514023603,
|
|
295130
|
+
1998579484,
|
|
295131
|
+
1312622330,
|
|
295132
|
+
694541497,
|
|
295133
|
+
2582060303,
|
|
295134
|
+
2151582166,
|
|
295135
|
+
1382467621,
|
|
295136
|
+
776784248,
|
|
295137
|
+
2618340202,
|
|
295138
|
+
3323268794,
|
|
295139
|
+
2497899128,
|
|
295140
|
+
2784771155,
|
|
295141
|
+
503983604,
|
|
295142
|
+
4076293799,
|
|
295143
|
+
907881277,
|
|
295144
|
+
423175695,
|
|
295145
|
+
432175456,
|
|
295146
|
+
1378068232,
|
|
295147
|
+
4145222326,
|
|
295148
|
+
3954048622,
|
|
295149
|
+
3938656102,
|
|
295150
|
+
3820766613,
|
|
295151
|
+
2793130115,
|
|
295152
|
+
2977904593,
|
|
295153
|
+
26017576,
|
|
295154
|
+
3274890735,
|
|
295155
|
+
3194772133,
|
|
295156
|
+
1700274565,
|
|
295157
|
+
1756076034,
|
|
295158
|
+
4006520079,
|
|
295159
|
+
3677328699,
|
|
295160
|
+
720338349,
|
|
295161
|
+
1533947780,
|
|
295162
|
+
354530856,
|
|
295163
|
+
688349552,
|
|
295164
|
+
3973924725,
|
|
295165
|
+
1637815568,
|
|
295166
|
+
332179504,
|
|
295167
|
+
3949051286,
|
|
295168
|
+
53804574,
|
|
295169
|
+
2852348879,
|
|
295170
|
+
3044236432,
|
|
295171
|
+
1282449977,
|
|
295172
|
+
3583942155,
|
|
295173
|
+
3416972820,
|
|
295174
|
+
4006381244,
|
|
295175
|
+
1617046695,
|
|
295176
|
+
2628476075,
|
|
295177
|
+
3002303598,
|
|
295178
|
+
1686838959,
|
|
295179
|
+
431878346,
|
|
295180
|
+
2686675385,
|
|
295181
|
+
1700445008,
|
|
295182
|
+
1080580658,
|
|
295183
|
+
1009431731,
|
|
295184
|
+
832498133,
|
|
295185
|
+
3223435511,
|
|
295186
|
+
2605976345,
|
|
295187
|
+
2271191193,
|
|
295188
|
+
2516031870,
|
|
295189
|
+
1648197032,
|
|
295190
|
+
4164389018,
|
|
295191
|
+
2548247927,
|
|
295192
|
+
300782431,
|
|
295193
|
+
375919233,
|
|
295194
|
+
238389289,
|
|
295195
|
+
3353747414,
|
|
295196
|
+
2531188641,
|
|
295197
|
+
2019080857,
|
|
295198
|
+
1475708069,
|
|
295199
|
+
455242339,
|
|
295200
|
+
2609103871,
|
|
295201
|
+
448939670,
|
|
295202
|
+
3451063019,
|
|
295203
|
+
1395535956,
|
|
295204
|
+
2413381860,
|
|
295205
|
+
1841049896,
|
|
295206
|
+
1491858159,
|
|
295207
|
+
885456874,
|
|
295208
|
+
4264095073,
|
|
295209
|
+
4001119347,
|
|
295210
|
+
1565136089,
|
|
295211
|
+
3898914787,
|
|
295212
|
+
1108368660,
|
|
295213
|
+
540939232,
|
|
295214
|
+
1173283510,
|
|
295215
|
+
2745871338,
|
|
295216
|
+
3681308437,
|
|
295217
|
+
4207628240,
|
|
295218
|
+
3343053890,
|
|
295219
|
+
4016749493,
|
|
295220
|
+
1699691293,
|
|
295221
|
+
1103962373,
|
|
295222
|
+
3625875870,
|
|
295223
|
+
2256883143,
|
|
295224
|
+
3830138730,
|
|
295225
|
+
1031889488,
|
|
295226
|
+
3479347698,
|
|
295227
|
+
1535977030,
|
|
295228
|
+
4236805024,
|
|
295229
|
+
3251091107,
|
|
295230
|
+
2132092099,
|
|
295231
|
+
1774941330,
|
|
295232
|
+
1199868427,
|
|
295233
|
+
1452454533,
|
|
295234
|
+
157007616,
|
|
295235
|
+
2904115357,
|
|
295236
|
+
342012276,
|
|
295237
|
+
595725824,
|
|
295238
|
+
1480756522,
|
|
295239
|
+
206960106,
|
|
295240
|
+
497939518,
|
|
295241
|
+
591360097,
|
|
295242
|
+
863170706,
|
|
295243
|
+
2375253569,
|
|
295244
|
+
3596610801,
|
|
295245
|
+
1814182875,
|
|
295246
|
+
2094937945,
|
|
295247
|
+
3421402208,
|
|
295248
|
+
1082520231,
|
|
295249
|
+
3463918190,
|
|
295250
|
+
2785509508,
|
|
295251
|
+
435703966,
|
|
295252
|
+
3908032597,
|
|
295253
|
+
1641649973,
|
|
295254
|
+
2842273706,
|
|
295255
|
+
3305899714,
|
|
295256
|
+
1510255612,
|
|
295257
|
+
2148256476,
|
|
295258
|
+
2655287854,
|
|
295259
|
+
3276092548,
|
|
295260
|
+
4258621189,
|
|
295261
|
+
236887753,
|
|
295262
|
+
3681803219,
|
|
295263
|
+
274041037,
|
|
295264
|
+
1734335097,
|
|
295265
|
+
3815195456,
|
|
295266
|
+
3317970021,
|
|
295267
|
+
1899903192,
|
|
295268
|
+
1026095262,
|
|
295269
|
+
4050517792,
|
|
295270
|
+
356393447,
|
|
295271
|
+
2410691914,
|
|
295272
|
+
3873677099,
|
|
295273
|
+
3682840055,
|
|
295274
|
+
3913112168,
|
|
295275
|
+
2491498743,
|
|
295276
|
+
4132185628,
|
|
295277
|
+
2489919796,
|
|
295278
|
+
1091903735,
|
|
295279
|
+
1979897079,
|
|
295280
|
+
3170134830,
|
|
295281
|
+
3567386728,
|
|
295282
|
+
3557303409,
|
|
295283
|
+
857797738,
|
|
295284
|
+
1136121015,
|
|
295285
|
+
1342202287,
|
|
295286
|
+
507115054,
|
|
295287
|
+
2535736646,
|
|
295288
|
+
337727348,
|
|
295289
|
+
3213592640,
|
|
295290
|
+
1301675037,
|
|
295291
|
+
2528481711,
|
|
295292
|
+
1895095763,
|
|
295293
|
+
1721773893,
|
|
295294
|
+
3216771564,
|
|
295295
|
+
62756741,
|
|
295296
|
+
2142006736,
|
|
295297
|
+
835421444,
|
|
295298
|
+
2531993523,
|
|
295299
|
+
1442658625,
|
|
295300
|
+
3659876326,
|
|
295301
|
+
2882144922,
|
|
295302
|
+
676362277,
|
|
295303
|
+
1392781812,
|
|
295304
|
+
170690266,
|
|
295305
|
+
3921047035,
|
|
295306
|
+
1759253602,
|
|
295307
|
+
3611846912,
|
|
295308
|
+
1745797284,
|
|
295309
|
+
664899054,
|
|
295310
|
+
1329594018,
|
|
295311
|
+
3901205900,
|
|
295312
|
+
3045908486,
|
|
295313
|
+
2062866102,
|
|
295314
|
+
2865634940,
|
|
295315
|
+
3543621612,
|
|
295316
|
+
3464012697,
|
|
295317
|
+
1080764994,
|
|
295318
|
+
553557557,
|
|
295319
|
+
3656615353,
|
|
295320
|
+
3996768171,
|
|
295321
|
+
991055499,
|
|
295322
|
+
499776247,
|
|
295323
|
+
1265440854,
|
|
295324
|
+
648242737,
|
|
295325
|
+
3940784050,
|
|
295326
|
+
980351604,
|
|
295327
|
+
3713745714,
|
|
295328
|
+
1749149687,
|
|
295329
|
+
3396870395,
|
|
295330
|
+
4211799374,
|
|
295331
|
+
3640570775,
|
|
295332
|
+
1161844396,
|
|
295333
|
+
3125318951,
|
|
295334
|
+
1431517754,
|
|
295335
|
+
545492359,
|
|
295336
|
+
4268468663,
|
|
295337
|
+
3499529547,
|
|
295338
|
+
1437099964,
|
|
295339
|
+
2702547544,
|
|
295340
|
+
3433638243,
|
|
295341
|
+
2581715763,
|
|
295342
|
+
2787789398,
|
|
295343
|
+
1060185593,
|
|
295344
|
+
1593081372,
|
|
295345
|
+
2418618748,
|
|
295346
|
+
4260947970,
|
|
295347
|
+
69676912,
|
|
295348
|
+
2159744348,
|
|
295349
|
+
86519011,
|
|
295350
|
+
2512459080,
|
|
295351
|
+
3838209314,
|
|
295352
|
+
1220612927,
|
|
295353
|
+
3339683548,
|
|
295354
|
+
133810670,
|
|
295355
|
+
1090789135,
|
|
295356
|
+
1078426020,
|
|
295357
|
+
1569222167,
|
|
295358
|
+
845107691,
|
|
295359
|
+
3583754449,
|
|
295360
|
+
4072456591,
|
|
295361
|
+
1091646820,
|
|
295362
|
+
628848692,
|
|
295363
|
+
1613405280,
|
|
295364
|
+
3757631651,
|
|
295365
|
+
526609435,
|
|
295366
|
+
236106946,
|
|
295367
|
+
48312990,
|
|
295368
|
+
2942717905,
|
|
295369
|
+
3402727701,
|
|
295370
|
+
1797494240,
|
|
295371
|
+
859738849,
|
|
295372
|
+
992217954,
|
|
295373
|
+
4005476642,
|
|
295374
|
+
2243076622,
|
|
295375
|
+
3870952857,
|
|
295376
|
+
3732016268,
|
|
295377
|
+
765654824,
|
|
295378
|
+
3490871365,
|
|
295379
|
+
2511836413,
|
|
295380
|
+
1685915746,
|
|
295381
|
+
3888969200,
|
|
295382
|
+
1414112111,
|
|
295383
|
+
2273134842,
|
|
295384
|
+
3281911079,
|
|
295385
|
+
4080962846,
|
|
295386
|
+
172450625,
|
|
295387
|
+
2569994100,
|
|
295388
|
+
980381355,
|
|
295389
|
+
4109958455,
|
|
295390
|
+
2819808352,
|
|
295391
|
+
2716589560,
|
|
295392
|
+
2568741196,
|
|
295393
|
+
3681446669,
|
|
295394
|
+
3329971472,
|
|
295395
|
+
1835478071,
|
|
295396
|
+
660984891,
|
|
295397
|
+
3704678404,
|
|
295398
|
+
4045999559,
|
|
295399
|
+
3422617507,
|
|
295400
|
+
3040415634,
|
|
295401
|
+
1762651403,
|
|
295402
|
+
1719377915,
|
|
295403
|
+
3470491036,
|
|
295404
|
+
2693910283,
|
|
295405
|
+
3642056355,
|
|
295406
|
+
3138596744,
|
|
295407
|
+
1364962596,
|
|
295408
|
+
2073328063,
|
|
295409
|
+
1983633131,
|
|
295410
|
+
926494387,
|
|
295411
|
+
3423689081,
|
|
295412
|
+
2150032023,
|
|
295413
|
+
4096667949,
|
|
295414
|
+
1749200295,
|
|
295415
|
+
3328846651,
|
|
295416
|
+
309677260,
|
|
295417
|
+
2016342300,
|
|
295418
|
+
1779581495,
|
|
295419
|
+
3079819751,
|
|
295420
|
+
111262694,
|
|
295421
|
+
1274766160,
|
|
295422
|
+
443224088,
|
|
295423
|
+
298511866,
|
|
295424
|
+
1025883608,
|
|
295425
|
+
3806446537,
|
|
295426
|
+
1145181785,
|
|
295427
|
+
168956806,
|
|
295428
|
+
3641502830,
|
|
295429
|
+
3584813610,
|
|
295430
|
+
1689216846,
|
|
295431
|
+
3666258015,
|
|
295432
|
+
3200248200,
|
|
295433
|
+
1692713982,
|
|
295434
|
+
2646376535,
|
|
295435
|
+
4042768518,
|
|
295436
|
+
1618508792,
|
|
295437
|
+
1610833997,
|
|
295438
|
+
3523052358,
|
|
295439
|
+
4130873264,
|
|
295440
|
+
2001055236,
|
|
295441
|
+
3610705100,
|
|
295442
|
+
2202168115,
|
|
295443
|
+
4028541809,
|
|
295444
|
+
2961195399,
|
|
295445
|
+
1006657119,
|
|
295446
|
+
2006996926,
|
|
295447
|
+
3186142756,
|
|
295448
|
+
1430667929,
|
|
295449
|
+
3210227297,
|
|
295450
|
+
1314452623,
|
|
295451
|
+
4074634658,
|
|
295452
|
+
4101304120,
|
|
295453
|
+
2273951170,
|
|
295454
|
+
1399257539,
|
|
295455
|
+
3367210612,
|
|
295456
|
+
3027628629,
|
|
295457
|
+
1190975929,
|
|
295458
|
+
2062231137,
|
|
295459
|
+
2333990788,
|
|
295460
|
+
2221543033,
|
|
295461
|
+
2438960610,
|
|
295462
|
+
1181637006,
|
|
295463
|
+
548689776,
|
|
295464
|
+
2362791313,
|
|
295465
|
+
3372408396,
|
|
295466
|
+
3104550113,
|
|
295467
|
+
3145860560,
|
|
295468
|
+
296247880,
|
|
295469
|
+
1970579870,
|
|
295470
|
+
3078560182,
|
|
295471
|
+
3769228297,
|
|
295472
|
+
1714227617,
|
|
295473
|
+
3291629107,
|
|
295474
|
+
3898220290,
|
|
295475
|
+
166772364,
|
|
295476
|
+
1251581989,
|
|
295477
|
+
493813264,
|
|
295478
|
+
448347421,
|
|
295479
|
+
195405023,
|
|
295480
|
+
2709975567,
|
|
295481
|
+
677966185,
|
|
295482
|
+
3703036547,
|
|
295483
|
+
1463355134,
|
|
295484
|
+
2715995803,
|
|
295485
|
+
1338867538,
|
|
295486
|
+
1343315457,
|
|
295487
|
+
2802222074,
|
|
295488
|
+
2684532164,
|
|
295489
|
+
233230375,
|
|
295490
|
+
2599980071,
|
|
295491
|
+
2000651841,
|
|
295492
|
+
3277868038,
|
|
295493
|
+
1638401717,
|
|
295494
|
+
4028070440,
|
|
295495
|
+
3237316320,
|
|
295496
|
+
6314154,
|
|
295497
|
+
819756386,
|
|
295498
|
+
300326615,
|
|
295499
|
+
590932579,
|
|
295500
|
+
1405279636,
|
|
295501
|
+
3267499572,
|
|
295502
|
+
3150704214,
|
|
295503
|
+
2428286686,
|
|
295504
|
+
3959192993,
|
|
295505
|
+
3461946742,
|
|
295506
|
+
1862657033,
|
|
295507
|
+
1266418056,
|
|
295508
|
+
963775037,
|
|
295509
|
+
2089974820,
|
|
295510
|
+
2263052895,
|
|
295511
|
+
1917689273,
|
|
295512
|
+
448879540,
|
|
295513
|
+
3550394620,
|
|
295514
|
+
3981727096,
|
|
295515
|
+
150775221,
|
|
295516
|
+
3627908307,
|
|
295517
|
+
1303187396,
|
|
295518
|
+
508620638,
|
|
295519
|
+
2975983352,
|
|
295520
|
+
2726630617,
|
|
295521
|
+
1817252668,
|
|
295522
|
+
1876281319,
|
|
295523
|
+
1457606340,
|
|
295524
|
+
908771278,
|
|
295525
|
+
3720792119,
|
|
295526
|
+
3617206836,
|
|
295527
|
+
2455994898,
|
|
295528
|
+
1729034894,
|
|
295529
|
+
1080033504,
|
|
295530
|
+
976866871,
|
|
295531
|
+
3556439503,
|
|
295532
|
+
2881648439,
|
|
295533
|
+
1522871579,
|
|
295534
|
+
1555064734,
|
|
295535
|
+
1336096578,
|
|
295536
|
+
3548522304,
|
|
295537
|
+
2579274686,
|
|
295538
|
+
3574697629,
|
|
295539
|
+
3205460757,
|
|
295540
|
+
3593280638,
|
|
295541
|
+
3338716283,
|
|
295542
|
+
3079412587,
|
|
295543
|
+
564236357,
|
|
295544
|
+
2993598910,
|
|
295545
|
+
1781952180,
|
|
295546
|
+
1464380207,
|
|
295547
|
+
3163844217,
|
|
295548
|
+
3332601554,
|
|
295549
|
+
1699332808,
|
|
295550
|
+
1393555694,
|
|
295551
|
+
1183702653,
|
|
295552
|
+
3581086237,
|
|
295553
|
+
1288719814,
|
|
295554
|
+
691649499,
|
|
295555
|
+
2847557200,
|
|
295556
|
+
2895455976,
|
|
295557
|
+
3193889540,
|
|
295558
|
+
2717570544,
|
|
295559
|
+
1781354906,
|
|
295560
|
+
1676643554,
|
|
295561
|
+
2592534050,
|
|
295562
|
+
3230253752,
|
|
295563
|
+
1126444790,
|
|
295564
|
+
2770207658,
|
|
295565
|
+
2633158820,
|
|
295566
|
+
2210423226,
|
|
295567
|
+
2615765581,
|
|
295568
|
+
2414155088,
|
|
295569
|
+
3127139286,
|
|
295570
|
+
673620729,
|
|
295571
|
+
2805611233,
|
|
295572
|
+
1269405062,
|
|
295573
|
+
4015350505,
|
|
295574
|
+
3341807571,
|
|
295575
|
+
4149409754,
|
|
295576
|
+
1057255273,
|
|
295577
|
+
2012875353,
|
|
295578
|
+
2162469141,
|
|
295579
|
+
2276492801,
|
|
295580
|
+
2601117357,
|
|
295581
|
+
993977747,
|
|
295582
|
+
3918593370,
|
|
295583
|
+
2654263191,
|
|
295584
|
+
753973209,
|
|
295585
|
+
36408145,
|
|
295586
|
+
2530585658,
|
|
295587
|
+
25011837,
|
|
295588
|
+
3520020182,
|
|
295589
|
+
2088578344,
|
|
295590
|
+
530523599,
|
|
295591
|
+
2918365339,
|
|
295592
|
+
1524020338,
|
|
295593
|
+
1518925132,
|
|
295594
|
+
3760827505,
|
|
295595
|
+
3759777254,
|
|
295596
|
+
1202760957,
|
|
295597
|
+
3985898139,
|
|
295598
|
+
3906192525,
|
|
295599
|
+
674977740,
|
|
295600
|
+
4174734889,
|
|
295601
|
+
2031300136,
|
|
295602
|
+
2019492241,
|
|
295603
|
+
3983892565,
|
|
295604
|
+
4153806404,
|
|
295605
|
+
3822280332,
|
|
295606
|
+
352677332,
|
|
295607
|
+
2297720250,
|
|
295608
|
+
60907813,
|
|
295609
|
+
90501309,
|
|
295610
|
+
3286998549,
|
|
295611
|
+
1016092578,
|
|
295612
|
+
2535922412,
|
|
295613
|
+
2839152426,
|
|
295614
|
+
457141659,
|
|
295615
|
+
509813237,
|
|
295616
|
+
4120667899,
|
|
295617
|
+
652014361,
|
|
295618
|
+
1966332200,
|
|
295619
|
+
2975202805,
|
|
295620
|
+
55981186,
|
|
295621
|
+
2327461051,
|
|
295622
|
+
676427537,
|
|
295623
|
+
3255491064,
|
|
295624
|
+
2882294119,
|
|
295625
|
+
3433927263,
|
|
295626
|
+
1307055953,
|
|
295627
|
+
942726286,
|
|
295628
|
+
933058658,
|
|
295629
|
+
2468411793,
|
|
295630
|
+
3933900994,
|
|
295631
|
+
4215176142,
|
|
295632
|
+
1361170020,
|
|
295633
|
+
2001714738,
|
|
295634
|
+
2830558078,
|
|
295635
|
+
3274259782,
|
|
295636
|
+
1222529897,
|
|
295637
|
+
1679025792,
|
|
295638
|
+
2729314320,
|
|
295639
|
+
3714953764,
|
|
295640
|
+
1770335741,
|
|
295641
|
+
151462246,
|
|
295642
|
+
3013232138,
|
|
295643
|
+
1682292957,
|
|
295644
|
+
1483529935,
|
|
295645
|
+
471910574,
|
|
295646
|
+
1539241949,
|
|
295647
|
+
458788160,
|
|
295648
|
+
3436315007,
|
|
295649
|
+
1807016891,
|
|
295650
|
+
3718408830,
|
|
295651
|
+
978976581,
|
|
295652
|
+
1043663428,
|
|
295653
|
+
3165965781,
|
|
295654
|
+
1927990952,
|
|
295655
|
+
4200891579,
|
|
295656
|
+
2372276910,
|
|
295657
|
+
3208408903,
|
|
295658
|
+
3533431907,
|
|
295659
|
+
1412390302,
|
|
295660
|
+
2931980059,
|
|
295661
|
+
4132332400,
|
|
295662
|
+
1947078029,
|
|
295663
|
+
3881505623,
|
|
295664
|
+
4168226417,
|
|
295665
|
+
2941484381,
|
|
295666
|
+
1077988104,
|
|
295667
|
+
1320477388,
|
|
295668
|
+
886195818,
|
|
295669
|
+
18198404,
|
|
295670
|
+
3786409000,
|
|
295671
|
+
2509781533,
|
|
295672
|
+
112762804,
|
|
295673
|
+
3463356488,
|
|
295674
|
+
1866414978,
|
|
295675
|
+
891333506,
|
|
295676
|
+
18488651,
|
|
295677
|
+
661792760,
|
|
295678
|
+
1628790961,
|
|
295679
|
+
3885187036,
|
|
295680
|
+
3141171499,
|
|
295681
|
+
876946877,
|
|
295682
|
+
2693282273,
|
|
295683
|
+
1372485963,
|
|
295684
|
+
791857591,
|
|
295685
|
+
2686433993,
|
|
295686
|
+
3759982718,
|
|
295687
|
+
3167212022,
|
|
295688
|
+
3472953795,
|
|
295689
|
+
2716379847,
|
|
295690
|
+
445679433,
|
|
295691
|
+
3561995674,
|
|
295692
|
+
3504004811,
|
|
295693
|
+
3574258232,
|
|
295694
|
+
54117162,
|
|
295695
|
+
3331405415,
|
|
295696
|
+
2381918588,
|
|
295697
|
+
3769707343,
|
|
295698
|
+
4154350007,
|
|
295699
|
+
1140177722,
|
|
295700
|
+
4074052095,
|
|
295701
|
+
668550556,
|
|
295702
|
+
3214352940,
|
|
295703
|
+
367459370,
|
|
295704
|
+
261225585,
|
|
295705
|
+
2610173221,
|
|
295706
|
+
4209349473,
|
|
295707
|
+
3468074219,
|
|
295708
|
+
3265815641,
|
|
295709
|
+
314222801,
|
|
295710
|
+
3066103646,
|
|
295711
|
+
3808782860,
|
|
295712
|
+
282218597,
|
|
295713
|
+
3406013506,
|
|
295714
|
+
3773591054,
|
|
295715
|
+
379116347,
|
|
295716
|
+
1285071038,
|
|
295717
|
+
846784868,
|
|
295718
|
+
2669647154,
|
|
295719
|
+
3771962079,
|
|
295720
|
+
3550491691,
|
|
295721
|
+
2305946142,
|
|
295722
|
+
453669953,
|
|
295723
|
+
1268987020,
|
|
295724
|
+
3317592352,
|
|
295725
|
+
3279303384,
|
|
295726
|
+
3744833421,
|
|
295727
|
+
2610507566,
|
|
295728
|
+
3859509063,
|
|
295729
|
+
266596637,
|
|
295730
|
+
3847019092,
|
|
295731
|
+
517658769,
|
|
295732
|
+
3462560207,
|
|
295733
|
+
3443424879,
|
|
295734
|
+
370717030,
|
|
295735
|
+
4247526661,
|
|
295736
|
+
2224018117,
|
|
295737
|
+
4143653529,
|
|
295738
|
+
4112773975,
|
|
295739
|
+
2788324899,
|
|
295740
|
+
2477274417,
|
|
295741
|
+
1456262402,
|
|
295742
|
+
2901442914,
|
|
295743
|
+
1517677493,
|
|
295744
|
+
1846949527,
|
|
295745
|
+
2295493580,
|
|
295746
|
+
3734397586,
|
|
295747
|
+
2176403920,
|
|
295748
|
+
1280348187,
|
|
295749
|
+
1908823572,
|
|
295750
|
+
3871786941,
|
|
295751
|
+
846861322,
|
|
295752
|
+
1172426758,
|
|
295753
|
+
3287448474,
|
|
295754
|
+
3383383037,
|
|
295755
|
+
1655181056,
|
|
295756
|
+
3139813346,
|
|
295757
|
+
901632758,
|
|
295758
|
+
1897031941,
|
|
295759
|
+
2986607138,
|
|
295760
|
+
3066810236,
|
|
295761
|
+
3447102507,
|
|
295762
|
+
1393639104,
|
|
295763
|
+
373351379,
|
|
295764
|
+
950779232,
|
|
295765
|
+
625454576,
|
|
295766
|
+
3124240540,
|
|
295767
|
+
4148612726,
|
|
295768
|
+
2007998917,
|
|
295769
|
+
544563296,
|
|
295770
|
+
2244738638,
|
|
295771
|
+
2330496472,
|
|
295772
|
+
2058025392,
|
|
295773
|
+
1291430526,
|
|
295774
|
+
424198748,
|
|
295775
|
+
50039436,
|
|
295776
|
+
29584100,
|
|
295777
|
+
3605783033,
|
|
295778
|
+
2429876329,
|
|
295779
|
+
2791104160,
|
|
295780
|
+
1057563949,
|
|
295781
|
+
3255363231,
|
|
295782
|
+
3075367218,
|
|
295783
|
+
3463963227,
|
|
295784
|
+
1469046755,
|
|
295785
|
+
985887462
|
|
295786
|
+
];
|
|
295787
|
+
var C_ORIG = [
|
|
295788
|
+
1332899944,
|
|
295789
|
+
1700884034,
|
|
295790
|
+
1701343084,
|
|
295791
|
+
1684370003,
|
|
295792
|
+
1668446532,
|
|
295793
|
+
1869963892
|
|
295794
|
+
];
|
|
295795
|
+
function _encipher(lr, off, P, S) {
|
|
295796
|
+
var n, l = lr[off], r = lr[off + 1];
|
|
295797
|
+
l ^= P[0];
|
|
295798
|
+
n = S[l >>> 24];
|
|
295799
|
+
n += S[256 | l >> 16 & 255];
|
|
295800
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295801
|
+
n += S[768 | l & 255];
|
|
295802
|
+
r ^= n ^ P[1];
|
|
295803
|
+
n = S[r >>> 24];
|
|
295804
|
+
n += S[256 | r >> 16 & 255];
|
|
295805
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295806
|
+
n += S[768 | r & 255];
|
|
295807
|
+
l ^= n ^ P[2];
|
|
295808
|
+
n = S[l >>> 24];
|
|
295809
|
+
n += S[256 | l >> 16 & 255];
|
|
295810
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295811
|
+
n += S[768 | l & 255];
|
|
295812
|
+
r ^= n ^ P[3];
|
|
295813
|
+
n = S[r >>> 24];
|
|
295814
|
+
n += S[256 | r >> 16 & 255];
|
|
295815
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295816
|
+
n += S[768 | r & 255];
|
|
295817
|
+
l ^= n ^ P[4];
|
|
295818
|
+
n = S[l >>> 24];
|
|
295819
|
+
n += S[256 | l >> 16 & 255];
|
|
295820
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295821
|
+
n += S[768 | l & 255];
|
|
295822
|
+
r ^= n ^ P[5];
|
|
295823
|
+
n = S[r >>> 24];
|
|
295824
|
+
n += S[256 | r >> 16 & 255];
|
|
295825
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295826
|
+
n += S[768 | r & 255];
|
|
295827
|
+
l ^= n ^ P[6];
|
|
295828
|
+
n = S[l >>> 24];
|
|
295829
|
+
n += S[256 | l >> 16 & 255];
|
|
295830
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295831
|
+
n += S[768 | l & 255];
|
|
295832
|
+
r ^= n ^ P[7];
|
|
295833
|
+
n = S[r >>> 24];
|
|
295834
|
+
n += S[256 | r >> 16 & 255];
|
|
295835
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295836
|
+
n += S[768 | r & 255];
|
|
295837
|
+
l ^= n ^ P[8];
|
|
295838
|
+
n = S[l >>> 24];
|
|
295839
|
+
n += S[256 | l >> 16 & 255];
|
|
295840
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295841
|
+
n += S[768 | l & 255];
|
|
295842
|
+
r ^= n ^ P[9];
|
|
295843
|
+
n = S[r >>> 24];
|
|
295844
|
+
n += S[256 | r >> 16 & 255];
|
|
295845
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295846
|
+
n += S[768 | r & 255];
|
|
295847
|
+
l ^= n ^ P[10];
|
|
295848
|
+
n = S[l >>> 24];
|
|
295849
|
+
n += S[256 | l >> 16 & 255];
|
|
295850
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295851
|
+
n += S[768 | l & 255];
|
|
295852
|
+
r ^= n ^ P[11];
|
|
295853
|
+
n = S[r >>> 24];
|
|
295854
|
+
n += S[256 | r >> 16 & 255];
|
|
295855
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295856
|
+
n += S[768 | r & 255];
|
|
295857
|
+
l ^= n ^ P[12];
|
|
295858
|
+
n = S[l >>> 24];
|
|
295859
|
+
n += S[256 | l >> 16 & 255];
|
|
295860
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295861
|
+
n += S[768 | l & 255];
|
|
295862
|
+
r ^= n ^ P[13];
|
|
295863
|
+
n = S[r >>> 24];
|
|
295864
|
+
n += S[256 | r >> 16 & 255];
|
|
295865
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295866
|
+
n += S[768 | r & 255];
|
|
295867
|
+
l ^= n ^ P[14];
|
|
295868
|
+
n = S[l >>> 24];
|
|
295869
|
+
n += S[256 | l >> 16 & 255];
|
|
295870
|
+
n ^= S[512 | l >> 8 & 255];
|
|
295871
|
+
n += S[768 | l & 255];
|
|
295872
|
+
r ^= n ^ P[15];
|
|
295873
|
+
n = S[r >>> 24];
|
|
295874
|
+
n += S[256 | r >> 16 & 255];
|
|
295875
|
+
n ^= S[512 | r >> 8 & 255];
|
|
295876
|
+
n += S[768 | r & 255];
|
|
295877
|
+
l ^= n ^ P[16];
|
|
295878
|
+
lr[off] = r ^ P[BLOWFISH_NUM_ROUNDS + 1];
|
|
295879
|
+
lr[off + 1] = l;
|
|
295880
|
+
return lr;
|
|
295881
|
+
}
|
|
295882
|
+
function _streamtoword(data, offp) {
|
|
295883
|
+
for (var i = 0, word = 0;i < 4; ++i)
|
|
295884
|
+
word = word << 8 | data[offp] & 255, offp = (offp + 1) % data.length;
|
|
295885
|
+
return { key: word, offp };
|
|
295886
|
+
}
|
|
295887
|
+
function _key(key, P, S) {
|
|
295888
|
+
var offset = 0, lr = [0, 0], plen = P.length, slen = S.length, sw;
|
|
295889
|
+
for (var i = 0;i < plen; i++)
|
|
295890
|
+
sw = _streamtoword(key, offset), offset = sw.offp, P[i] = P[i] ^ sw.key;
|
|
295891
|
+
for (i = 0;i < plen; i += 2)
|
|
295892
|
+
lr = _encipher(lr, 0, P, S), P[i] = lr[0], P[i + 1] = lr[1];
|
|
295893
|
+
for (i = 0;i < slen; i += 2)
|
|
295894
|
+
lr = _encipher(lr, 0, P, S), S[i] = lr[0], S[i + 1] = lr[1];
|
|
295895
|
+
}
|
|
295896
|
+
function _ekskey(data, key, P, S) {
|
|
295897
|
+
var offp = 0, lr = [0, 0], plen = P.length, slen = S.length, sw;
|
|
295898
|
+
for (var i = 0;i < plen; i++)
|
|
295899
|
+
sw = _streamtoword(key, offp), offp = sw.offp, P[i] = P[i] ^ sw.key;
|
|
295900
|
+
offp = 0;
|
|
295901
|
+
for (i = 0;i < plen; i += 2)
|
|
295902
|
+
sw = _streamtoword(data, offp), offp = sw.offp, lr[0] ^= sw.key, sw = _streamtoword(data, offp), offp = sw.offp, lr[1] ^= sw.key, lr = _encipher(lr, 0, P, S), P[i] = lr[0], P[i + 1] = lr[1];
|
|
295903
|
+
for (i = 0;i < slen; i += 2)
|
|
295904
|
+
sw = _streamtoword(data, offp), offp = sw.offp, lr[0] ^= sw.key, sw = _streamtoword(data, offp), offp = sw.offp, lr[1] ^= sw.key, lr = _encipher(lr, 0, P, S), S[i] = lr[0], S[i + 1] = lr[1];
|
|
295905
|
+
}
|
|
295906
|
+
function _crypt(b, salt, rounds, callback, progressCallback) {
|
|
295907
|
+
var cdata = C_ORIG.slice(), clen = cdata.length, err;
|
|
295908
|
+
if (rounds < 4 || rounds > 31) {
|
|
295909
|
+
err = Error("Illegal number of rounds (4-31): " + rounds);
|
|
295910
|
+
if (callback) {
|
|
295911
|
+
nextTick(callback.bind(this, err));
|
|
295912
|
+
return;
|
|
295913
|
+
} else
|
|
295914
|
+
throw err;
|
|
295915
|
+
}
|
|
295916
|
+
if (salt.length !== BCRYPT_SALT_LEN) {
|
|
295917
|
+
err = Error("Illegal salt length: " + salt.length + " != " + BCRYPT_SALT_LEN);
|
|
295918
|
+
if (callback) {
|
|
295919
|
+
nextTick(callback.bind(this, err));
|
|
295920
|
+
return;
|
|
295921
|
+
} else
|
|
295922
|
+
throw err;
|
|
295923
|
+
}
|
|
295924
|
+
rounds = 1 << rounds >>> 0;
|
|
295925
|
+
var P, S, i = 0, j;
|
|
295926
|
+
if (Int32Array) {
|
|
295927
|
+
P = new Int32Array(P_ORIG);
|
|
295928
|
+
S = new Int32Array(S_ORIG);
|
|
295929
|
+
} else {
|
|
295930
|
+
P = P_ORIG.slice();
|
|
295931
|
+
S = S_ORIG.slice();
|
|
295932
|
+
}
|
|
295933
|
+
_ekskey(salt, b, P, S);
|
|
295934
|
+
function next() {
|
|
295935
|
+
if (progressCallback)
|
|
295936
|
+
progressCallback(i / rounds);
|
|
295937
|
+
if (i < rounds) {
|
|
295938
|
+
var start = Date.now();
|
|
295939
|
+
for (;i < rounds; ) {
|
|
295940
|
+
i = i + 1;
|
|
295941
|
+
_key(b, P, S);
|
|
295942
|
+
_key(salt, P, S);
|
|
295943
|
+
if (Date.now() - start > MAX_EXECUTION_TIME)
|
|
295944
|
+
break;
|
|
295945
|
+
}
|
|
295946
|
+
} else {
|
|
295947
|
+
for (i = 0;i < 64; i++)
|
|
295948
|
+
for (j = 0;j < clen >> 1; j++)
|
|
295949
|
+
_encipher(cdata, j << 1, P, S);
|
|
295950
|
+
var ret = [];
|
|
295951
|
+
for (i = 0;i < clen; i++)
|
|
295952
|
+
ret.push((cdata[i] >> 24 & 255) >>> 0), ret.push((cdata[i] >> 16 & 255) >>> 0), ret.push((cdata[i] >> 8 & 255) >>> 0), ret.push((cdata[i] & 255) >>> 0);
|
|
295953
|
+
if (callback) {
|
|
295954
|
+
callback(null, ret);
|
|
295955
|
+
return;
|
|
295956
|
+
} else
|
|
295957
|
+
return ret;
|
|
295958
|
+
}
|
|
295959
|
+
if (callback)
|
|
295960
|
+
nextTick(next);
|
|
295961
|
+
}
|
|
295962
|
+
if (typeof callback !== "undefined") {
|
|
295963
|
+
next();
|
|
295964
|
+
} else {
|
|
295965
|
+
var res;
|
|
295966
|
+
while (true)
|
|
295967
|
+
if (typeof (res = next()) !== "undefined")
|
|
295968
|
+
return res || [];
|
|
295969
|
+
}
|
|
295970
|
+
}
|
|
295971
|
+
function _hash(s, salt, callback, progressCallback) {
|
|
295972
|
+
var err;
|
|
295973
|
+
if (typeof s !== "string" || typeof salt !== "string") {
|
|
295974
|
+
err = Error("Invalid string / salt: Not a string");
|
|
295975
|
+
if (callback) {
|
|
295976
|
+
nextTick(callback.bind(this, err));
|
|
295977
|
+
return;
|
|
295978
|
+
} else
|
|
295979
|
+
throw err;
|
|
295980
|
+
}
|
|
295981
|
+
var minor, offset;
|
|
295982
|
+
if (salt.charAt(0) !== "$" || salt.charAt(1) !== "2") {
|
|
295983
|
+
err = Error("Invalid salt version: " + salt.substring(0, 2));
|
|
295984
|
+
if (callback) {
|
|
295985
|
+
nextTick(callback.bind(this, err));
|
|
295986
|
+
return;
|
|
295987
|
+
} else
|
|
295988
|
+
throw err;
|
|
295989
|
+
}
|
|
295990
|
+
if (salt.charAt(2) === "$")
|
|
295991
|
+
minor = String.fromCharCode(0), offset = 3;
|
|
295992
|
+
else {
|
|
295993
|
+
minor = salt.charAt(2);
|
|
295994
|
+
if (minor !== "a" && minor !== "b" && minor !== "y" || salt.charAt(3) !== "$") {
|
|
295995
|
+
err = Error("Invalid salt revision: " + salt.substring(2, 4));
|
|
295996
|
+
if (callback) {
|
|
295997
|
+
nextTick(callback.bind(this, err));
|
|
295998
|
+
return;
|
|
295999
|
+
} else
|
|
296000
|
+
throw err;
|
|
296001
|
+
}
|
|
296002
|
+
offset = 4;
|
|
296003
|
+
}
|
|
296004
|
+
if (salt.charAt(offset + 2) > "$") {
|
|
296005
|
+
err = Error("Missing salt rounds");
|
|
296006
|
+
if (callback) {
|
|
296007
|
+
nextTick(callback.bind(this, err));
|
|
296008
|
+
return;
|
|
296009
|
+
} else
|
|
296010
|
+
throw err;
|
|
296011
|
+
}
|
|
296012
|
+
var r1 = parseInt(salt.substring(offset, offset + 1), 10) * 10, r2 = parseInt(salt.substring(offset + 1, offset + 2), 10), rounds = r1 + r2, real_salt = salt.substring(offset + 3, offset + 25);
|
|
296013
|
+
s += minor >= "a" ? "\0" : "";
|
|
296014
|
+
var passwordb = stringToBytes(s), saltb = base64_decode(real_salt, BCRYPT_SALT_LEN);
|
|
296015
|
+
function finish(bytes) {
|
|
296016
|
+
var res = [];
|
|
296017
|
+
res.push("$2");
|
|
296018
|
+
if (minor >= "a")
|
|
296019
|
+
res.push(minor);
|
|
296020
|
+
res.push("$");
|
|
296021
|
+
if (rounds < 10)
|
|
296022
|
+
res.push("0");
|
|
296023
|
+
res.push(rounds.toString());
|
|
296024
|
+
res.push("$");
|
|
296025
|
+
res.push(base64_encode(saltb, saltb.length));
|
|
296026
|
+
res.push(base64_encode(bytes, C_ORIG.length * 4 - 1));
|
|
296027
|
+
return res.join("");
|
|
296028
|
+
}
|
|
296029
|
+
if (typeof callback == "undefined")
|
|
296030
|
+
return finish(_crypt(passwordb, saltb, rounds));
|
|
296031
|
+
else {
|
|
296032
|
+
_crypt(passwordb, saltb, rounds, function(err2, bytes) {
|
|
296033
|
+
if (err2)
|
|
296034
|
+
callback(err2, null);
|
|
296035
|
+
else
|
|
296036
|
+
callback(null, finish(bytes));
|
|
296037
|
+
}, progressCallback);
|
|
296038
|
+
}
|
|
296039
|
+
}
|
|
296040
|
+
bcrypt.encodeBase64 = base64_encode;
|
|
296041
|
+
bcrypt.decodeBase64 = base64_decode;
|
|
296042
|
+
return bcrypt;
|
|
296043
|
+
});
|
|
296044
|
+
});
|
|
296045
|
+
|
|
294346
296046
|
// src/utils/ApplicationServer.ts
|
|
294347
296047
|
var import_express = __toESM(require_express2(), 1);
|
|
294348
296048
|
var import_cors = __toESM(require_lib3(), 1);
|
|
@@ -295030,6 +296730,7 @@ class DatabaseConnector {
|
|
|
295030
296730
|
const config = configs.default[env];
|
|
295031
296731
|
const connection = new Sequelize(config);
|
|
295032
296732
|
Logger.info("Connecting to:", config);
|
|
296733
|
+
this.checkConnection(connection);
|
|
295033
296734
|
DatabaseConnector.connection = connection;
|
|
295034
296735
|
connections.push(connection);
|
|
295035
296736
|
resolve(connections);
|
|
@@ -295041,6 +296742,14 @@ class DatabaseConnector {
|
|
|
295041
296742
|
}
|
|
295042
296743
|
});
|
|
295043
296744
|
}
|
|
296745
|
+
static async checkConnection(connection) {
|
|
296746
|
+
try {
|
|
296747
|
+
await connection.authenticate();
|
|
296748
|
+
console.log(`Connection has been established successfully: ${connection.config.database}`);
|
|
296749
|
+
} catch (error) {
|
|
296750
|
+
console.error("Unable to connect to the database:", error);
|
|
296751
|
+
}
|
|
296752
|
+
}
|
|
295044
296753
|
async initializeModels() {
|
|
295045
296754
|
try {
|
|
295046
296755
|
let files = fs.readdirSync(`${DatabaseConnector.rootDir}/models`).filter((file) => file.indexOf(".") !== 0 && file.slice(-3) === ".ts");
|
|
@@ -301769,6 +303478,29 @@ class BaseKafka {
|
|
|
301769
303478
|
await admin2.disconnect();
|
|
301770
303479
|
}
|
|
301771
303480
|
}
|
|
303481
|
+
// src/utils/BaseAuthenticatorModel.ts
|
|
303482
|
+
var import_bcryptjs = __toESM(require_bcrypt(), 1);
|
|
303483
|
+
var SALT_ROUNDS = process.env.AUTH_SALT_ROUNDS || 12;
|
|
303484
|
+
|
|
303485
|
+
class BaseAuthenticatorModel extends BaseModel {
|
|
303486
|
+
constructor() {
|
|
303487
|
+
super(...arguments);
|
|
303488
|
+
}
|
|
303489
|
+
authenticate(password) {
|
|
303490
|
+
if (this.password && password)
|
|
303491
|
+
return import_bcryptjs.compareSync(password, this.password);
|
|
303492
|
+
else
|
|
303493
|
+
return false;
|
|
303494
|
+
}
|
|
303495
|
+
updatePassword(password) {
|
|
303496
|
+
let newPassword = password ? password : this.password;
|
|
303497
|
+
if (newPassword) {
|
|
303498
|
+
const hash = import_bcryptjs.hashSync(newPassword, SALT_ROUNDS);
|
|
303499
|
+
this.password = hash;
|
|
303500
|
+
}
|
|
303501
|
+
return this.password;
|
|
303502
|
+
}
|
|
303503
|
+
}
|
|
301772
303504
|
export {
|
|
301773
303505
|
verify,
|
|
301774
303506
|
getMimeType,
|
|
@@ -301801,5 +303533,6 @@ export {
|
|
|
301801
303533
|
BaseKafka,
|
|
301802
303534
|
BaseController,
|
|
301803
303535
|
BaseConsumer,
|
|
303536
|
+
BaseAuthenticatorModel,
|
|
301804
303537
|
ApplicationServer
|
|
301805
303538
|
};
|