@pod-os/core 0.6.1-bea440b.0 → 0.6.1-bf507bb.0
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.js +1140 -1326
- package/lib/index.js +1140 -1326
- package/package.json +12 -12
- package/types/authentication/index.d.ts +1 -1
- package/Readme.md +0 -3
package/lib/index.js
CHANGED
|
@@ -402,148 +402,6 @@ var PodOS = (() => {
|
|
|
402
402
|
}
|
|
403
403
|
});
|
|
404
404
|
|
|
405
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/constant.js
|
|
406
|
-
var require_constant = __commonJS({
|
|
407
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/constant.js"(exports) {
|
|
408
|
-
"use strict";
|
|
409
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
410
|
-
exports.DEFAULT_SCOPES = exports.REFRESH_BEFORE_EXPIRATION_SECONDS = exports.EVENTS = exports.PREFERRED_SIGNING_ALG = exports.SOLID_CLIENT_AUTHN_KEY_PREFIX = void 0;
|
|
411
|
-
exports.SOLID_CLIENT_AUTHN_KEY_PREFIX = "solidClientAuthn:";
|
|
412
|
-
exports.PREFERRED_SIGNING_ALG = ["ES256", "RS256"];
|
|
413
|
-
exports.EVENTS = {
|
|
414
|
-
ERROR: "error",
|
|
415
|
-
LOGIN: "login",
|
|
416
|
-
LOGOUT: "logout",
|
|
417
|
-
NEW_REFRESH_TOKEN: "newRefreshToken",
|
|
418
|
-
SESSION_EXPIRED: "sessionExpired",
|
|
419
|
-
SESSION_EXTENDED: "sessionExtended",
|
|
420
|
-
SESSION_RESTORED: "sessionRestore",
|
|
421
|
-
TIMEOUT_SET: "timeoutSet"
|
|
422
|
-
};
|
|
423
|
-
exports.REFRESH_BEFORE_EXPIRATION_SECONDS = 5;
|
|
424
|
-
var SCOPE_OPENID = "openid";
|
|
425
|
-
var SCOPE_OFFLINE = "offline_access";
|
|
426
|
-
var SCOPE_WEBID = "webid";
|
|
427
|
-
exports.DEFAULT_SCOPES = [SCOPE_OPENID, SCOPE_OFFLINE, SCOPE_WEBID].join(" ");
|
|
428
|
-
}
|
|
429
|
-
});
|
|
430
|
-
|
|
431
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/errors/InruptError.js
|
|
432
|
-
var require_InruptError = __commonJS({
|
|
433
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/errors/InruptError.js"(exports) {
|
|
434
|
-
"use strict";
|
|
435
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
436
|
-
var InruptError = class extends Error {
|
|
437
|
-
constructor(messageOrIri, messageParams, appendErrorIri = true) {
|
|
438
|
-
super(typeof messageOrIri === "string" ? InruptError.substituteParams(messageOrIri, messageParams) : InruptError.appendErrorIri(InruptError.lookupErrorIri(messageOrIri, messageParams), messageOrIri, appendErrorIri));
|
|
439
|
-
}
|
|
440
|
-
httpResponse(httpErrorResponse, appendHttpDetails = true) {
|
|
441
|
-
this.message = InruptError.appendHttpResponseDetails(this.message, httpErrorResponse, appendHttpDetails);
|
|
442
|
-
this.httpErrorResponse = httpErrorResponse;
|
|
443
|
-
return this;
|
|
444
|
-
}
|
|
445
|
-
hasHttpResponse() {
|
|
446
|
-
return this.httpErrorResponse !== void 0;
|
|
447
|
-
}
|
|
448
|
-
getHttpResponse() {
|
|
449
|
-
return this.httpErrorResponse;
|
|
450
|
-
}
|
|
451
|
-
getHttpStatusCode() {
|
|
452
|
-
if (this.httpErrorResponse === void 0) {
|
|
453
|
-
throw new InruptError("This InruptError was not provided with a HTTP response - so we can't get its HTTP Status Code.");
|
|
454
|
-
}
|
|
455
|
-
return this.httpErrorResponse.status;
|
|
456
|
-
}
|
|
457
|
-
getHttpStatusText() {
|
|
458
|
-
if (this.httpErrorResponse === void 0) {
|
|
459
|
-
throw new InruptError("This InruptError was not provided with a HTTP response - so we can't get its HTTP Status Text!");
|
|
460
|
-
}
|
|
461
|
-
return this.httpErrorResponse.statusText;
|
|
462
|
-
}
|
|
463
|
-
static determineIfVocabTerm(value) {
|
|
464
|
-
if (value.strict !== void 0) {
|
|
465
|
-
return true;
|
|
466
|
-
}
|
|
467
|
-
return false;
|
|
468
|
-
}
|
|
469
|
-
static lookupErrorIri(iri, messageParams) {
|
|
470
|
-
if (InruptError.determineIfVocabTerm(iri)) {
|
|
471
|
-
const message2 = messageParams === void 0 ? iri.message : iri.messageParams(...messageParams);
|
|
472
|
-
return message2 === void 0 ? `Looked up error message IRI [${iri.value}], but found no message value.` : message2;
|
|
473
|
-
}
|
|
474
|
-
return `Error message looked up at: [${iri.value}]${messageParams === void 0 ? "" : `, with params [${messageParams.toString()}]`}`;
|
|
475
|
-
}
|
|
476
|
-
static appendHttpResponseDetails(message2, response, append) {
|
|
477
|
-
if (append && typeof response !== "undefined") {
|
|
478
|
-
return `${message2} HTTP details: status code [${response.status}], status text [${response.statusText}].`;
|
|
479
|
-
}
|
|
480
|
-
return message2;
|
|
481
|
-
}
|
|
482
|
-
static appendErrorIri(message2, iri, append) {
|
|
483
|
-
return append ? `${message2} Error IRI: [${iri.value}].` : message2;
|
|
484
|
-
}
|
|
485
|
-
static substituteParams(message2, params) {
|
|
486
|
-
let fullMessage = message2;
|
|
487
|
-
if (params !== void 0) {
|
|
488
|
-
const paramsRequired = message2.split("{{").length - 1;
|
|
489
|
-
if (paramsRequired !== params.length) {
|
|
490
|
-
throw new Error(`Setting parameters on message [${message2}], but it requires [${paramsRequired}] params and we received [${params.length}].`);
|
|
491
|
-
}
|
|
492
|
-
for (let i = 0; i < params.length; i += 1) {
|
|
493
|
-
const marker = `{{${i}}}`;
|
|
494
|
-
fullMessage = fullMessage.replace(marker, params[i]);
|
|
495
|
-
}
|
|
496
|
-
}
|
|
497
|
-
return fullMessage;
|
|
498
|
-
}
|
|
499
|
-
};
|
|
500
|
-
exports.default = InruptError;
|
|
501
|
-
}
|
|
502
|
-
});
|
|
503
|
-
|
|
504
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/util/handlerPattern/AggregateHandler.js
|
|
505
|
-
var require_AggregateHandler = __commonJS({
|
|
506
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/util/handlerPattern/AggregateHandler.js"(exports) {
|
|
507
|
-
"use strict";
|
|
508
|
-
var __importDefault = exports && exports.__importDefault || function(mod) {
|
|
509
|
-
return mod && mod.__esModule ? mod : { "default": mod };
|
|
510
|
-
};
|
|
511
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
512
|
-
var InruptError_1 = __importDefault(require_InruptError());
|
|
513
|
-
var AggregateHandler = class {
|
|
514
|
-
constructor(handleables) {
|
|
515
|
-
this.handleables = handleables;
|
|
516
|
-
}
|
|
517
|
-
async getProperHandler(params) {
|
|
518
|
-
const canHandleList = await Promise.all(this.handleables.map((handleable) => handleable.canHandle(...params)));
|
|
519
|
-
for (let i = 0; i < canHandleList.length; i += 1) {
|
|
520
|
-
if (canHandleList[i]) {
|
|
521
|
-
return this.handleables[i];
|
|
522
|
-
}
|
|
523
|
-
}
|
|
524
|
-
return null;
|
|
525
|
-
}
|
|
526
|
-
async canHandle(...params) {
|
|
527
|
-
return await this.getProperHandler(params) !== null;
|
|
528
|
-
}
|
|
529
|
-
async handle(...params) {
|
|
530
|
-
const handler = await this.getProperHandler(params);
|
|
531
|
-
if (handler) {
|
|
532
|
-
return handler.handle(...params);
|
|
533
|
-
}
|
|
534
|
-
throw new InruptError_1.default(`[${this.constructor.name}] cannot find a suitable handler for: ${params.map((param) => {
|
|
535
|
-
try {
|
|
536
|
-
return JSON.stringify(param);
|
|
537
|
-
} catch (err) {
|
|
538
|
-
return param.toString();
|
|
539
|
-
}
|
|
540
|
-
}).join(", ")}`);
|
|
541
|
-
}
|
|
542
|
-
};
|
|
543
|
-
exports.default = AggregateHandler;
|
|
544
|
-
}
|
|
545
|
-
});
|
|
546
|
-
|
|
547
405
|
// ../node_modules/cross-fetch/dist/browser-ponyfill.js
|
|
548
406
|
var require_browser_ponyfill = __commonJS({
|
|
549
407
|
"../node_modules/cross-fetch/dist/browser-ponyfill.js"(exports, module2) {
|
|
@@ -2339,6 +2197,7 @@ ${newlined}
|
|
|
2339
2197
|
}
|
|
2340
2198
|
const keyData = { ...jwk };
|
|
2341
2199
|
delete keyData.alg;
|
|
2200
|
+
delete keyData.use;
|
|
2342
2201
|
return webcrypto_default.subtle.importKey("jwk", keyData, ...rest);
|
|
2343
2202
|
};
|
|
2344
2203
|
jwk_to_key_default = parse;
|
|
@@ -2432,11 +2291,12 @@ ${newlined}
|
|
|
2432
2291
|
}
|
|
2433
2292
|
async function importPKCS8(pkcs8, alg, options) {
|
|
2434
2293
|
if (typeof pkcs8 !== "string" || pkcs8.indexOf("-----BEGIN PRIVATE KEY-----") !== 0) {
|
|
2435
|
-
throw new TypeError('"pkcs8" must be
|
|
2294
|
+
throw new TypeError('"pkcs8" must be PKCS#8 formatted string');
|
|
2436
2295
|
}
|
|
2437
2296
|
return fromPKCS8(pkcs8, alg, options);
|
|
2438
2297
|
}
|
|
2439
2298
|
async function importJWK(jwk, alg, octAsKeyObject) {
|
|
2299
|
+
var _a;
|
|
2440
2300
|
if (!isObject(jwk)) {
|
|
2441
2301
|
throw new TypeError("JWK must be an object");
|
|
2442
2302
|
}
|
|
@@ -2451,7 +2311,7 @@ ${newlined}
|
|
|
2451
2311
|
}
|
|
2452
2312
|
octAsKeyObject !== null && octAsKeyObject !== void 0 ? octAsKeyObject : octAsKeyObject = jwk.ext !== true;
|
|
2453
2313
|
if (octAsKeyObject) {
|
|
2454
|
-
return jwk_to_key_default({ ...jwk, alg, ext: false });
|
|
2314
|
+
return jwk_to_key_default({ ...jwk, alg, ext: (_a = jwk.ext) !== null && _a !== void 0 ? _a : false });
|
|
2455
2315
|
}
|
|
2456
2316
|
return decode(jwk.k);
|
|
2457
2317
|
case "RSA":
|
|
@@ -4989,16 +4849,764 @@ ${newlined}
|
|
|
4989
4849
|
}
|
|
4990
4850
|
});
|
|
4991
4851
|
|
|
4992
|
-
// ../node_modules
|
|
4993
|
-
var
|
|
4994
|
-
"../node_modules
|
|
4852
|
+
// ../node_modules/uuid/dist/commonjs-browser/rng.js
|
|
4853
|
+
var require_rng = __commonJS({
|
|
4854
|
+
"../node_modules/uuid/dist/commonjs-browser/rng.js"(exports) {
|
|
4995
4855
|
"use strict";
|
|
4996
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4997
|
-
|
|
4998
|
-
|
|
4999
|
-
|
|
4856
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4857
|
+
value: true
|
|
4858
|
+
});
|
|
4859
|
+
exports.default = rng;
|
|
4860
|
+
var getRandomValues;
|
|
4861
|
+
var rnds8 = new Uint8Array(16);
|
|
4862
|
+
function rng() {
|
|
4863
|
+
if (!getRandomValues) {
|
|
4864
|
+
getRandomValues = typeof crypto !== "undefined" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto);
|
|
4865
|
+
if (!getRandomValues) {
|
|
4866
|
+
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
4867
|
+
}
|
|
4868
|
+
}
|
|
4869
|
+
return getRandomValues(rnds8);
|
|
4870
|
+
}
|
|
4871
|
+
}
|
|
4872
|
+
});
|
|
4873
|
+
|
|
4874
|
+
// ../node_modules/uuid/dist/commonjs-browser/regex.js
|
|
4875
|
+
var require_regex = __commonJS({
|
|
4876
|
+
"../node_modules/uuid/dist/commonjs-browser/regex.js"(exports) {
|
|
4877
|
+
"use strict";
|
|
4878
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4879
|
+
value: true
|
|
4880
|
+
});
|
|
4881
|
+
exports.default = void 0;
|
|
4882
|
+
var _default = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
|
|
4883
|
+
exports.default = _default;
|
|
4884
|
+
}
|
|
4885
|
+
});
|
|
4886
|
+
|
|
4887
|
+
// ../node_modules/uuid/dist/commonjs-browser/validate.js
|
|
4888
|
+
var require_validate = __commonJS({
|
|
4889
|
+
"../node_modules/uuid/dist/commonjs-browser/validate.js"(exports) {
|
|
4890
|
+
"use strict";
|
|
4891
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4892
|
+
value: true
|
|
4893
|
+
});
|
|
4894
|
+
exports.default = void 0;
|
|
4895
|
+
var _regex = _interopRequireDefault(require_regex());
|
|
4896
|
+
function _interopRequireDefault(obj) {
|
|
4897
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
4898
|
+
}
|
|
4899
|
+
function validate(uuid) {
|
|
4900
|
+
return typeof uuid === "string" && _regex.default.test(uuid);
|
|
4901
|
+
}
|
|
4902
|
+
var _default = validate;
|
|
4903
|
+
exports.default = _default;
|
|
4904
|
+
}
|
|
4905
|
+
});
|
|
4906
|
+
|
|
4907
|
+
// ../node_modules/uuid/dist/commonjs-browser/stringify.js
|
|
4908
|
+
var require_stringify = __commonJS({
|
|
4909
|
+
"../node_modules/uuid/dist/commonjs-browser/stringify.js"(exports) {
|
|
4910
|
+
"use strict";
|
|
4911
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4912
|
+
value: true
|
|
4913
|
+
});
|
|
4914
|
+
exports.default = void 0;
|
|
4915
|
+
exports.unsafeStringify = unsafeStringify;
|
|
4916
|
+
var _validate = _interopRequireDefault(require_validate());
|
|
4917
|
+
function _interopRequireDefault(obj) {
|
|
4918
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
4919
|
+
}
|
|
4920
|
+
var byteToHex = [];
|
|
4921
|
+
for (let i = 0; i < 256; ++i) {
|
|
4922
|
+
byteToHex.push((i + 256).toString(16).slice(1));
|
|
4923
|
+
}
|
|
4924
|
+
function unsafeStringify(arr, offset = 0) {
|
|
4925
|
+
return (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + "-" + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + "-" + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + "-" + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + "-" + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase();
|
|
4926
|
+
}
|
|
4927
|
+
function stringify(arr, offset = 0) {
|
|
4928
|
+
const uuid = unsafeStringify(arr, offset);
|
|
4929
|
+
if (!(0, _validate.default)(uuid)) {
|
|
4930
|
+
throw TypeError("Stringified UUID is invalid");
|
|
4931
|
+
}
|
|
4932
|
+
return uuid;
|
|
4933
|
+
}
|
|
4934
|
+
var _default = stringify;
|
|
4935
|
+
exports.default = _default;
|
|
4936
|
+
}
|
|
4937
|
+
});
|
|
4938
|
+
|
|
4939
|
+
// ../node_modules/uuid/dist/commonjs-browser/v1.js
|
|
4940
|
+
var require_v1 = __commonJS({
|
|
4941
|
+
"../node_modules/uuid/dist/commonjs-browser/v1.js"(exports) {
|
|
4942
|
+
"use strict";
|
|
4943
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4944
|
+
value: true
|
|
4945
|
+
});
|
|
4946
|
+
exports.default = void 0;
|
|
4947
|
+
var _rng = _interopRequireDefault(require_rng());
|
|
4948
|
+
var _stringify = require_stringify();
|
|
4949
|
+
function _interopRequireDefault(obj) {
|
|
4950
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
4951
|
+
}
|
|
4952
|
+
var _nodeId;
|
|
4953
|
+
var _clockseq;
|
|
4954
|
+
var _lastMSecs = 0;
|
|
4955
|
+
var _lastNSecs = 0;
|
|
4956
|
+
function v1(options, buf, offset) {
|
|
4957
|
+
let i = buf && offset || 0;
|
|
4958
|
+
const b = buf || new Array(16);
|
|
4959
|
+
options = options || {};
|
|
4960
|
+
let node = options.node || _nodeId;
|
|
4961
|
+
let clockseq = options.clockseq !== void 0 ? options.clockseq : _clockseq;
|
|
4962
|
+
if (node == null || clockseq == null) {
|
|
4963
|
+
const seedBytes = options.random || (options.rng || _rng.default)();
|
|
4964
|
+
if (node == null) {
|
|
4965
|
+
node = _nodeId = [seedBytes[0] | 1, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]];
|
|
4966
|
+
}
|
|
4967
|
+
if (clockseq == null) {
|
|
4968
|
+
clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 16383;
|
|
4969
|
+
}
|
|
4970
|
+
}
|
|
4971
|
+
let msecs = options.msecs !== void 0 ? options.msecs : Date.now();
|
|
4972
|
+
let nsecs = options.nsecs !== void 0 ? options.nsecs : _lastNSecs + 1;
|
|
4973
|
+
const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 1e4;
|
|
4974
|
+
if (dt < 0 && options.clockseq === void 0) {
|
|
4975
|
+
clockseq = clockseq + 1 & 16383;
|
|
4976
|
+
}
|
|
4977
|
+
if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === void 0) {
|
|
4978
|
+
nsecs = 0;
|
|
4979
|
+
}
|
|
4980
|
+
if (nsecs >= 1e4) {
|
|
4981
|
+
throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");
|
|
4982
|
+
}
|
|
4983
|
+
_lastMSecs = msecs;
|
|
4984
|
+
_lastNSecs = nsecs;
|
|
4985
|
+
_clockseq = clockseq;
|
|
4986
|
+
msecs += 122192928e5;
|
|
4987
|
+
const tl = ((msecs & 268435455) * 1e4 + nsecs) % 4294967296;
|
|
4988
|
+
b[i++] = tl >>> 24 & 255;
|
|
4989
|
+
b[i++] = tl >>> 16 & 255;
|
|
4990
|
+
b[i++] = tl >>> 8 & 255;
|
|
4991
|
+
b[i++] = tl & 255;
|
|
4992
|
+
const tmh = msecs / 4294967296 * 1e4 & 268435455;
|
|
4993
|
+
b[i++] = tmh >>> 8 & 255;
|
|
4994
|
+
b[i++] = tmh & 255;
|
|
4995
|
+
b[i++] = tmh >>> 24 & 15 | 16;
|
|
4996
|
+
b[i++] = tmh >>> 16 & 255;
|
|
4997
|
+
b[i++] = clockseq >>> 8 | 128;
|
|
4998
|
+
b[i++] = clockseq & 255;
|
|
4999
|
+
for (let n = 0; n < 6; ++n) {
|
|
5000
|
+
b[i + n] = node[n];
|
|
5001
|
+
}
|
|
5002
|
+
return buf || (0, _stringify.unsafeStringify)(b);
|
|
5003
|
+
}
|
|
5004
|
+
var _default = v1;
|
|
5005
|
+
exports.default = _default;
|
|
5006
|
+
}
|
|
5007
|
+
});
|
|
5008
|
+
|
|
5009
|
+
// ../node_modules/uuid/dist/commonjs-browser/parse.js
|
|
5010
|
+
var require_parse = __commonJS({
|
|
5011
|
+
"../node_modules/uuid/dist/commonjs-browser/parse.js"(exports) {
|
|
5012
|
+
"use strict";
|
|
5013
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5014
|
+
value: true
|
|
5015
|
+
});
|
|
5016
|
+
exports.default = void 0;
|
|
5017
|
+
var _validate = _interopRequireDefault(require_validate());
|
|
5018
|
+
function _interopRequireDefault(obj) {
|
|
5019
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5020
|
+
}
|
|
5021
|
+
function parse3(uuid) {
|
|
5022
|
+
if (!(0, _validate.default)(uuid)) {
|
|
5023
|
+
throw TypeError("Invalid UUID");
|
|
5024
|
+
}
|
|
5025
|
+
let v;
|
|
5026
|
+
const arr = new Uint8Array(16);
|
|
5027
|
+
arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24;
|
|
5028
|
+
arr[1] = v >>> 16 & 255;
|
|
5029
|
+
arr[2] = v >>> 8 & 255;
|
|
5030
|
+
arr[3] = v & 255;
|
|
5031
|
+
arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8;
|
|
5032
|
+
arr[5] = v & 255;
|
|
5033
|
+
arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8;
|
|
5034
|
+
arr[7] = v & 255;
|
|
5035
|
+
arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8;
|
|
5036
|
+
arr[9] = v & 255;
|
|
5037
|
+
arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 1099511627776 & 255;
|
|
5038
|
+
arr[11] = v / 4294967296 & 255;
|
|
5039
|
+
arr[12] = v >>> 24 & 255;
|
|
5040
|
+
arr[13] = v >>> 16 & 255;
|
|
5041
|
+
arr[14] = v >>> 8 & 255;
|
|
5042
|
+
arr[15] = v & 255;
|
|
5043
|
+
return arr;
|
|
5044
|
+
}
|
|
5045
|
+
var _default = parse3;
|
|
5046
|
+
exports.default = _default;
|
|
5047
|
+
}
|
|
5048
|
+
});
|
|
5049
|
+
|
|
5050
|
+
// ../node_modules/uuid/dist/commonjs-browser/v35.js
|
|
5051
|
+
var require_v35 = __commonJS({
|
|
5052
|
+
"../node_modules/uuid/dist/commonjs-browser/v35.js"(exports) {
|
|
5053
|
+
"use strict";
|
|
5054
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5055
|
+
value: true
|
|
5056
|
+
});
|
|
5057
|
+
exports.URL = exports.DNS = void 0;
|
|
5058
|
+
exports.default = v35;
|
|
5059
|
+
var _stringify = require_stringify();
|
|
5060
|
+
var _parse = _interopRequireDefault(require_parse());
|
|
5061
|
+
function _interopRequireDefault(obj) {
|
|
5062
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5063
|
+
}
|
|
5064
|
+
function stringToBytes(str) {
|
|
5065
|
+
str = unescape(encodeURIComponent(str));
|
|
5066
|
+
const bytes = [];
|
|
5067
|
+
for (let i = 0; i < str.length; ++i) {
|
|
5068
|
+
bytes.push(str.charCodeAt(i));
|
|
5069
|
+
}
|
|
5070
|
+
return bytes;
|
|
5071
|
+
}
|
|
5072
|
+
var DNS = "6ba7b810-9dad-11d1-80b4-00c04fd430c8";
|
|
5073
|
+
exports.DNS = DNS;
|
|
5074
|
+
var URL2 = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
|
|
5075
|
+
exports.URL = URL2;
|
|
5076
|
+
function v35(name, version, hashfunc) {
|
|
5077
|
+
function generateUUID(value, namespace, buf, offset) {
|
|
5078
|
+
var _namespace;
|
|
5079
|
+
if (typeof value === "string") {
|
|
5080
|
+
value = stringToBytes(value);
|
|
5081
|
+
}
|
|
5082
|
+
if (typeof namespace === "string") {
|
|
5083
|
+
namespace = (0, _parse.default)(namespace);
|
|
5084
|
+
}
|
|
5085
|
+
if (((_namespace = namespace) === null || _namespace === void 0 ? void 0 : _namespace.length) !== 16) {
|
|
5086
|
+
throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
|
|
5087
|
+
}
|
|
5088
|
+
let bytes = new Uint8Array(16 + value.length);
|
|
5089
|
+
bytes.set(namespace);
|
|
5090
|
+
bytes.set(value, namespace.length);
|
|
5091
|
+
bytes = hashfunc(bytes);
|
|
5092
|
+
bytes[6] = bytes[6] & 15 | version;
|
|
5093
|
+
bytes[8] = bytes[8] & 63 | 128;
|
|
5094
|
+
if (buf) {
|
|
5095
|
+
offset = offset || 0;
|
|
5096
|
+
for (let i = 0; i < 16; ++i) {
|
|
5097
|
+
buf[offset + i] = bytes[i];
|
|
5098
|
+
}
|
|
5099
|
+
return buf;
|
|
5100
|
+
}
|
|
5101
|
+
return (0, _stringify.unsafeStringify)(bytes);
|
|
5102
|
+
}
|
|
5103
|
+
try {
|
|
5104
|
+
generateUUID.name = name;
|
|
5105
|
+
} catch (err) {
|
|
5106
|
+
}
|
|
5107
|
+
generateUUID.DNS = DNS;
|
|
5108
|
+
generateUUID.URL = URL2;
|
|
5109
|
+
return generateUUID;
|
|
5110
|
+
}
|
|
5111
|
+
}
|
|
5112
|
+
});
|
|
5113
|
+
|
|
5114
|
+
// ../node_modules/uuid/dist/commonjs-browser/md5.js
|
|
5115
|
+
var require_md5 = __commonJS({
|
|
5116
|
+
"../node_modules/uuid/dist/commonjs-browser/md5.js"(exports) {
|
|
5117
|
+
"use strict";
|
|
5118
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5119
|
+
value: true
|
|
5120
|
+
});
|
|
5121
|
+
exports.default = void 0;
|
|
5122
|
+
function md5(bytes) {
|
|
5123
|
+
if (typeof bytes === "string") {
|
|
5124
|
+
const msg2 = unescape(encodeURIComponent(bytes));
|
|
5125
|
+
bytes = new Uint8Array(msg2.length);
|
|
5126
|
+
for (let i = 0; i < msg2.length; ++i) {
|
|
5127
|
+
bytes[i] = msg2.charCodeAt(i);
|
|
5128
|
+
}
|
|
5129
|
+
}
|
|
5130
|
+
return md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), bytes.length * 8));
|
|
5131
|
+
}
|
|
5132
|
+
function md5ToHexEncodedArray(input) {
|
|
5133
|
+
const output = [];
|
|
5134
|
+
const length32 = input.length * 32;
|
|
5135
|
+
const hexTab = "0123456789abcdef";
|
|
5136
|
+
for (let i = 0; i < length32; i += 8) {
|
|
5137
|
+
const x = input[i >> 5] >>> i % 32 & 255;
|
|
5138
|
+
const hex = parseInt(hexTab.charAt(x >>> 4 & 15) + hexTab.charAt(x & 15), 16);
|
|
5139
|
+
output.push(hex);
|
|
5140
|
+
}
|
|
5141
|
+
return output;
|
|
5142
|
+
}
|
|
5143
|
+
function getOutputLength(inputLength8) {
|
|
5144
|
+
return (inputLength8 + 64 >>> 9 << 4) + 14 + 1;
|
|
5145
|
+
}
|
|
5146
|
+
function wordsToMd5(x, len) {
|
|
5147
|
+
x[len >> 5] |= 128 << len % 32;
|
|
5148
|
+
x[getOutputLength(len) - 1] = len;
|
|
5149
|
+
let a = 1732584193;
|
|
5150
|
+
let b = -271733879;
|
|
5151
|
+
let c = -1732584194;
|
|
5152
|
+
let d = 271733878;
|
|
5153
|
+
for (let i = 0; i < x.length; i += 16) {
|
|
5154
|
+
const olda = a;
|
|
5155
|
+
const oldb = b;
|
|
5156
|
+
const oldc = c;
|
|
5157
|
+
const oldd = d;
|
|
5158
|
+
a = md5ff(a, b, c, d, x[i], 7, -680876936);
|
|
5159
|
+
d = md5ff(d, a, b, c, x[i + 1], 12, -389564586);
|
|
5160
|
+
c = md5ff(c, d, a, b, x[i + 2], 17, 606105819);
|
|
5161
|
+
b = md5ff(b, c, d, a, x[i + 3], 22, -1044525330);
|
|
5162
|
+
a = md5ff(a, b, c, d, x[i + 4], 7, -176418897);
|
|
5163
|
+
d = md5ff(d, a, b, c, x[i + 5], 12, 1200080426);
|
|
5164
|
+
c = md5ff(c, d, a, b, x[i + 6], 17, -1473231341);
|
|
5165
|
+
b = md5ff(b, c, d, a, x[i + 7], 22, -45705983);
|
|
5166
|
+
a = md5ff(a, b, c, d, x[i + 8], 7, 1770035416);
|
|
5167
|
+
d = md5ff(d, a, b, c, x[i + 9], 12, -1958414417);
|
|
5168
|
+
c = md5ff(c, d, a, b, x[i + 10], 17, -42063);
|
|
5169
|
+
b = md5ff(b, c, d, a, x[i + 11], 22, -1990404162);
|
|
5170
|
+
a = md5ff(a, b, c, d, x[i + 12], 7, 1804603682);
|
|
5171
|
+
d = md5ff(d, a, b, c, x[i + 13], 12, -40341101);
|
|
5172
|
+
c = md5ff(c, d, a, b, x[i + 14], 17, -1502002290);
|
|
5173
|
+
b = md5ff(b, c, d, a, x[i + 15], 22, 1236535329);
|
|
5174
|
+
a = md5gg(a, b, c, d, x[i + 1], 5, -165796510);
|
|
5175
|
+
d = md5gg(d, a, b, c, x[i + 6], 9, -1069501632);
|
|
5176
|
+
c = md5gg(c, d, a, b, x[i + 11], 14, 643717713);
|
|
5177
|
+
b = md5gg(b, c, d, a, x[i], 20, -373897302);
|
|
5178
|
+
a = md5gg(a, b, c, d, x[i + 5], 5, -701558691);
|
|
5179
|
+
d = md5gg(d, a, b, c, x[i + 10], 9, 38016083);
|
|
5180
|
+
c = md5gg(c, d, a, b, x[i + 15], 14, -660478335);
|
|
5181
|
+
b = md5gg(b, c, d, a, x[i + 4], 20, -405537848);
|
|
5182
|
+
a = md5gg(a, b, c, d, x[i + 9], 5, 568446438);
|
|
5183
|
+
d = md5gg(d, a, b, c, x[i + 14], 9, -1019803690);
|
|
5184
|
+
c = md5gg(c, d, a, b, x[i + 3], 14, -187363961);
|
|
5185
|
+
b = md5gg(b, c, d, a, x[i + 8], 20, 1163531501);
|
|
5186
|
+
a = md5gg(a, b, c, d, x[i + 13], 5, -1444681467);
|
|
5187
|
+
d = md5gg(d, a, b, c, x[i + 2], 9, -51403784);
|
|
5188
|
+
c = md5gg(c, d, a, b, x[i + 7], 14, 1735328473);
|
|
5189
|
+
b = md5gg(b, c, d, a, x[i + 12], 20, -1926607734);
|
|
5190
|
+
a = md5hh(a, b, c, d, x[i + 5], 4, -378558);
|
|
5191
|
+
d = md5hh(d, a, b, c, x[i + 8], 11, -2022574463);
|
|
5192
|
+
c = md5hh(c, d, a, b, x[i + 11], 16, 1839030562);
|
|
5193
|
+
b = md5hh(b, c, d, a, x[i + 14], 23, -35309556);
|
|
5194
|
+
a = md5hh(a, b, c, d, x[i + 1], 4, -1530992060);
|
|
5195
|
+
d = md5hh(d, a, b, c, x[i + 4], 11, 1272893353);
|
|
5196
|
+
c = md5hh(c, d, a, b, x[i + 7], 16, -155497632);
|
|
5197
|
+
b = md5hh(b, c, d, a, x[i + 10], 23, -1094730640);
|
|
5198
|
+
a = md5hh(a, b, c, d, x[i + 13], 4, 681279174);
|
|
5199
|
+
d = md5hh(d, a, b, c, x[i], 11, -358537222);
|
|
5200
|
+
c = md5hh(c, d, a, b, x[i + 3], 16, -722521979);
|
|
5201
|
+
b = md5hh(b, c, d, a, x[i + 6], 23, 76029189);
|
|
5202
|
+
a = md5hh(a, b, c, d, x[i + 9], 4, -640364487);
|
|
5203
|
+
d = md5hh(d, a, b, c, x[i + 12], 11, -421815835);
|
|
5204
|
+
c = md5hh(c, d, a, b, x[i + 15], 16, 530742520);
|
|
5205
|
+
b = md5hh(b, c, d, a, x[i + 2], 23, -995338651);
|
|
5206
|
+
a = md5ii(a, b, c, d, x[i], 6, -198630844);
|
|
5207
|
+
d = md5ii(d, a, b, c, x[i + 7], 10, 1126891415);
|
|
5208
|
+
c = md5ii(c, d, a, b, x[i + 14], 15, -1416354905);
|
|
5209
|
+
b = md5ii(b, c, d, a, x[i + 5], 21, -57434055);
|
|
5210
|
+
a = md5ii(a, b, c, d, x[i + 12], 6, 1700485571);
|
|
5211
|
+
d = md5ii(d, a, b, c, x[i + 3], 10, -1894986606);
|
|
5212
|
+
c = md5ii(c, d, a, b, x[i + 10], 15, -1051523);
|
|
5213
|
+
b = md5ii(b, c, d, a, x[i + 1], 21, -2054922799);
|
|
5214
|
+
a = md5ii(a, b, c, d, x[i + 8], 6, 1873313359);
|
|
5215
|
+
d = md5ii(d, a, b, c, x[i + 15], 10, -30611744);
|
|
5216
|
+
c = md5ii(c, d, a, b, x[i + 6], 15, -1560198380);
|
|
5217
|
+
b = md5ii(b, c, d, a, x[i + 13], 21, 1309151649);
|
|
5218
|
+
a = md5ii(a, b, c, d, x[i + 4], 6, -145523070);
|
|
5219
|
+
d = md5ii(d, a, b, c, x[i + 11], 10, -1120210379);
|
|
5220
|
+
c = md5ii(c, d, a, b, x[i + 2], 15, 718787259);
|
|
5221
|
+
b = md5ii(b, c, d, a, x[i + 9], 21, -343485551);
|
|
5222
|
+
a = safeAdd(a, olda);
|
|
5223
|
+
b = safeAdd(b, oldb);
|
|
5224
|
+
c = safeAdd(c, oldc);
|
|
5225
|
+
d = safeAdd(d, oldd);
|
|
5226
|
+
}
|
|
5227
|
+
return [a, b, c, d];
|
|
5228
|
+
}
|
|
5229
|
+
function bytesToWords(input) {
|
|
5230
|
+
if (input.length === 0) {
|
|
5231
|
+
return [];
|
|
5232
|
+
}
|
|
5233
|
+
const length8 = input.length * 8;
|
|
5234
|
+
const output = new Uint32Array(getOutputLength(length8));
|
|
5235
|
+
for (let i = 0; i < length8; i += 8) {
|
|
5236
|
+
output[i >> 5] |= (input[i / 8] & 255) << i % 32;
|
|
5237
|
+
}
|
|
5238
|
+
return output;
|
|
5239
|
+
}
|
|
5240
|
+
function safeAdd(x, y) {
|
|
5241
|
+
const lsw = (x & 65535) + (y & 65535);
|
|
5242
|
+
const msw = (x >> 16) + (y >> 16) + (lsw >> 16);
|
|
5243
|
+
return msw << 16 | lsw & 65535;
|
|
5244
|
+
}
|
|
5245
|
+
function bitRotateLeft(num, cnt) {
|
|
5246
|
+
return num << cnt | num >>> 32 - cnt;
|
|
5247
|
+
}
|
|
5248
|
+
function md5cmn(q, a, b, x, s, t) {
|
|
5249
|
+
return safeAdd(bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s), b);
|
|
5250
|
+
}
|
|
5251
|
+
function md5ff(a, b, c, d, x, s, t) {
|
|
5252
|
+
return md5cmn(b & c | ~b & d, a, b, x, s, t);
|
|
5253
|
+
}
|
|
5254
|
+
function md5gg(a, b, c, d, x, s, t) {
|
|
5255
|
+
return md5cmn(b & d | c & ~d, a, b, x, s, t);
|
|
5256
|
+
}
|
|
5257
|
+
function md5hh(a, b, c, d, x, s, t) {
|
|
5258
|
+
return md5cmn(b ^ c ^ d, a, b, x, s, t);
|
|
5259
|
+
}
|
|
5260
|
+
function md5ii(a, b, c, d, x, s, t) {
|
|
5261
|
+
return md5cmn(c ^ (b | ~d), a, b, x, s, t);
|
|
5262
|
+
}
|
|
5263
|
+
var _default = md5;
|
|
5264
|
+
exports.default = _default;
|
|
5265
|
+
}
|
|
5266
|
+
});
|
|
5267
|
+
|
|
5268
|
+
// ../node_modules/uuid/dist/commonjs-browser/v3.js
|
|
5269
|
+
var require_v3 = __commonJS({
|
|
5270
|
+
"../node_modules/uuid/dist/commonjs-browser/v3.js"(exports) {
|
|
5271
|
+
"use strict";
|
|
5272
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5273
|
+
value: true
|
|
5274
|
+
});
|
|
5275
|
+
exports.default = void 0;
|
|
5276
|
+
var _v = _interopRequireDefault(require_v35());
|
|
5277
|
+
var _md = _interopRequireDefault(require_md5());
|
|
5278
|
+
function _interopRequireDefault(obj) {
|
|
5279
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5280
|
+
}
|
|
5281
|
+
var v3 = (0, _v.default)("v3", 48, _md.default);
|
|
5282
|
+
var _default = v3;
|
|
5283
|
+
exports.default = _default;
|
|
5284
|
+
}
|
|
5285
|
+
});
|
|
5286
|
+
|
|
5287
|
+
// ../node_modules/uuid/dist/commonjs-browser/native.js
|
|
5288
|
+
var require_native = __commonJS({
|
|
5289
|
+
"../node_modules/uuid/dist/commonjs-browser/native.js"(exports) {
|
|
5290
|
+
"use strict";
|
|
5291
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5292
|
+
value: true
|
|
5293
|
+
});
|
|
5294
|
+
exports.default = void 0;
|
|
5295
|
+
var randomUUID = typeof crypto !== "undefined" && crypto.randomUUID && crypto.randomUUID.bind(crypto);
|
|
5296
|
+
var _default = {
|
|
5297
|
+
randomUUID
|
|
5298
|
+
};
|
|
5299
|
+
exports.default = _default;
|
|
5300
|
+
}
|
|
5301
|
+
});
|
|
5302
|
+
|
|
5303
|
+
// ../node_modules/uuid/dist/commonjs-browser/v4.js
|
|
5304
|
+
var require_v4 = __commonJS({
|
|
5305
|
+
"../node_modules/uuid/dist/commonjs-browser/v4.js"(exports) {
|
|
5306
|
+
"use strict";
|
|
5307
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5308
|
+
value: true
|
|
5309
|
+
});
|
|
5310
|
+
exports.default = void 0;
|
|
5311
|
+
var _native = _interopRequireDefault(require_native());
|
|
5312
|
+
var _rng = _interopRequireDefault(require_rng());
|
|
5313
|
+
var _stringify = require_stringify();
|
|
5314
|
+
function _interopRequireDefault(obj) {
|
|
5315
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5316
|
+
}
|
|
5317
|
+
function v4(options, buf, offset) {
|
|
5318
|
+
if (_native.default.randomUUID && !buf && !options) {
|
|
5319
|
+
return _native.default.randomUUID();
|
|
5320
|
+
}
|
|
5321
|
+
options = options || {};
|
|
5322
|
+
const rnds = options.random || (options.rng || _rng.default)();
|
|
5323
|
+
rnds[6] = rnds[6] & 15 | 64;
|
|
5324
|
+
rnds[8] = rnds[8] & 63 | 128;
|
|
5325
|
+
if (buf) {
|
|
5326
|
+
offset = offset || 0;
|
|
5327
|
+
for (let i = 0; i < 16; ++i) {
|
|
5328
|
+
buf[offset + i] = rnds[i];
|
|
5329
|
+
}
|
|
5330
|
+
return buf;
|
|
5331
|
+
}
|
|
5332
|
+
return (0, _stringify.unsafeStringify)(rnds);
|
|
5333
|
+
}
|
|
5334
|
+
var _default = v4;
|
|
5335
|
+
exports.default = _default;
|
|
5336
|
+
}
|
|
5337
|
+
});
|
|
5338
|
+
|
|
5339
|
+
// ../node_modules/uuid/dist/commonjs-browser/sha1.js
|
|
5340
|
+
var require_sha1 = __commonJS({
|
|
5341
|
+
"../node_modules/uuid/dist/commonjs-browser/sha1.js"(exports) {
|
|
5342
|
+
"use strict";
|
|
5343
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5344
|
+
value: true
|
|
5345
|
+
});
|
|
5346
|
+
exports.default = void 0;
|
|
5347
|
+
function f(s, x, y, z) {
|
|
5348
|
+
switch (s) {
|
|
5349
|
+
case 0:
|
|
5350
|
+
return x & y ^ ~x & z;
|
|
5351
|
+
case 1:
|
|
5352
|
+
return x ^ y ^ z;
|
|
5353
|
+
case 2:
|
|
5354
|
+
return x & y ^ x & z ^ y & z;
|
|
5355
|
+
case 3:
|
|
5356
|
+
return x ^ y ^ z;
|
|
5357
|
+
}
|
|
5358
|
+
}
|
|
5359
|
+
function ROTL(x, n) {
|
|
5360
|
+
return x << n | x >>> 32 - n;
|
|
5361
|
+
}
|
|
5362
|
+
function sha1(bytes) {
|
|
5363
|
+
const K = [1518500249, 1859775393, 2400959708, 3395469782];
|
|
5364
|
+
const H = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
|
|
5365
|
+
if (typeof bytes === "string") {
|
|
5366
|
+
const msg2 = unescape(encodeURIComponent(bytes));
|
|
5367
|
+
bytes = [];
|
|
5368
|
+
for (let i = 0; i < msg2.length; ++i) {
|
|
5369
|
+
bytes.push(msg2.charCodeAt(i));
|
|
5370
|
+
}
|
|
5371
|
+
} else if (!Array.isArray(bytes)) {
|
|
5372
|
+
bytes = Array.prototype.slice.call(bytes);
|
|
5373
|
+
}
|
|
5374
|
+
bytes.push(128);
|
|
5375
|
+
const l = bytes.length / 4 + 2;
|
|
5376
|
+
const N = Math.ceil(l / 16);
|
|
5377
|
+
const M = new Array(N);
|
|
5378
|
+
for (let i = 0; i < N; ++i) {
|
|
5379
|
+
const arr = new Uint32Array(16);
|
|
5380
|
+
for (let j = 0; j < 16; ++j) {
|
|
5381
|
+
arr[j] = bytes[i * 64 + j * 4] << 24 | bytes[i * 64 + j * 4 + 1] << 16 | bytes[i * 64 + j * 4 + 2] << 8 | bytes[i * 64 + j * 4 + 3];
|
|
5382
|
+
}
|
|
5383
|
+
M[i] = arr;
|
|
5384
|
+
}
|
|
5385
|
+
M[N - 1][14] = (bytes.length - 1) * 8 / Math.pow(2, 32);
|
|
5386
|
+
M[N - 1][14] = Math.floor(M[N - 1][14]);
|
|
5387
|
+
M[N - 1][15] = (bytes.length - 1) * 8 & 4294967295;
|
|
5388
|
+
for (let i = 0; i < N; ++i) {
|
|
5389
|
+
const W = new Uint32Array(80);
|
|
5390
|
+
for (let t = 0; t < 16; ++t) {
|
|
5391
|
+
W[t] = M[i][t];
|
|
5392
|
+
}
|
|
5393
|
+
for (let t = 16; t < 80; ++t) {
|
|
5394
|
+
W[t] = ROTL(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1);
|
|
5395
|
+
}
|
|
5396
|
+
let a = H[0];
|
|
5397
|
+
let b = H[1];
|
|
5398
|
+
let c = H[2];
|
|
5399
|
+
let d = H[3];
|
|
5400
|
+
let e = H[4];
|
|
5401
|
+
for (let t = 0; t < 80; ++t) {
|
|
5402
|
+
const s = Math.floor(t / 20);
|
|
5403
|
+
const T = ROTL(a, 5) + f(s, b, c, d) + e + K[s] + W[t] >>> 0;
|
|
5404
|
+
e = d;
|
|
5405
|
+
d = c;
|
|
5406
|
+
c = ROTL(b, 30) >>> 0;
|
|
5407
|
+
b = a;
|
|
5408
|
+
a = T;
|
|
5409
|
+
}
|
|
5410
|
+
H[0] = H[0] + a >>> 0;
|
|
5411
|
+
H[1] = H[1] + b >>> 0;
|
|
5412
|
+
H[2] = H[2] + c >>> 0;
|
|
5413
|
+
H[3] = H[3] + d >>> 0;
|
|
5414
|
+
H[4] = H[4] + e >>> 0;
|
|
5415
|
+
}
|
|
5416
|
+
return [H[0] >> 24 & 255, H[0] >> 16 & 255, H[0] >> 8 & 255, H[0] & 255, H[1] >> 24 & 255, H[1] >> 16 & 255, H[1] >> 8 & 255, H[1] & 255, H[2] >> 24 & 255, H[2] >> 16 & 255, H[2] >> 8 & 255, H[2] & 255, H[3] >> 24 & 255, H[3] >> 16 & 255, H[3] >> 8 & 255, H[3] & 255, H[4] >> 24 & 255, H[4] >> 16 & 255, H[4] >> 8 & 255, H[4] & 255];
|
|
5417
|
+
}
|
|
5418
|
+
var _default = sha1;
|
|
5419
|
+
exports.default = _default;
|
|
5420
|
+
}
|
|
5421
|
+
});
|
|
5422
|
+
|
|
5423
|
+
// ../node_modules/uuid/dist/commonjs-browser/v5.js
|
|
5424
|
+
var require_v5 = __commonJS({
|
|
5425
|
+
"../node_modules/uuid/dist/commonjs-browser/v5.js"(exports) {
|
|
5426
|
+
"use strict";
|
|
5427
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5428
|
+
value: true
|
|
5429
|
+
});
|
|
5430
|
+
exports.default = void 0;
|
|
5431
|
+
var _v = _interopRequireDefault(require_v35());
|
|
5432
|
+
var _sha = _interopRequireDefault(require_sha1());
|
|
5433
|
+
function _interopRequireDefault(obj) {
|
|
5434
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5435
|
+
}
|
|
5436
|
+
var v5 = (0, _v.default)("v5", 80, _sha.default);
|
|
5437
|
+
var _default = v5;
|
|
5438
|
+
exports.default = _default;
|
|
5439
|
+
}
|
|
5440
|
+
});
|
|
5441
|
+
|
|
5442
|
+
// ../node_modules/uuid/dist/commonjs-browser/nil.js
|
|
5443
|
+
var require_nil = __commonJS({
|
|
5444
|
+
"../node_modules/uuid/dist/commonjs-browser/nil.js"(exports) {
|
|
5445
|
+
"use strict";
|
|
5446
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5447
|
+
value: true
|
|
5448
|
+
});
|
|
5449
|
+
exports.default = void 0;
|
|
5450
|
+
var _default = "00000000-0000-0000-0000-000000000000";
|
|
5451
|
+
exports.default = _default;
|
|
5452
|
+
}
|
|
5453
|
+
});
|
|
5454
|
+
|
|
5455
|
+
// ../node_modules/uuid/dist/commonjs-browser/version.js
|
|
5456
|
+
var require_version = __commonJS({
|
|
5457
|
+
"../node_modules/uuid/dist/commonjs-browser/version.js"(exports) {
|
|
5458
|
+
"use strict";
|
|
5459
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5460
|
+
value: true
|
|
5461
|
+
});
|
|
5462
|
+
exports.default = void 0;
|
|
5463
|
+
var _validate = _interopRequireDefault(require_validate());
|
|
5464
|
+
function _interopRequireDefault(obj) {
|
|
5465
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5466
|
+
}
|
|
5467
|
+
function version(uuid) {
|
|
5468
|
+
if (!(0, _validate.default)(uuid)) {
|
|
5469
|
+
throw TypeError("Invalid UUID");
|
|
5470
|
+
}
|
|
5471
|
+
return parseInt(uuid.slice(14, 15), 16);
|
|
5472
|
+
}
|
|
5473
|
+
var _default = version;
|
|
5474
|
+
exports.default = _default;
|
|
5475
|
+
}
|
|
5476
|
+
});
|
|
5477
|
+
|
|
5478
|
+
// ../node_modules/uuid/dist/commonjs-browser/index.js
|
|
5479
|
+
var require_commonjs_browser = __commonJS({
|
|
5480
|
+
"../node_modules/uuid/dist/commonjs-browser/index.js"(exports) {
|
|
5481
|
+
"use strict";
|
|
5482
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5483
|
+
value: true
|
|
5484
|
+
});
|
|
5485
|
+
Object.defineProperty(exports, "NIL", {
|
|
5486
|
+
enumerable: true,
|
|
5487
|
+
get: function get() {
|
|
5488
|
+
return _nil.default;
|
|
5489
|
+
}
|
|
5490
|
+
});
|
|
5491
|
+
Object.defineProperty(exports, "parse", {
|
|
5492
|
+
enumerable: true,
|
|
5493
|
+
get: function get() {
|
|
5494
|
+
return _parse.default;
|
|
5495
|
+
}
|
|
5496
|
+
});
|
|
5497
|
+
Object.defineProperty(exports, "stringify", {
|
|
5498
|
+
enumerable: true,
|
|
5499
|
+
get: function get() {
|
|
5500
|
+
return _stringify.default;
|
|
5501
|
+
}
|
|
5502
|
+
});
|
|
5503
|
+
Object.defineProperty(exports, "v1", {
|
|
5504
|
+
enumerable: true,
|
|
5505
|
+
get: function get() {
|
|
5506
|
+
return _v.default;
|
|
5507
|
+
}
|
|
5508
|
+
});
|
|
5509
|
+
Object.defineProperty(exports, "v3", {
|
|
5510
|
+
enumerable: true,
|
|
5511
|
+
get: function get() {
|
|
5512
|
+
return _v2.default;
|
|
5513
|
+
}
|
|
5514
|
+
});
|
|
5515
|
+
Object.defineProperty(exports, "v4", {
|
|
5516
|
+
enumerable: true,
|
|
5517
|
+
get: function get() {
|
|
5518
|
+
return _v3.default;
|
|
5519
|
+
}
|
|
5520
|
+
});
|
|
5521
|
+
Object.defineProperty(exports, "v5", {
|
|
5522
|
+
enumerable: true,
|
|
5523
|
+
get: function get() {
|
|
5524
|
+
return _v4.default;
|
|
5525
|
+
}
|
|
5526
|
+
});
|
|
5527
|
+
Object.defineProperty(exports, "validate", {
|
|
5528
|
+
enumerable: true,
|
|
5529
|
+
get: function get() {
|
|
5530
|
+
return _validate.default;
|
|
5531
|
+
}
|
|
5532
|
+
});
|
|
5533
|
+
Object.defineProperty(exports, "version", {
|
|
5534
|
+
enumerable: true,
|
|
5535
|
+
get: function get() {
|
|
5536
|
+
return _version.default;
|
|
5537
|
+
}
|
|
5538
|
+
});
|
|
5539
|
+
var _v = _interopRequireDefault(require_v1());
|
|
5540
|
+
var _v2 = _interopRequireDefault(require_v3());
|
|
5541
|
+
var _v3 = _interopRequireDefault(require_v4());
|
|
5542
|
+
var _v4 = _interopRequireDefault(require_v5());
|
|
5543
|
+
var _nil = _interopRequireDefault(require_nil());
|
|
5544
|
+
var _version = _interopRequireDefault(require_version());
|
|
5545
|
+
var _validate = _interopRequireDefault(require_validate());
|
|
5546
|
+
var _stringify = _interopRequireDefault(require_stringify());
|
|
5547
|
+
var _parse = _interopRequireDefault(require_parse());
|
|
5548
|
+
function _interopRequireDefault(obj) {
|
|
5549
|
+
return obj && obj.__esModule ? obj : { default: obj };
|
|
5550
|
+
}
|
|
5551
|
+
}
|
|
5552
|
+
});
|
|
5553
|
+
|
|
5554
|
+
// ../node_modules/@inrupt/solid-client-authn-core/dist/index.js
|
|
5555
|
+
var require_dist = __commonJS({
|
|
5556
|
+
"../node_modules/@inrupt/solid-client-authn-core/dist/index.js"(exports) {
|
|
5557
|
+
"use strict";
|
|
5558
|
+
var crossFetch2 = require_browser_ponyfill();
|
|
5559
|
+
var jose = (init_browser(), __toCommonJS(browser_exports));
|
|
5560
|
+
var uuid = require_commonjs_browser();
|
|
5561
|
+
var SOLID_CLIENT_AUTHN_KEY_PREFIX = "solidClientAuthn:";
|
|
5562
|
+
var PREFERRED_SIGNING_ALG = ["ES256", "RS256"];
|
|
5563
|
+
var EVENTS = {
|
|
5564
|
+
ERROR: "error",
|
|
5565
|
+
LOGIN: "login",
|
|
5566
|
+
LOGOUT: "logout",
|
|
5567
|
+
NEW_REFRESH_TOKEN: "newRefreshToken",
|
|
5568
|
+
SESSION_EXPIRED: "sessionExpired",
|
|
5569
|
+
SESSION_EXTENDED: "sessionExtended",
|
|
5570
|
+
SESSION_RESTORED: "sessionRestore",
|
|
5571
|
+
TIMEOUT_SET: "timeoutSet"
|
|
5572
|
+
};
|
|
5573
|
+
var REFRESH_BEFORE_EXPIRATION_SECONDS = 5;
|
|
5574
|
+
var SCOPE_OPENID = "openid";
|
|
5575
|
+
var SCOPE_OFFLINE = "offline_access";
|
|
5576
|
+
var SCOPE_WEBID = "webid";
|
|
5577
|
+
var DEFAULT_SCOPES = [SCOPE_OPENID, SCOPE_OFFLINE, SCOPE_WEBID].join(" ");
|
|
5578
|
+
var AggregateHandler = class {
|
|
5579
|
+
constructor(handleables) {
|
|
5580
|
+
this.handleables = handleables;
|
|
5581
|
+
}
|
|
5582
|
+
async getProperHandler(params) {
|
|
5583
|
+
const canHandleList = await Promise.all(this.handleables.map((handleable) => handleable.canHandle(...params)));
|
|
5584
|
+
for (let i = 0; i < canHandleList.length; i += 1) {
|
|
5585
|
+
if (canHandleList[i]) {
|
|
5586
|
+
return this.handleables[i];
|
|
5587
|
+
}
|
|
5588
|
+
}
|
|
5589
|
+
return null;
|
|
5590
|
+
}
|
|
5591
|
+
async canHandle(...params) {
|
|
5592
|
+
return await this.getProperHandler(params) !== null;
|
|
5593
|
+
}
|
|
5594
|
+
async handle(...params) {
|
|
5595
|
+
const handler = await this.getProperHandler(params);
|
|
5596
|
+
if (handler) {
|
|
5597
|
+
return handler.handle(...params);
|
|
5598
|
+
}
|
|
5599
|
+
throw new Error(`[${this.constructor.name}] cannot find a suitable handler for: ${params.map((param) => {
|
|
5600
|
+
try {
|
|
5601
|
+
return JSON.stringify(param);
|
|
5602
|
+
} catch (err) {
|
|
5603
|
+
return param.toString();
|
|
5604
|
+
}
|
|
5605
|
+
}).join(", ")}`);
|
|
5606
|
+
}
|
|
5607
|
+
};
|
|
5000
5608
|
async function fetchJwks2(jwksIri, issuerIri) {
|
|
5001
|
-
const jwksResponse = await
|
|
5609
|
+
const jwksResponse = await crossFetch2.fetch(jwksIri);
|
|
5002
5610
|
if (jwksResponse.status !== 200) {
|
|
5003
5611
|
throw new Error(`Could not fetch JWKS for [${issuerIri}] at [${jwksIri}]: ${jwksResponse.status} ${jwksResponse.statusText}`);
|
|
5004
5612
|
}
|
|
@@ -5010,12 +5618,11 @@ ${newlined}
|
|
|
5010
5618
|
}
|
|
5011
5619
|
return jwk;
|
|
5012
5620
|
}
|
|
5013
|
-
exports.fetchJwks = fetchJwks2;
|
|
5014
5621
|
async function getWebidFromTokenPayload(idToken, jwksIri, issuerIri, clientId) {
|
|
5015
5622
|
const jwk = await fetchJwks2(jwksIri, issuerIri);
|
|
5016
5623
|
let payload;
|
|
5017
5624
|
try {
|
|
5018
|
-
const { payload: verifiedPayload } = await
|
|
5625
|
+
const { payload: verifiedPayload } = await jose.jwtVerify(idToken, await jose.importJWK(jwk), {
|
|
5019
5626
|
issuer: issuerIri,
|
|
5020
5627
|
audience: clientId
|
|
5021
5628
|
});
|
|
@@ -5036,39 +5643,10 @@ ${newlined}
|
|
|
5036
5643
|
throw new Error(`The token has no 'webid' claim, and its 'sub' claim of [${payload.sub}] is invalid as a URL - error [${e}].`);
|
|
5037
5644
|
}
|
|
5038
5645
|
}
|
|
5039
|
-
exports.getWebidFromTokenPayload = getWebidFromTokenPayload;
|
|
5040
|
-
}
|
|
5041
|
-
});
|
|
5042
|
-
|
|
5043
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/sessionInfo/ISessionInfo.js
|
|
5044
|
-
var require_ISessionInfo = __commonJS({
|
|
5045
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/sessionInfo/ISessionInfo.js"(exports) {
|
|
5046
|
-
"use strict";
|
|
5047
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5048
|
-
exports.isSupportedTokenType = void 0;
|
|
5049
5646
|
function isSupportedTokenType(token) {
|
|
5050
5647
|
return typeof token === "string" && ["DPoP", "Bearer"].includes(token);
|
|
5051
5648
|
}
|
|
5052
|
-
|
|
5053
|
-
}
|
|
5054
|
-
});
|
|
5055
|
-
|
|
5056
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/sessionInfo/ISessionInfoManager.js
|
|
5057
|
-
var require_ISessionInfoManager = __commonJS({
|
|
5058
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/sessionInfo/ISessionInfoManager.js"(exports) {
|
|
5059
|
-
"use strict";
|
|
5060
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5061
|
-
exports.USER_SESSION_PREFIX = void 0;
|
|
5062
|
-
exports.USER_SESSION_PREFIX = "solidClientAuthenticationUser";
|
|
5063
|
-
}
|
|
5064
|
-
});
|
|
5065
|
-
|
|
5066
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/login/oidc/IClientRegistrar.js
|
|
5067
|
-
var require_IClientRegistrar = __commonJS({
|
|
5068
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/login/oidc/IClientRegistrar.js"(exports) {
|
|
5069
|
-
"use strict";
|
|
5070
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5071
|
-
exports.handleRegistration = exports.determineSigningAlg = void 0;
|
|
5649
|
+
var USER_SESSION_PREFIX = "solidClientAuthenticationUser";
|
|
5072
5650
|
function isValidUrl(url) {
|
|
5073
5651
|
try {
|
|
5074
5652
|
new URL(url);
|
|
@@ -5083,7 +5661,6 @@ ${newlined}
|
|
|
5083
5661
|
return supported.includes(signingAlg);
|
|
5084
5662
|
})) !== null && _a !== void 0 ? _a : null;
|
|
5085
5663
|
}
|
|
5086
|
-
exports.determineSigningAlg = determineSigningAlg;
|
|
5087
5664
|
function determineClientType(options, issuerConfig) {
|
|
5088
5665
|
if (options.clientId !== void 0 && !isValidUrl(options.clientId)) {
|
|
5089
5666
|
return "static";
|
|
@@ -5122,25 +5699,9 @@ ${newlined}
|
|
|
5122
5699
|
clientType
|
|
5123
5700
|
};
|
|
5124
5701
|
}
|
|
5125
|
-
exports.handleRegistration = handleRegistration;
|
|
5126
|
-
}
|
|
5127
|
-
});
|
|
5128
|
-
|
|
5129
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/storage/StorageUtility.js
|
|
5130
|
-
var require_StorageUtility = __commonJS({
|
|
5131
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/storage/StorageUtility.js"(exports) {
|
|
5132
|
-
"use strict";
|
|
5133
|
-
var __importDefault = exports && exports.__importDefault || function(mod) {
|
|
5134
|
-
return mod && mod.__esModule ? mod : { "default": mod };
|
|
5135
|
-
};
|
|
5136
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5137
|
-
exports.saveSessionInfoToStorage = exports.loadOidcContextFromStorage = exports.getSessionIdFromOauthState = void 0;
|
|
5138
|
-
var jose_1 = (init_browser(), __toCommonJS(browser_exports));
|
|
5139
|
-
var InruptError_1 = __importDefault(require_InruptError());
|
|
5140
5702
|
async function getSessionIdFromOauthState(storageUtility, oauthState) {
|
|
5141
5703
|
return storageUtility.getForUser(oauthState, "sessionId");
|
|
5142
5704
|
}
|
|
5143
|
-
exports.getSessionIdFromOauthState = getSessionIdFromOauthState;
|
|
5144
5705
|
async function loadOidcContextFromStorage(sessionId, storageUtility, configFetcher) {
|
|
5145
5706
|
try {
|
|
5146
5707
|
const [issuerIri, codeVerifier, storedRedirectIri, dpop] = await Promise.all([
|
|
@@ -5163,7 +5724,6 @@ ${newlined}
|
|
|
5163
5724
|
throw new Error(`Failed to retrieve OIDC context from storage associated with session [${sessionId}]: ${e}`);
|
|
5164
5725
|
}
|
|
5165
5726
|
}
|
|
5166
|
-
exports.loadOidcContextFromStorage = loadOidcContextFromStorage;
|
|
5167
5727
|
async function saveSessionInfoToStorage(storageUtility, sessionId, webId, isLoggedIn, refreshToken, secure, dpopKey) {
|
|
5168
5728
|
if (refreshToken !== void 0) {
|
|
5169
5729
|
await storageUtility.setForUser(sessionId, { refreshToken }, { secure });
|
|
@@ -5177,11 +5737,10 @@ ${newlined}
|
|
|
5177
5737
|
if (dpopKey !== void 0) {
|
|
5178
5738
|
await storageUtility.setForUser(sessionId, {
|
|
5179
5739
|
publicKey: JSON.stringify(dpopKey.publicKey),
|
|
5180
|
-
privateKey: JSON.stringify(await
|
|
5740
|
+
privateKey: JSON.stringify(await jose.exportJWK(dpopKey.privateKey))
|
|
5181
5741
|
}, { secure });
|
|
5182
5742
|
}
|
|
5183
5743
|
}
|
|
5184
|
-
exports.saveSessionInfoToStorage = saveSessionInfoToStorage;
|
|
5185
5744
|
var StorageUtility = class {
|
|
5186
5745
|
constructor(secureStorage, insecureStorage) {
|
|
5187
5746
|
this.secureStorage = secureStorage;
|
|
@@ -5198,7 +5757,7 @@ ${newlined}
|
|
|
5198
5757
|
try {
|
|
5199
5758
|
return JSON.parse(stored);
|
|
5200
5759
|
} catch (err) {
|
|
5201
|
-
throw new
|
|
5760
|
+
throw new Error(`Data for user [${userId}] in [${secure ? "secure" : "unsecure"}] storage is corrupted - expected valid JSON, but got: ${stored}`);
|
|
5202
5761
|
}
|
|
5203
5762
|
}
|
|
5204
5763
|
async setUserData(userId, data, secure) {
|
|
@@ -5207,7 +5766,7 @@ ${newlined}
|
|
|
5207
5766
|
async get(key, options) {
|
|
5208
5767
|
const value = await ((options === null || options === void 0 ? void 0 : options.secure) ? this.secureStorage : this.insecureStorage).get(key);
|
|
5209
5768
|
if (value === void 0 && (options === null || options === void 0 ? void 0 : options.errorIfNull)) {
|
|
5210
|
-
throw new
|
|
5769
|
+
throw new Error(`[${key}] is not stored`);
|
|
5211
5770
|
}
|
|
5212
5771
|
return value;
|
|
5213
5772
|
}
|
|
@@ -5225,7 +5784,7 @@ ${newlined}
|
|
|
5225
5784
|
}
|
|
5226
5785
|
value = userData[key];
|
|
5227
5786
|
if (value === void 0 && (options === null || options === void 0 ? void 0 : options.errorIfNull)) {
|
|
5228
|
-
throw new
|
|
5787
|
+
throw new Error(`Field [${key}] for user [${userId}] is not stored`);
|
|
5229
5788
|
}
|
|
5230
5789
|
return value || void 0;
|
|
5231
5790
|
}
|
|
@@ -5247,15 +5806,6 @@ ${newlined}
|
|
|
5247
5806
|
await ((options === null || options === void 0 ? void 0 : options.secure) ? this.secureStorage : this.insecureStorage).delete(this.getKey(userId));
|
|
5248
5807
|
}
|
|
5249
5808
|
};
|
|
5250
|
-
exports.default = StorageUtility;
|
|
5251
|
-
}
|
|
5252
|
-
});
|
|
5253
|
-
|
|
5254
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/storage/InMemoryStorage.js
|
|
5255
|
-
var require_InMemoryStorage = __commonJS({
|
|
5256
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/storage/InMemoryStorage.js"(exports) {
|
|
5257
|
-
"use strict";
|
|
5258
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5259
5809
|
var InMemoryStorage = class {
|
|
5260
5810
|
constructor() {
|
|
5261
5811
|
this.map = {};
|
|
@@ -5270,60 +5820,22 @@ ${newlined}
|
|
|
5270
5820
|
delete this.map[key];
|
|
5271
5821
|
}
|
|
5272
5822
|
};
|
|
5273
|
-
exports.default = InMemoryStorage;
|
|
5274
|
-
}
|
|
5275
|
-
});
|
|
5276
|
-
|
|
5277
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/errors/ConfigurationError.js
|
|
5278
|
-
var require_ConfigurationError = __commonJS({
|
|
5279
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/errors/ConfigurationError.js"(exports) {
|
|
5280
|
-
"use strict";
|
|
5281
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5282
5823
|
var ConfigurationError = class extends Error {
|
|
5283
5824
|
constructor(message2) {
|
|
5284
5825
|
super(message2);
|
|
5285
5826
|
}
|
|
5286
5827
|
};
|
|
5287
|
-
exports.default = ConfigurationError;
|
|
5288
|
-
}
|
|
5289
|
-
});
|
|
5290
|
-
|
|
5291
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/errors/NotImplementedError.js
|
|
5292
|
-
var require_NotImplementedError = __commonJS({
|
|
5293
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/errors/NotImplementedError.js"(exports) {
|
|
5294
|
-
"use strict";
|
|
5295
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5296
5828
|
var NotImplementedError = class extends Error {
|
|
5297
5829
|
constructor(methodName) {
|
|
5298
5830
|
super(`[${methodName}] is not implemented`);
|
|
5299
5831
|
}
|
|
5300
5832
|
};
|
|
5301
|
-
exports.default = NotImplementedError;
|
|
5302
|
-
}
|
|
5303
|
-
});
|
|
5304
|
-
|
|
5305
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/errors/InvalidResponseError.js
|
|
5306
|
-
var require_InvalidResponseError = __commonJS({
|
|
5307
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/errors/InvalidResponseError.js"(exports) {
|
|
5308
|
-
"use strict";
|
|
5309
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5310
|
-
exports.InvalidResponseError = void 0;
|
|
5311
5833
|
var InvalidResponseError = class extends Error {
|
|
5312
5834
|
constructor(missingFields) {
|
|
5313
5835
|
super(`Invalid response from OIDC provider: missing fields ${missingFields}`);
|
|
5314
5836
|
this.missingFields = missingFields;
|
|
5315
5837
|
}
|
|
5316
5838
|
};
|
|
5317
|
-
exports.InvalidResponseError = InvalidResponseError;
|
|
5318
|
-
}
|
|
5319
|
-
});
|
|
5320
|
-
|
|
5321
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/errors/OidcProviderError.js
|
|
5322
|
-
var require_OidcProviderError = __commonJS({
|
|
5323
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/errors/OidcProviderError.js"(exports) {
|
|
5324
|
-
"use strict";
|
|
5325
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5326
|
-
exports.OidcProviderError = void 0;
|
|
5327
5839
|
var OidcProviderError = class extends Error {
|
|
5328
5840
|
constructor(message2, error2, errorDescription) {
|
|
5329
5841
|
super(message2);
|
|
@@ -5331,596 +5843,39 @@ ${newlined}
|
|
|
5331
5843
|
this.errorDescription = errorDescription;
|
|
5332
5844
|
}
|
|
5333
5845
|
};
|
|
5334
|
-
exports.OidcProviderError = OidcProviderError;
|
|
5335
|
-
}
|
|
5336
|
-
});
|
|
5337
|
-
|
|
5338
|
-
// ../node_modules/uuid/dist/esm-browser/rng.js
|
|
5339
|
-
function rng() {
|
|
5340
|
-
if (!getRandomValues) {
|
|
5341
|
-
getRandomValues = typeof crypto !== "undefined" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto !== "undefined" && typeof msCrypto.getRandomValues === "function" && msCrypto.getRandomValues.bind(msCrypto);
|
|
5342
|
-
if (!getRandomValues) {
|
|
5343
|
-
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
5344
|
-
}
|
|
5345
|
-
}
|
|
5346
|
-
return getRandomValues(rnds8);
|
|
5347
|
-
}
|
|
5348
|
-
var getRandomValues, rnds8;
|
|
5349
|
-
var init_rng = __esm({
|
|
5350
|
-
"../node_modules/uuid/dist/esm-browser/rng.js"() {
|
|
5351
|
-
rnds8 = new Uint8Array(16);
|
|
5352
|
-
}
|
|
5353
|
-
});
|
|
5354
|
-
|
|
5355
|
-
// ../node_modules/uuid/dist/esm-browser/regex.js
|
|
5356
|
-
var regex_default;
|
|
5357
|
-
var init_regex = __esm({
|
|
5358
|
-
"../node_modules/uuid/dist/esm-browser/regex.js"() {
|
|
5359
|
-
regex_default = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
|
|
5360
|
-
}
|
|
5361
|
-
});
|
|
5362
|
-
|
|
5363
|
-
// ../node_modules/uuid/dist/esm-browser/validate.js
|
|
5364
|
-
function validate(uuid) {
|
|
5365
|
-
return typeof uuid === "string" && regex_default.test(uuid);
|
|
5366
|
-
}
|
|
5367
|
-
var validate_default;
|
|
5368
|
-
var init_validate = __esm({
|
|
5369
|
-
"../node_modules/uuid/dist/esm-browser/validate.js"() {
|
|
5370
|
-
init_regex();
|
|
5371
|
-
validate_default = validate;
|
|
5372
|
-
}
|
|
5373
|
-
});
|
|
5374
|
-
|
|
5375
|
-
// ../node_modules/uuid/dist/esm-browser/stringify.js
|
|
5376
|
-
function stringify(arr) {
|
|
5377
|
-
var offset = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
|
|
5378
|
-
var uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + "-" + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + "-" + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + "-" + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + "-" + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase();
|
|
5379
|
-
if (!validate_default(uuid)) {
|
|
5380
|
-
throw TypeError("Stringified UUID is invalid");
|
|
5381
|
-
}
|
|
5382
|
-
return uuid;
|
|
5383
|
-
}
|
|
5384
|
-
var byteToHex, i, stringify_default;
|
|
5385
|
-
var init_stringify = __esm({
|
|
5386
|
-
"../node_modules/uuid/dist/esm-browser/stringify.js"() {
|
|
5387
|
-
init_validate();
|
|
5388
|
-
byteToHex = [];
|
|
5389
|
-
for (i = 0; i < 256; ++i) {
|
|
5390
|
-
byteToHex.push((i + 256).toString(16).substr(1));
|
|
5391
|
-
}
|
|
5392
|
-
stringify_default = stringify;
|
|
5393
|
-
}
|
|
5394
|
-
});
|
|
5395
|
-
|
|
5396
|
-
// ../node_modules/uuid/dist/esm-browser/v1.js
|
|
5397
|
-
function v1(options, buf, offset) {
|
|
5398
|
-
var i = buf && offset || 0;
|
|
5399
|
-
var b = buf || new Array(16);
|
|
5400
|
-
options = options || {};
|
|
5401
|
-
var node = options.node || _nodeId;
|
|
5402
|
-
var clockseq = options.clockseq !== void 0 ? options.clockseq : _clockseq;
|
|
5403
|
-
if (node == null || clockseq == null) {
|
|
5404
|
-
var seedBytes = options.random || (options.rng || rng)();
|
|
5405
|
-
if (node == null) {
|
|
5406
|
-
node = _nodeId = [seedBytes[0] | 1, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]];
|
|
5407
|
-
}
|
|
5408
|
-
if (clockseq == null) {
|
|
5409
|
-
clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 16383;
|
|
5410
|
-
}
|
|
5411
|
-
}
|
|
5412
|
-
var msecs = options.msecs !== void 0 ? options.msecs : Date.now();
|
|
5413
|
-
var nsecs = options.nsecs !== void 0 ? options.nsecs : _lastNSecs + 1;
|
|
5414
|
-
var dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 1e4;
|
|
5415
|
-
if (dt < 0 && options.clockseq === void 0) {
|
|
5416
|
-
clockseq = clockseq + 1 & 16383;
|
|
5417
|
-
}
|
|
5418
|
-
if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === void 0) {
|
|
5419
|
-
nsecs = 0;
|
|
5420
|
-
}
|
|
5421
|
-
if (nsecs >= 1e4) {
|
|
5422
|
-
throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");
|
|
5423
|
-
}
|
|
5424
|
-
_lastMSecs = msecs;
|
|
5425
|
-
_lastNSecs = nsecs;
|
|
5426
|
-
_clockseq = clockseq;
|
|
5427
|
-
msecs += 122192928e5;
|
|
5428
|
-
var tl = ((msecs & 268435455) * 1e4 + nsecs) % 4294967296;
|
|
5429
|
-
b[i++] = tl >>> 24 & 255;
|
|
5430
|
-
b[i++] = tl >>> 16 & 255;
|
|
5431
|
-
b[i++] = tl >>> 8 & 255;
|
|
5432
|
-
b[i++] = tl & 255;
|
|
5433
|
-
var tmh = msecs / 4294967296 * 1e4 & 268435455;
|
|
5434
|
-
b[i++] = tmh >>> 8 & 255;
|
|
5435
|
-
b[i++] = tmh & 255;
|
|
5436
|
-
b[i++] = tmh >>> 24 & 15 | 16;
|
|
5437
|
-
b[i++] = tmh >>> 16 & 255;
|
|
5438
|
-
b[i++] = clockseq >>> 8 | 128;
|
|
5439
|
-
b[i++] = clockseq & 255;
|
|
5440
|
-
for (var n = 0; n < 6; ++n) {
|
|
5441
|
-
b[i + n] = node[n];
|
|
5442
|
-
}
|
|
5443
|
-
return buf || stringify_default(b);
|
|
5444
|
-
}
|
|
5445
|
-
var _nodeId, _clockseq, _lastMSecs, _lastNSecs, v1_default;
|
|
5446
|
-
var init_v1 = __esm({
|
|
5447
|
-
"../node_modules/uuid/dist/esm-browser/v1.js"() {
|
|
5448
|
-
init_rng();
|
|
5449
|
-
init_stringify();
|
|
5450
|
-
_lastMSecs = 0;
|
|
5451
|
-
_lastNSecs = 0;
|
|
5452
|
-
v1_default = v1;
|
|
5453
|
-
}
|
|
5454
|
-
});
|
|
5455
|
-
|
|
5456
|
-
// ../node_modules/uuid/dist/esm-browser/parse.js
|
|
5457
|
-
function parse2(uuid) {
|
|
5458
|
-
if (!validate_default(uuid)) {
|
|
5459
|
-
throw TypeError("Invalid UUID");
|
|
5460
|
-
}
|
|
5461
|
-
var v;
|
|
5462
|
-
var arr = new Uint8Array(16);
|
|
5463
|
-
arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24;
|
|
5464
|
-
arr[1] = v >>> 16 & 255;
|
|
5465
|
-
arr[2] = v >>> 8 & 255;
|
|
5466
|
-
arr[3] = v & 255;
|
|
5467
|
-
arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8;
|
|
5468
|
-
arr[5] = v & 255;
|
|
5469
|
-
arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8;
|
|
5470
|
-
arr[7] = v & 255;
|
|
5471
|
-
arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8;
|
|
5472
|
-
arr[9] = v & 255;
|
|
5473
|
-
arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 1099511627776 & 255;
|
|
5474
|
-
arr[11] = v / 4294967296 & 255;
|
|
5475
|
-
arr[12] = v >>> 24 & 255;
|
|
5476
|
-
arr[13] = v >>> 16 & 255;
|
|
5477
|
-
arr[14] = v >>> 8 & 255;
|
|
5478
|
-
arr[15] = v & 255;
|
|
5479
|
-
return arr;
|
|
5480
|
-
}
|
|
5481
|
-
var parse_default;
|
|
5482
|
-
var init_parse = __esm({
|
|
5483
|
-
"../node_modules/uuid/dist/esm-browser/parse.js"() {
|
|
5484
|
-
init_validate();
|
|
5485
|
-
parse_default = parse2;
|
|
5486
|
-
}
|
|
5487
|
-
});
|
|
5488
|
-
|
|
5489
|
-
// ../node_modules/uuid/dist/esm-browser/v35.js
|
|
5490
|
-
function stringToBytes(str) {
|
|
5491
|
-
str = unescape(encodeURIComponent(str));
|
|
5492
|
-
var bytes = [];
|
|
5493
|
-
for (var i = 0; i < str.length; ++i) {
|
|
5494
|
-
bytes.push(str.charCodeAt(i));
|
|
5495
|
-
}
|
|
5496
|
-
return bytes;
|
|
5497
|
-
}
|
|
5498
|
-
function v35_default(name, version2, hashfunc) {
|
|
5499
|
-
function generateUUID(value, namespace, buf, offset) {
|
|
5500
|
-
if (typeof value === "string") {
|
|
5501
|
-
value = stringToBytes(value);
|
|
5502
|
-
}
|
|
5503
|
-
if (typeof namespace === "string") {
|
|
5504
|
-
namespace = parse_default(namespace);
|
|
5505
|
-
}
|
|
5506
|
-
if (namespace.length !== 16) {
|
|
5507
|
-
throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
|
|
5508
|
-
}
|
|
5509
|
-
var bytes = new Uint8Array(16 + value.length);
|
|
5510
|
-
bytes.set(namespace);
|
|
5511
|
-
bytes.set(value, namespace.length);
|
|
5512
|
-
bytes = hashfunc(bytes);
|
|
5513
|
-
bytes[6] = bytes[6] & 15 | version2;
|
|
5514
|
-
bytes[8] = bytes[8] & 63 | 128;
|
|
5515
|
-
if (buf) {
|
|
5516
|
-
offset = offset || 0;
|
|
5517
|
-
for (var i = 0; i < 16; ++i) {
|
|
5518
|
-
buf[offset + i] = bytes[i];
|
|
5519
|
-
}
|
|
5520
|
-
return buf;
|
|
5521
|
-
}
|
|
5522
|
-
return stringify_default(bytes);
|
|
5523
|
-
}
|
|
5524
|
-
try {
|
|
5525
|
-
generateUUID.name = name;
|
|
5526
|
-
} catch (err) {
|
|
5527
|
-
}
|
|
5528
|
-
generateUUID.DNS = DNS;
|
|
5529
|
-
generateUUID.URL = URL2;
|
|
5530
|
-
return generateUUID;
|
|
5531
|
-
}
|
|
5532
|
-
var DNS, URL2;
|
|
5533
|
-
var init_v35 = __esm({
|
|
5534
|
-
"../node_modules/uuid/dist/esm-browser/v35.js"() {
|
|
5535
|
-
init_stringify();
|
|
5536
|
-
init_parse();
|
|
5537
|
-
DNS = "6ba7b810-9dad-11d1-80b4-00c04fd430c8";
|
|
5538
|
-
URL2 = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
|
|
5539
|
-
}
|
|
5540
|
-
});
|
|
5541
|
-
|
|
5542
|
-
// ../node_modules/uuid/dist/esm-browser/md5.js
|
|
5543
|
-
function md5(bytes) {
|
|
5544
|
-
if (typeof bytes === "string") {
|
|
5545
|
-
var msg2 = unescape(encodeURIComponent(bytes));
|
|
5546
|
-
bytes = new Uint8Array(msg2.length);
|
|
5547
|
-
for (var i = 0; i < msg2.length; ++i) {
|
|
5548
|
-
bytes[i] = msg2.charCodeAt(i);
|
|
5549
|
-
}
|
|
5550
|
-
}
|
|
5551
|
-
return md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), bytes.length * 8));
|
|
5552
|
-
}
|
|
5553
|
-
function md5ToHexEncodedArray(input) {
|
|
5554
|
-
var output = [];
|
|
5555
|
-
var length32 = input.length * 32;
|
|
5556
|
-
var hexTab = "0123456789abcdef";
|
|
5557
|
-
for (var i = 0; i < length32; i += 8) {
|
|
5558
|
-
var x = input[i >> 5] >>> i % 32 & 255;
|
|
5559
|
-
var hex = parseInt(hexTab.charAt(x >>> 4 & 15) + hexTab.charAt(x & 15), 16);
|
|
5560
|
-
output.push(hex);
|
|
5561
|
-
}
|
|
5562
|
-
return output;
|
|
5563
|
-
}
|
|
5564
|
-
function getOutputLength(inputLength8) {
|
|
5565
|
-
return (inputLength8 + 64 >>> 9 << 4) + 14 + 1;
|
|
5566
|
-
}
|
|
5567
|
-
function wordsToMd5(x, len) {
|
|
5568
|
-
x[len >> 5] |= 128 << len % 32;
|
|
5569
|
-
x[getOutputLength(len) - 1] = len;
|
|
5570
|
-
var a = 1732584193;
|
|
5571
|
-
var b = -271733879;
|
|
5572
|
-
var c = -1732584194;
|
|
5573
|
-
var d = 271733878;
|
|
5574
|
-
for (var i = 0; i < x.length; i += 16) {
|
|
5575
|
-
var olda = a;
|
|
5576
|
-
var oldb = b;
|
|
5577
|
-
var oldc = c;
|
|
5578
|
-
var oldd = d;
|
|
5579
|
-
a = md5ff(a, b, c, d, x[i], 7, -680876936);
|
|
5580
|
-
d = md5ff(d, a, b, c, x[i + 1], 12, -389564586);
|
|
5581
|
-
c = md5ff(c, d, a, b, x[i + 2], 17, 606105819);
|
|
5582
|
-
b = md5ff(b, c, d, a, x[i + 3], 22, -1044525330);
|
|
5583
|
-
a = md5ff(a, b, c, d, x[i + 4], 7, -176418897);
|
|
5584
|
-
d = md5ff(d, a, b, c, x[i + 5], 12, 1200080426);
|
|
5585
|
-
c = md5ff(c, d, a, b, x[i + 6], 17, -1473231341);
|
|
5586
|
-
b = md5ff(b, c, d, a, x[i + 7], 22, -45705983);
|
|
5587
|
-
a = md5ff(a, b, c, d, x[i + 8], 7, 1770035416);
|
|
5588
|
-
d = md5ff(d, a, b, c, x[i + 9], 12, -1958414417);
|
|
5589
|
-
c = md5ff(c, d, a, b, x[i + 10], 17, -42063);
|
|
5590
|
-
b = md5ff(b, c, d, a, x[i + 11], 22, -1990404162);
|
|
5591
|
-
a = md5ff(a, b, c, d, x[i + 12], 7, 1804603682);
|
|
5592
|
-
d = md5ff(d, a, b, c, x[i + 13], 12, -40341101);
|
|
5593
|
-
c = md5ff(c, d, a, b, x[i + 14], 17, -1502002290);
|
|
5594
|
-
b = md5ff(b, c, d, a, x[i + 15], 22, 1236535329);
|
|
5595
|
-
a = md5gg(a, b, c, d, x[i + 1], 5, -165796510);
|
|
5596
|
-
d = md5gg(d, a, b, c, x[i + 6], 9, -1069501632);
|
|
5597
|
-
c = md5gg(c, d, a, b, x[i + 11], 14, 643717713);
|
|
5598
|
-
b = md5gg(b, c, d, a, x[i], 20, -373897302);
|
|
5599
|
-
a = md5gg(a, b, c, d, x[i + 5], 5, -701558691);
|
|
5600
|
-
d = md5gg(d, a, b, c, x[i + 10], 9, 38016083);
|
|
5601
|
-
c = md5gg(c, d, a, b, x[i + 15], 14, -660478335);
|
|
5602
|
-
b = md5gg(b, c, d, a, x[i + 4], 20, -405537848);
|
|
5603
|
-
a = md5gg(a, b, c, d, x[i + 9], 5, 568446438);
|
|
5604
|
-
d = md5gg(d, a, b, c, x[i + 14], 9, -1019803690);
|
|
5605
|
-
c = md5gg(c, d, a, b, x[i + 3], 14, -187363961);
|
|
5606
|
-
b = md5gg(b, c, d, a, x[i + 8], 20, 1163531501);
|
|
5607
|
-
a = md5gg(a, b, c, d, x[i + 13], 5, -1444681467);
|
|
5608
|
-
d = md5gg(d, a, b, c, x[i + 2], 9, -51403784);
|
|
5609
|
-
c = md5gg(c, d, a, b, x[i + 7], 14, 1735328473);
|
|
5610
|
-
b = md5gg(b, c, d, a, x[i + 12], 20, -1926607734);
|
|
5611
|
-
a = md5hh(a, b, c, d, x[i + 5], 4, -378558);
|
|
5612
|
-
d = md5hh(d, a, b, c, x[i + 8], 11, -2022574463);
|
|
5613
|
-
c = md5hh(c, d, a, b, x[i + 11], 16, 1839030562);
|
|
5614
|
-
b = md5hh(b, c, d, a, x[i + 14], 23, -35309556);
|
|
5615
|
-
a = md5hh(a, b, c, d, x[i + 1], 4, -1530992060);
|
|
5616
|
-
d = md5hh(d, a, b, c, x[i + 4], 11, 1272893353);
|
|
5617
|
-
c = md5hh(c, d, a, b, x[i + 7], 16, -155497632);
|
|
5618
|
-
b = md5hh(b, c, d, a, x[i + 10], 23, -1094730640);
|
|
5619
|
-
a = md5hh(a, b, c, d, x[i + 13], 4, 681279174);
|
|
5620
|
-
d = md5hh(d, a, b, c, x[i], 11, -358537222);
|
|
5621
|
-
c = md5hh(c, d, a, b, x[i + 3], 16, -722521979);
|
|
5622
|
-
b = md5hh(b, c, d, a, x[i + 6], 23, 76029189);
|
|
5623
|
-
a = md5hh(a, b, c, d, x[i + 9], 4, -640364487);
|
|
5624
|
-
d = md5hh(d, a, b, c, x[i + 12], 11, -421815835);
|
|
5625
|
-
c = md5hh(c, d, a, b, x[i + 15], 16, 530742520);
|
|
5626
|
-
b = md5hh(b, c, d, a, x[i + 2], 23, -995338651);
|
|
5627
|
-
a = md5ii(a, b, c, d, x[i], 6, -198630844);
|
|
5628
|
-
d = md5ii(d, a, b, c, x[i + 7], 10, 1126891415);
|
|
5629
|
-
c = md5ii(c, d, a, b, x[i + 14], 15, -1416354905);
|
|
5630
|
-
b = md5ii(b, c, d, a, x[i + 5], 21, -57434055);
|
|
5631
|
-
a = md5ii(a, b, c, d, x[i + 12], 6, 1700485571);
|
|
5632
|
-
d = md5ii(d, a, b, c, x[i + 3], 10, -1894986606);
|
|
5633
|
-
c = md5ii(c, d, a, b, x[i + 10], 15, -1051523);
|
|
5634
|
-
b = md5ii(b, c, d, a, x[i + 1], 21, -2054922799);
|
|
5635
|
-
a = md5ii(a, b, c, d, x[i + 8], 6, 1873313359);
|
|
5636
|
-
d = md5ii(d, a, b, c, x[i + 15], 10, -30611744);
|
|
5637
|
-
c = md5ii(c, d, a, b, x[i + 6], 15, -1560198380);
|
|
5638
|
-
b = md5ii(b, c, d, a, x[i + 13], 21, 1309151649);
|
|
5639
|
-
a = md5ii(a, b, c, d, x[i + 4], 6, -145523070);
|
|
5640
|
-
d = md5ii(d, a, b, c, x[i + 11], 10, -1120210379);
|
|
5641
|
-
c = md5ii(c, d, a, b, x[i + 2], 15, 718787259);
|
|
5642
|
-
b = md5ii(b, c, d, a, x[i + 9], 21, -343485551);
|
|
5643
|
-
a = safeAdd(a, olda);
|
|
5644
|
-
b = safeAdd(b, oldb);
|
|
5645
|
-
c = safeAdd(c, oldc);
|
|
5646
|
-
d = safeAdd(d, oldd);
|
|
5647
|
-
}
|
|
5648
|
-
return [a, b, c, d];
|
|
5649
|
-
}
|
|
5650
|
-
function bytesToWords(input) {
|
|
5651
|
-
if (input.length === 0) {
|
|
5652
|
-
return [];
|
|
5653
|
-
}
|
|
5654
|
-
var length8 = input.length * 8;
|
|
5655
|
-
var output = new Uint32Array(getOutputLength(length8));
|
|
5656
|
-
for (var i = 0; i < length8; i += 8) {
|
|
5657
|
-
output[i >> 5] |= (input[i / 8] & 255) << i % 32;
|
|
5658
|
-
}
|
|
5659
|
-
return output;
|
|
5660
|
-
}
|
|
5661
|
-
function safeAdd(x, y) {
|
|
5662
|
-
var lsw = (x & 65535) + (y & 65535);
|
|
5663
|
-
var msw = (x >> 16) + (y >> 16) + (lsw >> 16);
|
|
5664
|
-
return msw << 16 | lsw & 65535;
|
|
5665
|
-
}
|
|
5666
|
-
function bitRotateLeft(num, cnt) {
|
|
5667
|
-
return num << cnt | num >>> 32 - cnt;
|
|
5668
|
-
}
|
|
5669
|
-
function md5cmn(q, a, b, x, s, t) {
|
|
5670
|
-
return safeAdd(bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s), b);
|
|
5671
|
-
}
|
|
5672
|
-
function md5ff(a, b, c, d, x, s, t) {
|
|
5673
|
-
return md5cmn(b & c | ~b & d, a, b, x, s, t);
|
|
5674
|
-
}
|
|
5675
|
-
function md5gg(a, b, c, d, x, s, t) {
|
|
5676
|
-
return md5cmn(b & d | c & ~d, a, b, x, s, t);
|
|
5677
|
-
}
|
|
5678
|
-
function md5hh(a, b, c, d, x, s, t) {
|
|
5679
|
-
return md5cmn(b ^ c ^ d, a, b, x, s, t);
|
|
5680
|
-
}
|
|
5681
|
-
function md5ii(a, b, c, d, x, s, t) {
|
|
5682
|
-
return md5cmn(c ^ (b | ~d), a, b, x, s, t);
|
|
5683
|
-
}
|
|
5684
|
-
var md5_default;
|
|
5685
|
-
var init_md5 = __esm({
|
|
5686
|
-
"../node_modules/uuid/dist/esm-browser/md5.js"() {
|
|
5687
|
-
md5_default = md5;
|
|
5688
|
-
}
|
|
5689
|
-
});
|
|
5690
|
-
|
|
5691
|
-
// ../node_modules/uuid/dist/esm-browser/v3.js
|
|
5692
|
-
var v3, v3_default;
|
|
5693
|
-
var init_v3 = __esm({
|
|
5694
|
-
"../node_modules/uuid/dist/esm-browser/v3.js"() {
|
|
5695
|
-
init_v35();
|
|
5696
|
-
init_md5();
|
|
5697
|
-
v3 = v35_default("v3", 48, md5_default);
|
|
5698
|
-
v3_default = v3;
|
|
5699
|
-
}
|
|
5700
|
-
});
|
|
5701
|
-
|
|
5702
|
-
// ../node_modules/uuid/dist/esm-browser/v4.js
|
|
5703
|
-
function v4(options, buf, offset) {
|
|
5704
|
-
options = options || {};
|
|
5705
|
-
var rnds = options.random || (options.rng || rng)();
|
|
5706
|
-
rnds[6] = rnds[6] & 15 | 64;
|
|
5707
|
-
rnds[8] = rnds[8] & 63 | 128;
|
|
5708
|
-
if (buf) {
|
|
5709
|
-
offset = offset || 0;
|
|
5710
|
-
for (var i = 0; i < 16; ++i) {
|
|
5711
|
-
buf[offset + i] = rnds[i];
|
|
5712
|
-
}
|
|
5713
|
-
return buf;
|
|
5714
|
-
}
|
|
5715
|
-
return stringify_default(rnds);
|
|
5716
|
-
}
|
|
5717
|
-
var v4_default;
|
|
5718
|
-
var init_v4 = __esm({
|
|
5719
|
-
"../node_modules/uuid/dist/esm-browser/v4.js"() {
|
|
5720
|
-
init_rng();
|
|
5721
|
-
init_stringify();
|
|
5722
|
-
v4_default = v4;
|
|
5723
|
-
}
|
|
5724
|
-
});
|
|
5725
|
-
|
|
5726
|
-
// ../node_modules/uuid/dist/esm-browser/sha1.js
|
|
5727
|
-
function f(s, x, y, z) {
|
|
5728
|
-
switch (s) {
|
|
5729
|
-
case 0:
|
|
5730
|
-
return x & y ^ ~x & z;
|
|
5731
|
-
case 1:
|
|
5732
|
-
return x ^ y ^ z;
|
|
5733
|
-
case 2:
|
|
5734
|
-
return x & y ^ x & z ^ y & z;
|
|
5735
|
-
case 3:
|
|
5736
|
-
return x ^ y ^ z;
|
|
5737
|
-
}
|
|
5738
|
-
}
|
|
5739
|
-
function ROTL(x, n) {
|
|
5740
|
-
return x << n | x >>> 32 - n;
|
|
5741
|
-
}
|
|
5742
|
-
function sha1(bytes) {
|
|
5743
|
-
var K = [1518500249, 1859775393, 2400959708, 3395469782];
|
|
5744
|
-
var H = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
|
|
5745
|
-
if (typeof bytes === "string") {
|
|
5746
|
-
var msg2 = unescape(encodeURIComponent(bytes));
|
|
5747
|
-
bytes = [];
|
|
5748
|
-
for (var i = 0; i < msg2.length; ++i) {
|
|
5749
|
-
bytes.push(msg2.charCodeAt(i));
|
|
5750
|
-
}
|
|
5751
|
-
} else if (!Array.isArray(bytes)) {
|
|
5752
|
-
bytes = Array.prototype.slice.call(bytes);
|
|
5753
|
-
}
|
|
5754
|
-
bytes.push(128);
|
|
5755
|
-
var l = bytes.length / 4 + 2;
|
|
5756
|
-
var N = Math.ceil(l / 16);
|
|
5757
|
-
var M = new Array(N);
|
|
5758
|
-
for (var _i = 0; _i < N; ++_i) {
|
|
5759
|
-
var arr = new Uint32Array(16);
|
|
5760
|
-
for (var j = 0; j < 16; ++j) {
|
|
5761
|
-
arr[j] = bytes[_i * 64 + j * 4] << 24 | bytes[_i * 64 + j * 4 + 1] << 16 | bytes[_i * 64 + j * 4 + 2] << 8 | bytes[_i * 64 + j * 4 + 3];
|
|
5762
|
-
}
|
|
5763
|
-
M[_i] = arr;
|
|
5764
|
-
}
|
|
5765
|
-
M[N - 1][14] = (bytes.length - 1) * 8 / Math.pow(2, 32);
|
|
5766
|
-
M[N - 1][14] = Math.floor(M[N - 1][14]);
|
|
5767
|
-
M[N - 1][15] = (bytes.length - 1) * 8 & 4294967295;
|
|
5768
|
-
for (var _i2 = 0; _i2 < N; ++_i2) {
|
|
5769
|
-
var W = new Uint32Array(80);
|
|
5770
|
-
for (var t = 0; t < 16; ++t) {
|
|
5771
|
-
W[t] = M[_i2][t];
|
|
5772
|
-
}
|
|
5773
|
-
for (var _t = 16; _t < 80; ++_t) {
|
|
5774
|
-
W[_t] = ROTL(W[_t - 3] ^ W[_t - 8] ^ W[_t - 14] ^ W[_t - 16], 1);
|
|
5775
|
-
}
|
|
5776
|
-
var a = H[0];
|
|
5777
|
-
var b = H[1];
|
|
5778
|
-
var c = H[2];
|
|
5779
|
-
var d = H[3];
|
|
5780
|
-
var e = H[4];
|
|
5781
|
-
for (var _t2 = 0; _t2 < 80; ++_t2) {
|
|
5782
|
-
var s = Math.floor(_t2 / 20);
|
|
5783
|
-
var T = ROTL(a, 5) + f(s, b, c, d) + e + K[s] + W[_t2] >>> 0;
|
|
5784
|
-
e = d;
|
|
5785
|
-
d = c;
|
|
5786
|
-
c = ROTL(b, 30) >>> 0;
|
|
5787
|
-
b = a;
|
|
5788
|
-
a = T;
|
|
5789
|
-
}
|
|
5790
|
-
H[0] = H[0] + a >>> 0;
|
|
5791
|
-
H[1] = H[1] + b >>> 0;
|
|
5792
|
-
H[2] = H[2] + c >>> 0;
|
|
5793
|
-
H[3] = H[3] + d >>> 0;
|
|
5794
|
-
H[4] = H[4] + e >>> 0;
|
|
5795
|
-
}
|
|
5796
|
-
return [H[0] >> 24 & 255, H[0] >> 16 & 255, H[0] >> 8 & 255, H[0] & 255, H[1] >> 24 & 255, H[1] >> 16 & 255, H[1] >> 8 & 255, H[1] & 255, H[2] >> 24 & 255, H[2] >> 16 & 255, H[2] >> 8 & 255, H[2] & 255, H[3] >> 24 & 255, H[3] >> 16 & 255, H[3] >> 8 & 255, H[3] & 255, H[4] >> 24 & 255, H[4] >> 16 & 255, H[4] >> 8 & 255, H[4] & 255];
|
|
5797
|
-
}
|
|
5798
|
-
var sha1_default;
|
|
5799
|
-
var init_sha1 = __esm({
|
|
5800
|
-
"../node_modules/uuid/dist/esm-browser/sha1.js"() {
|
|
5801
|
-
sha1_default = sha1;
|
|
5802
|
-
}
|
|
5803
|
-
});
|
|
5804
|
-
|
|
5805
|
-
// ../node_modules/uuid/dist/esm-browser/v5.js
|
|
5806
|
-
var v5, v5_default;
|
|
5807
|
-
var init_v5 = __esm({
|
|
5808
|
-
"../node_modules/uuid/dist/esm-browser/v5.js"() {
|
|
5809
|
-
init_v35();
|
|
5810
|
-
init_sha1();
|
|
5811
|
-
v5 = v35_default("v5", 80, sha1_default);
|
|
5812
|
-
v5_default = v5;
|
|
5813
|
-
}
|
|
5814
|
-
});
|
|
5815
|
-
|
|
5816
|
-
// ../node_modules/uuid/dist/esm-browser/nil.js
|
|
5817
|
-
var nil_default;
|
|
5818
|
-
var init_nil = __esm({
|
|
5819
|
-
"../node_modules/uuid/dist/esm-browser/nil.js"() {
|
|
5820
|
-
nil_default = "00000000-0000-0000-0000-000000000000";
|
|
5821
|
-
}
|
|
5822
|
-
});
|
|
5823
|
-
|
|
5824
|
-
// ../node_modules/uuid/dist/esm-browser/version.js
|
|
5825
|
-
function version(uuid) {
|
|
5826
|
-
if (!validate_default(uuid)) {
|
|
5827
|
-
throw TypeError("Invalid UUID");
|
|
5828
|
-
}
|
|
5829
|
-
return parseInt(uuid.substr(14, 1), 16);
|
|
5830
|
-
}
|
|
5831
|
-
var version_default;
|
|
5832
|
-
var init_version = __esm({
|
|
5833
|
-
"../node_modules/uuid/dist/esm-browser/version.js"() {
|
|
5834
|
-
init_validate();
|
|
5835
|
-
version_default = version;
|
|
5836
|
-
}
|
|
5837
|
-
});
|
|
5838
|
-
|
|
5839
|
-
// ../node_modules/uuid/dist/esm-browser/index.js
|
|
5840
|
-
var esm_browser_exports = {};
|
|
5841
|
-
__export(esm_browser_exports, {
|
|
5842
|
-
NIL: () => nil_default,
|
|
5843
|
-
parse: () => parse_default,
|
|
5844
|
-
stringify: () => stringify_default,
|
|
5845
|
-
v1: () => v1_default,
|
|
5846
|
-
v3: () => v3_default,
|
|
5847
|
-
v4: () => v4_default,
|
|
5848
|
-
v5: () => v5_default,
|
|
5849
|
-
validate: () => validate_default,
|
|
5850
|
-
version: () => version_default
|
|
5851
|
-
});
|
|
5852
|
-
var init_esm_browser = __esm({
|
|
5853
|
-
"../node_modules/uuid/dist/esm-browser/index.js"() {
|
|
5854
|
-
init_v1();
|
|
5855
|
-
init_v3();
|
|
5856
|
-
init_v4();
|
|
5857
|
-
init_v5();
|
|
5858
|
-
init_nil();
|
|
5859
|
-
init_version();
|
|
5860
|
-
init_validate();
|
|
5861
|
-
init_stringify();
|
|
5862
|
-
init_parse();
|
|
5863
|
-
}
|
|
5864
|
-
});
|
|
5865
|
-
|
|
5866
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/authenticatedFetch/dpopUtils.js
|
|
5867
|
-
var require_dpopUtils = __commonJS({
|
|
5868
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/authenticatedFetch/dpopUtils.js"(exports) {
|
|
5869
|
-
"use strict";
|
|
5870
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5871
|
-
exports.generateDpopKeyPair = exports.createDpopHeader = void 0;
|
|
5872
|
-
var jose_1 = (init_browser(), __toCommonJS(browser_exports));
|
|
5873
|
-
var uuid_1 = (init_esm_browser(), __toCommonJS(esm_browser_exports));
|
|
5874
|
-
var constant_1 = require_constant();
|
|
5875
5846
|
function normalizeHTU(audience) {
|
|
5876
5847
|
const audienceUrl = new URL(audience);
|
|
5877
5848
|
return new URL(audienceUrl.pathname, audienceUrl.origin).toString();
|
|
5878
5849
|
}
|
|
5879
5850
|
async function createDpopHeader(audience, method, dpopKey) {
|
|
5880
|
-
return new
|
|
5851
|
+
return new jose.SignJWT({
|
|
5881
5852
|
htu: normalizeHTU(audience),
|
|
5882
5853
|
htm: method.toUpperCase(),
|
|
5883
|
-
jti:
|
|
5854
|
+
jti: uuid.v4()
|
|
5884
5855
|
}).setProtectedHeader({
|
|
5885
|
-
alg:
|
|
5856
|
+
alg: PREFERRED_SIGNING_ALG[0],
|
|
5886
5857
|
jwk: dpopKey.publicKey,
|
|
5887
5858
|
typ: "dpop+jwt"
|
|
5888
5859
|
}).setIssuedAt().sign(dpopKey.privateKey, {});
|
|
5889
5860
|
}
|
|
5890
|
-
exports.createDpopHeader = createDpopHeader;
|
|
5891
5861
|
async function generateDpopKeyPair() {
|
|
5892
|
-
const { privateKey, publicKey } = await
|
|
5862
|
+
const { privateKey, publicKey } = await jose.generateKeyPair(PREFERRED_SIGNING_ALG[0]);
|
|
5893
5863
|
const dpopKeyPair = {
|
|
5894
5864
|
privateKey,
|
|
5895
|
-
publicKey: await
|
|
5865
|
+
publicKey: await jose.exportJWK(publicKey)
|
|
5896
5866
|
};
|
|
5897
|
-
[dpopKeyPair.publicKey.alg] =
|
|
5867
|
+
[dpopKeyPair.publicKey.alg] = PREFERRED_SIGNING_ALG;
|
|
5898
5868
|
return dpopKeyPair;
|
|
5899
5869
|
}
|
|
5900
|
-
|
|
5901
|
-
}
|
|
5902
|
-
});
|
|
5903
|
-
|
|
5904
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/authenticatedFetch/fetchFactory.js
|
|
5905
|
-
var require_fetchFactory = __commonJS({
|
|
5906
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/authenticatedFetch/fetchFactory.js"(exports) {
|
|
5907
|
-
"use strict";
|
|
5908
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5909
|
-
exports.buildAuthenticatedFetch = exports.DEFAULT_EXPIRATION_TIME_SECONDS = void 0;
|
|
5910
|
-
var cross_fetch_1 = require_browser_ponyfill();
|
|
5911
|
-
var constant_1 = require_constant();
|
|
5912
|
-
var dpopUtils_1 = require_dpopUtils();
|
|
5913
|
-
var OidcProviderError_1 = require_OidcProviderError();
|
|
5914
|
-
var InvalidResponseError_1 = require_InvalidResponseError();
|
|
5915
|
-
exports.DEFAULT_EXPIRATION_TIME_SECONDS = 600;
|
|
5870
|
+
var DEFAULT_EXPIRATION_TIME_SECONDS = 600;
|
|
5916
5871
|
function isExpectedAuthError(statusCode) {
|
|
5917
5872
|
return [401, 403].includes(statusCode);
|
|
5918
5873
|
}
|
|
5919
5874
|
async function buildDpopFetchOptions(targetUrl, authToken, dpopKey, defaultOptions) {
|
|
5920
5875
|
var _a;
|
|
5921
|
-
const headers = new
|
|
5876
|
+
const headers = new crossFetch2.Headers(defaultOptions === null || defaultOptions === void 0 ? void 0 : defaultOptions.headers);
|
|
5922
5877
|
headers.set("Authorization", `DPoP ${authToken}`);
|
|
5923
|
-
headers.set("DPoP", await
|
|
5878
|
+
headers.set("DPoP", await createDpopHeader(targetUrl, (_a = defaultOptions === null || defaultOptions === void 0 ? void 0 : defaultOptions.method) !== null && _a !== void 0 ? _a : "get", dpopKey));
|
|
5924
5879
|
return {
|
|
5925
5880
|
...defaultOptions,
|
|
5926
5881
|
headers
|
|
@@ -5930,7 +5885,7 @@ ${newlined}
|
|
|
5930
5885
|
if (dpopKey !== void 0) {
|
|
5931
5886
|
return buildDpopFetchOptions(targetUrl, authToken, dpopKey, defaultOptions);
|
|
5932
5887
|
}
|
|
5933
|
-
const headers = new
|
|
5888
|
+
const headers = new crossFetch2.Headers(defaultOptions === null || defaultOptions === void 0 ? void 0 : defaultOptions.headers);
|
|
5934
5889
|
headers.set("Authorization", `Bearer ${authToken}`);
|
|
5935
5890
|
return {
|
|
5936
5891
|
...defaultOptions,
|
|
@@ -5943,9 +5898,9 @@ ${newlined}
|
|
|
5943
5898
|
async function refreshAccessToken(refreshOptions, dpopKey, eventEmitter) {
|
|
5944
5899
|
var _a;
|
|
5945
5900
|
const tokenSet = await refreshOptions.tokenRefresher.refresh(refreshOptions.sessionId, refreshOptions.refreshToken, dpopKey);
|
|
5946
|
-
eventEmitter === null || eventEmitter === void 0 ? void 0 : eventEmitter.emit(
|
|
5901
|
+
eventEmitter === null || eventEmitter === void 0 ? void 0 : eventEmitter.emit(EVENTS.SESSION_EXTENDED, (_a = tokenSet.expiresIn) !== null && _a !== void 0 ? _a : DEFAULT_EXPIRATION_TIME_SECONDS);
|
|
5947
5902
|
if (typeof tokenSet.refreshToken === "string") {
|
|
5948
|
-
eventEmitter === null || eventEmitter === void 0 ? void 0 : eventEmitter.emit(
|
|
5903
|
+
eventEmitter === null || eventEmitter === void 0 ? void 0 : eventEmitter.emit(EVENTS.NEW_REFRESH_TOKEN, tokenSet.refreshToken);
|
|
5949
5904
|
}
|
|
5950
5905
|
return {
|
|
5951
5906
|
accessToken: tokenSet.accessToken,
|
|
@@ -5955,9 +5910,9 @@ ${newlined}
|
|
|
5955
5910
|
}
|
|
5956
5911
|
var computeRefreshDelay = (expiresIn) => {
|
|
5957
5912
|
if (expiresIn !== void 0) {
|
|
5958
|
-
return expiresIn -
|
|
5913
|
+
return expiresIn - REFRESH_BEFORE_EXPIRATION_SECONDS > 0 ? expiresIn - REFRESH_BEFORE_EXPIRATION_SECONDS : expiresIn;
|
|
5959
5914
|
}
|
|
5960
|
-
return
|
|
5915
|
+
return DEFAULT_EXPIRATION_TIME_SECONDS;
|
|
5961
5916
|
};
|
|
5962
5917
|
async function buildAuthenticatedFetch(unauthFetch, accessToken, options) {
|
|
5963
5918
|
var _a;
|
|
@@ -5975,24 +5930,24 @@ ${newlined}
|
|
|
5975
5930
|
}
|
|
5976
5931
|
clearTimeout(latestTimeout);
|
|
5977
5932
|
latestTimeout = setTimeout(proactivelyRefreshToken, computeRefreshDelay(expiresIn) * 1e3);
|
|
5978
|
-
(_a2 = options.eventEmitter) === null || _a2 === void 0 ? void 0 : _a2.emit(
|
|
5933
|
+
(_a2 = options.eventEmitter) === null || _a2 === void 0 ? void 0 : _a2.emit(EVENTS.TIMEOUT_SET, latestTimeout);
|
|
5979
5934
|
} catch (e) {
|
|
5980
|
-
if (e instanceof
|
|
5981
|
-
(_b = options === null || options === void 0 ? void 0 : options.eventEmitter) === null || _b === void 0 ? void 0 : _b.emit(
|
|
5982
|
-
(_c = options === null || options === void 0 ? void 0 : options.eventEmitter) === null || _c === void 0 ? void 0 : _c.emit(
|
|
5935
|
+
if (e instanceof OidcProviderError) {
|
|
5936
|
+
(_b = options === null || options === void 0 ? void 0 : options.eventEmitter) === null || _b === void 0 ? void 0 : _b.emit(EVENTS.ERROR, e.error, e.errorDescription);
|
|
5937
|
+
(_c = options === null || options === void 0 ? void 0 : options.eventEmitter) === null || _c === void 0 ? void 0 : _c.emit(EVENTS.SESSION_EXPIRED);
|
|
5983
5938
|
}
|
|
5984
|
-
if (e instanceof
|
|
5985
|
-
(_d = options === null || options === void 0 ? void 0 : options.eventEmitter) === null || _d === void 0 ? void 0 : _d.emit(
|
|
5939
|
+
if (e instanceof InvalidResponseError && e.missingFields.includes("access_token")) {
|
|
5940
|
+
(_d = options === null || options === void 0 ? void 0 : options.eventEmitter) === null || _d === void 0 ? void 0 : _d.emit(EVENTS.SESSION_EXPIRED);
|
|
5986
5941
|
}
|
|
5987
5942
|
}
|
|
5988
5943
|
};
|
|
5989
5944
|
latestTimeout = setTimeout(proactivelyRefreshToken, computeRefreshDelay(options.expiresIn) * 1e3);
|
|
5990
|
-
(_a = options.eventEmitter) === null || _a === void 0 ? void 0 : _a.emit(
|
|
5945
|
+
(_a = options.eventEmitter) === null || _a === void 0 ? void 0 : _a.emit(EVENTS.TIMEOUT_SET, latestTimeout);
|
|
5991
5946
|
} else if (options !== void 0 && options.eventEmitter !== void 0) {
|
|
5992
5947
|
const expirationTimeout = setTimeout(() => {
|
|
5993
|
-
options.eventEmitter.emit(
|
|
5948
|
+
options.eventEmitter.emit(EVENTS.SESSION_EXPIRED);
|
|
5994
5949
|
}, computeRefreshDelay(options.expiresIn) * 1e3);
|
|
5995
|
-
options.eventEmitter.emit(
|
|
5950
|
+
options.eventEmitter.emit(EVENTS.TIMEOUT_SET, expirationTimeout);
|
|
5996
5951
|
}
|
|
5997
5952
|
return async (url, requestInit) => {
|
|
5998
5953
|
let response = await makeAuthenticatedRequest(unauthFetch, currentAccessToken, url, requestInit, options === null || options === void 0 ? void 0 : options.dpopKey);
|
|
@@ -6007,28 +5962,14 @@ ${newlined}
|
|
|
6007
5962
|
return response;
|
|
6008
5963
|
};
|
|
6009
5964
|
}
|
|
6010
|
-
|
|
6011
|
-
|
|
6012
|
-
|
|
6013
|
-
|
|
6014
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/storage/__mocks__/StorageUtility.js
|
|
6015
|
-
var require_StorageUtility2 = __commonJS({
|
|
6016
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/storage/__mocks__/StorageUtility.js"(exports) {
|
|
6017
|
-
"use strict";
|
|
6018
|
-
var __importDefault = exports && exports.__importDefault || function(mod) {
|
|
6019
|
-
return mod && mod.__esModule ? mod : { "default": mod };
|
|
6020
|
-
};
|
|
6021
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6022
|
-
exports.mockStorageUtility = exports.mockStorage = exports.StorageUtilityMock = exports.StorageUtilityGetResponse = void 0;
|
|
6023
|
-
var StorageUtility_1 = __importDefault(require_StorageUtility());
|
|
6024
|
-
exports.StorageUtilityGetResponse = "getResponse";
|
|
6025
|
-
exports.StorageUtilityMock = {
|
|
6026
|
-
get: async (key, options) => exports.StorageUtilityGetResponse,
|
|
5965
|
+
var StorageUtilityGetResponse = "getResponse";
|
|
5966
|
+
var StorageUtilityMock = {
|
|
5967
|
+
get: async (key, options) => StorageUtilityGetResponse,
|
|
6027
5968
|
set: async (key, value) => {
|
|
6028
5969
|
},
|
|
6029
5970
|
delete: async (key) => {
|
|
6030
5971
|
},
|
|
6031
|
-
getForUser: async (userId, key, options) =>
|
|
5972
|
+
getForUser: async (userId, key, options) => StorageUtilityGetResponse,
|
|
6032
5973
|
setForUser: async (userId, values, options) => {
|
|
6033
5974
|
},
|
|
6034
5975
|
deleteForUser: async (userId, key, options) => {
|
|
@@ -6056,135 +5997,45 @@ ${newlined}
|
|
|
6056
5997
|
}
|
|
6057
5998
|
};
|
|
6058
5999
|
};
|
|
6059
|
-
exports.mockStorage = mockStorage;
|
|
6060
6000
|
var mockStorageUtility = (stored, isSecure = false) => {
|
|
6061
6001
|
if (isSecure) {
|
|
6062
|
-
return new
|
|
6002
|
+
return new StorageUtility(mockStorage(stored), mockStorage({}));
|
|
6063
6003
|
}
|
|
6064
|
-
return new
|
|
6004
|
+
return new StorageUtility(mockStorage({}), mockStorage(stored));
|
|
6065
6005
|
};
|
|
6006
|
+
exports.AggregateHandler = AggregateHandler;
|
|
6007
|
+
exports.ConfigurationError = ConfigurationError;
|
|
6008
|
+
exports.DEFAULT_SCOPES = DEFAULT_SCOPES;
|
|
6009
|
+
exports.EVENTS = EVENTS;
|
|
6010
|
+
exports.InMemoryStorage = InMemoryStorage;
|
|
6011
|
+
exports.InvalidResponseError = InvalidResponseError;
|
|
6012
|
+
exports.NotImplementedError = NotImplementedError;
|
|
6013
|
+
exports.OidcProviderError = OidcProviderError;
|
|
6014
|
+
exports.PREFERRED_SIGNING_ALG = PREFERRED_SIGNING_ALG;
|
|
6015
|
+
exports.REFRESH_BEFORE_EXPIRATION_SECONDS = REFRESH_BEFORE_EXPIRATION_SECONDS;
|
|
6016
|
+
exports.SOLID_CLIENT_AUTHN_KEY_PREFIX = SOLID_CLIENT_AUTHN_KEY_PREFIX;
|
|
6017
|
+
exports.StorageUtility = StorageUtility;
|
|
6018
|
+
exports.StorageUtilityGetResponse = StorageUtilityGetResponse;
|
|
6019
|
+
exports.StorageUtilityMock = StorageUtilityMock;
|
|
6020
|
+
exports.USER_SESSION_PREFIX = USER_SESSION_PREFIX;
|
|
6021
|
+
exports.buildAuthenticatedFetch = buildAuthenticatedFetch;
|
|
6022
|
+
exports.createDpopHeader = createDpopHeader;
|
|
6023
|
+
exports.determineSigningAlg = determineSigningAlg;
|
|
6024
|
+
exports.fetchJwks = fetchJwks2;
|
|
6025
|
+
exports.generateDpopKeyPair = generateDpopKeyPair;
|
|
6026
|
+
exports.getSessionIdFromOauthState = getSessionIdFromOauthState;
|
|
6027
|
+
exports.getWebidFromTokenPayload = getWebidFromTokenPayload;
|
|
6028
|
+
exports.handleRegistration = handleRegistration;
|
|
6029
|
+
exports.isSupportedTokenType = isSupportedTokenType;
|
|
6030
|
+
exports.loadOidcContextFromStorage = loadOidcContextFromStorage;
|
|
6031
|
+
exports.mockStorage = mockStorage;
|
|
6066
6032
|
exports.mockStorageUtility = mockStorageUtility;
|
|
6067
|
-
|
|
6068
|
-
});
|
|
6069
|
-
|
|
6070
|
-
// ../node_modules/@inrupt/solid-client-authn-core/dist/index.js
|
|
6071
|
-
var require_dist = __commonJS({
|
|
6072
|
-
"../node_modules/@inrupt/solid-client-authn-core/dist/index.js"(exports) {
|
|
6073
|
-
"use strict";
|
|
6074
|
-
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
6075
|
-
if (k2 === void 0)
|
|
6076
|
-
k2 = k;
|
|
6077
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6078
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6079
|
-
desc = { enumerable: true, get: function() {
|
|
6080
|
-
return m[k];
|
|
6081
|
-
} };
|
|
6082
|
-
}
|
|
6083
|
-
Object.defineProperty(o, k2, desc);
|
|
6084
|
-
} : function(o, m, k, k2) {
|
|
6085
|
-
if (k2 === void 0)
|
|
6086
|
-
k2 = k;
|
|
6087
|
-
o[k2] = m[k];
|
|
6088
|
-
});
|
|
6089
|
-
var __exportStar = exports && exports.__exportStar || function(m, exports2) {
|
|
6090
|
-
for (var p in m)
|
|
6091
|
-
if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports2, p))
|
|
6092
|
-
__createBinding(exports2, m, p);
|
|
6093
|
-
};
|
|
6094
|
-
var __importDefault = exports && exports.__importDefault || function(mod) {
|
|
6095
|
-
return mod && mod.__esModule ? mod : { "default": mod };
|
|
6096
|
-
};
|
|
6097
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6098
|
-
exports.StorageUtilityGetResponse = exports.StorageUtilityMock = exports.mockStorageUtility = exports.mockStorage = exports.buildAuthenticatedFetch = exports.generateDpopKeyPair = exports.createDpopHeader = exports.OidcProviderError = exports.InvalidResponseError = exports.NotImplementedError = exports.ConfigurationError = exports.InMemoryStorage = exports.getSessionIdFromOauthState = exports.saveSessionInfoToStorage = exports.loadOidcContextFromStorage = exports.StorageUtility = exports.determineSigningAlg = exports.handleRegistration = exports.USER_SESSION_PREFIX = exports.isSupportedTokenType = exports.fetchJwks = exports.getWebidFromTokenPayload = exports.AggregateHandler = void 0;
|
|
6099
|
-
__exportStar(require_constant(), exports);
|
|
6100
|
-
var AggregateHandler_1 = require_AggregateHandler();
|
|
6101
|
-
Object.defineProperty(exports, "AggregateHandler", { enumerable: true, get: function() {
|
|
6102
|
-
return __importDefault(AggregateHandler_1).default;
|
|
6103
|
-
} });
|
|
6104
|
-
var token_1 = require_token();
|
|
6105
|
-
Object.defineProperty(exports, "getWebidFromTokenPayload", { enumerable: true, get: function() {
|
|
6106
|
-
return token_1.getWebidFromTokenPayload;
|
|
6107
|
-
} });
|
|
6108
|
-
Object.defineProperty(exports, "fetchJwks", { enumerable: true, get: function() {
|
|
6109
|
-
return token_1.fetchJwks;
|
|
6110
|
-
} });
|
|
6111
|
-
var ISessionInfo_1 = require_ISessionInfo();
|
|
6112
|
-
Object.defineProperty(exports, "isSupportedTokenType", { enumerable: true, get: function() {
|
|
6113
|
-
return ISessionInfo_1.isSupportedTokenType;
|
|
6114
|
-
} });
|
|
6115
|
-
var ISessionInfoManager_1 = require_ISessionInfoManager();
|
|
6116
|
-
Object.defineProperty(exports, "USER_SESSION_PREFIX", { enumerable: true, get: function() {
|
|
6117
|
-
return ISessionInfoManager_1.USER_SESSION_PREFIX;
|
|
6118
|
-
} });
|
|
6119
|
-
var IClientRegistrar_1 = require_IClientRegistrar();
|
|
6120
|
-
Object.defineProperty(exports, "handleRegistration", { enumerable: true, get: function() {
|
|
6121
|
-
return IClientRegistrar_1.handleRegistration;
|
|
6122
|
-
} });
|
|
6123
|
-
Object.defineProperty(exports, "determineSigningAlg", { enumerable: true, get: function() {
|
|
6124
|
-
return IClientRegistrar_1.determineSigningAlg;
|
|
6125
|
-
} });
|
|
6126
|
-
var StorageUtility_1 = require_StorageUtility();
|
|
6127
|
-
Object.defineProperty(exports, "StorageUtility", { enumerable: true, get: function() {
|
|
6128
|
-
return __importDefault(StorageUtility_1).default;
|
|
6129
|
-
} });
|
|
6130
|
-
Object.defineProperty(exports, "loadOidcContextFromStorage", { enumerable: true, get: function() {
|
|
6131
|
-
return StorageUtility_1.loadOidcContextFromStorage;
|
|
6132
|
-
} });
|
|
6133
|
-
Object.defineProperty(exports, "saveSessionInfoToStorage", { enumerable: true, get: function() {
|
|
6134
|
-
return StorageUtility_1.saveSessionInfoToStorage;
|
|
6135
|
-
} });
|
|
6136
|
-
Object.defineProperty(exports, "getSessionIdFromOauthState", { enumerable: true, get: function() {
|
|
6137
|
-
return StorageUtility_1.getSessionIdFromOauthState;
|
|
6138
|
-
} });
|
|
6139
|
-
var InMemoryStorage_1 = require_InMemoryStorage();
|
|
6140
|
-
Object.defineProperty(exports, "InMemoryStorage", { enumerable: true, get: function() {
|
|
6141
|
-
return __importDefault(InMemoryStorage_1).default;
|
|
6142
|
-
} });
|
|
6143
|
-
var ConfigurationError_1 = require_ConfigurationError();
|
|
6144
|
-
Object.defineProperty(exports, "ConfigurationError", { enumerable: true, get: function() {
|
|
6145
|
-
return __importDefault(ConfigurationError_1).default;
|
|
6146
|
-
} });
|
|
6147
|
-
var NotImplementedError_1 = require_NotImplementedError();
|
|
6148
|
-
Object.defineProperty(exports, "NotImplementedError", { enumerable: true, get: function() {
|
|
6149
|
-
return __importDefault(NotImplementedError_1).default;
|
|
6150
|
-
} });
|
|
6151
|
-
var InvalidResponseError_1 = require_InvalidResponseError();
|
|
6152
|
-
Object.defineProperty(exports, "InvalidResponseError", { enumerable: true, get: function() {
|
|
6153
|
-
return InvalidResponseError_1.InvalidResponseError;
|
|
6154
|
-
} });
|
|
6155
|
-
var OidcProviderError_1 = require_OidcProviderError();
|
|
6156
|
-
Object.defineProperty(exports, "OidcProviderError", { enumerable: true, get: function() {
|
|
6157
|
-
return OidcProviderError_1.OidcProviderError;
|
|
6158
|
-
} });
|
|
6159
|
-
var dpopUtils_1 = require_dpopUtils();
|
|
6160
|
-
Object.defineProperty(exports, "createDpopHeader", { enumerable: true, get: function() {
|
|
6161
|
-
return dpopUtils_1.createDpopHeader;
|
|
6162
|
-
} });
|
|
6163
|
-
Object.defineProperty(exports, "generateDpopKeyPair", { enumerable: true, get: function() {
|
|
6164
|
-
return dpopUtils_1.generateDpopKeyPair;
|
|
6165
|
-
} });
|
|
6166
|
-
var fetchFactory_1 = require_fetchFactory();
|
|
6167
|
-
Object.defineProperty(exports, "buildAuthenticatedFetch", { enumerable: true, get: function() {
|
|
6168
|
-
return fetchFactory_1.buildAuthenticatedFetch;
|
|
6169
|
-
} });
|
|
6170
|
-
var StorageUtility_2 = require_StorageUtility2();
|
|
6171
|
-
Object.defineProperty(exports, "mockStorage", { enumerable: true, get: function() {
|
|
6172
|
-
return StorageUtility_2.mockStorage;
|
|
6173
|
-
} });
|
|
6174
|
-
Object.defineProperty(exports, "mockStorageUtility", { enumerable: true, get: function() {
|
|
6175
|
-
return StorageUtility_2.mockStorageUtility;
|
|
6176
|
-
} });
|
|
6177
|
-
Object.defineProperty(exports, "StorageUtilityMock", { enumerable: true, get: function() {
|
|
6178
|
-
return StorageUtility_2.StorageUtilityMock;
|
|
6179
|
-
} });
|
|
6180
|
-
Object.defineProperty(exports, "StorageUtilityGetResponse", { enumerable: true, get: function() {
|
|
6181
|
-
return StorageUtility_2.StorageUtilityGetResponse;
|
|
6182
|
-
} });
|
|
6033
|
+
exports.saveSessionInfoToStorage = saveSessionInfoToStorage;
|
|
6183
6034
|
}
|
|
6184
6035
|
});
|
|
6185
6036
|
|
|
6186
6037
|
// ../node_modules/@inrupt/solid-client-authn-browser/dist/storage/StorageUtility.js
|
|
6187
|
-
var
|
|
6038
|
+
var require_StorageUtility = __commonJS({
|
|
6188
6039
|
"../node_modules/@inrupt/solid-client-authn-browser/dist/storage/StorageUtility.js"(exports) {
|
|
6189
6040
|
"use strict";
|
|
6190
6041
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -6513,10 +6364,10 @@ ${newlined}
|
|
|
6513
6364
|
if (!(t2 instanceof e2))
|
|
6514
6365
|
throw new TypeError("Cannot call a class as a function");
|
|
6515
6366
|
}
|
|
6516
|
-
var l = ".well-known/openid-configuration",
|
|
6367
|
+
var l = ".well-known/openid-configuration", f = "id_token", g = "openid", d = "client_secret_post";
|
|
6517
6368
|
e.OidcClientSettings = function() {
|
|
6518
6369
|
function t2() {
|
|
6519
|
-
var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, r2 = e2.authority, i2 = e2.metadataUrl, o2 = e2.metadata, l2 = e2.signingKeys, p = e2.metadataSeed, v = e2.client_id, y = e2.client_secret, m = e2.response_type, _ = void 0 === m ?
|
|
6370
|
+
var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, r2 = e2.authority, i2 = e2.metadataUrl, o2 = e2.metadata, l2 = e2.signingKeys, p = e2.metadataSeed, v = e2.client_id, y = e2.client_secret, m = e2.response_type, _ = void 0 === m ? f : m, S = e2.scope, b = void 0 === S ? g : S, w = e2.redirect_uri, F = e2.post_logout_redirect_uri, E = e2.client_authentication, x = void 0 === E ? d : E, A = e2.prompt, k = e2.display, P = e2.max_age, C = e2.ui_locales, T = e2.acr_values, R = e2.resource, I = e2.response_mode, D = e2.filterProtocolClaims, L = void 0 === D || D, N = e2.loadUserInfo, U = void 0 === N || N, B = e2.staleStateAge, O = void 0 === B ? 900 : B, j = e2.clockSkew, M = void 0 === j ? 300 : j, H = e2.clockService, V = void 0 === H ? new s.ClockService() : H, K = e2.userInfoJwtIssuer, q = void 0 === K ? "OP" : K, J = e2.mergeClaims, W = void 0 !== J && J, z = e2.stateStore, Y = void 0 === z ? new a.WebStorageStateStore() : z, G = e2.ResponseValidatorCtor, X = void 0 === G ? u.ResponseValidator : G, $ = e2.MetadataServiceCtor, Q = void 0 === $ ? c.MetadataService : $, Z = e2.extraQueryParams, tt = void 0 === Z ? {} : Z, et = e2.extraTokenParams, rt = void 0 === et ? {} : et;
|
|
6520
6371
|
h(this, t2), this._authority = r2, this._metadataUrl = i2, this._metadata = o2, this._metadataSeed = p, this._signingKeys = l2, this._client_id = v, this._client_secret = y, this._response_type = _, this._scope = b, this._redirect_uri = w, this._post_logout_redirect_uri = F, this._client_authentication = x, this._prompt = A, this._display = k, this._max_age = P, this._ui_locales = C, this._acr_values = T, this._resource = R, this._response_mode = I, this._filterProtocolClaims = !!L, this._loadUserInfo = !!U, this._staleStateAge = O, this._clockSkew = M, this._clockService = V, this._userInfoJwtIssuer = q, this._mergeClaims = !!W, this._stateStore = Y, this._validator = new X(this), this._metadataService = new Q(this), this._extraQueryParams = "object" === (void 0 === tt ? "undefined" : n(tt)) ? tt : {}, this._extraTokenParams = "object" === (void 0 === rt ? "undefined" : n(rt)) ? rt : {};
|
|
6521
6372
|
}
|
|
6522
6373
|
return t2.prototype.getEpochTime = function t3() {
|
|
@@ -6735,7 +6586,7 @@ ${newlined}
|
|
|
6735
6586
|
var n = r(0), i = r(3), o = r(13);
|
|
6736
6587
|
e.SigninRequest = function() {
|
|
6737
6588
|
function t2(e2) {
|
|
6738
|
-
var r2 = e2.url, s = e2.client_id, a = e2.redirect_uri, u = e2.response_type, c = e2.scope, h = e2.authority, l = e2.data,
|
|
6589
|
+
var r2 = e2.url, s = e2.client_id, a = e2.redirect_uri, u = e2.response_type, c = e2.scope, h = e2.authority, l = e2.data, f = e2.prompt, g = e2.display, d = e2.max_age, p = e2.ui_locales, v = e2.id_token_hint, y = e2.login_hint, m = e2.acr_values, _ = e2.resource, S = e2.response_mode, b = e2.request, w = e2.request_uri, F = e2.extraQueryParams, E = e2.request_type, x = e2.client_secret, A = e2.extraTokenParams, k = e2.skipUserInfo;
|
|
6739
6590
|
if (function P(t3, e3) {
|
|
6740
6591
|
if (!(t3 instanceof e3))
|
|
6741
6592
|
throw new TypeError("Cannot call a class as a function");
|
|
@@ -6753,7 +6604,7 @@ ${newlined}
|
|
|
6753
6604
|
throw n.Log.error("SigninRequest.ctor: No authority passed"), new Error("authority");
|
|
6754
6605
|
var C = t2.isOidc(u), T = t2.isCode(u);
|
|
6755
6606
|
S || (S = t2.isCode(u) ? "query" : null), this.state = new o.SigninState({ nonce: C, data: l, client_id: s, authority: h, redirect_uri: a, code_verifier: T, request_type: E, response_mode: S, client_secret: x, scope: c, extraTokenParams: A, skipUserInfo: k }), r2 = i.UrlUtility.addQueryParam(r2, "client_id", s), r2 = i.UrlUtility.addQueryParam(r2, "redirect_uri", a), r2 = i.UrlUtility.addQueryParam(r2, "response_type", u), r2 = i.UrlUtility.addQueryParam(r2, "scope", c), r2 = i.UrlUtility.addQueryParam(r2, "state", this.state.id), C && (r2 = i.UrlUtility.addQueryParam(r2, "nonce", this.state.nonce)), T && (r2 = i.UrlUtility.addQueryParam(r2, "code_challenge", this.state.code_challenge), r2 = i.UrlUtility.addQueryParam(r2, "code_challenge_method", "S256"));
|
|
6756
|
-
var R = { prompt:
|
|
6607
|
+
var R = { prompt: f, display: g, max_age: d, ui_locales: p, id_token_hint: v, login_hint: y, acr_values: m, resource: _, request: b, request_uri: w, response_mode: S };
|
|
6757
6608
|
for (var I in R)
|
|
6758
6609
|
R[I] && (r2 = i.UrlUtility.addQueryParam(r2, I, R[I]));
|
|
6759
6610
|
for (var D in F)
|
|
@@ -6852,7 +6703,7 @@ ${newlined}
|
|
|
6852
6703
|
return function(e2, r2, n2) {
|
|
6853
6704
|
return r2 && t2(e2.prototype, r2), n2 && t2(e2, n2), e2;
|
|
6854
6705
|
};
|
|
6855
|
-
}(), i = r(0), o = r(5), s = r(12), a = r(8), u = r(34), c = r(35), h = r(36), l = r(13),
|
|
6706
|
+
}(), i = r(0), o = r(5), s = r(12), a = r(8), u = r(34), c = r(35), h = r(36), l = r(13), f = r(9);
|
|
6856
6707
|
function g(t2, e2) {
|
|
6857
6708
|
if (!(t2 instanceof e2))
|
|
6858
6709
|
throw new TypeError("Cannot call a class as a function");
|
|
@@ -6863,14 +6714,14 @@ ${newlined}
|
|
|
6863
6714
|
g(this, t2), e2 instanceof o.OidcClientSettings ? this._settings = e2 : this._settings = new o.OidcClientSettings(e2);
|
|
6864
6715
|
}
|
|
6865
6716
|
return t2.prototype.createSigninRequest = function t3() {
|
|
6866
|
-
var e2 = this, r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = r2.response_type, o2 = r2.scope, s2 = r2.redirect_uri, u2 = r2.data, c2 = r2.state, h2 = r2.prompt, l2 = r2.display,
|
|
6717
|
+
var e2 = this, r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = r2.response_type, o2 = r2.scope, s2 = r2.redirect_uri, u2 = r2.data, c2 = r2.state, h2 = r2.prompt, l2 = r2.display, f2 = r2.max_age, g2 = r2.ui_locales, d = r2.id_token_hint, p = r2.login_hint, v = r2.acr_values, y = r2.resource, m = r2.request, _ = r2.request_uri, S = r2.response_mode, b = r2.extraQueryParams, w = r2.extraTokenParams, F = r2.request_type, E = r2.skipUserInfo, x = arguments[1];
|
|
6867
6718
|
i.Log.debug("OidcClient.createSigninRequest");
|
|
6868
6719
|
var A = this._settings.client_id;
|
|
6869
|
-
n2 = n2 || this._settings.response_type, o2 = o2 || this._settings.scope, s2 = s2 || this._settings.redirect_uri, h2 = h2 || this._settings.prompt, l2 = l2 || this._settings.display,
|
|
6720
|
+
n2 = n2 || this._settings.response_type, o2 = o2 || this._settings.scope, s2 = s2 || this._settings.redirect_uri, h2 = h2 || this._settings.prompt, l2 = l2 || this._settings.display, f2 = f2 || this._settings.max_age, g2 = g2 || this._settings.ui_locales, v = v || this._settings.acr_values, y = y || this._settings.resource, S = S || this._settings.response_mode, b = b || this._settings.extraQueryParams, w = w || this._settings.extraTokenParams;
|
|
6870
6721
|
var k = this._settings.authority;
|
|
6871
6722
|
return a.SigninRequest.isCode(n2) && "code" !== n2 ? Promise.reject(new Error("OpenID Connect hybrid flow is not supported")) : this._metadataService.getAuthorizationEndpoint().then(function(t4) {
|
|
6872
6723
|
i.Log.debug("OidcClient.createSigninRequest: Received authorization endpoint", t4);
|
|
6873
|
-
var r3 = new a.SigninRequest({ url: t4, client_id: A, redirect_uri: s2, response_type: n2, scope: o2, data: u2 || c2, authority: k, prompt: h2, display: l2, max_age:
|
|
6724
|
+
var r3 = new a.SigninRequest({ url: t4, client_id: A, redirect_uri: s2, response_type: n2, scope: o2, data: u2 || c2, authority: k, prompt: h2, display: l2, max_age: f2, ui_locales: g2, id_token_hint: d, login_hint: p, acr_values: v, resource: y, request: m, request_uri: _, extraQueryParams: b, extraTokenParams: w, request_type: F, response_mode: S, client_secret: e2._settings.client_secret, skipUserInfo: E }), P = r3.state;
|
|
6874
6725
|
return (x = x || e2._stateStore).set(P.id, P.toStorageString()).then(function() {
|
|
6875
6726
|
return r3;
|
|
6876
6727
|
});
|
|
@@ -6900,8 +6751,8 @@ ${newlined}
|
|
|
6900
6751
|
if (!t4)
|
|
6901
6752
|
throw i.Log.error("OidcClient.createSignoutRequest: No end session endpoint url returned"), new Error("no end session endpoint");
|
|
6902
6753
|
i.Log.debug("OidcClient.createSignoutRequest: Received end session endpoint", t4);
|
|
6903
|
-
var r3 = new c.SignoutRequest({ url: t4, id_token_hint: n2, post_logout_redirect_uri: a2, data: o2 || s2, extraQueryParams: u2, request_type: h2 }),
|
|
6904
|
-
return
|
|
6754
|
+
var r3 = new c.SignoutRequest({ url: t4, id_token_hint: n2, post_logout_redirect_uri: a2, data: o2 || s2, extraQueryParams: u2, request_type: h2 }), f2 = r3.state;
|
|
6755
|
+
return f2 && (i.Log.debug("OidcClient.createSignoutRequest: Signout request has state to persist"), (l2 = l2 || e2._stateStore).set(f2.id, f2.toStorageString())), r3;
|
|
6905
6756
|
});
|
|
6906
6757
|
}, t2.prototype.readSignoutResponseState = function t3(e2, r2) {
|
|
6907
6758
|
var n2 = arguments.length > 2 && void 0 !== arguments[2] && arguments[2];
|
|
@@ -6915,7 +6766,7 @@ ${newlined}
|
|
|
6915
6766
|
return u2(a2).then(function(t4) {
|
|
6916
6767
|
if (!t4)
|
|
6917
6768
|
throw i.Log.error("OidcClient.readSignoutResponseState: No matching state found in storage"), new Error("No matching state found in storage");
|
|
6918
|
-
return { state:
|
|
6769
|
+
return { state: f.State.fromStorageString(t4), response: o2 };
|
|
6919
6770
|
});
|
|
6920
6771
|
}, t2.prototype.processSignoutResponse = function t3(e2, r2) {
|
|
6921
6772
|
var n2 = this;
|
|
@@ -6924,7 +6775,7 @@ ${newlined}
|
|
|
6924
6775
|
return e3 ? (i.Log.debug("OidcClient.processSignoutResponse: Received state from storage; validating response"), n2._validator.validateSignoutResponse(e3, r3)) : (i.Log.debug("OidcClient.processSignoutResponse: No state from storage; skipping validating response"), r3);
|
|
6925
6776
|
});
|
|
6926
6777
|
}, t2.prototype.clearStaleState = function t3(e2) {
|
|
6927
|
-
return i.Log.debug("OidcClient.clearStaleState"), e2 = e2 || this._stateStore,
|
|
6778
|
+
return i.Log.debug("OidcClient.clearStaleState"), e2 = e2 || this._stateStore, f.State.clearStaleState(e2, this.settings.staleStateAge);
|
|
6928
6779
|
}, n(t2, [{ key: "_stateStore", get: function t3() {
|
|
6929
6780
|
return this.settings.stateStore;
|
|
6930
6781
|
} }, { key: "_validator", get: function t3() {
|
|
@@ -7026,14 +6877,14 @@ ${newlined}
|
|
|
7026
6877
|
}
|
|
7027
6878
|
e.SigninState = function(t2) {
|
|
7028
6879
|
function e2() {
|
|
7029
|
-
var r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = r2.nonce, i2 = r2.authority, o2 = r2.client_id, u = r2.redirect_uri, l = r2.code_verifier,
|
|
6880
|
+
var r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = r2.nonce, i2 = r2.authority, o2 = r2.client_id, u = r2.redirect_uri, l = r2.code_verifier, f = r2.response_mode, g = r2.client_secret, d = r2.scope, p = r2.extraTokenParams, v = r2.skipUserInfo;
|
|
7030
6881
|
c(this, e2);
|
|
7031
6882
|
var y = h(this, t2.call(this, arguments[0]));
|
|
7032
6883
|
if (true === n2 ? y._nonce = (0, a.default)() : n2 && (y._nonce = n2), true === l ? y._code_verifier = (0, a.default)() + (0, a.default)() + (0, a.default)() : l && (y._code_verifier = l), y.code_verifier) {
|
|
7033
6884
|
var m = s.JoseUtil.hashString(y.code_verifier, "SHA256");
|
|
7034
6885
|
y._code_challenge = s.JoseUtil.hexToBase64Url(m);
|
|
7035
6886
|
}
|
|
7036
|
-
return y._redirect_uri = u, y._authority = i2, y._client_id = o2, y._response_mode =
|
|
6887
|
+
return y._redirect_uri = u, y._authority = i2, y._client_id = o2, y._response_mode = f, y._client_secret = g, y._scope = d, y._extraTokenParams = p, y._skipUserInfo = v, y;
|
|
7037
6888
|
}
|
|
7038
6889
|
return function r2(t3, e3) {
|
|
7039
6890
|
if ("function" != typeof e3 && null !== e3)
|
|
@@ -7411,8 +7262,8 @@ ${newlined}
|
|
|
7411
7262
|
}, function(t, e, r) {
|
|
7412
7263
|
"use strict";
|
|
7413
7264
|
Object.defineProperty(e, "__esModule", { value: true });
|
|
7414
|
-
var n = r(0), i = r(10), o = r(5), s = r(6), a = r(37), u = r(38), c = r(16), h = r(2), l = r(48),
|
|
7415
|
-
e.default = { Version: m.Version, Log: n.Log, OidcClient: i.OidcClient, OidcClientSettings: o.OidcClientSettings, WebStorageStateStore: s.WebStorageStateStore, InMemoryWebStorage: a.InMemoryWebStorage, UserManager: u.UserManager, AccessTokenEvents: c.AccessTokenEvents, MetadataService: h.MetadataService, CordovaPopupNavigator: l.CordovaPopupNavigator, CordovaIFrameNavigator:
|
|
7265
|
+
var n = r(0), i = r(10), o = r(5), s = r(6), a = r(37), u = r(38), c = r(16), h = r(2), l = r(48), f = r(49), g = r(19), d = r(20), p = r(18), v = r(1), y = r(15), m = r(50);
|
|
7266
|
+
e.default = { Version: m.Version, Log: n.Log, OidcClient: i.OidcClient, OidcClientSettings: o.OidcClientSettings, WebStorageStateStore: s.WebStorageStateStore, InMemoryWebStorage: a.InMemoryWebStorage, UserManager: u.UserManager, AccessTokenEvents: c.AccessTokenEvents, MetadataService: h.MetadataService, CordovaPopupNavigator: l.CordovaPopupNavigator, CordovaIFrameNavigator: f.CordovaIFrameNavigator, CheckSessionIFrame: g.CheckSessionIFrame, TokenRevocationClient: d.TokenRevocationClient, SessionMonitor: p.SessionMonitor, Global: v.Global, User: y.User }, t.exports = e.default;
|
|
7416
7267
|
}, function(t, e, r) {
|
|
7417
7268
|
"use strict";
|
|
7418
7269
|
Object.defineProperty(e, "__esModule", { value: true });
|
|
@@ -7696,7 +7547,7 @@ ${newlined}
|
|
|
7696
7547
|
"use strict";
|
|
7697
7548
|
(function(t2) {
|
|
7698
7549
|
Object.defineProperty(e, "__esModule", { value: true });
|
|
7699
|
-
var r2, n, i, o, s, a, u, c, h, l,
|
|
7550
|
+
var r2, n, i, o, s, a, u, c, h, l, f, g = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(t3) {
|
|
7700
7551
|
return typeof t3;
|
|
7701
7552
|
} : function(t3) {
|
|
7702
7553
|
return t3 && "function" == typeof Symbol && t3.constructor === Symbol && t3 !== Symbol.prototype ? "symbol" : typeof t3;
|
|
@@ -7782,10 +7633,10 @@ ${newlined}
|
|
|
7782
7633
|
if (c2) {
|
|
7783
7634
|
for (var l2 = 0; l2 < c2; l2 += a2)
|
|
7784
7635
|
this._doProcessBlock(i2, l2);
|
|
7785
|
-
var
|
|
7636
|
+
var f2 = i2.splice(0, c2);
|
|
7786
7637
|
n2.sigBytes -= h2;
|
|
7787
7638
|
}
|
|
7788
|
-
return new s.init(
|
|
7639
|
+
return new s.init(f2, h2);
|
|
7789
7640
|
}, clone: function t3() {
|
|
7790
7641
|
var e2 = o.clone.call(this);
|
|
7791
7642
|
return e2._data = this._data.clone(), e2;
|
|
@@ -7803,9 +7654,9 @@ ${newlined}
|
|
|
7803
7654
|
};
|
|
7804
7655
|
}, _createHmacHelper: function t3(e2) {
|
|
7805
7656
|
return function(t4, r3) {
|
|
7806
|
-
return new
|
|
7657
|
+
return new f.HMAC.init(e2, r3).finalize(t4);
|
|
7807
7658
|
};
|
|
7808
|
-
} }),
|
|
7659
|
+
} }), f = n.algo = {}, n);
|
|
7809
7660
|
!function(t3) {
|
|
7810
7661
|
var e2, r3 = (e2 = v).lib, n2 = r3.Base, i2 = r3.WordArray;
|
|
7811
7662
|
(e2 = e2.x64 = {}).Word = n2.extend({ init: function t4(e3, r4) {
|
|
@@ -7852,8 +7703,8 @@ ${newlined}
|
|
|
7852
7703
|
var h2;
|
|
7853
7704
|
t: {
|
|
7854
7705
|
h2 = u2;
|
|
7855
|
-
for (var l2 = t3.sqrt(h2),
|
|
7856
|
-
if (!(h2 %
|
|
7706
|
+
for (var l2 = t3.sqrt(h2), f2 = 2; f2 <= l2; f2++)
|
|
7707
|
+
if (!(h2 % f2)) {
|
|
7857
7708
|
h2 = false;
|
|
7858
7709
|
break t;
|
|
7859
7710
|
}
|
|
@@ -7865,16 +7716,16 @@ ${newlined}
|
|
|
7865
7716
|
i2 = i2.SHA256 = n2.extend({ _doReset: function t4() {
|
|
7866
7717
|
this._hash = new r3.init(o2.slice(0));
|
|
7867
7718
|
}, _doProcessBlock: function t4(e3, r4) {
|
|
7868
|
-
for (var n3 = this._hash.words, i3 = n3[0], o3 = n3[1], a3 = n3[2], u3 = n3[3], c3 = n3[4], h3 = n3[5], l3 = n3[6],
|
|
7719
|
+
for (var n3 = this._hash.words, i3 = n3[0], o3 = n3[1], a3 = n3[2], u3 = n3[3], c3 = n3[4], h3 = n3[5], l3 = n3[6], f3 = n3[7], d2 = 0; 64 > d2; d2++) {
|
|
7869
7720
|
if (16 > d2)
|
|
7870
7721
|
g2[d2] = 0 | e3[r4 + d2];
|
|
7871
7722
|
else {
|
|
7872
7723
|
var p2 = g2[d2 - 15], v2 = g2[d2 - 2];
|
|
7873
7724
|
g2[d2] = ((p2 << 25 | p2 >>> 7) ^ (p2 << 14 | p2 >>> 18) ^ p2 >>> 3) + g2[d2 - 7] + ((v2 << 15 | v2 >>> 17) ^ (v2 << 13 | v2 >>> 19) ^ v2 >>> 10) + g2[d2 - 16];
|
|
7874
7725
|
}
|
|
7875
|
-
p2 =
|
|
7726
|
+
p2 = f3 + ((c3 << 26 | c3 >>> 6) ^ (c3 << 21 | c3 >>> 11) ^ (c3 << 7 | c3 >>> 25)) + (c3 & h3 ^ ~c3 & l3) + s2[d2] + g2[d2], v2 = ((i3 << 30 | i3 >>> 2) ^ (i3 << 19 | i3 >>> 13) ^ (i3 << 10 | i3 >>> 22)) + (i3 & o3 ^ i3 & a3 ^ o3 & a3), f3 = l3, l3 = h3, h3 = c3, c3 = u3 + p2 | 0, u3 = a3, a3 = o3, o3 = i3, i3 = p2 + v2 | 0;
|
|
7876
7727
|
}
|
|
7877
|
-
n3[0] = n3[0] + i3 | 0, n3[1] = n3[1] + o3 | 0, n3[2] = n3[2] + a3 | 0, n3[3] = n3[3] + u3 | 0, n3[4] = n3[4] + c3 | 0, n3[5] = n3[5] + h3 | 0, n3[6] = n3[6] + l3 | 0, n3[7] = n3[7] +
|
|
7728
|
+
n3[0] = n3[0] + i3 | 0, n3[1] = n3[1] + o3 | 0, n3[2] = n3[2] + a3 | 0, n3[3] = n3[3] + u3 | 0, n3[4] = n3[4] + c3 | 0, n3[5] = n3[5] + h3 | 0, n3[6] = n3[6] + l3 | 0, n3[7] = n3[7] + f3 | 0;
|
|
7878
7729
|
}, _doFinalize: function e3() {
|
|
7879
7730
|
var r4 = this._data, n3 = r4.words, i3 = 8 * this._nDataBytes, o3 = 8 * r4.sigBytes;
|
|
7880
7731
|
return n3[o3 >>> 5] |= 128 << 24 - o3 % 32, n3[14 + (o3 + 64 >>> 9 << 4)] = t3.floor(i3 / 4294967296), n3[15 + (o3 + 64 >>> 9 << 4)] = i3, r4.sigBytes = 4 * n3.length, this._process(), this._hash;
|
|
@@ -7892,7 +7743,7 @@ ${newlined}
|
|
|
7892
7743
|
o2 = o2.SHA512 = r3.extend({ _doReset: function t4() {
|
|
7893
7744
|
this._hash = new i2.init([new n2.init(1779033703, 4089235720), new n2.init(3144134277, 2227873595), new n2.init(1013904242, 4271175723), new n2.init(2773480762, 1595750129), new n2.init(1359893119, 2917565137), new n2.init(2600822924, 725511199), new n2.init(528734635, 4215389547), new n2.init(1541459225, 327033209)]);
|
|
7894
7745
|
}, _doProcessBlock: function t4(e3, r4) {
|
|
7895
|
-
for (var n3 = (
|
|
7746
|
+
for (var n3 = (f2 = this._hash.words)[0], i3 = f2[1], o3 = f2[2], u3 = f2[3], c2 = f2[4], h2 = f2[5], l2 = f2[6], f2 = f2[7], g2 = n3.high, d2 = n3.low, p2 = i3.high, v2 = i3.low, y2 = o3.high, m2 = o3.low, _2 = u3.high, S2 = u3.low, b2 = c2.high, w2 = c2.low, F2 = h2.high, E = h2.low, x = l2.high, A = l2.low, k2 = f2.high, P2 = f2.low, C2 = g2, T2 = d2, R2 = p2, I2 = v2, D2 = y2, L2 = m2, N2 = _2, U2 = S2, B2 = b2, O2 = w2, j2 = F2, M2 = E, H2 = x, V2 = A, K2 = k2, q2 = P2, J = 0; 80 > J; J++) {
|
|
7896
7747
|
var W = a2[J];
|
|
7897
7748
|
if (16 > J)
|
|
7898
7749
|
var z = W.high = 0 | e3[r4 + 2 * J], Y = W.low = 0 | e3[r4 + 2 * J + 1];
|
|
@@ -7906,7 +7757,7 @@ ${newlined}
|
|
|
7906
7757
|
var et = T2 & I2 ^ T2 & L2 ^ I2 & L2, rt = (G = (C2 >>> 28 | T2 << 4) ^ (C2 << 30 | T2 >>> 2) ^ (C2 << 25 | T2 >>> 7), X = (T2 >>> 28 | C2 << 4) ^ (T2 << 30 | C2 >>> 2) ^ (T2 << 25 | C2 >>> 7), ($ = s2[J]).high), nt = $.low;
|
|
7907
7758
|
Z = K2 + ((B2 >>> 14 | O2 << 18) ^ (B2 >>> 18 | O2 << 14) ^ (B2 << 23 | O2 >>> 9)) + (($ = q2 + ((O2 >>> 14 | B2 << 18) ^ (O2 >>> 18 | B2 << 14) ^ (O2 << 23 | B2 >>> 9))) >>> 0 < q2 >>> 0 ? 1 : 0), K2 = H2, q2 = V2, H2 = j2, V2 = M2, j2 = B2, M2 = O2, B2 = N2 + (Z = (Z = (Z = Z + Q + (($ = $ + tt) >>> 0 < tt >>> 0 ? 1 : 0)) + rt + (($ = $ + nt) >>> 0 < nt >>> 0 ? 1 : 0)) + z + (($ = $ + Y) >>> 0 < Y >>> 0 ? 1 : 0)) + ((O2 = U2 + $ | 0) >>> 0 < U2 >>> 0 ? 1 : 0) | 0, N2 = D2, U2 = L2, D2 = R2, L2 = I2, R2 = C2, I2 = T2, C2 = Z + (W = G + W + ((Y = X + et) >>> 0 < X >>> 0 ? 1 : 0)) + ((T2 = $ + Y | 0) >>> 0 < $ >>> 0 ? 1 : 0) | 0;
|
|
7908
7759
|
}
|
|
7909
|
-
d2 = n3.low = d2 + T2, n3.high = g2 + C2 + (d2 >>> 0 < T2 >>> 0 ? 1 : 0), v2 = i3.low = v2 + I2, i3.high = p2 + R2 + (v2 >>> 0 < I2 >>> 0 ? 1 : 0), m2 = o3.low = m2 + L2, o3.high = y2 + D2 + (m2 >>> 0 < L2 >>> 0 ? 1 : 0), S2 = u3.low = S2 + U2, u3.high = _2 + N2 + (S2 >>> 0 < U2 >>> 0 ? 1 : 0), w2 = c2.low = w2 + O2, c2.high = b2 + B2 + (w2 >>> 0 < O2 >>> 0 ? 1 : 0), E = h2.low = E + M2, h2.high = F2 + j2 + (E >>> 0 < M2 >>> 0 ? 1 : 0), A = l2.low = A + V2, l2.high = x + H2 + (A >>> 0 < V2 >>> 0 ? 1 : 0), P2 =
|
|
7760
|
+
d2 = n3.low = d2 + T2, n3.high = g2 + C2 + (d2 >>> 0 < T2 >>> 0 ? 1 : 0), v2 = i3.low = v2 + I2, i3.high = p2 + R2 + (v2 >>> 0 < I2 >>> 0 ? 1 : 0), m2 = o3.low = m2 + L2, o3.high = y2 + D2 + (m2 >>> 0 < L2 >>> 0 ? 1 : 0), S2 = u3.low = S2 + U2, u3.high = _2 + N2 + (S2 >>> 0 < U2 >>> 0 ? 1 : 0), w2 = c2.low = w2 + O2, c2.high = b2 + B2 + (w2 >>> 0 < O2 >>> 0 ? 1 : 0), E = h2.low = E + M2, h2.high = F2 + j2 + (E >>> 0 < M2 >>> 0 ? 1 : 0), A = l2.low = A + V2, l2.high = x + H2 + (A >>> 0 < V2 >>> 0 ? 1 : 0), P2 = f2.low = P2 + q2, f2.high = k2 + K2 + (P2 >>> 0 < q2 >>> 0 ? 1 : 0);
|
|
7910
7761
|
}, _doFinalize: function t4() {
|
|
7911
7762
|
var e3 = this._data, r4 = e3.words, n3 = 8 * this._nDataBytes, i3 = 8 * e3.sigBytes;
|
|
7912
7763
|
return r4[i3 >>> 5] |= 128 << 24 - i3 % 32, r4[30 + (i3 + 128 >>> 10 << 5)] = Math.floor(n3 / 4294967296), r4[31 + (i3 + 128 >>> 10 << 5)] = n3, e3.sigBytes = 4 * r4.length, this._process(), this._hash.toX32();
|
|
@@ -8159,11 +8010,11 @@ ${newlined}
|
|
|
8159
8010
|
u2 > 0 ? (n2.lShiftTo(u2, o2), i2.lShiftTo(u2, r3)) : (n2.copyTo(o2), i2.copyTo(r3));
|
|
8160
8011
|
var c2 = o2.t, h2 = o2[c2 - 1];
|
|
8161
8012
|
if (0 != h2) {
|
|
8162
|
-
var l2 = h2 * (1 << this.F1) + (c2 > 1 ? o2[c2 - 2] >> this.F2 : 0),
|
|
8013
|
+
var l2 = h2 * (1 << this.F1) + (c2 > 1 ? o2[c2 - 2] >> this.F2 : 0), f2 = this.FV / l2, g2 = (1 << this.F1) / l2, d2 = 1 << this.F2, p2 = r3.t, v2 = p2 - c2, y2 = null == e2 ? F() : e2;
|
|
8163
8014
|
for (o2.dlShiftTo(v2, y2), r3.compareTo(y2) >= 0 && (r3[r3.t++] = 1, r3.subTo(y2, r3)), w.ONE.dlShiftTo(c2, y2), y2.subTo(o2, o2); o2.t < c2; )
|
|
8164
8015
|
o2[o2.t++] = 0;
|
|
8165
8016
|
for (; --v2 >= 0; ) {
|
|
8166
|
-
var m2 = r3[--p2] == h2 ? this.DM : Math.floor(r3[p2] *
|
|
8017
|
+
var m2 = r3[--p2] == h2 ? this.DM : Math.floor(r3[p2] * f2 + (r3[p2 - 1] + d2) * g2);
|
|
8167
8018
|
if ((r3[p2] += o2.am(0, m2, r3, v2, 0, c2)) < m2)
|
|
8168
8019
|
for (o2.dlShiftTo(v2, y2), r3.subTo(y2, r3); r3[p2] < --m2; )
|
|
8169
8020
|
r3.subTo(y2, r3);
|
|
@@ -8483,7 +8334,7 @@ ${newlined}
|
|
|
8483
8334
|
for (n2.sqrTo(s2[1], h2); a2 <= c2; )
|
|
8484
8335
|
s2[a2] = F(), n2.mulTo(h2, s2[a2 - 2], s2[a2]), a2 += 2;
|
|
8485
8336
|
}
|
|
8486
|
-
var l2,
|
|
8337
|
+
var l2, f2, g2 = t3.t - 1, d2 = true, p2 = F();
|
|
8487
8338
|
for (i2 = D(t3[g2]) - 1; g2 >= 0; ) {
|
|
8488
8339
|
for (i2 >= u2 ? l2 = t3[g2] >> i2 - u2 & c2 : (l2 = (t3[g2] & (1 << i2 + 1) - 1) << u2 - i2, g2 > 0 && (l2 |= t3[g2 - 1] >> this.DB + i2 - u2)), a2 = r3; 0 == (1 & l2); )
|
|
8489
8340
|
l2 >>= 1, --a2;
|
|
@@ -8492,10 +8343,10 @@ ${newlined}
|
|
|
8492
8343
|
else {
|
|
8493
8344
|
for (; a2 > 1; )
|
|
8494
8345
|
n2.sqrTo(o2, p2), n2.sqrTo(p2, o2), a2 -= 2;
|
|
8495
|
-
a2 > 0 ? n2.sqrTo(o2, p2) : (
|
|
8346
|
+
a2 > 0 ? n2.sqrTo(o2, p2) : (f2 = o2, o2 = p2, p2 = f2), n2.mulTo(p2, s2[l2], o2);
|
|
8496
8347
|
}
|
|
8497
8348
|
for (; g2 >= 0 && 0 == (t3[g2] & 1 << i2); )
|
|
8498
|
-
n2.sqrTo(o2, p2),
|
|
8349
|
+
n2.sqrTo(o2, p2), f2 = o2, o2 = p2, p2 = f2, --i2 < 0 && (i2 = this.DB - 1, --g2);
|
|
8499
8350
|
}
|
|
8500
8351
|
return n2.revert(o2);
|
|
8501
8352
|
}, w.prototype.modInverse = function be(t3) {
|
|
@@ -8661,13 +8512,13 @@ ${newlined}
|
|
|
8661
8512
|
u2 += "\0";
|
|
8662
8513
|
var c2 = r4("") + u2 + "" + t4, h2 = new Array(n3);
|
|
8663
8514
|
new Be().nextBytes(h2);
|
|
8664
|
-
var l2 = je(h2, c2.length, r4),
|
|
8515
|
+
var l2 = je(h2, c2.length, r4), f2 = [];
|
|
8665
8516
|
for (a2 = 0; a2 < c2.length; a2 += 1)
|
|
8666
|
-
|
|
8667
|
-
var g2 = je(
|
|
8517
|
+
f2[a2] = c2.charCodeAt(a2) ^ l2.charCodeAt(a2);
|
|
8518
|
+
var g2 = je(f2, h2.length, r4), d2 = [0];
|
|
8668
8519
|
for (a2 = 0; a2 < h2.length; a2 += 1)
|
|
8669
8520
|
d2[a2 + 1] = h2[a2] ^ g2.charCodeAt(a2);
|
|
8670
|
-
return new w(d2.concat(
|
|
8521
|
+
return new w(d2.concat(f2));
|
|
8671
8522
|
}(t3, this.n.bitLength() + 7 >> 3, e2, r3);
|
|
8672
8523
|
if (null == n2)
|
|
8673
8524
|
return null;
|
|
@@ -8710,8 +8561,8 @@ ${newlined}
|
|
|
8710
8561
|
var e2 = t3.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(t3.z)).mod(this.curve.q), r3 = t3.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(t3.z)).mod(this.curve.q);
|
|
8711
8562
|
if (w.ZERO.equals(r3))
|
|
8712
8563
|
return w.ZERO.equals(e2) ? this.twice() : this.curve.getInfinity();
|
|
8713
|
-
var n2 = new w("3"), i2 = this.x.toBigInteger(), o2 = this.y.toBigInteger(), s2 = (t3.x.toBigInteger(), t3.y.toBigInteger(), r3.square()), a2 = s2.multiply(r3), u2 = i2.multiply(s2), c2 = e2.square().multiply(this.z), h2 = c2.subtract(u2.shiftLeft(1)).multiply(t3.z).subtract(a2).multiply(r3).mod(this.curve.q), l2 = u2.multiply(n2).multiply(e2).subtract(o2.multiply(a2)).subtract(c2.multiply(e2)).multiply(t3.z).add(e2.multiply(a2)).mod(this.curve.q),
|
|
8714
|
-
return new Ve(this.curve, this.curve.fromBigInteger(h2), this.curve.fromBigInteger(l2),
|
|
8564
|
+
var n2 = new w("3"), i2 = this.x.toBigInteger(), o2 = this.y.toBigInteger(), s2 = (t3.x.toBigInteger(), t3.y.toBigInteger(), r3.square()), a2 = s2.multiply(r3), u2 = i2.multiply(s2), c2 = e2.square().multiply(this.z), h2 = c2.subtract(u2.shiftLeft(1)).multiply(t3.z).subtract(a2).multiply(r3).mod(this.curve.q), l2 = u2.multiply(n2).multiply(e2).subtract(o2.multiply(a2)).subtract(c2.multiply(e2)).multiply(t3.z).add(e2.multiply(a2)).mod(this.curve.q), f2 = a2.multiply(this.z).multiply(t3.z).mod(this.curve.q);
|
|
8565
|
+
return new Ve(this.curve, this.curve.fromBigInteger(h2), this.curve.fromBigInteger(l2), f2);
|
|
8715
8566
|
}, Ve.prototype.twice = function cr() {
|
|
8716
8567
|
if (this.isInfinity())
|
|
8717
8568
|
return this;
|
|
@@ -8851,14 +8702,14 @@ ${newlined}
|
|
|
8851
8702
|
return function(r4, s2) {
|
|
8852
8703
|
var a2, u2, c2 = r4.match(t3), h2 = c2[0], l2 = false;
|
|
8853
8704
|
"{" === h2 ? a2 = {} : "[" === h2 ? a2 = [] : (a2 = [], l2 = true);
|
|
8854
|
-
for (var
|
|
8705
|
+
for (var f2 = [a2], d2 = 1 - l2, p2 = c2.length; d2 < p2; ++d2) {
|
|
8855
8706
|
var v2;
|
|
8856
8707
|
switch ((h2 = c2[d2]).charCodeAt(0)) {
|
|
8857
8708
|
default:
|
|
8858
|
-
(v2 =
|
|
8709
|
+
(v2 = f2[0])[u2 || v2.length] = +h2, u2 = void 0;
|
|
8859
8710
|
break;
|
|
8860
8711
|
case 34:
|
|
8861
|
-
if (-1 !== (h2 = h2.substring(1, h2.length - 1)).indexOf("\\") && (h2 = h2.replace(e2, n2)), v2 =
|
|
8712
|
+
if (-1 !== (h2 = h2.substring(1, h2.length - 1)).indexOf("\\") && (h2 = h2.replace(e2, n2)), v2 = f2[0], !u2) {
|
|
8862
8713
|
if (!(v2 instanceof Array)) {
|
|
8863
8714
|
u2 = h2 || i2;
|
|
8864
8715
|
break;
|
|
@@ -8868,32 +8719,32 @@ ${newlined}
|
|
|
8868
8719
|
v2[u2] = h2, u2 = void 0;
|
|
8869
8720
|
break;
|
|
8870
8721
|
case 91:
|
|
8871
|
-
v2 =
|
|
8722
|
+
v2 = f2[0], f2.unshift(v2[u2 || v2.length] = []), u2 = void 0;
|
|
8872
8723
|
break;
|
|
8873
8724
|
case 93:
|
|
8874
|
-
|
|
8725
|
+
f2.shift();
|
|
8875
8726
|
break;
|
|
8876
8727
|
case 102:
|
|
8877
|
-
(v2 =
|
|
8728
|
+
(v2 = f2[0])[u2 || v2.length] = false, u2 = void 0;
|
|
8878
8729
|
break;
|
|
8879
8730
|
case 110:
|
|
8880
|
-
(v2 =
|
|
8731
|
+
(v2 = f2[0])[u2 || v2.length] = null, u2 = void 0;
|
|
8881
8732
|
break;
|
|
8882
8733
|
case 116:
|
|
8883
|
-
(v2 =
|
|
8734
|
+
(v2 = f2[0])[u2 || v2.length] = true, u2 = void 0;
|
|
8884
8735
|
break;
|
|
8885
8736
|
case 123:
|
|
8886
|
-
v2 =
|
|
8737
|
+
v2 = f2[0], f2.unshift(v2[u2 || v2.length] = {}), u2 = void 0;
|
|
8887
8738
|
break;
|
|
8888
8739
|
case 125:
|
|
8889
|
-
|
|
8740
|
+
f2.shift();
|
|
8890
8741
|
}
|
|
8891
8742
|
}
|
|
8892
8743
|
if (l2) {
|
|
8893
|
-
if (1 !==
|
|
8744
|
+
if (1 !== f2.length)
|
|
8894
8745
|
throw new Error();
|
|
8895
8746
|
a2 = a2[0];
|
|
8896
|
-
} else if (
|
|
8747
|
+
} else if (f2.length)
|
|
8897
8748
|
throw new Error();
|
|
8898
8749
|
if (s2) {
|
|
8899
8750
|
a2 = function t4(e3, r5) {
|
|
@@ -8934,7 +8785,7 @@ ${newlined}
|
|
|
8934
8785
|
}, this.getPEMStringFromHex = function(t3, e2) {
|
|
8935
8786
|
return jr(t3, e2);
|
|
8936
8787
|
}, this.newObject = function(t3) {
|
|
8937
|
-
var e2 = Sr.asn1, r3 = e2.ASN1Object, n2 = e2.DERBoolean, i2 = e2.DERInteger, o2 = e2.DERBitString, s2 = e2.DEROctetString, a2 = e2.DERNull, u2 = e2.DERObjectIdentifier, c2 = e2.DEREnumerated, h2 = e2.DERUTF8String, l2 = e2.DERNumericString,
|
|
8788
|
+
var e2 = Sr.asn1, r3 = e2.ASN1Object, n2 = e2.DERBoolean, i2 = e2.DERInteger, o2 = e2.DERBitString, s2 = e2.DEROctetString, a2 = e2.DERNull, u2 = e2.DERObjectIdentifier, c2 = e2.DEREnumerated, h2 = e2.DERUTF8String, l2 = e2.DERNumericString, f2 = e2.DERPrintableString, g2 = e2.DERTeletexString, d2 = e2.DERIA5String, p2 = e2.DERUTCTime, v2 = e2.DERGeneralizedTime, y2 = e2.DERVisibleString, m2 = e2.DERBMPString, _2 = e2.DERSequence, S2 = e2.DERSet, b2 = e2.DERTaggedObject, w2 = e2.ASN1Util.newObject;
|
|
8938
8789
|
if (t3 instanceof e2.ASN1Object)
|
|
8939
8790
|
return t3;
|
|
8940
8791
|
var F2 = Object.keys(t3);
|
|
@@ -8962,7 +8813,7 @@ ${newlined}
|
|
|
8962
8813
|
if ("numstr" == E)
|
|
8963
8814
|
return new l2(t3[E]);
|
|
8964
8815
|
if ("prnstr" == E)
|
|
8965
|
-
return new
|
|
8816
|
+
return new f2(t3[E]);
|
|
8966
8817
|
if ("telstr" == E)
|
|
8967
8818
|
return new g2(t3[E]);
|
|
8968
8819
|
if ("ia5str" == E)
|
|
@@ -9557,24 +9408,24 @@ ${newlined}
|
|
|
9557
9408
|
void 0 === e2 && (e2 = { ommit_long_octet: 32 }), void 0 === r3 && (r3 = 0), void 0 === n2 && (n2 = "");
|
|
9558
9409
|
var h2, l2 = e2.ommit_long_octet;
|
|
9559
9410
|
if ("01" == (h2 = u2.substr(r3, 2)))
|
|
9560
|
-
return "00" == (
|
|
9411
|
+
return "00" == (f2 = o2(u2, r3)) ? n2 + "BOOLEAN FALSE\n" : n2 + "BOOLEAN TRUE\n";
|
|
9561
9412
|
if ("02" == h2)
|
|
9562
|
-
return n2 + "INTEGER " + c2(
|
|
9413
|
+
return n2 + "INTEGER " + c2(f2 = o2(u2, r3), l2) + "\n";
|
|
9563
9414
|
if ("03" == h2) {
|
|
9564
|
-
var
|
|
9565
|
-
if (i2.isASN1HEX(
|
|
9415
|
+
var f2 = o2(u2, r3);
|
|
9416
|
+
if (i2.isASN1HEX(f2.substr(2))) {
|
|
9566
9417
|
var g2 = n2 + "BITSTRING, encapsulates\n";
|
|
9567
|
-
return g2 += s2(
|
|
9418
|
+
return g2 += s2(f2.substr(2), e2, 0, n2 + " ");
|
|
9568
9419
|
}
|
|
9569
|
-
return n2 + "BITSTRING " + c2(
|
|
9420
|
+
return n2 + "BITSTRING " + c2(f2, l2) + "\n";
|
|
9570
9421
|
}
|
|
9571
9422
|
if ("04" == h2) {
|
|
9572
|
-
|
|
9573
|
-
if (i2.isASN1HEX(
|
|
9423
|
+
f2 = o2(u2, r3);
|
|
9424
|
+
if (i2.isASN1HEX(f2)) {
|
|
9574
9425
|
g2 = n2 + "OCTETSTRING, encapsulates\n";
|
|
9575
|
-
return g2 += s2(
|
|
9426
|
+
return g2 += s2(f2, e2, 0, n2 + " ");
|
|
9576
9427
|
}
|
|
9577
|
-
return n2 + "OCTETSTRING " + c2(
|
|
9428
|
+
return n2 + "OCTETSTRING " + c2(f2, l2) + "\n";
|
|
9578
9429
|
}
|
|
9579
9430
|
if ("05" == h2)
|
|
9580
9431
|
return n2 + "NULL\n";
|
|
@@ -9628,12 +9479,12 @@ ${newlined}
|
|
|
9628
9479
|
g2 += s2(u2, e2, b2[S2], n2 + " ");
|
|
9629
9480
|
return g2;
|
|
9630
9481
|
}
|
|
9631
|
-
|
|
9632
|
-
if (Fr.isASN1HEX(
|
|
9482
|
+
f2 = o2(u2, r3);
|
|
9483
|
+
if (Fr.isASN1HEX(f2)) {
|
|
9633
9484
|
var g2 = n2 + "[" + w2 + "]\n";
|
|
9634
|
-
return g2 += s2(
|
|
9485
|
+
return g2 += s2(f2, e2, 0, n2 + " ");
|
|
9635
9486
|
}
|
|
9636
|
-
return ("68747470" ==
|
|
9487
|
+
return ("68747470" == f2.substr(0, 8) || "subjectAltName" === e2.x509ExtName && 2 == w2) && (f2 = Dr(f2)), g2 = n2 + "[" + w2 + "] " + f2 + "\n";
|
|
9637
9488
|
}
|
|
9638
9489
|
return n2 + "UNKNOWN(" + h2 + ") " + o2(u2, r3) + "\n";
|
|
9639
9490
|
}, Fr.isContextTag = function(t3, e2) {
|
|
@@ -9683,11 +9534,11 @@ ${newlined}
|
|
|
9683
9534
|
throw new Error("not least zeros for DER INTEGER");
|
|
9684
9535
|
}
|
|
9685
9536
|
if (32 & parseInt(c2, 16)) {
|
|
9686
|
-
for (var l2 = o2.getVblen(t3, e2),
|
|
9687
|
-
|
|
9537
|
+
for (var l2 = o2.getVblen(t3, e2), f2 = 0, g2 = o2.getChildIdx(t3, e2), d2 = 0; d2 < g2.length; d2++) {
|
|
9538
|
+
f2 += o2.getTLV(t3, g2[d2]).length, o2.checkStrictDER(t3, g2[d2], r3, n2, i2);
|
|
9688
9539
|
}
|
|
9689
|
-
if (2 * l2 !=
|
|
9690
|
-
throw new Error("sum of children's TLV length and L unmatch: " + 2 * l2 + "!=" +
|
|
9540
|
+
if (2 * l2 != f2)
|
|
9541
|
+
throw new Error("sum of children's TLV length and L unmatch: " + 2 * l2 + "!=" + f2);
|
|
9691
9542
|
}
|
|
9692
9543
|
}, Fr.oidname = function(t3) {
|
|
9693
9544
|
var e2 = Sr.asn1;
|
|
@@ -10228,12 +10079,12 @@ ${newlined}
|
|
|
10228
10079
|
if (void 0 !== e2[n2] && (n2 = e2[r4]), void 0 !== t3[n2])
|
|
10229
10080
|
return t3[n2];
|
|
10230
10081
|
throw "unregistered EC curve name: " + n2;
|
|
10231
|
-
}, this.regist = function(n2, i2, o2, s2, a2, u2, c2, h2, l2,
|
|
10082
|
+
}, this.regist = function(n2, i2, o2, s2, a2, u2, c2, h2, l2, f2, g2, d2) {
|
|
10232
10083
|
t3[n2] = {};
|
|
10233
10084
|
var p2 = r3(o2), v2 = r3(s2), y2 = r3(a2), m2 = r3(u2), _2 = r3(c2), S2 = new Ke(p2, v2, y2), b2 = S2.decodePointHex("04" + h2 + l2);
|
|
10234
10085
|
t3[n2].name = n2, t3[n2].keylen = i2, t3[n2].curve = S2, t3[n2].G = b2, t3[n2].n = m2, t3[n2].h = _2, t3[n2].oid = g2, t3[n2].info = d2;
|
|
10235
|
-
for (var w2 = 0; w2 <
|
|
10236
|
-
e2[
|
|
10086
|
+
for (var w2 = 0; w2 < f2.length; w2++)
|
|
10087
|
+
e2[f2[w2]] = n2;
|
|
10237
10088
|
};
|
|
10238
10089
|
}(), Sr.crypto.ECParameterDB.regist("secp128r1", 128, "FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFF", "FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFC", "E87579C11079F43DD824993C2CEE5ED3", "FFFFFFFE0000000075A30D1B9038A115", "1", "161FF7528B899B2D0C28607CA52C5B86", "CF5AC8395BAFEB13C02DA292DDED7A83", [], "", "secp128r1 : SECG curve over a 128 bit prime field"), Sr.crypto.ECParameterDB.regist("secp160k1", 160, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73", "0", "7", "0100000000000000000001B8FA16DFAB9ACA16B6B3", "1", "3B4C382CE37AA192A4019E763036F4F5DD4D7EBB", "938CF935318FDCED6BC28286531733C3F03C4FEE", [], "", "secp160k1 : SECG curve over a 160 bit prime field"), Sr.crypto.ECParameterDB.regist("secp160r1", 160, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFF", "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFC", "1C97BEFC54BD7A8B65ACF89F81D4D4ADC565FA45", "0100000000000000000001F4C8F927AED3CA752257", "1", "4A96B5688EF573284664698968C38BB913CBFC82", "23A628553168947D59DCC912042351377AC5FB32", [], "", "secp160r1 : SECG curve over a 160 bit prime field"), Sr.crypto.ECParameterDB.regist("secp192k1", 192, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFEE37", "0", "3", "FFFFFFFFFFFFFFFFFFFFFFFE26F2FC170F69466A74DEFD8D", "1", "DB4FF10EC057E9AE26B07D0280B7F4341DA5D1B1EAE06C7D", "9B2F2F6D9C5628A7844163D015BE86344082AA88D95E2F9D", []), Sr.crypto.ECParameterDB.regist("secp192r1", 192, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF", "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC", "64210519E59C80E70FA7E9AB72243049FEB8DEECC146B9B1", "FFFFFFFFFFFFFFFFFFFFFFFF99DEF836146BC9B1B4D22831", "1", "188DA80EB03090F67CBF20EB43A18800F4FF0AFD82FF1012", "07192B95FFC8DA78631011ED6B24CDD573F977A11E794811", []), Sr.crypto.ECParameterDB.regist("secp224r1", 224, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF000000000000000000000001", "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFE", "B4050A850C04B3ABF54132565044B0B7D7BFD8BA270B39432355FFB4", "FFFFFFFFFFFFFFFFFFFFFFFFFFFF16A2E0B8F03E13DD29455C5C2A3D", "1", "B70E0CBD6BB4BF7F321390B94A03C1D356C21122343280D6115C1D21", "BD376388B5F723FB4C22DFE6CD4375A05A07476444D5819985007E34", []), Sr.crypto.ECParameterDB.regist("secp256k1", 256, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2F", "0", "7", "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141", "1", "79BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798", "483ADA7726A3C4655DA4FBFC0E1108A8FD17B448A68554199C47D08FFB10D4B8", []), Sr.crypto.ECParameterDB.regist("secp256r1", 256, "FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFF", "FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFC", "5AC635D8AA3A93E7B3EBBD55769886BC651D06B0CC53B0F63BCE3C3E27D2604B", "FFFFFFFF00000000FFFFFFFFFFFFFFFFBCE6FAADA7179E84F3B9CAC2FC632551", "1", "6B17D1F2E12C4247F8BCE6E563A440F277037D812DEB33A0F4A13945D898C296", "4FE342E2FE1A7F9B8EE7EB4A7C0F9E162BCE33576B315ECECBB6406837BF51F5", ["NIST P-256", "P-256", "prime256v1"]), Sr.crypto.ECParameterDB.regist("secp384r1", 384, "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFF0000000000000000FFFFFFFF", "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFF0000000000000000FFFFFFFC", "B3312FA7E23EE7E4988E056BE3F82D19181D9C6EFE8141120314088F5013875AC656398D8A2ED19D2A85C8EDD3EC2AEF", "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC7634D81F4372DDF581A0DB248B0A77AECEC196ACCC52973", "1", "AA87CA22BE8B05378EB1C71EF320AD746E1D3B628BA79B9859F741E082542A385502F25DBF55296C3A545E3872760AB7", "3617de4a96262c6f5d9e98bf9292dc29f8f41dbd289a147ce9da3113b5f0b8c00a60b1ce1d7e819d7a431d7c90ea0e5f", ["NIST P-384", "P-384"]), Sr.crypto.ECParameterDB.regist("secp521r1", 521, "1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC", "051953EB9618E1C9A1F929A21A0B68540EEA2DA725B99B315F3B8B489918EF109E156193951EC7E937B1652C0BD3BB1BF073573DF883D2C34F1EF451FD46B503F00", "1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFA51868783BF2F966B7FCC0148F709A5D03BB5C9B8899C47AEBB6FB71E91386409", "1", "C6858E06B70404E9CD9E3ECB662395B4429C648139053FB521F828AF606B4D3DBAA14B5E77EFE75928FE1DC127A2FFA8DE3348B3C1856A429BF97E7E31C2E5BD66", "011839296a789a3bc0045c8a5fb42c7d1bd998f54449579b446817afbd17273e662c97ee72995ef42640c550b9013fad0761353c7086a272c24088be94769fd16650", ["NIST P-521", "P-521"]);
|
|
10239
10090
|
var tn = function() {
|
|
@@ -10276,8 +10127,8 @@ ${newlined}
|
|
|
10276
10127
|
if (null != h2 && l2.update(h2), l2.update(a3), l2.update(s3), h2 = l2.finalize(), (c2 += v.enc.Hex.stringify(h2)).length >= 2 * u2)
|
|
10277
10128
|
break;
|
|
10278
10129
|
}
|
|
10279
|
-
var
|
|
10280
|
-
return
|
|
10130
|
+
var f2 = {};
|
|
10131
|
+
return f2.keyhex = c2.substr(0, 2 * i2[e3].keylen), f2.ivhex = c2.substr(2 * i2[e3].keylen, 2 * i2[e3].ivlen), f2;
|
|
10281
10132
|
}, a2 = function t4(e3, r4, n3, o3) {
|
|
10282
10133
|
var s3 = v.enc.Base64.parse(e3), a3 = v.enc.Hex.stringify(s3);
|
|
10283
10134
|
return (0, i2[r4].proc)(a3, n3, o3);
|
|
@@ -10332,11 +10183,11 @@ ${newlined}
|
|
|
10332
10183
|
if (l2.length < 2)
|
|
10333
10184
|
throw new Error("malformed format: SEQUENCE(0.0.1.0.1).items < 2: " + l2.length);
|
|
10334
10185
|
o3.pbkdf2Salt = i3(e3, l2[0]);
|
|
10335
|
-
var
|
|
10186
|
+
var f2 = i3(e3, l2[1]);
|
|
10336
10187
|
try {
|
|
10337
|
-
o3.pbkdf2Iter = parseInt(
|
|
10188
|
+
o3.pbkdf2Iter = parseInt(f2, 16);
|
|
10338
10189
|
} catch (t5) {
|
|
10339
|
-
throw new Error("malformed format pbkdf2Iter: " +
|
|
10190
|
+
throw new Error("malformed format pbkdf2Iter: " + f2);
|
|
10340
10191
|
}
|
|
10341
10192
|
return o3;
|
|
10342
10193
|
}, getPBKDF2KeyHexFromParam: function t4(e3, r4) {
|
|
@@ -10452,13 +10303,13 @@ ${newlined}
|
|
|
10452
10303
|
if ("RSA" === t3.kty && void 0 !== t3.n && void 0 !== t3.e && void 0 !== t3.d)
|
|
10453
10304
|
return (P2 = new u2()).setPrivate(Rr(t3.n), Rr(t3.e), Rr(t3.d)), P2;
|
|
10454
10305
|
if ("EC" === t3.kty && void 0 !== t3.crv && void 0 !== t3.x && void 0 !== t3.y && void 0 === t3.d) {
|
|
10455
|
-
var l2 = (k2 = new s2({ curve: t3.crv })).ecparams.keylen / 4,
|
|
10456
|
-
return k2.setPublicKeyHex(
|
|
10306
|
+
var l2 = (k2 = new s2({ curve: t3.crv })).ecparams.keylen / 4, f2 = "04" + ("0000000000" + Rr(t3.x)).slice(-l2) + ("0000000000" + Rr(t3.y)).slice(-l2);
|
|
10307
|
+
return k2.setPublicKeyHex(f2), k2;
|
|
10457
10308
|
}
|
|
10458
10309
|
if ("EC" === t3.kty && void 0 !== t3.crv && void 0 !== t3.x && void 0 !== t3.y && void 0 !== t3.d) {
|
|
10459
|
-
l2 = (k2 = new s2({ curve: t3.crv })).ecparams.keylen / 4,
|
|
10310
|
+
l2 = (k2 = new s2({ curve: t3.crv })).ecparams.keylen / 4, f2 = "04" + ("0000000000" + Rr(t3.x)).slice(-l2) + ("0000000000" + Rr(t3.y)).slice(-l2);
|
|
10460
10311
|
var g2 = ("0000000000" + Rr(t3.d)).slice(-l2);
|
|
10461
|
-
return k2.setPublicKeyHex(
|
|
10312
|
+
return k2.setPublicKeyHex(f2), k2.setPrivateKeyHex(g2), k2;
|
|
10462
10313
|
}
|
|
10463
10314
|
if ("pkcs5prv" === r3) {
|
|
10464
10315
|
var d2, p2 = t3, v2 = Fr;
|
|
@@ -10530,7 +10381,7 @@ ${newlined}
|
|
|
10530
10381
|
}
|
|
10531
10382
|
throw new Error("unknown algorithm: " + t3);
|
|
10532
10383
|
}, tn.getPEM = function(t3, e2, r3, n2, i2, o2) {
|
|
10533
|
-
var s2 = Sr, a2 = s2.asn1, u2 = a2.DERObjectIdentifier, c2 = a2.DERInteger, h2 = a2.ASN1Util.newObject, l2 = a2.x509.SubjectPublicKeyInfo,
|
|
10384
|
+
var s2 = Sr, a2 = s2.asn1, u2 = a2.DERObjectIdentifier, c2 = a2.DERInteger, h2 = a2.ASN1Util.newObject, l2 = a2.x509.SubjectPublicKeyInfo, f2 = s2.crypto, g2 = f2.DSA, d2 = f2.ECDSA, p2 = Me;
|
|
10534
10385
|
function y2(t4) {
|
|
10535
10386
|
return h2({ seq: [{ int: 0 }, { int: { bigint: t4.n } }, { int: t4.e }, { int: { bigint: t4.d } }, { int: { bigint: t4.p } }, { int: { bigint: t4.q } }, { int: { bigint: t4.dmp1 } }, { int: { bigint: t4.dmq1 } }, { int: { bigint: t4.coeff } }] });
|
|
10536
10387
|
}
|
|
@@ -10689,7 +10540,7 @@ ${newlined}
|
|
|
10689
10540
|
return [];
|
|
10690
10541
|
}
|
|
10691
10542
|
function on(t3) {
|
|
10692
|
-
var e2, r3 = Fr, n2 = r3.getChildIdx, i2 = r3.getV, o2 = r3.getTLV, s2 = r3.getVbyList, a2 = r3.getVbyListEx, u2 = r3.getTLVbyList, c2 = r3.getTLVbyListEx, h2 = r3.getIdxbyList, l2 = r3.getIdxbyListEx,
|
|
10543
|
+
var e2, r3 = Fr, n2 = r3.getChildIdx, i2 = r3.getV, o2 = r3.getTLV, s2 = r3.getVbyList, a2 = r3.getVbyListEx, u2 = r3.getTLVbyList, c2 = r3.getTLVbyListEx, h2 = r3.getIdxbyList, l2 = r3.getIdxbyListEx, f2 = r3.getVidx, g2 = r3.getInt, d2 = r3.oidname, p2 = r3.hextooidstr, v2 = Mr;
|
|
10693
10544
|
try {
|
|
10694
10545
|
e2 = Sr.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV;
|
|
10695
10546
|
} catch (t4) {
|
|
@@ -10768,7 +10619,7 @@ ${newlined}
|
|
|
10768
10619
|
var l3 = { critical: false }, g3 = 0;
|
|
10769
10620
|
3 === n2(a3, o3[c3]).length && (l3.critical = true, g3 = 1), l3.oid = r3.hextooidstr(s2(a3, o3[c3], [0], "06"));
|
|
10770
10621
|
var d3 = h2(a3, o3[c3], [1 + g3]);
|
|
10771
|
-
l3.vidx =
|
|
10622
|
+
l3.vidx = f2(a3, d3), this.aExtInfo.push(l3);
|
|
10772
10623
|
}
|
|
10773
10624
|
}, this.getExtInfo = function(t4) {
|
|
10774
10625
|
var e3 = this.aExtInfo, r4 = t4;
|
|
@@ -11202,8 +11053,8 @@ ${newlined}
|
|
|
11202
11053
|
else if ("subjectKeyIdentifier" === c3)
|
|
11203
11054
|
t4 += " " + this.getExtSubjectKeyIdentifier().kid.hex + "\n";
|
|
11204
11055
|
else if ("authorityKeyIdentifier" === c3) {
|
|
11205
|
-
var
|
|
11206
|
-
void 0 !==
|
|
11056
|
+
var f3 = this.getExtAuthorityKeyIdentifier();
|
|
11057
|
+
void 0 !== f3.kid && (t4 += " kid=" + f3.kid.hex + "\n");
|
|
11207
11058
|
} else {
|
|
11208
11059
|
if ("extKeyUsage" === c3)
|
|
11209
11060
|
t4 += " " + this.getExtExtKeyUsage().array.join(", ") + "\n";
|
|
@@ -11251,9 +11102,9 @@ ${newlined}
|
|
|
11251
11102
|
var h2 = Lr(u2(Nr("\0\0\0\0\0\0\0\0" + i2 + c2))), l2 = [];
|
|
11252
11103
|
for (n2 = 0; n2 < a2 - r3 - o2 - 2; n2 += 1)
|
|
11253
11104
|
l2[n2] = 0;
|
|
11254
|
-
var
|
|
11255
|
-
for (n2 = 0; n2 <
|
|
11256
|
-
d2[n2] =
|
|
11105
|
+
var f2 = String.fromCharCode.apply(String, l2) + "" + c2, g2 = rn(h2, f2.length, u2), d2 = [];
|
|
11106
|
+
for (n2 = 0; n2 < f2.length; n2 += 1)
|
|
11107
|
+
d2[n2] = f2.charCodeAt(n2) ^ g2.charCodeAt(n2);
|
|
11257
11108
|
var p2 = 65280 >> 8 * a2 - s2 & 255;
|
|
11258
11109
|
for (d2[0] &= ~p2, n2 = 0; n2 < o2; n2++)
|
|
11259
11110
|
d2.push(h2.charCodeAt(n2));
|
|
@@ -11311,12 +11162,12 @@ ${newlined}
|
|
|
11311
11162
|
l2.unshift(0);
|
|
11312
11163
|
if (188 !== l2[h2 - 1])
|
|
11313
11164
|
throw new Error("encoded message does not end in 0xbc");
|
|
11314
|
-
var
|
|
11315
|
-
if (0 != (
|
|
11165
|
+
var f2 = (l2 = String.fromCharCode.apply(String, l2)).substr(0, h2 - u2 - 1), g2 = l2.substr(f2.length, u2), d2 = 65280 >> 8 * h2 - c2 & 255;
|
|
11166
|
+
if (0 != (f2.charCodeAt(0) & d2))
|
|
11316
11167
|
throw new Error("bits beyond keysize not zero");
|
|
11317
|
-
var p2 = rn(g2,
|
|
11318
|
-
for (i2 = 0; i2 <
|
|
11319
|
-
v2[i2] =
|
|
11168
|
+
var p2 = rn(g2, f2.length, s2), v2 = [];
|
|
11169
|
+
for (i2 = 0; i2 < f2.length; i2 += 1)
|
|
11170
|
+
v2[i2] = f2.charCodeAt(i2) ^ p2.charCodeAt(i2);
|
|
11320
11171
|
v2[0] &= ~d2;
|
|
11321
11172
|
var y2 = h2 - u2 - n2 - 2;
|
|
11322
11173
|
for (i2 = 0; i2 < y2; i2 += 1)
|
|
@@ -11373,7 +11224,7 @@ ${newlined}
|
|
|
11373
11224
|
}
|
|
11374
11225
|
};
|
|
11375
11226
|
}, Sr.jws.JWS.sign = function(t3, e2, r3, n2, i2) {
|
|
11376
|
-
var o2, s2, a2, u2 = Sr, c2 = u2.jws.JWS, h2 = c2.readSafeJSONString, l2 = c2.isSafeJSONString,
|
|
11227
|
+
var o2, s2, a2, u2 = Sr, c2 = u2.jws.JWS, h2 = c2.readSafeJSONString, l2 = c2.isSafeJSONString, f2 = u2.crypto, d2 = (f2.ECDSA, f2.Mac), p2 = f2.Signature, v2 = JSON;
|
|
11377
11228
|
if ("string" != typeof e2 && "object" != (void 0 === e2 ? "undefined" : g(e2)))
|
|
11378
11229
|
throw "spHeader must be JSON string or object: " + e2;
|
|
11379
11230
|
if ("object" == (void 0 === e2 ? "undefined" : g(e2)) && (s2 = e2, o2 = v2.stringify(s2)), "string" == typeof e2) {
|
|
@@ -11409,7 +11260,7 @@ ${newlined}
|
|
|
11409
11260
|
var l2 = t3.split(".");
|
|
11410
11261
|
if (3 !== l2.length)
|
|
11411
11262
|
return false;
|
|
11412
|
-
var
|
|
11263
|
+
var f2 = l2[0] + "." + l2[1], d2 = Rr(l2[2]), p2 = s2(wr(l2[0])), v2 = null, y2 = null;
|
|
11413
11264
|
if (void 0 === p2.alg)
|
|
11414
11265
|
throw "algorithm not specified in header";
|
|
11415
11266
|
if ((y2 = (v2 = p2.alg).substr(0, 2), null != r3 && "[object Array]" === Object.prototype.toString.call(r3) && r3.length > 0) && -1 == (":" + r3.join(":") + ":").indexOf(":" + v2 + ":"))
|
|
@@ -11429,7 +11280,7 @@ ${newlined}
|
|
|
11429
11280
|
if (void 0 === e2)
|
|
11430
11281
|
throw "hexadecimal key shall be specified for HMAC";
|
|
11431
11282
|
var _2 = new c2({ alg: m2, pass: e2 });
|
|
11432
|
-
return _2.updateString(
|
|
11283
|
+
return _2.updateString(f2), d2 == _2.doFinal();
|
|
11433
11284
|
}
|
|
11434
11285
|
if (-1 != m2.indexOf("withECDSA")) {
|
|
11435
11286
|
var S2, b2 = null;
|
|
@@ -11438,35 +11289,35 @@ ${newlined}
|
|
|
11438
11289
|
} catch (t4) {
|
|
11439
11290
|
return false;
|
|
11440
11291
|
}
|
|
11441
|
-
return (S2 = new h2({ alg: m2 })).init(e2), S2.updateString(
|
|
11292
|
+
return (S2 = new h2({ alg: m2 })).init(e2), S2.updateString(f2), S2.verify(b2);
|
|
11442
11293
|
}
|
|
11443
|
-
return (S2 = new h2({ alg: m2 })).init(e2), S2.updateString(
|
|
11294
|
+
return (S2 = new h2({ alg: m2 })).init(e2), S2.updateString(f2), S2.verify(d2);
|
|
11444
11295
|
}, Sr.jws.JWS.parse = function(t3) {
|
|
11445
11296
|
var e2, r3, n2, i2 = t3.split("."), o2 = {};
|
|
11446
11297
|
if (2 != i2.length && 3 != i2.length)
|
|
11447
11298
|
throw "malformed sJWS: wrong number of '.' splitted elements";
|
|
11448
11299
|
return e2 = i2[0], r3 = i2[1], 3 == i2.length && (n2 = i2[2]), o2.headerObj = Sr.jws.JWS.readSafeJSONString(wr(e2)), o2.payloadObj = Sr.jws.JWS.readSafeJSONString(wr(r3)), o2.headerPP = JSON.stringify(o2.headerObj, null, " "), null == o2.payloadObj ? o2.payloadPP = wr(r3) : o2.payloadPP = JSON.stringify(o2.payloadObj, null, " "), void 0 !== n2 && (o2.sigHex = Rr(n2)), o2;
|
|
11449
11300
|
}, Sr.jws.JWS.verifyJWT = function(t3, e2, r3) {
|
|
11450
|
-
var n2 = Sr.jws, i2 = n2.JWS, o2 = i2.readSafeJSONString, s2 = i2.inArray, a2 = i2.includedArray, u2 = t3.split("."), c2 = u2[0], h2 = u2[1], l2 = (Rr(u2[2]), o2(wr(c2))),
|
|
11301
|
+
var n2 = Sr.jws, i2 = n2.JWS, o2 = i2.readSafeJSONString, s2 = i2.inArray, a2 = i2.includedArray, u2 = t3.split("."), c2 = u2[0], h2 = u2[1], l2 = (Rr(u2[2]), o2(wr(c2))), f2 = o2(wr(h2));
|
|
11451
11302
|
if (void 0 === l2.alg)
|
|
11452
11303
|
return false;
|
|
11453
11304
|
if (void 0 === r3.alg)
|
|
11454
11305
|
throw "acceptField.alg shall be specified";
|
|
11455
11306
|
if (!s2(l2.alg, r3.alg))
|
|
11456
11307
|
return false;
|
|
11457
|
-
if (void 0 !==
|
|
11308
|
+
if (void 0 !== f2.iss && "object" === g(r3.iss) && !s2(f2.iss, r3.iss))
|
|
11458
11309
|
return false;
|
|
11459
|
-
if (void 0 !==
|
|
11310
|
+
if (void 0 !== f2.sub && "object" === g(r3.sub) && !s2(f2.sub, r3.sub))
|
|
11460
11311
|
return false;
|
|
11461
|
-
if (void 0 !==
|
|
11462
|
-
if ("string" == typeof
|
|
11463
|
-
if (!s2(
|
|
11312
|
+
if (void 0 !== f2.aud && "object" === g(r3.aud)) {
|
|
11313
|
+
if ("string" == typeof f2.aud) {
|
|
11314
|
+
if (!s2(f2.aud, r3.aud))
|
|
11464
11315
|
return false;
|
|
11465
|
-
} else if ("object" == g(
|
|
11316
|
+
} else if ("object" == g(f2.aud) && !a2(f2.aud, r3.aud))
|
|
11466
11317
|
return false;
|
|
11467
11318
|
}
|
|
11468
11319
|
var d2 = n2.IntDate.getNow();
|
|
11469
|
-
return void 0 !== r3.verifyAt && "number" == typeof r3.verifyAt && (d2 = r3.verifyAt), void 0 !== r3.gracePeriod && "number" == typeof r3.gracePeriod || (r3.gracePeriod = 0), !(void 0 !==
|
|
11320
|
+
return void 0 !== r3.verifyAt && "number" == typeof r3.verifyAt && (d2 = r3.verifyAt), void 0 !== r3.gracePeriod && "number" == typeof r3.gracePeriod || (r3.gracePeriod = 0), !(void 0 !== f2.exp && "number" == typeof f2.exp && f2.exp + r3.gracePeriod < d2) && (!(void 0 !== f2.nbf && "number" == typeof f2.nbf && d2 < f2.nbf - r3.gracePeriod) && (!(void 0 !== f2.iat && "number" == typeof f2.iat && d2 < f2.iat - r3.gracePeriod) && ((void 0 === f2.jti || void 0 === r3.jti || f2.jti === r3.jti) && !!i2.verify(t3, e2, r3.alg))));
|
|
11470
11321
|
}, Sr.jws.JWS.includedArray = function(t3, e2) {
|
|
11471
11322
|
var r3 = Sr.jws.JWS.inArray;
|
|
11472
11323
|
if (null === t3)
|
|
@@ -11686,7 +11537,7 @@ ${newlined}
|
|
|
11686
11537
|
if (e3.byteLength < r3 + (n3 || 0))
|
|
11687
11538
|
throw new RangeError("'length' is out of bounds");
|
|
11688
11539
|
e3 = void 0 === r3 && void 0 === n3 ? new Uint8Array(e3) : void 0 === n3 ? new Uint8Array(e3, r3) : new Uint8Array(e3, r3, n3);
|
|
11689
|
-
u.TYPED_ARRAY_SUPPORT ? (t4 = e3).__proto__ = u.prototype : t4 =
|
|
11540
|
+
u.TYPED_ARRAY_SUPPORT ? (t4 = e3).__proto__ = u.prototype : t4 = f(t4, e3);
|
|
11690
11541
|
return t4;
|
|
11691
11542
|
}(t3, e2, r2, n2) : "string" == typeof e2 ? function s2(t4, e3, r3) {
|
|
11692
11543
|
"string" == typeof r3 && "" !== r3 || (r3 = "utf8");
|
|
@@ -11704,9 +11555,9 @@ ${newlined}
|
|
|
11704
11555
|
if ("undefined" != typeof ArrayBuffer && e3.buffer instanceof ArrayBuffer || "length" in e3)
|
|
11705
11556
|
return "number" != typeof e3.length || function n3(t5) {
|
|
11706
11557
|
return t5 != t5;
|
|
11707
|
-
}(e3.length) ? a(t4, 0) :
|
|
11558
|
+
}(e3.length) ? a(t4, 0) : f(t4, e3);
|
|
11708
11559
|
if ("Buffer" === e3.type && o(e3.data))
|
|
11709
|
-
return
|
|
11560
|
+
return f(t4, e3.data);
|
|
11710
11561
|
}
|
|
11711
11562
|
throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.");
|
|
11712
11563
|
}(t3, e2);
|
|
@@ -11723,7 +11574,7 @@ ${newlined}
|
|
|
11723
11574
|
t3[r2] = 0;
|
|
11724
11575
|
return t3;
|
|
11725
11576
|
}
|
|
11726
|
-
function
|
|
11577
|
+
function f(t3, e2) {
|
|
11727
11578
|
var r2 = e2.length < 0 ? 0 : 0 | g(e2.length);
|
|
11728
11579
|
t3 = a(t3, r2);
|
|
11729
11580
|
for (var n2 = 0; n2 < r2; n2 += 1)
|
|
@@ -11844,8 +11695,8 @@ ${newlined}
|
|
|
11844
11695
|
-1 !== h2 && (o2 -= o2 - h2), h2 = -1;
|
|
11845
11696
|
} else
|
|
11846
11697
|
for (r2 + u2 > a2 && (r2 = a2 - u2), o2 = r2; o2 >= 0; o2--) {
|
|
11847
|
-
for (var l2 = true,
|
|
11848
|
-
if (c2(t3, o2 +
|
|
11698
|
+
for (var l2 = true, f2 = 0; f2 < u2; f2++)
|
|
11699
|
+
if (c2(t3, o2 + f2) !== c2(e2, f2)) {
|
|
11849
11700
|
l2 = false;
|
|
11850
11701
|
break;
|
|
11851
11702
|
}
|
|
@@ -11916,7 +11767,7 @@ ${newlined}
|
|
|
11916
11767
|
}
|
|
11917
11768
|
null === h2 ? (h2 = 65533, l2 = 1) : h2 > 65535 && (h2 -= 65536, n2.push(h2 >>> 10 & 1023 | 55296), h2 = 56320 | 1023 & h2), n2.push(h2), i2 += l2;
|
|
11918
11769
|
}
|
|
11919
|
-
return function
|
|
11770
|
+
return function f2(t4) {
|
|
11920
11771
|
var e3 = t4.length;
|
|
11921
11772
|
if (e3 <= C)
|
|
11922
11773
|
return String.fromCharCode.apply(String, t4);
|
|
@@ -12041,9 +11892,9 @@ ${newlined}
|
|
|
12041
11892
|
return 1;
|
|
12042
11893
|
if (this === e2)
|
|
12043
11894
|
return 0;
|
|
12044
|
-
for (var s2 = (o2 >>>= 0) - (i2 >>>= 0), a2 = (n2 >>>= 0) - (r2 >>>= 0), c2 = Math.min(s2, a2), h2 = this.slice(i2, o2), l2 = e2.slice(r2, n2),
|
|
12045
|
-
if (h2[
|
|
12046
|
-
s2 = h2[
|
|
11895
|
+
for (var s2 = (o2 >>>= 0) - (i2 >>>= 0), a2 = (n2 >>>= 0) - (r2 >>>= 0), c2 = Math.min(s2, a2), h2 = this.slice(i2, o2), l2 = e2.slice(r2, n2), f2 = 0; f2 < c2; ++f2)
|
|
11896
|
+
if (h2[f2] !== l2[f2]) {
|
|
11897
|
+
s2 = h2[f2], a2 = l2[f2];
|
|
12047
11898
|
break;
|
|
12048
11899
|
}
|
|
12049
11900
|
return s2 < a2 ? -1 : a2 < s2 ? 1 : 0;
|
|
@@ -12408,10 +12259,10 @@ ${newlined}
|
|
|
12408
12259
|
}, function(t, e, r) {
|
|
12409
12260
|
"use strict";
|
|
12410
12261
|
e.byteLength = function n(t2) {
|
|
12411
|
-
var e2 =
|
|
12262
|
+
var e2 = f(t2), r2 = e2[0], n2 = e2[1];
|
|
12412
12263
|
return 3 * (r2 + n2) / 4 - n2;
|
|
12413
12264
|
}, e.toByteArray = function i(t2) {
|
|
12414
|
-
var e2, r2, n =
|
|
12265
|
+
var e2, r2, n = f(t2), i2 = n[0], o = n[1], s2 = new u(function c2(t3, e3, r3) {
|
|
12415
12266
|
return 3 * (e3 + r3) / 4 - r3;
|
|
12416
12267
|
}(0, i2, o)), h2 = 0, l2 = o > 0 ? i2 - 4 : i2;
|
|
12417
12268
|
for (r2 = 0; r2 < l2; r2 += 4)
|
|
@@ -12427,7 +12278,7 @@ ${newlined}
|
|
|
12427
12278
|
};
|
|
12428
12279
|
for (var s = [], a = [], u = "undefined" != typeof Uint8Array ? Uint8Array : Array, c = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", h = 0, l = c.length; h < l; ++h)
|
|
12429
12280
|
s[h] = c[h], a[c.charCodeAt(h)] = h;
|
|
12430
|
-
function
|
|
12281
|
+
function f(t2) {
|
|
12431
12282
|
var e2 = t2.length;
|
|
12432
12283
|
if (e2 % 4 > 0)
|
|
12433
12284
|
throw new Error("Invalid string. Length must be a multiple of 4");
|
|
@@ -12442,10 +12293,10 @@ ${newlined}
|
|
|
12442
12293
|
a["-".charCodeAt(0)] = 62, a["_".charCodeAt(0)] = 63;
|
|
12443
12294
|
}, function(t, e) {
|
|
12444
12295
|
e.read = function(t2, e2, r, n, i) {
|
|
12445
|
-
var o, s, a = 8 * i - n - 1, u = (1 << a) - 1, c = u >> 1, h = -7, l = r ? i - 1 : 0,
|
|
12446
|
-
for (l +=
|
|
12296
|
+
var o, s, a = 8 * i - n - 1, u = (1 << a) - 1, c = u >> 1, h = -7, l = r ? i - 1 : 0, f = r ? -1 : 1, g = t2[e2 + l];
|
|
12297
|
+
for (l += f, o = g & (1 << -h) - 1, g >>= -h, h += a; h > 0; o = 256 * o + t2[e2 + l], l += f, h -= 8)
|
|
12447
12298
|
;
|
|
12448
|
-
for (s = o & (1 << -h) - 1, o >>= -h, h += n; h > 0; s = 256 * s + t2[e2 + l], l +=
|
|
12299
|
+
for (s = o & (1 << -h) - 1, o >>= -h, h += n; h > 0; s = 256 * s + t2[e2 + l], l += f, h -= 8)
|
|
12449
12300
|
;
|
|
12450
12301
|
if (0 === o)
|
|
12451
12302
|
o = 1 - c;
|
|
@@ -12456,8 +12307,8 @@ ${newlined}
|
|
|
12456
12307
|
}
|
|
12457
12308
|
return (g ? -1 : 1) * s * Math.pow(2, o - n);
|
|
12458
12309
|
}, e.write = function(t2, e2, r, n, i, o) {
|
|
12459
|
-
var s, a, u, c = 8 * o - i - 1, h = (1 << c) - 1, l = h >> 1,
|
|
12460
|
-
for (e2 = Math.abs(e2), isNaN(e2) || e2 === 1 / 0 ? (a = isNaN(e2) ? 1 : 0, s = h) : (s = Math.floor(Math.log(e2) / Math.LN2), e2 * (u = Math.pow(2, -s)) < 1 && (s--, u *= 2), (e2 += s + l >= 1 ?
|
|
12310
|
+
var s, a, u, c = 8 * o - i - 1, h = (1 << c) - 1, l = h >> 1, f = 23 === i ? Math.pow(2, -24) - Math.pow(2, -77) : 0, g = n ? 0 : o - 1, d = n ? 1 : -1, p = e2 < 0 || 0 === e2 && 1 / e2 < 0 ? 1 : 0;
|
|
12311
|
+
for (e2 = Math.abs(e2), isNaN(e2) || e2 === 1 / 0 ? (a = isNaN(e2) ? 1 : 0, s = h) : (s = Math.floor(Math.log(e2) / Math.LN2), e2 * (u = Math.pow(2, -s)) < 1 && (s--, u *= 2), (e2 += s + l >= 1 ? f / u : f * Math.pow(2, 1 - l)) * u >= 2 && (s++, u /= 2), s + l >= h ? (a = 0, s = h) : s + l >= 1 ? (a = (e2 * u - 1) * Math.pow(2, i), s += l) : (a = e2 * Math.pow(2, l - 1) * Math.pow(2, i), s = 0)); i >= 8; t2[r + g] = 255 & a, g += d, a /= 256, i -= 8)
|
|
12461
12312
|
;
|
|
12462
12313
|
for (s = s << i | a, c += i; c > 0; t2[r + g] = 255 & s, g += d, s /= 256, c -= 8)
|
|
12463
12314
|
;
|
|
@@ -12487,7 +12338,7 @@ ${newlined}
|
|
|
12487
12338
|
} catch (t5) {
|
|
12488
12339
|
i.Log.error(t5);
|
|
12489
12340
|
}
|
|
12490
|
-
}, t3.validateJwt = function e3(o2, s2, u2, c, h, l,
|
|
12341
|
+
}, t3.validateJwt = function e3(o2, s2, u2, c, h, l, f) {
|
|
12491
12342
|
i.Log.debug("JoseUtil.validateJwt");
|
|
12492
12343
|
try {
|
|
12493
12344
|
if ("RSA" === s2.kty)
|
|
@@ -12506,7 +12357,7 @@ ${newlined}
|
|
|
12506
12357
|
return i.Log.error("JoseUtil.validateJwt: EC key missing key material", s2), Promise.reject(new Error("EC key missing key material"));
|
|
12507
12358
|
s2 = r2.getKey(s2);
|
|
12508
12359
|
}
|
|
12509
|
-
return t3._validateJwt(o2, s2, u2, c, h, l,
|
|
12360
|
+
return t3._validateJwt(o2, s2, u2, c, h, l, f);
|
|
12510
12361
|
} catch (t4) {
|
|
12511
12362
|
return i.Log.error(t4 && t4.message || t4), Promise.reject("JWT validation failed");
|
|
12512
12363
|
}
|
|
@@ -12619,8 +12470,8 @@ ${newlined}
|
|
|
12619
12470
|
throw new TypeError("Cannot call a class as a function");
|
|
12620
12471
|
}(this, t2), !r2)
|
|
12621
12472
|
throw n.Log.error("SignoutRequest.ctor: No url passed"), new Error("url");
|
|
12622
|
-
for (var
|
|
12623
|
-
r2 = i.UrlUtility.addQueryParam(r2,
|
|
12473
|
+
for (var f in s && (r2 = i.UrlUtility.addQueryParam(r2, "id_token_hint", s)), a && (r2 = i.UrlUtility.addQueryParam(r2, "post_logout_redirect_uri", a), u && (this.state = new o.State({ data: u, request_type: h }), r2 = i.UrlUtility.addQueryParam(r2, "state", this.state.id))), c)
|
|
12474
|
+
r2 = i.UrlUtility.addQueryParam(r2, f, c[f]);
|
|
12624
12475
|
this.url = r2;
|
|
12625
12476
|
};
|
|
12626
12477
|
}, function(t, e, r) {
|
|
@@ -12681,7 +12532,7 @@ ${newlined}
|
|
|
12681
12532
|
return function(e2, r2, n2) {
|
|
12682
12533
|
return r2 && t2(e2.prototype, r2), n2 && t2(e2, n2), e2;
|
|
12683
12534
|
};
|
|
12684
|
-
}(), i = r(0), o = r(10), s = r(39), a = r(15), u = r(45), c = r(47), h = r(18), l = r(8),
|
|
12535
|
+
}(), i = r(0), o = r(10), s = r(39), a = r(15), u = r(45), c = r(47), h = r(18), l = r(8), f = r(20), g = r(11), d = r(4);
|
|
12685
12536
|
function p(t2, e2) {
|
|
12686
12537
|
if (!(t2 instanceof e2))
|
|
12687
12538
|
throw new TypeError("Cannot call a class as a function");
|
|
@@ -12693,7 +12544,7 @@ ${newlined}
|
|
|
12693
12544
|
}
|
|
12694
12545
|
e.UserManager = function(t2) {
|
|
12695
12546
|
function e2() {
|
|
12696
|
-
var r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : c.SilentRenewService, o2 = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : h.SessionMonitor, a2 = arguments.length > 3 && void 0 !== arguments[3] ? arguments[3] :
|
|
12547
|
+
var r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : c.SilentRenewService, o2 = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : h.SessionMonitor, a2 = arguments.length > 3 && void 0 !== arguments[3] ? arguments[3] : f.TokenRevocationClient, l2 = arguments.length > 4 && void 0 !== arguments[4] ? arguments[4] : g.TokenClient, y = arguments.length > 5 && void 0 !== arguments[5] ? arguments[5] : d.JoseUtil;
|
|
12697
12548
|
p(this, e2), r2 instanceof s.UserManagerSettings || (r2 = new s.UserManagerSettings(r2));
|
|
12698
12549
|
var m = v(this, t2.call(this, r2));
|
|
12699
12550
|
return m._events = new u.UserManagerEvents(r2), m._silentRenewService = new n2(m), m.settings.automaticSilentRenew && (i.Log.debug("UserManager.ctor: automaticSilentRenew is configured, setting up silent renew"), m.startSilentRenew()), m.settings.monitorSession && (i.Log.debug("UserManager.ctor: monitorSession is configured, setting up session monitor"), m._sessionMonitor = new o2(m)), m._tokenRevocationClient = new a2(m._settings), m._tokenClient = new l2(m._settings), m._joseUtil = y, m;
|
|
@@ -12962,7 +12813,7 @@ ${newlined}
|
|
|
12962
12813
|
if (!(t2 instanceof e2))
|
|
12963
12814
|
throw new TypeError("Cannot call a class as a function");
|
|
12964
12815
|
}
|
|
12965
|
-
function
|
|
12816
|
+
function f(t2, e2) {
|
|
12966
12817
|
if (!t2)
|
|
12967
12818
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
12968
12819
|
return !e2 || "object" != typeof e2 && "function" != typeof e2 ? t2 : e2;
|
|
@@ -12971,7 +12822,7 @@ ${newlined}
|
|
|
12971
12822
|
function e2() {
|
|
12972
12823
|
var r2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, n2 = r2.popup_redirect_uri, i2 = r2.popup_post_logout_redirect_uri, g = r2.popupWindowFeatures, d = r2.popupWindowTarget, p = r2.silent_redirect_uri, v = r2.silentRequestTimeout, y = r2.automaticSilentRenew, m = void 0 !== y && y, _ = r2.validateSubOnSilentRenew, S = void 0 !== _ && _, b = r2.includeIdTokenInSilentRenew, w = void 0 === b || b, F = r2.monitorSession, E = void 0 === F || F, x = r2.monitorAnonymousSession, A = void 0 !== x && x, k = r2.checkSessionInterval, P = void 0 === k ? 2e3 : k, C = r2.stopCheckSessionOnError, T = void 0 === C || C, R = r2.query_status_response_type, I = r2.revokeAccessTokenOnSignout, D = void 0 !== I && I, L = r2.accessTokenExpiringNotificationTime, N = void 0 === L ? 60 : L, U = r2.redirectNavigator, B = void 0 === U ? new o.RedirectNavigator() : U, O = r2.popupNavigator, j = void 0 === O ? new s.PopupNavigator() : O, M = r2.iframeNavigator, H = void 0 === M ? new a.IFrameNavigator() : M, V = r2.userStore, K = void 0 === V ? new u.WebStorageStateStore({ store: c.Global.sessionStorage }) : V;
|
|
12973
12824
|
l(this, e2);
|
|
12974
|
-
var q =
|
|
12825
|
+
var q = f(this, t2.call(this, arguments[0]));
|
|
12975
12826
|
return q._popup_redirect_uri = n2, q._popup_post_logout_redirect_uri = i2, q._popupWindowFeatures = g, q._popupWindowTarget = d, q._silent_redirect_uri = p, q._silentRequestTimeout = v, q._automaticSilentRenew = m, q._validateSubOnSilentRenew = S, q._includeIdTokenInSilentRenew = w, q._accessTokenExpiringNotificationTime = N, q._monitorSession = E, q._monitorAnonymousSession = A, q._checkSessionInterval = P, q._stopCheckSessionOnError = T, R ? q._query_status_response_type = R : arguments[0] && arguments[0].response_type ? q._query_status_response_type = h.SigninRequest.isOidc(arguments[0].response_type) ? "id_token" : "code" : q._query_status_response_type = "id_token", q._revokeAccessTokenOnSignout = D, q._redirectNavigator = B, q._popupNavigator = j, q._iframeNavigator = H, q._userStore = K, q;
|
|
12976
12827
|
}
|
|
12977
12828
|
return function r2(t3, e3) {
|
|
@@ -13395,7 +13246,6 @@ ${newlined}
|
|
|
13395
13246
|
var require_dist2 = __commonJS({
|
|
13396
13247
|
"../node_modules/@inrupt/oidc-client-ext/dist/index.js"(exports) {
|
|
13397
13248
|
"use strict";
|
|
13398
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13399
13249
|
var oidcClient = require_oidc_client_min();
|
|
13400
13250
|
var solidClientAuthnCore = require_dist();
|
|
13401
13251
|
function processErrorResponse(responseBody, options) {
|
|
@@ -14064,7 +13914,7 @@ ${newlined}
|
|
|
14064
13914
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14065
13915
|
exports.SessionInfoManager = exports.clear = exports.getUnauthenticatedSession = void 0;
|
|
14066
13916
|
var solid_client_authn_core_1 = require_dist();
|
|
14067
|
-
var uuid_1 = (
|
|
13917
|
+
var uuid_1 = require_commonjs_browser();
|
|
14068
13918
|
var oidc_client_ext_1 = require_dist2();
|
|
14069
13919
|
function getUnauthenticatedSession() {
|
|
14070
13920
|
return {
|
|
@@ -14474,7 +14324,7 @@ ${newlined}
|
|
|
14474
14324
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14475
14325
|
exports.getClientAuthenticationWithDependencies = void 0;
|
|
14476
14326
|
var solid_client_authn_core_1 = require_dist();
|
|
14477
|
-
var StorageUtility_1 = __importDefault(
|
|
14327
|
+
var StorageUtility_1 = __importDefault(require_StorageUtility());
|
|
14478
14328
|
var ClientAuthentication_1 = __importDefault(require_ClientAuthentication());
|
|
14479
14329
|
var OidcLoginHandler_1 = __importDefault(require_OidcLoginHandler());
|
|
14480
14330
|
var AuthorizationCodeWithPkceOidcHandler_1 = __importDefault(require_AuthorizationCodeWithPkceOidcHandler());
|
|
@@ -14511,7 +14361,7 @@ ${newlined}
|
|
|
14511
14361
|
});
|
|
14512
14362
|
|
|
14513
14363
|
// ../node_modules/@inrupt/solid-client-authn-browser/dist/constant.js
|
|
14514
|
-
var
|
|
14364
|
+
var require_constant = __commonJS({
|
|
14515
14365
|
"../node_modules/@inrupt/solid-client-authn-browser/dist/constant.js"(exports) {
|
|
14516
14366
|
"use strict";
|
|
14517
14367
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -14530,9 +14380,9 @@ ${newlined}
|
|
|
14530
14380
|
exports.Session = exports.silentlyAuthenticate = void 0;
|
|
14531
14381
|
var events_1 = require_events();
|
|
14532
14382
|
var solid_client_authn_core_1 = require_dist();
|
|
14533
|
-
var uuid_1 = (
|
|
14383
|
+
var uuid_1 = require_commonjs_browser();
|
|
14534
14384
|
var dependencies_1 = require_dependencies();
|
|
14535
|
-
var constant_1 =
|
|
14385
|
+
var constant_1 = require_constant();
|
|
14536
14386
|
async function silentlyAuthenticate(sessionId, clientAuthn, session) {
|
|
14537
14387
|
var _a;
|
|
14538
14388
|
const storedSessionInfo = await clientAuthn.validateCurrentSession(sessionId);
|
|
@@ -14556,7 +14406,7 @@ ${newlined}
|
|
|
14556
14406
|
return !!(sessionInfo === null || sessionInfo === void 0 ? void 0 : sessionInfo.isLoggedIn);
|
|
14557
14407
|
}
|
|
14558
14408
|
var Session2 = class extends events_1.EventEmitter {
|
|
14559
|
-
constructor(sessionOptions = {}, sessionId) {
|
|
14409
|
+
constructor(sessionOptions = {}, sessionId = void 0) {
|
|
14560
14410
|
super();
|
|
14561
14411
|
this.tokenRequestInProgress = false;
|
|
14562
14412
|
this.login = async (options) => {
|
|
@@ -14566,7 +14416,8 @@ ${newlined}
|
|
|
14566
14416
|
...options,
|
|
14567
14417
|
tokenType: (_a = options.tokenType) !== null && _a !== void 0 ? _a : "DPoP"
|
|
14568
14418
|
}, this);
|
|
14569
|
-
return new Promise(() =>
|
|
14419
|
+
return new Promise(() => {
|
|
14420
|
+
});
|
|
14570
14421
|
};
|
|
14571
14422
|
this.fetch = async (url, init) => {
|
|
14572
14423
|
return this.clientAuthentication.fetch(url, init);
|
|
@@ -16410,15 +16261,15 @@ ${newlined}
|
|
|
16410
16261
|
const issuer = options.issuer || new IdentifierIssuer("_:b");
|
|
16411
16262
|
return _labelBlankNodes(issuer, input);
|
|
16412
16263
|
};
|
|
16413
|
-
api.compareValues = (
|
|
16414
|
-
if (
|
|
16264
|
+
api.compareValues = (v1, v2) => {
|
|
16265
|
+
if (v1 === v2) {
|
|
16415
16266
|
return true;
|
|
16416
16267
|
}
|
|
16417
|
-
if (graphTypes.isValue(
|
|
16268
|
+
if (graphTypes.isValue(v1) && graphTypes.isValue(v2) && v1["@value"] === v2["@value"] && v1["@type"] === v2["@type"] && v1["@language"] === v2["@language"] && v1["@index"] === v2["@index"]) {
|
|
16418
16269
|
return true;
|
|
16419
16270
|
}
|
|
16420
|
-
if (types2.isObject(
|
|
16421
|
-
return
|
|
16271
|
+
if (types2.isObject(v1) && "@id" in v1 && types2.isObject(v2) && "@id" in v2) {
|
|
16272
|
+
return v1["@id"] === v2["@id"];
|
|
16422
16273
|
}
|
|
16423
16274
|
return false;
|
|
16424
16275
|
};
|
|
@@ -18785,9 +18636,9 @@ ${newlined}
|
|
|
18785
18636
|
}
|
|
18786
18637
|
return null;
|
|
18787
18638
|
};
|
|
18788
|
-
api.processingMode = (activeCtx,
|
|
18789
|
-
if (
|
|
18790
|
-
return !activeCtx.processingMode || activeCtx.processingMode >= "json-ld-" +
|
|
18639
|
+
api.processingMode = (activeCtx, version) => {
|
|
18640
|
+
if (version.toString() >= "1.1") {
|
|
18641
|
+
return !activeCtx.processingMode || activeCtx.processingMode >= "json-ld-" + version.toString();
|
|
18791
18642
|
} else {
|
|
18792
18643
|
return activeCtx.processingMode === "json-ld-1.0";
|
|
18793
18644
|
}
|
|
@@ -18853,15 +18704,15 @@ ${newlined}
|
|
|
18853
18704
|
return false;
|
|
18854
18705
|
}
|
|
18855
18706
|
for (const k1 in x1) {
|
|
18856
|
-
let
|
|
18707
|
+
let v1 = x1[k1];
|
|
18857
18708
|
let v2 = x2[k1];
|
|
18858
18709
|
if (k1 === "@container") {
|
|
18859
|
-
if (Array.isArray(
|
|
18860
|
-
|
|
18710
|
+
if (Array.isArray(v1) && Array.isArray(v2)) {
|
|
18711
|
+
v1 = v1.slice().sort();
|
|
18861
18712
|
v2 = v2.slice().sort();
|
|
18862
18713
|
}
|
|
18863
18714
|
}
|
|
18864
|
-
if (!_deepCompare(
|
|
18715
|
+
if (!_deepCompare(v1, v2)) {
|
|
18865
18716
|
return false;
|
|
18866
18717
|
}
|
|
18867
18718
|
}
|
|
@@ -20954,7 +20805,7 @@ ${newlined}
|
|
|
20954
20805
|
return nodeObject && _filterSubject(state, nodeObject, pattern, flags);
|
|
20955
20806
|
}
|
|
20956
20807
|
function _valueMatch(pattern, value) {
|
|
20957
|
-
const
|
|
20808
|
+
const v1 = value["@value"];
|
|
20958
20809
|
const t1 = value["@type"];
|
|
20959
20810
|
const l1 = value["@language"];
|
|
20960
20811
|
const v2 = pattern["@value"] ? types2.isArray(pattern["@value"]) ? pattern["@value"] : [pattern["@value"]] : [];
|
|
@@ -20963,7 +20814,7 @@ ${newlined}
|
|
|
20963
20814
|
if (v2.length === 0 && t2.length === 0 && l2.length === 0) {
|
|
20964
20815
|
return true;
|
|
20965
20816
|
}
|
|
20966
|
-
if (!(v2.includes(
|
|
20817
|
+
if (!(v2.includes(v1) || types2.isEmptyObject(v2[0]))) {
|
|
20967
20818
|
return false;
|
|
20968
20819
|
}
|
|
20969
20820
|
if (!(!t1 && t2.length === 0 || t2.includes(t1) || t1 && types2.isEmptyObject(t2[0]))) {
|
|
@@ -22538,7 +22389,9 @@ ${newlined}
|
|
|
22538
22389
|
module2.exports = _regeneratorRuntime2 = function _regeneratorRuntime3() {
|
|
22539
22390
|
return exports2;
|
|
22540
22391
|
}, module2.exports.__esModule = true, module2.exports["default"] = module2.exports;
|
|
22541
|
-
var exports2 = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty,
|
|
22392
|
+
var exports2 = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function(obj, key, desc) {
|
|
22393
|
+
obj[key] = desc.value;
|
|
22394
|
+
}, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
|
|
22542
22395
|
function define2(obj, key, value) {
|
|
22543
22396
|
return Object.defineProperty(obj, key, {
|
|
22544
22397
|
value,
|
|
@@ -22556,48 +22409,9 @@ ${newlined}
|
|
|
22556
22409
|
}
|
|
22557
22410
|
function wrap4(innerFn, outerFn, self2, tryLocsList) {
|
|
22558
22411
|
var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []);
|
|
22559
|
-
return generator
|
|
22560
|
-
|
|
22561
|
-
|
|
22562
|
-
if ("executing" === state)
|
|
22563
|
-
throw new Error("Generator is already running");
|
|
22564
|
-
if ("completed" === state) {
|
|
22565
|
-
if ("throw" === method)
|
|
22566
|
-
throw arg;
|
|
22567
|
-
return doneResult();
|
|
22568
|
-
}
|
|
22569
|
-
for (context2.method = method, context2.arg = arg; ; ) {
|
|
22570
|
-
var delegate = context2.delegate;
|
|
22571
|
-
if (delegate) {
|
|
22572
|
-
var delegateResult = maybeInvokeDelegate(delegate, context2);
|
|
22573
|
-
if (delegateResult) {
|
|
22574
|
-
if (delegateResult === ContinueSentinel)
|
|
22575
|
-
continue;
|
|
22576
|
-
return delegateResult;
|
|
22577
|
-
}
|
|
22578
|
-
}
|
|
22579
|
-
if ("next" === context2.method)
|
|
22580
|
-
context2.sent = context2._sent = context2.arg;
|
|
22581
|
-
else if ("throw" === context2.method) {
|
|
22582
|
-
if ("suspendedStart" === state)
|
|
22583
|
-
throw state = "completed", context2.arg;
|
|
22584
|
-
context2.dispatchException(context2.arg);
|
|
22585
|
-
} else
|
|
22586
|
-
"return" === context2.method && context2.abrupt("return", context2.arg);
|
|
22587
|
-
state = "executing";
|
|
22588
|
-
var record = tryCatch(innerFn2, self3, context2);
|
|
22589
|
-
if ("normal" === record.type) {
|
|
22590
|
-
if (state = context2.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel)
|
|
22591
|
-
continue;
|
|
22592
|
-
return {
|
|
22593
|
-
value: record.arg,
|
|
22594
|
-
done: context2.done
|
|
22595
|
-
};
|
|
22596
|
-
}
|
|
22597
|
-
"throw" === record.type && (state = "completed", context2.method = "throw", context2.arg = record.arg);
|
|
22598
|
-
}
|
|
22599
|
-
};
|
|
22600
|
-
}(innerFn, self2, context), generator;
|
|
22412
|
+
return defineProperty(generator, "_invoke", {
|
|
22413
|
+
value: makeInvokeMethod(innerFn, self2, context)
|
|
22414
|
+
}), generator;
|
|
22601
22415
|
}
|
|
22602
22416
|
function tryCatch(fn, obj, arg) {
|
|
22603
22417
|
try {
|
|
@@ -22652,25 +22466,63 @@ ${newlined}
|
|
|
22652
22466
|
reject3(record.arg);
|
|
22653
22467
|
}
|
|
22654
22468
|
var previousPromise;
|
|
22655
|
-
this
|
|
22656
|
-
function
|
|
22657
|
-
|
|
22658
|
-
|
|
22659
|
-
|
|
22469
|
+
defineProperty(this, "_invoke", {
|
|
22470
|
+
value: function value(method, arg) {
|
|
22471
|
+
function callInvokeWithMethodAndArg() {
|
|
22472
|
+
return new PromiseImpl(function(resolve, reject3) {
|
|
22473
|
+
invoke(method, arg, resolve, reject3);
|
|
22474
|
+
});
|
|
22475
|
+
}
|
|
22476
|
+
return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
|
|
22477
|
+
}
|
|
22478
|
+
});
|
|
22479
|
+
}
|
|
22480
|
+
function makeInvokeMethod(innerFn, self2, context) {
|
|
22481
|
+
var state = "suspendedStart";
|
|
22482
|
+
return function(method, arg) {
|
|
22483
|
+
if ("executing" === state)
|
|
22484
|
+
throw new Error("Generator is already running");
|
|
22485
|
+
if ("completed" === state) {
|
|
22486
|
+
if ("throw" === method)
|
|
22487
|
+
throw arg;
|
|
22488
|
+
return doneResult();
|
|
22489
|
+
}
|
|
22490
|
+
for (context.method = method, context.arg = arg; ; ) {
|
|
22491
|
+
var delegate = context.delegate;
|
|
22492
|
+
if (delegate) {
|
|
22493
|
+
var delegateResult = maybeInvokeDelegate(delegate, context);
|
|
22494
|
+
if (delegateResult) {
|
|
22495
|
+
if (delegateResult === ContinueSentinel)
|
|
22496
|
+
continue;
|
|
22497
|
+
return delegateResult;
|
|
22498
|
+
}
|
|
22499
|
+
}
|
|
22500
|
+
if ("next" === context.method)
|
|
22501
|
+
context.sent = context._sent = context.arg;
|
|
22502
|
+
else if ("throw" === context.method) {
|
|
22503
|
+
if ("suspendedStart" === state)
|
|
22504
|
+
throw state = "completed", context.arg;
|
|
22505
|
+
context.dispatchException(context.arg);
|
|
22506
|
+
} else
|
|
22507
|
+
"return" === context.method && context.abrupt("return", context.arg);
|
|
22508
|
+
state = "executing";
|
|
22509
|
+
var record = tryCatch(innerFn, self2, context);
|
|
22510
|
+
if ("normal" === record.type) {
|
|
22511
|
+
if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel)
|
|
22512
|
+
continue;
|
|
22513
|
+
return {
|
|
22514
|
+
value: record.arg,
|
|
22515
|
+
done: context.done
|
|
22516
|
+
};
|
|
22517
|
+
}
|
|
22518
|
+
"throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
|
|
22660
22519
|
}
|
|
22661
|
-
return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
|
|
22662
22520
|
};
|
|
22663
22521
|
}
|
|
22664
22522
|
function maybeInvokeDelegate(delegate, context) {
|
|
22665
|
-
var method = delegate.iterator[
|
|
22666
|
-
if (void 0 === method)
|
|
22667
|
-
|
|
22668
|
-
if (delegate.iterator["return"] && (context.method = "return", context.arg = void 0, maybeInvokeDelegate(delegate, context), "throw" === context.method))
|
|
22669
|
-
return ContinueSentinel;
|
|
22670
|
-
context.method = "throw", context.arg = new TypeError("The iterator does not provide a 'throw' method");
|
|
22671
|
-
}
|
|
22672
|
-
return ContinueSentinel;
|
|
22673
|
-
}
|
|
22523
|
+
var methodName = context.method, method = delegate.iterator[methodName];
|
|
22524
|
+
if (void 0 === method)
|
|
22525
|
+
return context.delegate = null, "throw" === methodName && delegate.iterator["return"] && (context.method = "return", context.arg = void 0, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel;
|
|
22674
22526
|
var record = tryCatch(method, delegate.iterator, context.arg);
|
|
22675
22527
|
if ("throw" === record.type)
|
|
22676
22528
|
return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
|
|
@@ -22720,7 +22572,13 @@ ${newlined}
|
|
|
22720
22572
|
done: true
|
|
22721
22573
|
};
|
|
22722
22574
|
}
|
|
22723
|
-
return GeneratorFunction.prototype = GeneratorFunctionPrototype,
|
|
22575
|
+
return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", {
|
|
22576
|
+
value: GeneratorFunctionPrototype,
|
|
22577
|
+
configurable: true
|
|
22578
|
+
}), defineProperty(GeneratorFunctionPrototype, "constructor", {
|
|
22579
|
+
value: GeneratorFunction,
|
|
22580
|
+
configurable: true
|
|
22581
|
+
}), GeneratorFunction.displayName = define2(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports2.isGeneratorFunction = function(genFun) {
|
|
22724
22582
|
var ctor = "function" == typeof genFun && genFun.constructor;
|
|
22725
22583
|
return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
|
|
22726
22584
|
}, exports2.mark = function(genFun) {
|
|
@@ -22741,8 +22599,8 @@ ${newlined}
|
|
|
22741
22599
|
return this;
|
|
22742
22600
|
}), define2(Gp, "toString", function() {
|
|
22743
22601
|
return "[object Generator]";
|
|
22744
|
-
}), exports2.keys = function(
|
|
22745
|
-
var keys = [];
|
|
22602
|
+
}), exports2.keys = function(val) {
|
|
22603
|
+
var object = Object(val), keys = [];
|
|
22746
22604
|
for (var key in object) {
|
|
22747
22605
|
keys.push(key);
|
|
22748
22606
|
}
|
|
@@ -23170,7 +23028,7 @@ ${newlined}
|
|
|
23170
23028
|
function DOMImplementation() {
|
|
23171
23029
|
}
|
|
23172
23030
|
DOMImplementation.prototype = {
|
|
23173
|
-
hasFeature: function(feature,
|
|
23031
|
+
hasFeature: function(feature, version) {
|
|
23174
23032
|
return true;
|
|
23175
23033
|
},
|
|
23176
23034
|
createDocument: function(namespaceURI, qualifiedName, doctype) {
|
|
@@ -23245,8 +23103,8 @@ ${newlined}
|
|
|
23245
23103
|
}
|
|
23246
23104
|
}
|
|
23247
23105
|
},
|
|
23248
|
-
isSupported: function(feature,
|
|
23249
|
-
return this.ownerDocument.implementation.hasFeature(feature,
|
|
23106
|
+
isSupported: function(feature, version) {
|
|
23107
|
+
return this.ownerDocument.implementation.hasFeature(feature, version);
|
|
23250
23108
|
},
|
|
23251
23109
|
hasAttributes: function() {
|
|
23252
23110
|
return this.attributes.length > 0;
|
|
@@ -24471,7 +24329,7 @@ ${newlined}
|
|
|
24471
24329
|
var domBuilder = this.domBuilder;
|
|
24472
24330
|
domBuilder.startDocument();
|
|
24473
24331
|
_copy(defaultNSMap, defaultNSMap = {});
|
|
24474
|
-
|
|
24332
|
+
parse3(
|
|
24475
24333
|
source,
|
|
24476
24334
|
defaultNSMap,
|
|
24477
24335
|
entityMap,
|
|
@@ -24481,7 +24339,7 @@ ${newlined}
|
|
|
24481
24339
|
domBuilder.endDocument();
|
|
24482
24340
|
}
|
|
24483
24341
|
};
|
|
24484
|
-
function
|
|
24342
|
+
function parse3(source, defaultNSMapCopy, entityMap, domBuilder, errorHandler) {
|
|
24485
24343
|
function fixedFromCharCode(code) {
|
|
24486
24344
|
if (code > 65535) {
|
|
24487
24345
|
code -= 65536;
|
|
@@ -24631,9 +24489,9 @@ ${newlined}
|
|
|
24631
24489
|
}
|
|
24632
24490
|
}
|
|
24633
24491
|
}
|
|
24634
|
-
function copyLocator(
|
|
24635
|
-
t.lineNumber =
|
|
24636
|
-
t.columnNumber =
|
|
24492
|
+
function copyLocator(f, t) {
|
|
24493
|
+
t.lineNumber = f.lineNumber;
|
|
24494
|
+
t.columnNumber = f.columnNumber;
|
|
24637
24495
|
return t;
|
|
24638
24496
|
}
|
|
24639
24497
|
function parseElementStartPart(source, start, el, currentNSMap, entityReplacer, errorHandler) {
|
|
@@ -25394,6 +25252,36 @@ ${newlined}
|
|
|
25394
25252
|
}
|
|
25395
25253
|
};
|
|
25396
25254
|
|
|
25255
|
+
// ../node_modules/@babel/runtime/helpers/esm/typeof.js
|
|
25256
|
+
function _typeof(obj) {
|
|
25257
|
+
"@babel/helpers - typeof";
|
|
25258
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(obj2) {
|
|
25259
|
+
return typeof obj2;
|
|
25260
|
+
} : function(obj2) {
|
|
25261
|
+
return obj2 && "function" == typeof Symbol && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? "symbol" : typeof obj2;
|
|
25262
|
+
}, _typeof(obj);
|
|
25263
|
+
}
|
|
25264
|
+
|
|
25265
|
+
// ../node_modules/@babel/runtime/helpers/esm/toPrimitive.js
|
|
25266
|
+
function _toPrimitive(input, hint) {
|
|
25267
|
+
if (_typeof(input) !== "object" || input === null)
|
|
25268
|
+
return input;
|
|
25269
|
+
var prim = input[Symbol.toPrimitive];
|
|
25270
|
+
if (prim !== void 0) {
|
|
25271
|
+
var res = prim.call(input, hint || "default");
|
|
25272
|
+
if (_typeof(res) !== "object")
|
|
25273
|
+
return res;
|
|
25274
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
25275
|
+
}
|
|
25276
|
+
return (hint === "string" ? String : Number)(input);
|
|
25277
|
+
}
|
|
25278
|
+
|
|
25279
|
+
// ../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js
|
|
25280
|
+
function _toPropertyKey(arg) {
|
|
25281
|
+
var key = _toPrimitive(arg, "string");
|
|
25282
|
+
return _typeof(key) === "symbol" ? key : String(key);
|
|
25283
|
+
}
|
|
25284
|
+
|
|
25397
25285
|
// ../node_modules/@babel/runtime/helpers/esm/createClass.js
|
|
25398
25286
|
function _defineProperties(target, props) {
|
|
25399
25287
|
for (var i = 0; i < props.length; i++) {
|
|
@@ -25402,7 +25290,7 @@ ${newlined}
|
|
|
25402
25290
|
descriptor.configurable = true;
|
|
25403
25291
|
if ("value" in descriptor)
|
|
25404
25292
|
descriptor.writable = true;
|
|
25405
|
-
Object.defineProperty(target, descriptor.key, descriptor);
|
|
25293
|
+
Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);
|
|
25406
25294
|
}
|
|
25407
25295
|
}
|
|
25408
25296
|
function _createClass(Constructor, protoProps, staticProps) {
|
|
@@ -25459,16 +25347,6 @@ ${newlined}
|
|
|
25459
25347
|
_setPrototypeOf(subClass, superClass);
|
|
25460
25348
|
}
|
|
25461
25349
|
|
|
25462
|
-
// ../node_modules/@babel/runtime/helpers/esm/typeof.js
|
|
25463
|
-
function _typeof(obj) {
|
|
25464
|
-
"@babel/helpers - typeof";
|
|
25465
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(obj2) {
|
|
25466
|
-
return typeof obj2;
|
|
25467
|
-
} : function(obj2) {
|
|
25468
|
-
return obj2 && "function" == typeof Symbol && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? "symbol" : typeof obj2;
|
|
25469
|
-
}, _typeof(obj);
|
|
25470
|
-
}
|
|
25471
|
-
|
|
25472
25350
|
// ../node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js
|
|
25473
25351
|
function _possibleConstructorReturn(self2, call) {
|
|
25474
25352
|
if (call && (_typeof(call) === "object" || typeof call === "function")) {
|
|
@@ -25489,6 +25367,7 @@ ${newlined}
|
|
|
25489
25367
|
|
|
25490
25368
|
// ../node_modules/@babel/runtime/helpers/esm/defineProperty.js
|
|
25491
25369
|
function _defineProperty(obj, key, value) {
|
|
25370
|
+
key = _toPropertyKey(key);
|
|
25492
25371
|
if (key in obj) {
|
|
25493
25372
|
Object.defineProperty(obj, key, {
|
|
25494
25373
|
value,
|
|
@@ -25739,6 +25618,12 @@ ${newlined}
|
|
|
25739
25618
|
function isRDFlibObject(obj) {
|
|
25740
25619
|
return obj && Object.prototype.hasOwnProperty.call(obj, "termType") && (obj.termType === NamedNodeTermType || obj.termType === VariableTermType || obj.termType === BlankNodeTermType || obj.termType === CollectionTermType || obj.termType === LiteralTermType || obj.termType === GraphTermType);
|
|
25741
25620
|
}
|
|
25621
|
+
function isRDFlibSubject(obj) {
|
|
25622
|
+
return obj && Object.prototype.hasOwnProperty.call(obj, "termType") && (obj.termType === NamedNodeTermType || obj.termType === VariableTermType || obj.termType === BlankNodeTermType || obj.termType === CollectionTermType || obj.termType === LiteralTermType || obj.termType === GraphTermType);
|
|
25623
|
+
}
|
|
25624
|
+
function isRDFlibPredicate(obj) {
|
|
25625
|
+
return isTerm(obj) && (obj.termType === NamedNodeTermType || obj.termType === BlankNodeTermType || obj.termType === VariableTermType);
|
|
25626
|
+
}
|
|
25742
25627
|
function isVariable(obj) {
|
|
25743
25628
|
return isTerm(obj) && obj.termType === VariableTermType;
|
|
25744
25629
|
}
|
|
@@ -25757,12 +25642,6 @@ ${newlined}
|
|
|
25757
25642
|
function isBlankNode(obj) {
|
|
25758
25643
|
return isTerm(obj) && "termType" in obj && obj.termType === "BlankNode";
|
|
25759
25644
|
}
|
|
25760
|
-
function isSubject(obj) {
|
|
25761
|
-
return isTerm(obj) && (obj.termType === NamedNodeTermType || obj.termType === VariableTermType || obj.termType === BlankNodeTermType);
|
|
25762
|
-
}
|
|
25763
|
-
function isPredicate(obj) {
|
|
25764
|
-
return isTerm(obj) && (obj.termType === NamedNodeTermType || obj.termType === VariableTermType);
|
|
25765
|
-
}
|
|
25766
25645
|
function isGraph(obj) {
|
|
25767
25646
|
return isTerm(obj) && (obj.termType === NamedNodeTermType || obj.termType === VariableTermType || obj.termType === BlankNodeTermType || obj.termType === DefaultGraphTermType);
|
|
25768
25647
|
}
|
|
@@ -29631,7 +29510,7 @@ ${newlined}
|
|
|
29631
29510
|
prefixList += (prefixList ? "|" : "") + this._prefixIRIs[prefixIRI];
|
|
29632
29511
|
}
|
|
29633
29512
|
IRIlist = escapeRegex(IRIlist, /[\]\/\(\)\*\+\?\.\\\$]/g, "\\$&");
|
|
29634
|
-
this._prefixRegex = new RegExp(`^(?:${prefixList})[^/]*$|^(${IRIlist})([
|
|
29513
|
+
this._prefixRegex = new RegExp(`^(?:${prefixList})[^/]*$|^(${IRIlist})([_a-zA-Z][\\-_a-zA-Z0-9]*)$`);
|
|
29635
29514
|
}
|
|
29636
29515
|
this._write(hasPrefixes ? "\n" : "", done);
|
|
29637
29516
|
}
|
|
@@ -30732,8 +30611,8 @@ ${newlined}
|
|
|
30732
30611
|
}
|
|
30733
30612
|
}, {
|
|
30734
30613
|
key: "toN3",
|
|
30735
|
-
value: function toN3(
|
|
30736
|
-
return this.statementsToN3(
|
|
30614
|
+
value: function toN3(f) {
|
|
30615
|
+
return this.statementsToN3(f.statements);
|
|
30737
30616
|
}
|
|
30738
30617
|
}, {
|
|
30739
30618
|
key: "explicitURI",
|
|
@@ -31519,7 +31398,7 @@ ${newlined}
|
|
|
31519
31398
|
}, e: function e(_e2) {
|
|
31520
31399
|
didErr = true;
|
|
31521
31400
|
err = _e2;
|
|
31522
|
-
}, f: function
|
|
31401
|
+
}, f: function f() {
|
|
31523
31402
|
try {
|
|
31524
31403
|
if (!normalCompletion && it.return != null)
|
|
31525
31404
|
it.return();
|
|
@@ -32357,12 +32236,12 @@ ${newlined}
|
|
|
32357
32236
|
this.done = true;
|
|
32358
32237
|
this.junction.checkAllDone();
|
|
32359
32238
|
};
|
|
32360
|
-
function prepare(
|
|
32239
|
+
function prepare(f2, item, bindings) {
|
|
32361
32240
|
var terms, termIndex, i, ind;
|
|
32362
32241
|
item.nvars = 0;
|
|
32363
32242
|
item.index = null;
|
|
32364
32243
|
terms = [item.subject, item.predicate, item.object, item.why];
|
|
32365
|
-
ind = [
|
|
32244
|
+
ind = [f2.subjectIndex, f2.predicateIndex, f2.objectIndex, f2.whyIndex];
|
|
32366
32245
|
for (i = 0; i < 4; i++) {
|
|
32367
32246
|
var t = terms[i];
|
|
32368
32247
|
if (t.uri && t.uri === defaultGraphURI) {
|
|
@@ -32370,10 +32249,10 @@ ${newlined}
|
|
|
32370
32249
|
item.nvars++;
|
|
32371
32250
|
} else {
|
|
32372
32251
|
t = bind(terms[i], bindings);
|
|
32373
|
-
if (
|
|
32374
|
-
t =
|
|
32252
|
+
if (f2.redirections[f2.id(t)]) {
|
|
32253
|
+
t = f2.redirections[f2.id(t)];
|
|
32375
32254
|
}
|
|
32376
|
-
termIndex = ind[i][
|
|
32255
|
+
termIndex = ind[i][f2.id(t)];
|
|
32377
32256
|
if (!termIndex) {
|
|
32378
32257
|
item.index = [];
|
|
32379
32258
|
return false;
|
|
@@ -32384,7 +32263,7 @@ ${newlined}
|
|
|
32384
32263
|
}
|
|
32385
32264
|
}
|
|
32386
32265
|
if (item.index === null) {
|
|
32387
|
-
item.index =
|
|
32266
|
+
item.index = f2.statements;
|
|
32388
32267
|
}
|
|
32389
32268
|
return true;
|
|
32390
32269
|
}
|
|
@@ -32395,7 +32274,7 @@ ${newlined}
|
|
|
32395
32274
|
return self2.index.length - other.index.length;
|
|
32396
32275
|
}
|
|
32397
32276
|
var matchIndex = 0;
|
|
32398
|
-
var match = function match3(
|
|
32277
|
+
var match = function match3(f2, g, bindingsSoFar, level, fetcher4, localCallback, branch) {
|
|
32399
32278
|
log_default.debug("Match begins, Branch count now: " + branch.count + " for " + branch.pattern_debug);
|
|
32400
32279
|
var pattern = g.statements;
|
|
32401
32280
|
if (pattern.length === 0) {
|
|
@@ -32413,7 +32292,7 @@ ${newlined}
|
|
|
32413
32292
|
}
|
|
32414
32293
|
for (b = 0; b < g.optional.length; b++) {
|
|
32415
32294
|
br[b].count = br[b].count + 1;
|
|
32416
|
-
match3(
|
|
32295
|
+
match3(f2, g.optional[b], bindingsSoFar, "", fetcher4, callback, br[b]);
|
|
32417
32296
|
}
|
|
32418
32297
|
}
|
|
32419
32298
|
branch.count--;
|
|
@@ -32432,7 +32311,7 @@ ${newlined}
|
|
|
32432
32311
|
console.log("Error following link to <" + requestedTerm.uri + "> in query: " + body);
|
|
32433
32312
|
}
|
|
32434
32313
|
match3(
|
|
32435
|
-
|
|
32314
|
+
f2,
|
|
32436
32315
|
g,
|
|
32437
32316
|
bindingsSoFar,
|
|
32438
32317
|
level,
|
|
@@ -32454,7 +32333,7 @@ ${newlined}
|
|
|
32454
32333
|
}
|
|
32455
32334
|
}
|
|
32456
32335
|
}
|
|
32457
|
-
match2(
|
|
32336
|
+
match2(f2, g, bindingsSoFar, level, fetcher4, localCallback, branch);
|
|
32458
32337
|
};
|
|
32459
32338
|
var constraintsSatisfied = function constraintsSatisfied2(bindings, constraints) {
|
|
32460
32339
|
var res = true;
|
|
@@ -32472,7 +32351,7 @@ ${newlined}
|
|
|
32472
32351
|
}
|
|
32473
32352
|
return res;
|
|
32474
32353
|
};
|
|
32475
|
-
var match2 = function match22(
|
|
32354
|
+
var match2 = function match22(f2, g, bindingsSoFar, level, fetcher4, callback2, branch) {
|
|
32476
32355
|
var pattern = g.statements;
|
|
32477
32356
|
var n = pattern.length;
|
|
32478
32357
|
var i;
|
|
@@ -32484,11 +32363,11 @@ ${newlined}
|
|
|
32484
32363
|
var item;
|
|
32485
32364
|
for (i = 0; i < n; i++) {
|
|
32486
32365
|
item = pattern[i];
|
|
32487
|
-
prepare(
|
|
32366
|
+
prepare(f2, item, bindingsSoFar);
|
|
32488
32367
|
}
|
|
32489
32368
|
pattern.sort(easiestQuery);
|
|
32490
32369
|
item = pattern[0];
|
|
32491
|
-
var rest =
|
|
32370
|
+
var rest = f2.formula();
|
|
32492
32371
|
rest.optional = g.optional;
|
|
32493
32372
|
rest.constraints = g.constraints;
|
|
32494
32373
|
rest.statements = pattern.slice(1);
|
|
@@ -32500,7 +32379,7 @@ ${newlined}
|
|
|
32500
32379
|
var onward = 0;
|
|
32501
32380
|
for (c = 0; c < nc; c++) {
|
|
32502
32381
|
st3 = item.index[c];
|
|
32503
|
-
nbs1 = unifyContents([item.subject, item.predicate, item.object, item.why], [st3.subject, st3.predicate, st3.object, st3.why], bindingsSoFar,
|
|
32382
|
+
nbs1 = unifyContents([item.subject, item.predicate, item.object, item.why], [st3.subject, st3.predicate, st3.object, st3.why], bindingsSoFar, f2);
|
|
32504
32383
|
log_default.info(level + " From first: " + nbs1.length + ": " + bindingsDebug(nbs1));
|
|
32505
32384
|
nk = nbs1.length;
|
|
32506
32385
|
for (k = 0; k < nk; k++) {
|
|
@@ -32521,7 +32400,7 @@ ${newlined}
|
|
|
32521
32400
|
}
|
|
32522
32401
|
branch.count++;
|
|
32523
32402
|
onward++;
|
|
32524
|
-
match(
|
|
32403
|
+
match(f2, rest, bindings2, level + " ", fetcher4, callback2, branch);
|
|
32525
32404
|
}
|
|
32526
32405
|
}
|
|
32527
32406
|
}
|
|
@@ -32535,15 +32414,15 @@ ${newlined}
|
|
|
32535
32414
|
branch.reportDone();
|
|
32536
32415
|
}
|
|
32537
32416
|
};
|
|
32538
|
-
var
|
|
32417
|
+
var f = this;
|
|
32539
32418
|
log_default.debug("Query on " + this.statements.length);
|
|
32540
32419
|
var trunck = new MandatoryBranch(callback, onDone);
|
|
32541
32420
|
trunck.count++;
|
|
32542
32421
|
if (myQuery.sync) {
|
|
32543
|
-
match(
|
|
32422
|
+
match(f, myQuery.pat, myQuery.pat.initBindings, "", fetcher3, callback, trunck);
|
|
32544
32423
|
} else {
|
|
32545
32424
|
setTimeout(function() {
|
|
32546
|
-
match(
|
|
32425
|
+
match(f, myQuery.pat, myQuery.pat.initBindings, "", fetcher3, callback, trunck);
|
|
32547
32426
|
}, 0);
|
|
32548
32427
|
}
|
|
32549
32428
|
}
|
|
@@ -32599,7 +32478,7 @@ ${newlined}
|
|
|
32599
32478
|
}, e: function e(_e2) {
|
|
32600
32479
|
didErr = true;
|
|
32601
32480
|
err = _e2;
|
|
32602
|
-
}, f: function
|
|
32481
|
+
}, f: function f() {
|
|
32603
32482
|
try {
|
|
32604
32483
|
if (!normalCompletion && it.return != null)
|
|
32605
32484
|
it.return();
|
|
@@ -32877,10 +32756,10 @@ ${newlined}
|
|
|
32877
32756
|
pred = node_default.fromValue(pred);
|
|
32878
32757
|
var objNode = node_default.fromValue(obj);
|
|
32879
32758
|
why = node_default.fromValue(why);
|
|
32880
|
-
if (!
|
|
32759
|
+
if (!isRDFlibSubject(subj)) {
|
|
32881
32760
|
throw new Error("Subject is not a subject type");
|
|
32882
32761
|
}
|
|
32883
|
-
if (!
|
|
32762
|
+
if (!isRDFlibPredicate(pred)) {
|
|
32884
32763
|
throw new Error("Predicate ".concat(pred, " is not a predicate type"));
|
|
32885
32764
|
}
|
|
32886
32765
|
if (!isRDFlibObject(objNode)) {
|
|
@@ -33206,7 +33085,7 @@ ${newlined}
|
|
|
33206
33085
|
}, {
|
|
33207
33086
|
key: "removeMatches",
|
|
33208
33087
|
value: function removeMatches(subject, predicate, object, graph3) {
|
|
33209
|
-
this.
|
|
33088
|
+
this.removeMany(subject, predicate, object, graph3);
|
|
33210
33089
|
return this;
|
|
33211
33090
|
}
|
|
33212
33091
|
}, {
|
|
@@ -35995,7 +35874,7 @@ ${newlined}
|
|
|
35995
35874
|
}
|
|
35996
35875
|
}, {
|
|
35997
35876
|
key: "parse",
|
|
35998
|
-
value: function
|
|
35877
|
+
value: function parse3(document3, base, why) {
|
|
35999
35878
|
var children = document3.childNodes;
|
|
36000
35879
|
this.cleanParser();
|
|
36001
35880
|
var root;
|
|
@@ -36012,11 +35891,11 @@ ${newlined}
|
|
|
36012
35891
|
throw new Error("RDFParser: can't find root in " + base + ". Halting. ");
|
|
36013
35892
|
}
|
|
36014
35893
|
this.why = why;
|
|
36015
|
-
var
|
|
35894
|
+
var f = this.frameFactory(this);
|
|
36016
35895
|
this.base = base;
|
|
36017
|
-
|
|
36018
|
-
|
|
36019
|
-
this.parseDOM(this.buildFrame(
|
|
35896
|
+
f.base = base;
|
|
35897
|
+
f.lang = null;
|
|
35898
|
+
this.parseDOM(this.buildFrame(f, root));
|
|
36020
35899
|
return true;
|
|
36021
35900
|
}
|
|
36022
35901
|
}, {
|
|
@@ -36142,12 +36021,12 @@ ${newlined}
|
|
|
36142
36021
|
}
|
|
36143
36022
|
}
|
|
36144
36023
|
for (var x1 = attrs.length - 1; x1 >= 0; x1--) {
|
|
36145
|
-
var
|
|
36146
|
-
|
|
36024
|
+
var f = this.buildFrame(frame);
|
|
36025
|
+
f.addArc(elementURI(attrs[x1]));
|
|
36147
36026
|
if (elementURI(attrs[x1]) === RDFParser2.ns.RDF + "type") {
|
|
36148
|
-
this.buildFrame(
|
|
36027
|
+
this.buildFrame(f).addNode(attrs[x1].nodeValue);
|
|
36149
36028
|
} else {
|
|
36150
|
-
this.buildFrame(
|
|
36029
|
+
this.buildFrame(f).addLiteral(attrs[x1].nodeValue);
|
|
36151
36030
|
}
|
|
36152
36031
|
}
|
|
36153
36032
|
} else if (dom.childNodes.length === 0) {
|
|
@@ -36309,7 +36188,7 @@ ${newlined}
|
|
|
36309
36188
|
}
|
|
36310
36189
|
|
|
36311
36190
|
// ../node_modules/rdflib/esm/parse.js
|
|
36312
|
-
function
|
|
36191
|
+
function parse2(str, kb, base) {
|
|
36313
36192
|
var contentType = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : "text/turtle";
|
|
36314
36193
|
var callback = arguments.length > 4 ? arguments[4] : void 0;
|
|
36315
36194
|
contentType = contentType || TurtleContentType;
|
|
@@ -36351,7 +36230,7 @@ ${newlined}
|
|
|
36351
36230
|
} catch (e) {
|
|
36352
36231
|
executeErrorCallback(e);
|
|
36353
36232
|
}
|
|
36354
|
-
|
|
36233
|
+
parse2.handled = {
|
|
36355
36234
|
"text/n3": true,
|
|
36356
36235
|
"text/turtle": true,
|
|
36357
36236
|
"application/rdf+xml": true,
|
|
@@ -36479,7 +36358,7 @@ ${newlined}
|
|
|
36479
36358
|
}
|
|
36480
36359
|
_createClass(RDFXMLHandler2, [{
|
|
36481
36360
|
key: "parse",
|
|
36482
|
-
value: function
|
|
36361
|
+
value: function parse3(fetcher3, responseText, options) {
|
|
36483
36362
|
var kb = fetcher3.store;
|
|
36484
36363
|
if (!this.dom) {
|
|
36485
36364
|
this.dom = parseXML(responseText);
|
|
@@ -36524,7 +36403,7 @@ ${newlined}
|
|
|
36524
36403
|
}
|
|
36525
36404
|
_createClass(XHTMLHandler2, [{
|
|
36526
36405
|
key: "parse",
|
|
36527
|
-
value: function
|
|
36406
|
+
value: function parse3(fetcher3, responseText, options) {
|
|
36528
36407
|
var relation, reverse;
|
|
36529
36408
|
if (!this.dom) {
|
|
36530
36409
|
this.dom = parseXML(responseText);
|
|
@@ -36550,8 +36429,8 @@ ${newlined}
|
|
|
36550
36429
|
for (var i = 0; i < scripts.length; i++) {
|
|
36551
36430
|
var contentType = scripts[i].getAttribute("type");
|
|
36552
36431
|
if (Parsable[contentType]) {
|
|
36553
|
-
|
|
36554
|
-
|
|
36432
|
+
parse2(scripts[i].textContent, kb, options.original.value, contentType);
|
|
36433
|
+
parse2(scripts[i].textContent, kb, options.original.value, contentType);
|
|
36555
36434
|
}
|
|
36556
36435
|
}
|
|
36557
36436
|
if (!options.noMeta) {
|
|
@@ -36590,7 +36469,7 @@ ${newlined}
|
|
|
36590
36469
|
}
|
|
36591
36470
|
_createClass(XMLHandler2, [{
|
|
36592
36471
|
key: "parse",
|
|
36593
|
-
value: function
|
|
36472
|
+
value: function parse3(fetcher3, responseText, options) {
|
|
36594
36473
|
var dom = parseXML(responseText);
|
|
36595
36474
|
for (var c = 0; c < dom.childNodes.length; c++) {
|
|
36596
36475
|
var node = dom.childNodes[c];
|
|
@@ -36655,7 +36534,7 @@ ${newlined}
|
|
|
36655
36534
|
}
|
|
36656
36535
|
_createClass(HTMLHandler2, [{
|
|
36657
36536
|
key: "parse",
|
|
36658
|
-
value: function
|
|
36537
|
+
value: function parse3(fetcher3, responseText, options) {
|
|
36659
36538
|
var kb = fetcher3.store;
|
|
36660
36539
|
if (isXML(responseText)) {
|
|
36661
36540
|
fetcher3.addStatus(options.req, "Has an XML declaration. We'll assume it's XHTML as the content-type was text/html.\n");
|
|
@@ -36705,7 +36584,7 @@ ${newlined}
|
|
|
36705
36584
|
}
|
|
36706
36585
|
_createClass(JsonLdHandler2, [{
|
|
36707
36586
|
key: "parse",
|
|
36708
|
-
value: function
|
|
36587
|
+
value: function parse3(fetcher3, responseText, options, response) {
|
|
36709
36588
|
var kb = fetcher3.store;
|
|
36710
36589
|
return new Promise(function(resolve, reject3) {
|
|
36711
36590
|
try {
|
|
@@ -36743,7 +36622,7 @@ ${newlined}
|
|
|
36743
36622
|
}
|
|
36744
36623
|
_createClass(TextHandler2, [{
|
|
36745
36624
|
key: "parse",
|
|
36746
|
-
value: function
|
|
36625
|
+
value: function parse3(fetcher3, responseText, options) {
|
|
36747
36626
|
if (isXML(responseText)) {
|
|
36748
36627
|
fetcher3.addStatus(options.req, "Warning: " + options.resource + " has an XML declaration. We'll assume it's XML but its content-type wasn't XML.\n");
|
|
36749
36628
|
var xmlHandler = new XMLHandler(this.response);
|
|
@@ -36782,7 +36661,7 @@ ${newlined}
|
|
|
36782
36661
|
}
|
|
36783
36662
|
_createClass(N3Handler2, [{
|
|
36784
36663
|
key: "parse",
|
|
36785
|
-
value: function
|
|
36664
|
+
value: function parse3(fetcher3, responseText, options, response) {
|
|
36786
36665
|
var kb = fetcher3.store;
|
|
36787
36666
|
var p = n3parser_default(kb, kb, options.original.value, options.original.value, null, null, "", null);
|
|
36788
36667
|
try {
|
|
@@ -38157,68 +38036,3 @@ ${newlined}
|
|
|
38157
38036
|
};
|
|
38158
38037
|
return __toCommonJS(src_exports);
|
|
38159
38038
|
})();
|
|
38160
|
-
/*!
|
|
38161
|
-
* Copyright (c) 2016-2021 Digital Bazaar, Inc. All rights reserved.
|
|
38162
|
-
*/
|
|
38163
|
-
/*!
|
|
38164
|
-
* Copyright (c) 2016-2022 Digital Bazaar, Inc. All rights reserved.
|
|
38165
|
-
*/
|
|
38166
|
-
/*!
|
|
38167
|
-
* The buffer module from node.js, for the browser.
|
|
38168
|
-
*
|
|
38169
|
-
* @author Feross Aboukhadijeh <http://feross.org>
|
|
38170
|
-
* @license MIT
|
|
38171
|
-
*/
|
|
38172
|
-
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
|
38173
|
-
*/
|
|
38174
|
-
/*! Mike Samuel (c) 2009 | code.google.com/p/json-sans-eval
|
|
38175
|
-
*/
|
|
38176
|
-
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
38177
|
-
/*! queue-microtask. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
38178
|
-
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
|
|
38179
|
-
/**
|
|
38180
|
-
* A JavaScript implementation of the JSON-LD API.
|
|
38181
|
-
*
|
|
38182
|
-
* @author Dave Longley
|
|
38183
|
-
*
|
|
38184
|
-
* @license BSD 3-Clause License
|
|
38185
|
-
* Copyright (c) 2011-2019 Digital Bazaar, Inc.
|
|
38186
|
-
* All rights reserved.
|
|
38187
|
-
*
|
|
38188
|
-
* Redistribution and use in source and binary forms, with or without
|
|
38189
|
-
* modification, are permitted provided that the following conditions are met:
|
|
38190
|
-
*
|
|
38191
|
-
* Redistributions of source code must retain the above copyright notice,
|
|
38192
|
-
* this list of conditions and the following disclaimer.
|
|
38193
|
-
*
|
|
38194
|
-
* Redistributions in binary form must reproduce the above copyright
|
|
38195
|
-
* notice, this list of conditions and the following disclaimer in the
|
|
38196
|
-
* documentation and/or other materials provided with the distribution.
|
|
38197
|
-
*
|
|
38198
|
-
* Neither the name of the Digital Bazaar, Inc. nor the names of its
|
|
38199
|
-
* contributors may be used to endorse or promote products derived from
|
|
38200
|
-
* this software without specific prior written permission.
|
|
38201
|
-
*
|
|
38202
|
-
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
|
|
38203
|
-
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
38204
|
-
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
|
38205
|
-
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
|
38206
|
-
* HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
38207
|
-
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
|
|
38208
|
-
* TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
|
38209
|
-
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
|
38210
|
-
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
|
38211
|
-
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
|
38212
|
-
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
38213
|
-
*/
|
|
38214
|
-
/**
|
|
38215
|
-
* Removes the @preserve keywords from expanded result of framing.
|
|
38216
|
-
*
|
|
38217
|
-
* @param input the framed, framed output.
|
|
38218
|
-
* @param options the framing options used.
|
|
38219
|
-
*
|
|
38220
|
-
* @return the resulting output.
|
|
38221
|
-
*/
|
|
38222
|
-
// disallow aliasing @context and @preserve
|
|
38223
|
-
// remove @preserve
|
|
38224
|
-
// remove @preserve from results
|