ses 0.18.2 → 0.18.4
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/NEWS.md +14 -0
- package/dist/lockdown.cjs +648 -275
- package/dist/lockdown.mjs +648 -275
- package/dist/lockdown.umd.js +648 -275
- package/dist/lockdown.umd.min.js +1 -1
- package/dist/ses.cjs +648 -275
- package/dist/ses.mjs +648 -275
- package/dist/ses.umd.js +648 -275
- package/dist/ses.umd.min.js +1 -1
- package/package.json +9 -16
- package/src/commons.js +14 -8
- package/src/compartment-shim.js +1 -5
- package/src/enablements.js +1 -1
- package/src/error/assert.js +4 -19
- package/src/error/note-log-args.js +280 -0
- package/src/error/tame-v8-error-constructor.js +1 -1
- package/src/eval-scope.js +4 -2
- package/src/get-anonymous-intrinsics.js +2 -4
- package/src/intrinsics.js +4 -1
- package/src/lockdown-shim.js +7 -4
- package/src/make-hardener.js +7 -0
- package/src/make-safe-evaluator.js +6 -5
- package/src/module-instance.js +3 -2
- package/src/module-load.js +1 -1
- package/src/scope-constants.js +1 -0
- package/src/strict-scope-terminator.js +2 -3
- package/src/tame-function-tostring.js +1 -1
- package/src/tame-harden.js +29 -0
- package/src/tame-regexp-constructor.js +10 -1
- package/src/whitelist-intrinsics.js +3 -0
- package/src/whitelist.js +9 -1
- package/types.d.ts +1 -0
package/dist/lockdown.cjs
CHANGED
|
@@ -63,6 +63,8 @@ const {
|
|
|
63
63
|
getOwnPropertyNames,
|
|
64
64
|
getPrototypeOf,
|
|
65
65
|
is,
|
|
66
|
+
isFrozen,
|
|
67
|
+
isSealed,
|
|
66
68
|
isExtensible,
|
|
67
69
|
keys,
|
|
68
70
|
prototype: objectPrototype,
|
|
@@ -71,7 +73,7 @@ const {
|
|
|
71
73
|
setPrototypeOf,
|
|
72
74
|
values,
|
|
73
75
|
fromEntries}=
|
|
74
|
-
Object;$h_once.assign(assign);$h_once.create(create);$h_once.defineProperties(defineProperties);$h_once.entries(entries);$h_once.freeze(freeze);$h_once.getOwnPropertyDescriptor(getOwnPropertyDescriptor);$h_once.getOwnPropertyDescriptors(getOwnPropertyDescriptors);$h_once.getOwnPropertyNames(getOwnPropertyNames);$h_once.getPrototypeOf(getPrototypeOf);$h_once.is(is);$h_once.isExtensible(isExtensible);$h_once.keys(keys);$h_once.objectPrototype(objectPrototype);$h_once.seal(seal);$h_once.preventExtensions(preventExtensions);$h_once.setPrototypeOf(setPrototypeOf);$h_once.values(values);$h_once.fromEntries(fromEntries);
|
|
76
|
+
Object;$h_once.assign(assign);$h_once.create(create);$h_once.defineProperties(defineProperties);$h_once.entries(entries);$h_once.freeze(freeze);$h_once.getOwnPropertyDescriptor(getOwnPropertyDescriptor);$h_once.getOwnPropertyDescriptors(getOwnPropertyDescriptors);$h_once.getOwnPropertyNames(getOwnPropertyNames);$h_once.getPrototypeOf(getPrototypeOf);$h_once.is(is);$h_once.isFrozen(isFrozen);$h_once.isSealed(isSealed);$h_once.isExtensible(isExtensible);$h_once.keys(keys);$h_once.objectPrototype(objectPrototype);$h_once.seal(seal);$h_once.preventExtensions(preventExtensions);$h_once.setPrototypeOf(setPrototypeOf);$h_once.values(values);$h_once.fromEntries(fromEntries);
|
|
75
77
|
|
|
76
78
|
const {
|
|
77
79
|
species: speciesSymbol,
|
|
@@ -137,6 +139,7 @@ const { prototype: promisePrototype}= Promise;$h_once.promisePrototy
|
|
|
137
139
|
const typedArrayPrototype= getPrototypeOf(Uint8Array.prototype);$h_once.typedArrayPrototype(typedArrayPrototype);
|
|
138
140
|
|
|
139
141
|
const { bind}= functionPrototype;
|
|
142
|
+
|
|
140
143
|
/**
|
|
141
144
|
* uncurryThis()
|
|
142
145
|
* Equivalent of: fn => (thisArg, ...args) => apply(fn, thisArg, args)
|
|
@@ -156,8 +159,8 @@ $h_once.objectHasOwnProperty(objectHasOwnProperty);const arrayFilter=uncurryT
|
|
|
156
159
|
const arrayForEach= uncurryThis(arrayPrototype.forEach);$h_once.arrayForEach(arrayForEach);
|
|
157
160
|
const arrayIncludes= uncurryThis(arrayPrototype.includes);$h_once.arrayIncludes(arrayIncludes);
|
|
158
161
|
const arrayJoin= uncurryThis(arrayPrototype.join);
|
|
159
|
-
/** @type {<T, U>(thisArg: readonly T[], callbackfn: (value: T, index: number, array: T[]) => U,
|
|
160
|
-
const arrayMap= uncurryThis(arrayPrototype.map);$h_once.arrayMap(arrayMap);
|
|
162
|
+
/** @type {<T, U>(thisArg: readonly T[], callbackfn: (value: T, index: number, array: T[]) => U, cbThisArg?: any) => U[]} */$h_once.arrayJoin(arrayJoin);
|
|
163
|
+
const arrayMap= /** @type {any} */ uncurryThis(arrayPrototype.map);$h_once.arrayMap(arrayMap);
|
|
161
164
|
const arrayPop= uncurryThis(arrayPrototype.pop);
|
|
162
165
|
/** @type {<T>(thisArg: T[], ...items: T[]) => number} */$h_once.arrayPop(arrayPop);
|
|
163
166
|
const arrayPush= uncurryThis(arrayPrototype.push);$h_once.arrayPush(arrayPush);
|
|
@@ -188,12 +191,14 @@ const stringIncludes= uncurryThis(stringPrototype.includes);$h_once.s
|
|
|
188
191
|
const stringIndexOf= uncurryThis(stringPrototype.indexOf);$h_once.stringIndexOf(stringIndexOf);
|
|
189
192
|
const stringMatch= uncurryThis(stringPrototype.match);
|
|
190
193
|
/**
|
|
191
|
-
* @type {
|
|
192
|
-
* ((thisArg: string, searchValue: { [Symbol.replace](string: string, replaceValue: string): string; }, replaceValue: string) => string)
|
|
194
|
+
* @type { &
|
|
195
|
+
* ((thisArg: string, searchValue: { [Symbol.replace](string: string, replaceValue: string): string; }, replaceValue: string) => string) &
|
|
193
196
|
* ((thisArg: string, searchValue: { [Symbol.replace](string: string, replacer: (substring: string, ...args: any[]) => string): string; }, replacer: (substring: string, ...args: any[]) => string) => string)
|
|
194
197
|
* }
|
|
195
198
|
*/$h_once.stringMatch(stringMatch);
|
|
196
|
-
const stringReplace=
|
|
199
|
+
const stringReplace= /** @type {any} */
|
|
200
|
+
uncurryThis(stringPrototype.replace);$h_once.stringReplace(stringReplace);
|
|
201
|
+
|
|
197
202
|
const stringSearch= uncurryThis(stringPrototype.search);$h_once.stringSearch(stringSearch);
|
|
198
203
|
const stringSlice= uncurryThis(stringPrototype.slice);
|
|
199
204
|
/** @type {(thisArg: string, splitter: string | RegExp | { [Symbol.split](string: string, limit?: number): string[]; }, limit?: number) => string[]} */$h_once.stringSlice(stringSlice);
|
|
@@ -202,13 +207,12 @@ const stringStartsWith= uncurryThis(stringPrototype.startsWith);$h_on
|
|
|
202
207
|
const iterateString= uncurryThis(stringPrototype[iteratorSymbol]);
|
|
203
208
|
//
|
|
204
209
|
$h_once.iterateString(iterateString);const weakmapDelete=uncurryThis(weakmapPrototype.delete);
|
|
205
|
-
/** @type {<K, V>(thisArg: WeakMap<K, V>, ...args: Parameters<WeakMap<K,V>['get']>) => ReturnType<WeakMap<K,V>['get']>} */$h_once.weakmapDelete(weakmapDelete);
|
|
210
|
+
/** @type {<K extends {}, V>(thisArg: WeakMap<K, V>, ...args: Parameters<WeakMap<K,V>['get']>) => ReturnType<WeakMap<K,V>['get']>} */$h_once.weakmapDelete(weakmapDelete);
|
|
206
211
|
const weakmapGet= uncurryThis(weakmapPrototype.get);$h_once.weakmapGet(weakmapGet);
|
|
207
212
|
const weakmapHas= uncurryThis(weakmapPrototype.has);$h_once.weakmapHas(weakmapHas);
|
|
208
213
|
const weakmapSet= uncurryThis(weakmapPrototype.set);
|
|
209
214
|
//
|
|
210
215
|
$h_once.weakmapSet(weakmapSet);const weaksetAdd=uncurryThis(weaksetPrototype.add);$h_once.weaksetAdd(weaksetAdd);
|
|
211
|
-
const weaksetGet= uncurryThis(weaksetPrototype.get);$h_once.weaksetGet(weaksetGet);
|
|
212
216
|
const weaksetHas= uncurryThis(weaksetPrototype.has);
|
|
213
217
|
//
|
|
214
218
|
$h_once.weaksetHas(weaksetHas);const functionToString=uncurryThis(functionPrototype.toString);
|
|
@@ -217,7 +221,9 @@ $h_once.functionToString(functionToString);const{all}=Promise;
|
|
|
217
221
|
const promiseAll= (promises)=>apply(all, Promise, [promises]);$h_once.promiseAll(promiseAll);
|
|
218
222
|
const promiseCatch= uncurryThis(promisePrototype.catch);
|
|
219
223
|
/** @type {<T, TResult1 = T, TResult2 = never>(thisArg: T, onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null) => Promise<TResult1 | TResult2>} */$h_once.promiseCatch(promiseCatch);
|
|
220
|
-
const promiseThen=
|
|
224
|
+
const promiseThen= /** @type {any} */
|
|
225
|
+
uncurryThis(promisePrototype.then);
|
|
226
|
+
|
|
221
227
|
//
|
|
222
228
|
$h_once.promiseThen(promiseThen);const finalizationRegistryRegister=
|
|
223
229
|
FinalizationRegistry&& uncurryThis(FinalizationRegistry.prototype.register);$h_once.finalizationRegistryRegister(finalizationRegistryRegister);
|
|
@@ -384,6 +390,289 @@ const noEvalEvaluate= ()=> {
|
|
|
384
390
|
})
|
|
385
391
|
,
|
|
386
392
|
// === functors[2] ===
|
|
393
|
+
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { $h_imports([["./internal-types.js", []]]);
|
|
394
|
+
|
|
395
|
+
|
|
396
|
+
|
|
397
|
+
|
|
398
|
+
|
|
399
|
+
const { freeze}= Object;
|
|
400
|
+
const { isSafeInteger}= Number;
|
|
401
|
+
|
|
402
|
+
/**
|
|
403
|
+
* @template Data
|
|
404
|
+
* @typedef {object} DoublyLinkedCell
|
|
405
|
+
* A cell of a doubly-linked ring, i.e., a doubly-linked circular list.
|
|
406
|
+
* DoublyLinkedCells are not frozen, and so should be closely encapsulated by
|
|
407
|
+
* any abstraction that uses them.
|
|
408
|
+
* @property {DoublyLinkedCell<Data>} next
|
|
409
|
+
* @property {DoublyLinkedCell<Data>} prev
|
|
410
|
+
* @property {Data} data
|
|
411
|
+
*/
|
|
412
|
+
|
|
413
|
+
/**
|
|
414
|
+
* Makes a new self-linked cell. There are two reasons to do so:
|
|
415
|
+
* * To make the head sigil of a new initially-empty doubly-linked ring.
|
|
416
|
+
* * To make a non-sigil cell to be `spliceAfter`ed.
|
|
417
|
+
*
|
|
418
|
+
* @template Data
|
|
419
|
+
* @param {Data} data
|
|
420
|
+
* @returns {DoublyLinkedCell<Data>}
|
|
421
|
+
*/
|
|
422
|
+
const makeSelfCell= (data)=>{
|
|
423
|
+
/** @type {Partial<DoublyLinkedCell<Data>>} */
|
|
424
|
+
const incompleteCell= {
|
|
425
|
+
next: undefined,
|
|
426
|
+
prev: undefined,
|
|
427
|
+
data};
|
|
428
|
+
|
|
429
|
+
const selfCell= /** @type {DoublyLinkedCell<Data>} */ incompleteCell;
|
|
430
|
+
selfCell.next= selfCell;
|
|
431
|
+
selfCell.prev= selfCell;
|
|
432
|
+
// Not frozen!
|
|
433
|
+
return selfCell;
|
|
434
|
+
};
|
|
435
|
+
|
|
436
|
+
/**
|
|
437
|
+
* Splices a self-linked non-sigil cell into a ring after `prev`.
|
|
438
|
+
* `prev` could be the head sigil, or it could be some other non-sigil
|
|
439
|
+
* cell within a ring.
|
|
440
|
+
*
|
|
441
|
+
* @template Data
|
|
442
|
+
* @param {DoublyLinkedCell<Data>} prev
|
|
443
|
+
* @param {DoublyLinkedCell<Data>} selfCell
|
|
444
|
+
*/
|
|
445
|
+
const spliceAfter= (prev, selfCell)=> {
|
|
446
|
+
if( prev=== selfCell) {
|
|
447
|
+
throw TypeError('Cannot splice a cell into itself');
|
|
448
|
+
}
|
|
449
|
+
if( selfCell.next!== selfCell|| selfCell.prev!== selfCell) {
|
|
450
|
+
throw TypeError('Expected self-linked cell');
|
|
451
|
+
}
|
|
452
|
+
const cell= selfCell;
|
|
453
|
+
// rename variable cause it isn't self-linked after this point.
|
|
454
|
+
|
|
455
|
+
const next= prev.next;
|
|
456
|
+
cell.prev= prev;
|
|
457
|
+
cell.next= next;
|
|
458
|
+
prev.next= cell;
|
|
459
|
+
next.prev= cell;
|
|
460
|
+
// Not frozen!
|
|
461
|
+
return cell;
|
|
462
|
+
};
|
|
463
|
+
|
|
464
|
+
/**
|
|
465
|
+
* @template Data
|
|
466
|
+
* @param {DoublyLinkedCell<Data>} cell
|
|
467
|
+
* No-op if the cell is self-linked.
|
|
468
|
+
*/
|
|
469
|
+
const spliceOut= (cell)=>{
|
|
470
|
+
const { prev, next}= cell;
|
|
471
|
+
prev.next= next;
|
|
472
|
+
next.prev= prev;
|
|
473
|
+
cell.prev= cell;
|
|
474
|
+
cell.next= cell;
|
|
475
|
+
};
|
|
476
|
+
|
|
477
|
+
/**
|
|
478
|
+
* The LRUCacheMap is used within the implementation of `assert` and so
|
|
479
|
+
* at a layer below SES or harden. Thus, we give it a `WeakMap`-like interface
|
|
480
|
+
* rather than a `WeakMapStore`-like interface. To work before `lockdown`,
|
|
481
|
+
* the implementation must use `freeze` manually, but still exhaustively.
|
|
482
|
+
*
|
|
483
|
+
* It implements the WeakMap interface, and holds its keys weakly. Cached
|
|
484
|
+
* values are only held while the key is held by the user and the key/value
|
|
485
|
+
* bookkeeping cell has not been pushed off the end of the cache by `budget`
|
|
486
|
+
* number of more recently referenced cells. If the key is dropped by the user,
|
|
487
|
+
* the value will no longer be held by the cache, but the bookkeeping cell
|
|
488
|
+
* itself will stay in memory.
|
|
489
|
+
*
|
|
490
|
+
* @template {{}} K
|
|
491
|
+
* @template {unknown} V
|
|
492
|
+
* @param {number} keysBudget
|
|
493
|
+
* @returns {WeakMap<K,V>}
|
|
494
|
+
*/
|
|
495
|
+
const makeLRUCacheMap= (keysBudget)=>{
|
|
496
|
+
if( !isSafeInteger(keysBudget)|| keysBudget< 0) {
|
|
497
|
+
throw new TypeError(
|
|
498
|
+
'keysBudget must be a safe non-negative integer number');
|
|
499
|
+
|
|
500
|
+
}
|
|
501
|
+
/** @typedef {DoublyLinkedCell<WeakMap<K, V> | undefined>} LRUCacheCell */
|
|
502
|
+
/** @type {WeakMap<K, LRUCacheCell>} */
|
|
503
|
+
const keyToCell= new WeakMap();
|
|
504
|
+
let size= 0; // `size` must remain <= `keysBudget`
|
|
505
|
+
// As a sigil, `head` uniquely is not in the `keyToCell` map.
|
|
506
|
+
/** @type {LRUCacheCell} */
|
|
507
|
+
const head= makeSelfCell(undefined);
|
|
508
|
+
|
|
509
|
+
const touchCell= (key)=>{
|
|
510
|
+
const cell= keyToCell.get(key);
|
|
511
|
+
if( cell=== undefined|| cell.data=== undefined) {
|
|
512
|
+
// Either the key was GCed, or the cell was condemned.
|
|
513
|
+
return undefined;
|
|
514
|
+
}
|
|
515
|
+
// Becomes most recently used
|
|
516
|
+
spliceOut(cell);
|
|
517
|
+
spliceAfter(head, cell);
|
|
518
|
+
return cell;
|
|
519
|
+
};
|
|
520
|
+
|
|
521
|
+
/**
|
|
522
|
+
* @param {K} key
|
|
523
|
+
*/
|
|
524
|
+
const has= (key)=>touchCell(key)!== undefined;
|
|
525
|
+
freeze(has);
|
|
526
|
+
|
|
527
|
+
/**
|
|
528
|
+
* @param {K} key
|
|
529
|
+
*/
|
|
530
|
+
// TODO Change to the following line, once our tools don't choke on `?.`.
|
|
531
|
+
// See https://github.com/endojs/endo/issues/1514
|
|
532
|
+
// const get = key => touchCell(key)?.data?.get(key);
|
|
533
|
+
const get= (key)=>{
|
|
534
|
+
const cell= touchCell(key);
|
|
535
|
+
return cell&& cell.data&& cell.data.get(key);
|
|
536
|
+
};
|
|
537
|
+
freeze(get);
|
|
538
|
+
|
|
539
|
+
/**
|
|
540
|
+
* @param {K} key
|
|
541
|
+
* @param {V} value
|
|
542
|
+
*/
|
|
543
|
+
const set= (key, value)=> {
|
|
544
|
+
if( keysBudget< 1) {
|
|
545
|
+
// eslint-disable-next-line no-use-before-define
|
|
546
|
+
return lruCacheMap; // Implements WeakMap.set
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
let cell= touchCell(key);
|
|
550
|
+
if( cell=== undefined) {
|
|
551
|
+
cell= makeSelfCell(undefined);
|
|
552
|
+
spliceAfter(head, cell); // start most recently used
|
|
553
|
+
}
|
|
554
|
+
if( !cell.data) {
|
|
555
|
+
// Either a fresh cell or a reused condemned cell.
|
|
556
|
+
size+= 1;
|
|
557
|
+
// Add its data.
|
|
558
|
+
cell.data= new WeakMap();
|
|
559
|
+
// Advertise the cell for this key.
|
|
560
|
+
keyToCell.set(key, cell);
|
|
561
|
+
while( size> keysBudget) {
|
|
562
|
+
const condemned= head.prev;
|
|
563
|
+
spliceOut(condemned); // Drop least recently used
|
|
564
|
+
condemned.data= undefined;
|
|
565
|
+
size-= 1;
|
|
566
|
+
}
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
// Update the data.
|
|
570
|
+
cell.data.set(key, value);
|
|
571
|
+
|
|
572
|
+
// eslint-disable-next-line no-use-before-define
|
|
573
|
+
return lruCacheMap; // Implements WeakMap.set
|
|
574
|
+
};
|
|
575
|
+
freeze(set);
|
|
576
|
+
|
|
577
|
+
// "delete" is a keyword.
|
|
578
|
+
/**
|
|
579
|
+
* @param {K} key
|
|
580
|
+
*/
|
|
581
|
+
const deleteIt= (key)=>{
|
|
582
|
+
const cell= keyToCell.get(key);
|
|
583
|
+
if( cell=== undefined) {
|
|
584
|
+
return false;
|
|
585
|
+
}
|
|
586
|
+
spliceOut(cell);
|
|
587
|
+
keyToCell.delete(key);
|
|
588
|
+
if( cell.data=== undefined) {
|
|
589
|
+
// Already condemned.
|
|
590
|
+
return false;
|
|
591
|
+
}
|
|
592
|
+
|
|
593
|
+
cell.data= undefined;
|
|
594
|
+
size-= 1;
|
|
595
|
+
return true;
|
|
596
|
+
};
|
|
597
|
+
freeze(deleteIt);
|
|
598
|
+
|
|
599
|
+
const lruCacheMap= freeze({
|
|
600
|
+
has,
|
|
601
|
+
get,
|
|
602
|
+
set,
|
|
603
|
+
delete: deleteIt,
|
|
604
|
+
[Symbol.toStringTag]: 'LRUCacheMap'});
|
|
605
|
+
|
|
606
|
+
return lruCacheMap;
|
|
607
|
+
};$h_once.makeLRUCacheMap(makeLRUCacheMap);
|
|
608
|
+
freeze(makeLRUCacheMap);
|
|
609
|
+
|
|
610
|
+
const defaultLoggedErrorsBudget= 1000;
|
|
611
|
+
const defaultArgsPerErrorBudget= 100;
|
|
612
|
+
|
|
613
|
+
/**
|
|
614
|
+
* @param {number} [errorsBudget]
|
|
615
|
+
* @param {number} [argsPerErrorBudget]
|
|
616
|
+
*/
|
|
617
|
+
const makeNoteLogArgsArrayKit= (
|
|
618
|
+
errorsBudget= defaultLoggedErrorsBudget,
|
|
619
|
+
argsPerErrorBudget= defaultArgsPerErrorBudget)=>
|
|
620
|
+
{
|
|
621
|
+
if( !isSafeInteger(argsPerErrorBudget)|| argsPerErrorBudget< 1) {
|
|
622
|
+
throw new TypeError(
|
|
623
|
+
'argsPerErrorBudget must be a safe positive integer number');
|
|
624
|
+
|
|
625
|
+
}
|
|
626
|
+
|
|
627
|
+
/**
|
|
628
|
+
* @type {WeakMap<Error, LogArgs[]>}
|
|
629
|
+
*
|
|
630
|
+
* Maps from an error to an array of log args, where each log args is
|
|
631
|
+
* remembered as an annotation on that error. This can be used, for example,
|
|
632
|
+
* to keep track of additional causes of the error. The elements of any
|
|
633
|
+
* log args may include errors which are associated with further annotations.
|
|
634
|
+
* An augmented console, like the causal console of `console.js`, could
|
|
635
|
+
* then retrieve the graph of such annotations.
|
|
636
|
+
*/
|
|
637
|
+
const noteLogArgsArrayMap= makeLRUCacheMap(errorsBudget);
|
|
638
|
+
|
|
639
|
+
/**
|
|
640
|
+
* @param {Error} error
|
|
641
|
+
* @param {LogArgs} logArgs
|
|
642
|
+
*/
|
|
643
|
+
const addLogArgs= (error, logArgs)=> {
|
|
644
|
+
const logArgsArray= noteLogArgsArrayMap.get(error);
|
|
645
|
+
if( logArgsArray!== undefined) {
|
|
646
|
+
if( logArgsArray.length>= argsPerErrorBudget) {
|
|
647
|
+
logArgsArray.shift();
|
|
648
|
+
}
|
|
649
|
+
logArgsArray.push(logArgs);
|
|
650
|
+
}else {
|
|
651
|
+
noteLogArgsArrayMap.set(error, [logArgs]);
|
|
652
|
+
}
|
|
653
|
+
};
|
|
654
|
+
freeze(addLogArgs);
|
|
655
|
+
|
|
656
|
+
/**
|
|
657
|
+
* @param {Error} error
|
|
658
|
+
* @returns {LogArgs[] | undefined}
|
|
659
|
+
*/
|
|
660
|
+
const takeLogArgsArray= (error)=>{
|
|
661
|
+
const result= noteLogArgsArrayMap.get(error);
|
|
662
|
+
noteLogArgsArrayMap.delete(error);
|
|
663
|
+
return result;
|
|
664
|
+
};
|
|
665
|
+
freeze(takeLogArgsArray);
|
|
666
|
+
|
|
667
|
+
return freeze({
|
|
668
|
+
addLogArgs,
|
|
669
|
+
takeLogArgsArray});
|
|
670
|
+
|
|
671
|
+
};$h_once.makeNoteLogArgsArrayKit(makeNoteLogArgsArrayKit);
|
|
672
|
+
freeze(makeNoteLogArgsArrayKit);
|
|
673
|
+
})
|
|
674
|
+
,
|
|
675
|
+
// === functors[3] ===
|
|
387
676
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Set,String,arrayJoin,arraySlice,freeze,is,isError,setAdd,setHas,stringIncludes,stringStartsWith,stringifyJson,toStringTagSymbol;$h_imports([["../commons.js", [["Set", [$h_a => (Set = $h_a)]],["String", [$h_a => (String = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["arraySlice", [$h_a => (arraySlice = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["is", [$h_a => (is = $h_a)]],["isError", [$h_a => (isError = $h_a)]],["setAdd", [$h_a => (setAdd = $h_a)]],["setHas", [$h_a => (setHas = $h_a)]],["stringIncludes", [$h_a => (stringIncludes = $h_a)]],["stringStartsWith", [$h_a => (stringStartsWith = $h_a)]],["stringifyJson", [$h_a => (stringifyJson = $h_a)]],["toStringTagSymbol", [$h_a => (toStringTagSymbol = $h_a)]]]]]);
|
|
388
677
|
|
|
389
678
|
|
|
@@ -554,7 +843,7 @@ const bestEffortStringify= (payload, spaces= undefined)=> {
|
|
|
554
843
|
freeze(bestEffortStringify);
|
|
555
844
|
})
|
|
556
845
|
,
|
|
557
|
-
// === functors[
|
|
846
|
+
// === functors[4] ===
|
|
558
847
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { $h_imports([]); // @ts-check
|
|
559
848
|
|
|
560
849
|
/**
|
|
@@ -961,8 +1250,9 @@ freeze(bestEffortStringify);
|
|
|
961
1250
|
*/
|
|
962
1251
|
})
|
|
963
1252
|
,
|
|
964
|
-
// === functors[
|
|
965
|
-
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let RangeError,TypeError,WeakMap,arrayJoin,arrayMap,arrayPop,arrayPush,assign,freeze,globalThis,is,isError,stringIndexOf,stringReplace,stringSlice,stringStartsWith,weakmapDelete,weakmapGet,weakmapHas,weakmapSet,an,bestEffortStringify;$h_imports([["../commons.js", [["RangeError", [$h_a => (RangeError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["WeakMap", [$h_a => (WeakMap = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["arrayPop", [$h_a => (arrayPop = $h_a)]],["arrayPush", [$h_a => (arrayPush = $h_a)]],["assign", [$h_a => (assign = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["is", [$h_a => (is = $h_a)]],["isError", [$h_a => (isError = $h_a)]],["stringIndexOf", [$h_a => (stringIndexOf = $h_a)]],["stringReplace", [$h_a => (stringReplace = $h_a)]],["stringSlice", [$h_a => (stringSlice = $h_a)]],["stringStartsWith", [$h_a => (stringStartsWith = $h_a)]],["weakmapDelete", [$h_a => (weakmapDelete = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["weakmapHas", [$h_a => (weakmapHas = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]]]],["./stringify-utils.js", [["an", [$h_a => (an = $h_a)]],["bestEffortStringify", [$h_a => (bestEffortStringify = $h_a)]]]],["./types.js", []],["./internal-types.js", []]]);
|
|
1253
|
+
// === functors[5] ===
|
|
1254
|
+
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let RangeError,TypeError,WeakMap,arrayJoin,arrayMap,arrayPop,arrayPush,assign,freeze,globalThis,is,isError,stringIndexOf,stringReplace,stringSlice,stringStartsWith,weakmapDelete,weakmapGet,weakmapHas,weakmapSet,an,bestEffortStringify,makeNoteLogArgsArrayKit;$h_imports([["../commons.js", [["RangeError", [$h_a => (RangeError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["WeakMap", [$h_a => (WeakMap = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["arrayPop", [$h_a => (arrayPop = $h_a)]],["arrayPush", [$h_a => (arrayPush = $h_a)]],["assign", [$h_a => (assign = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["is", [$h_a => (is = $h_a)]],["isError", [$h_a => (isError = $h_a)]],["stringIndexOf", [$h_a => (stringIndexOf = $h_a)]],["stringReplace", [$h_a => (stringReplace = $h_a)]],["stringSlice", [$h_a => (stringSlice = $h_a)]],["stringStartsWith", [$h_a => (stringStartsWith = $h_a)]],["weakmapDelete", [$h_a => (weakmapDelete = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["weakmapHas", [$h_a => (weakmapHas = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]]]],["./stringify-utils.js", [["an", [$h_a => (an = $h_a)]],["bestEffortStringify", [$h_a => (bestEffortStringify = $h_a)]]]],["./types.js", []],["./internal-types.js", []],["./note-log-args.js", [["makeNoteLogArgsArrayKit", [$h_a => (makeNoteLogArgsArrayKit = $h_a)]]]]]);
|
|
1255
|
+
|
|
966
1256
|
|
|
967
1257
|
|
|
968
1258
|
|
|
@@ -1215,17 +1505,7 @@ freeze(makeError);
|
|
|
1215
1505
|
|
|
1216
1506
|
// /////////////////////////////////////////////////////////////////////////////
|
|
1217
1507
|
|
|
1218
|
-
|
|
1219
|
-
* @type {WeakMap<Error, LogArgs[]>}
|
|
1220
|
-
*
|
|
1221
|
-
* Maps from an error to an array of log args, where each log args is
|
|
1222
|
-
* remembered as an annotation on that error. This can be used, for example,
|
|
1223
|
-
* to keep track of additional causes of the error. The elements of any
|
|
1224
|
-
* log args may include errors which are associated with further annotations.
|
|
1225
|
-
* An augmented console, like the causal console of `console.js`, could
|
|
1226
|
-
* then retrieve the graph of such annotations.
|
|
1227
|
-
*/
|
|
1228
|
-
const hiddenNoteLogArgsArrays= new WeakMap();
|
|
1508
|
+
const { addLogArgs, takeLogArgsArray}= makeNoteLogArgsArrayKit();
|
|
1229
1509
|
|
|
1230
1510
|
/**
|
|
1231
1511
|
* @type {WeakMap<Error, NoteCallback[]>}
|
|
@@ -1259,12 +1539,7 @@ const note= (error, detailsNote)=> {
|
|
|
1259
1539
|
callback(error, logArgs);
|
|
1260
1540
|
}
|
|
1261
1541
|
}else {
|
|
1262
|
-
|
|
1263
|
-
if( logArgsArray!== undefined) {
|
|
1264
|
-
arrayPush(logArgsArray, logArgs);
|
|
1265
|
-
}else {
|
|
1266
|
-
weakmapSet(hiddenNoteLogArgsArrays, error, [logArgs]);
|
|
1267
|
-
}
|
|
1542
|
+
addLogArgs(error, logArgs);
|
|
1268
1543
|
}
|
|
1269
1544
|
};
|
|
1270
1545
|
freeze(note);
|
|
@@ -1303,8 +1578,7 @@ const loggedErrorHandler= {
|
|
|
1303
1578
|
return result;
|
|
1304
1579
|
},
|
|
1305
1580
|
takeNoteLogArgsArray: (error, callback)=> {
|
|
1306
|
-
const result=
|
|
1307
|
-
weakmapDelete(hiddenNoteLogArgsArrays, error);
|
|
1581
|
+
const result= takeLogArgsArray(error);
|
|
1308
1582
|
if( callback!== undefined) {
|
|
1309
1583
|
const callbacks= weakmapGet(hiddenNoteCallbackArrays, error);
|
|
1310
1584
|
if( callbacks) {
|
|
@@ -1421,7 +1695,7 @@ freeze(makeAssert);
|
|
|
1421
1695
|
const assert= makeAssert();$h_once.assert(assert);
|
|
1422
1696
|
})
|
|
1423
1697
|
,
|
|
1424
|
-
// === functors[
|
|
1698
|
+
// === functors[6] ===
|
|
1425
1699
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_EVAL,create,defineProperties,freeze,assert;$h_imports([["./commons.js", [["FERAL_EVAL", [$h_a => (FERAL_EVAL = $h_a)]],["create", [$h_a => (create = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
1426
1700
|
|
|
1427
1701
|
|
|
@@ -1496,14 +1770,16 @@ const makeEvalScopeKit= ()=> {
|
|
|
1496
1770
|
const evalScopeKit= {
|
|
1497
1771
|
evalScope,
|
|
1498
1772
|
allowNextEvalToBeUnsafe() {
|
|
1499
|
-
|
|
1500
|
-
|
|
1773
|
+
const { revoked}= evalScopeKit;
|
|
1774
|
+
if( revoked!== null) {
|
|
1775
|
+
Fail `a handler did not reset allowNextEvalToBeUnsafe ${revoked.err}`;
|
|
1501
1776
|
}
|
|
1502
1777
|
// Allow next reference to eval produce the unsafe FERAL_EVAL.
|
|
1503
1778
|
// We avoid defineProperty because it consumes an extra stack frame taming
|
|
1504
1779
|
// its return value.
|
|
1505
1780
|
defineProperties(evalScope, oneTimeEvalProperties);
|
|
1506
1781
|
},
|
|
1782
|
+
/** @type {null | { err: any }} */
|
|
1507
1783
|
revoked: null};
|
|
1508
1784
|
|
|
1509
1785
|
|
|
@@ -1511,7 +1787,7 @@ const makeEvalScopeKit= ()=> {
|
|
|
1511
1787
|
};$h_once.makeEvalScopeKit(makeEvalScopeKit);
|
|
1512
1788
|
})
|
|
1513
1789
|
,
|
|
1514
|
-
// === functors[
|
|
1790
|
+
// === functors[7] ===
|
|
1515
1791
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let arrayFilter,arrayIncludes,getOwnPropertyDescriptor,getOwnPropertyNames,objectHasOwnProperty,regexpTest;$h_imports([["./commons.js", [["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["arrayIncludes", [$h_a => (arrayIncludes = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getOwnPropertyNames", [$h_a => (getOwnPropertyNames = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["regexpTest", [$h_a => (regexpTest = $h_a)]]]]]);
|
|
1516
1792
|
|
|
1517
1793
|
|
|
@@ -1629,6 +1905,7 @@ const isValidIdentifierName= (name)=>{
|
|
|
1629
1905
|
function isImmutableDataProperty(obj, name) {
|
|
1630
1906
|
const desc= getOwnPropertyDescriptor(obj, name);
|
|
1631
1907
|
return(
|
|
1908
|
+
desc&&
|
|
1632
1909
|
//
|
|
1633
1910
|
// The getters will not have .writable, don't let the falsyness of
|
|
1634
1911
|
// 'undefined' trick us: test with === false, not ! . However descriptors
|
|
@@ -1693,7 +1970,7 @@ const getScopeConstants= (globalObject, moduleLexicals= {})=> {
|
|
|
1693
1970
|
};$h_once.getScopeConstants(getScopeConstants);
|
|
1694
1971
|
})
|
|
1695
1972
|
,
|
|
1696
|
-
// === functors[
|
|
1973
|
+
// === functors[8] ===
|
|
1697
1974
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_FUNCTION,arrayJoin,apply,getScopeConstants;$h_imports([["./commons.js", [["FERAL_FUNCTION", [$h_a => (FERAL_FUNCTION = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["apply", [$h_a => (apply = $h_a)]]]],["./scope-constants.js", [["getScopeConstants", [$h_a => (getScopeConstants = $h_a)]]]]]);
|
|
1698
1975
|
|
|
1699
1976
|
|
|
@@ -1806,7 +2083,7 @@ const makeEvaluate= (context)=>{
|
|
|
1806
2083
|
};$h_once.makeEvaluate(makeEvaluate);
|
|
1807
2084
|
})
|
|
1808
2085
|
,
|
|
1809
|
-
// === functors[
|
|
2086
|
+
// === functors[9] ===
|
|
1810
2087
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Proxy,String,TypeError,ReferenceError,create,freeze,getOwnPropertyDescriptors,globalThis,immutableObject,assert;$h_imports([["./commons.js", [["Proxy", [$h_a => (Proxy = $h_a)]],["String", [$h_a => (String = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["ReferenceError", [$h_a => (ReferenceError = $h_a)]],["create", [$h_a => (create = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["immutableObject", [$h_a => (immutableObject = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
1811
2088
|
|
|
1812
2089
|
|
|
@@ -1866,9 +2143,8 @@ const scopeProxyHandlerProperties= {
|
|
|
1866
2143
|
return null;
|
|
1867
2144
|
},
|
|
1868
2145
|
|
|
1869
|
-
//
|
|
1870
|
-
// TODO
|
|
1871
|
-
// TODO report as bug to v8 or Chrome, and record issue link here.
|
|
2146
|
+
// See https://github.com/endojs/endo/issues/1510
|
|
2147
|
+
// TODO: report as bug to v8 or Chrome, and record issue link here.
|
|
1872
2148
|
getOwnPropertyDescriptor(_target, prop) {
|
|
1873
2149
|
// Coerce with `String` in case prop is a symbol.
|
|
1874
2150
|
const quotedProp= q(String(prop));
|
|
@@ -1896,7 +2172,7 @@ const strictScopeTerminator= new Proxy(
|
|
|
1896
2172
|
strictScopeTerminatorHandler);$h_once.strictScopeTerminator(strictScopeTerminator);
|
|
1897
2173
|
})
|
|
1898
2174
|
,
|
|
1899
|
-
// === functors[
|
|
2175
|
+
// === functors[10] ===
|
|
1900
2176
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Proxy,create,freeze,getOwnPropertyDescriptors,immutableObject,reflectSet,strictScopeTerminatorHandler,alwaysThrowHandler;$h_imports([["./commons.js", [["Proxy", [$h_a => (Proxy = $h_a)]],["create", [$h_a => (create = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["immutableObject", [$h_a => (immutableObject = $h_a)]],["reflectSet", [$h_a => (reflectSet = $h_a)]]]],["./strict-scope-terminator.js", [["strictScopeTerminatorHandler", [$h_a => (strictScopeTerminatorHandler = $h_a)]],["alwaysThrowHandler", [$h_a => (alwaysThrowHandler = $h_a)]]]]]);
|
|
1901
2177
|
|
|
1902
2178
|
|
|
@@ -1953,7 +2229,7 @@ const createSloppyGlobalsScopeTerminator= (globalObject)=>{
|
|
|
1953
2229
|
freeze(createSloppyGlobalsScopeTerminator);
|
|
1954
2230
|
})
|
|
1955
2231
|
,
|
|
1956
|
-
// === functors[
|
|
2232
|
+
// === functors[11] ===
|
|
1957
2233
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_REG_EXP,regexpExec,stringSlice;$h_imports([["./commons.js", [["FERAL_REG_EXP", [$h_a => (FERAL_REG_EXP = $h_a)]],["regexpExec", [$h_a => (regexpExec = $h_a)]],["stringSlice", [$h_a => (stringSlice = $h_a)]]]]]);
|
|
1958
2234
|
|
|
1959
2235
|
// Captures a key and value of the form #key=value or @key=value
|
|
@@ -2006,7 +2282,7 @@ const getSourceURL= (src)=>{
|
|
|
2006
2282
|
};$h_once.getSourceURL(getSourceURL);
|
|
2007
2283
|
})
|
|
2008
2284
|
,
|
|
2009
|
-
// === functors[
|
|
2285
|
+
// === functors[12] ===
|
|
2010
2286
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_REG_EXP,SyntaxError,stringReplace,stringSearch,stringSlice,stringSplit,freeze,getSourceURL;$h_imports([["./commons.js", [["FERAL_REG_EXP", [$h_a => (FERAL_REG_EXP = $h_a)]],["SyntaxError", [$h_a => (SyntaxError = $h_a)]],["stringReplace", [$h_a => (stringReplace = $h_a)]],["stringSearch", [$h_a => (stringSearch = $h_a)]],["stringSlice", [$h_a => (stringSlice = $h_a)]],["stringSplit", [$h_a => (stringSplit = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]]]],["./get-source-url.js", [["getSourceURL", [$h_a => (getSourceURL = $h_a)]]]]]);
|
|
2011
2287
|
|
|
2012
2288
|
|
|
@@ -2274,7 +2550,7 @@ $h_once.applyTransforms(applyTransforms);const transforms=freeze({
|
|
|
2274
2550
|
applyTransforms: freeze(applyTransforms)});$h_once.transforms(transforms);
|
|
2275
2551
|
})
|
|
2276
2552
|
,
|
|
2277
|
-
// === functors[
|
|
2553
|
+
// === functors[13] ===
|
|
2278
2554
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let apply,freeze,strictScopeTerminator,createSloppyGlobalsScopeTerminator,makeEvalScopeKit,applyTransforms,mandatoryTransforms,makeEvaluate,assert;$h_imports([["./commons.js", [["apply", [$h_a => (apply = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]]]],["./strict-scope-terminator.js", [["strictScopeTerminator", [$h_a => (strictScopeTerminator = $h_a)]]]],["./sloppy-globals-scope-terminator.js", [["createSloppyGlobalsScopeTerminator", [$h_a => (createSloppyGlobalsScopeTerminator = $h_a)]]]],["./eval-scope.js", [["makeEvalScopeKit", [$h_a => (makeEvalScopeKit = $h_a)]]]],["./transforms.js", [["applyTransforms", [$h_a => (applyTransforms = $h_a)]],["mandatoryTransforms", [$h_a => (mandatoryTransforms = $h_a)]]]],["./make-evaluate.js", [["makeEvaluate", [$h_a => (makeEvaluate = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
2279
2555
|
|
|
2280
2556
|
|
|
@@ -2296,15 +2572,15 @@ const { Fail}= assert;
|
|
|
2296
2572
|
* @param {object} options
|
|
2297
2573
|
* @param {object} options.globalObject
|
|
2298
2574
|
* @param {object} [options.moduleLexicals]
|
|
2299
|
-
* @param {Array<Transform>} [options.globalTransforms]
|
|
2300
|
-
* @param {
|
|
2575
|
+
* @param {Array<import('./lockdown-shim.js').Transform>} [options.globalTransforms]
|
|
2576
|
+
* @param {boolean} [options.sloppyGlobalsMode]
|
|
2301
2577
|
*/
|
|
2302
2578
|
const makeSafeEvaluator= ({
|
|
2303
2579
|
globalObject,
|
|
2304
2580
|
moduleLexicals= {},
|
|
2305
2581
|
globalTransforms= [],
|
|
2306
|
-
sloppyGlobalsMode= false}
|
|
2307
|
-
|
|
2582
|
+
sloppyGlobalsMode= false})=>
|
|
2583
|
+
{
|
|
2308
2584
|
const scopeTerminator= sloppyGlobalsMode?
|
|
2309
2585
|
createSloppyGlobalsScopeTerminator(globalObject):
|
|
2310
2586
|
strictScopeTerminator;
|
|
@@ -2331,9 +2607,10 @@ const makeSafeEvaluator= ({
|
|
|
2331
2607
|
/**
|
|
2332
2608
|
* @param {string} source
|
|
2333
2609
|
* @param {object} [options]
|
|
2334
|
-
* @param {Array<Transform>} [options.localTransforms]
|
|
2610
|
+
* @param {Array<import('./lockdown-shim.js').Transform>} [options.localTransforms]
|
|
2335
2611
|
*/
|
|
2336
|
-
const safeEvaluate= (source,
|
|
2612
|
+
const safeEvaluate= (source, options)=> {
|
|
2613
|
+
const { localTransforms= []}= options|| {};
|
|
2337
2614
|
provideEvaluate();
|
|
2338
2615
|
|
|
2339
2616
|
// Execute the mandatory transforms last to ensure that any rewritten code
|
|
@@ -2386,7 +2663,7 @@ const makeSafeEvaluator= ({
|
|
|
2386
2663
|
};$h_once.makeSafeEvaluator(makeSafeEvaluator);
|
|
2387
2664
|
})
|
|
2388
2665
|
,
|
|
2389
|
-
// === functors[
|
|
2666
|
+
// === functors[14] ===
|
|
2390
2667
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,arrayPush,create,getOwnPropertyDescriptors,evadeHtmlCommentTest,evadeImportExpressionTest,rejectSomeDirectEvalExpressions,makeSafeEvaluator;$h_imports([["./commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["arrayPush", [$h_a => (arrayPush = $h_a)]],["create", [$h_a => (create = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]]]],["./transforms.js", [["evadeHtmlCommentTest", [$h_a => (evadeHtmlCommentTest = $h_a)]],["evadeImportExpressionTest", [$h_a => (evadeImportExpressionTest = $h_a)]],["rejectSomeDirectEvalExpressions", [$h_a => (rejectSomeDirectEvalExpressions = $h_a)]]]],["./make-safe-evaluator.js", [["makeSafeEvaluator", [$h_a => (makeSafeEvaluator = $h_a)]]]]]);
|
|
2391
2668
|
|
|
2392
2669
|
|
|
@@ -2482,7 +2759,7 @@ const compartmentEvaluate= (compartmentFields, source, options)=> {
|
|
|
2482
2759
|
};$h_once.compartmentEvaluate(compartmentEvaluate);
|
|
2483
2760
|
})
|
|
2484
2761
|
,
|
|
2485
|
-
// === functors[
|
|
2762
|
+
// === functors[15] ===
|
|
2486
2763
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { $h_imports([]); /**
|
|
2487
2764
|
* makeEvalFunction()
|
|
2488
2765
|
* A safe version of the native eval function which relies on
|
|
@@ -2512,7 +2789,7 @@ const makeEvalFunction= (safeEvaluate)=>{
|
|
|
2512
2789
|
};$h_once.makeEvalFunction(makeEvalFunction);
|
|
2513
2790
|
})
|
|
2514
2791
|
,
|
|
2515
|
-
// === functors[
|
|
2792
|
+
// === functors[16] ===
|
|
2516
2793
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_FUNCTION,arrayJoin,arrayPop,defineProperties,getPrototypeOf,assert;$h_imports([["./commons.js", [["FERAL_FUNCTION", [$h_a => (FERAL_FUNCTION = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["arrayPop", [$h_a => (arrayPop = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["getPrototypeOf", [$h_a => (getPrototypeOf = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
2517
2794
|
|
|
2518
2795
|
|
|
@@ -2593,7 +2870,7 @@ const makeFunctionConstructor= (safeEvaluate)=>{
|
|
|
2593
2870
|
};$h_once.makeFunctionConstructor(makeFunctionConstructor);
|
|
2594
2871
|
})
|
|
2595
2872
|
,
|
|
2596
|
-
// === functors[
|
|
2873
|
+
// === functors[17] ===
|
|
2597
2874
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { $h_imports([]); /* eslint-disable no-restricted-globals */
|
|
2598
2875
|
/**
|
|
2599
2876
|
* @file Exports {@code whitelist}, a recursively defined
|
|
@@ -3817,6 +4094,10 @@ const whitelist= {
|
|
|
3817
4094
|
'[[Proto]]': '%FunctionPrototype%',
|
|
3818
4095
|
constructor: '%InertAsyncGeneratorFunction%',
|
|
3819
4096
|
prototype: '%AsyncGeneratorPrototype%',
|
|
4097
|
+
// length prop added here for React Native jsc-android
|
|
4098
|
+
// https://github.com/endojs/endo/issues/660
|
|
4099
|
+
// https://github.com/react-native-community/jsc-android-buildscripts/issues/181
|
|
4100
|
+
length: 'number',
|
|
3820
4101
|
'@@toStringTag': 'string'},
|
|
3821
4102
|
|
|
3822
4103
|
|
|
@@ -3899,6 +4180,10 @@ const whitelist= {
|
|
|
3899
4180
|
// Properties of the AsyncFunction Prototype Object
|
|
3900
4181
|
'[[Proto]]': '%FunctionPrototype%',
|
|
3901
4182
|
constructor: '%InertAsyncFunction%',
|
|
4183
|
+
// length prop added here for React Native jsc-android
|
|
4184
|
+
// https://github.com/endojs/endo/issues/660
|
|
4185
|
+
// https://github.com/react-native-community/jsc-android-buildscripts/issues/181
|
|
4186
|
+
length: 'number',
|
|
3902
4187
|
'@@toStringTag': 'string'},
|
|
3903
4188
|
|
|
3904
4189
|
|
|
@@ -3964,12 +4249,12 @@ const whitelist= {
|
|
|
3964
4249
|
|
|
3965
4250
|
|
|
3966
4251
|
lockdown: fn,
|
|
3967
|
-
harden: fn,
|
|
4252
|
+
harden: { ...fn, isFake: 'boolean'},
|
|
3968
4253
|
|
|
3969
4254
|
'%InitialGetStackString%': fn};$h_once.whitelist(whitelist);
|
|
3970
4255
|
})
|
|
3971
4256
|
,
|
|
3972
|
-
// === functors[
|
|
4257
|
+
// === functors[18] ===
|
|
3973
4258
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,assign,create,defineProperty,entries,freeze,objectHasOwnProperty,unscopablesSymbol,makeEvalFunction,makeFunctionConstructor,constantProperties,universalPropertyNames;$h_imports([["./commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["assign", [$h_a => (assign = $h_a)]],["create", [$h_a => (create = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["unscopablesSymbol", [$h_a => (unscopablesSymbol = $h_a)]]]],["./make-eval-function.js", [["makeEvalFunction", [$h_a => (makeEvalFunction = $h_a)]]]],["./make-function-constructor.js", [["makeFunctionConstructor", [$h_a => (makeFunctionConstructor = $h_a)]]]],["./whitelist.js", [["constantProperties", [$h_a => (constantProperties = $h_a)]],["universalPropertyNames", [$h_a => (universalPropertyNames = $h_a)]]]]]);
|
|
3974
4259
|
|
|
3975
4260
|
|
|
@@ -4139,7 +4424,7 @@ const setGlobalObjectEvaluators= (
|
|
|
4139
4424
|
};$h_once.setGlobalObjectEvaluators(setGlobalObjectEvaluators);
|
|
4140
4425
|
})
|
|
4141
4426
|
,
|
|
4142
|
-
// === functors[
|
|
4427
|
+
// === functors[19] ===
|
|
4143
4428
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let ReferenceError,TypeError,Map,Set,arrayJoin,arrayMap,arrayPush,create,freeze,mapGet,mapHas,mapSet,setAdd,promiseCatch,promiseThen,values,weakmapGet,assert;$h_imports([["./commons.js", [["ReferenceError", [$h_a => (ReferenceError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["Map", [$h_a => (Map = $h_a)]],["Set", [$h_a => (Set = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["arrayPush", [$h_a => (arrayPush = $h_a)]],["create", [$h_a => (create = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["mapGet", [$h_a => (mapGet = $h_a)]],["mapHas", [$h_a => (mapHas = $h_a)]],["mapSet", [$h_a => (mapSet = $h_a)]],["setAdd", [$h_a => (setAdd = $h_a)]],["promiseCatch", [$h_a => (promiseCatch = $h_a)]],["promiseThen", [$h_a => (promiseThen = $h_a)]],["values", [$h_a => (values = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
4144
4429
|
|
|
4145
4430
|
|
|
@@ -4461,7 +4746,7 @@ const load= async(
|
|
|
4461
4746
|
|
|
4462
4747
|
/** @type {Set<Promise<undefined>>} */
|
|
4463
4748
|
const pendingJobs= new Set();
|
|
4464
|
-
/** @type {Map<object, Map<string, Promise<Record
|
|
4749
|
+
/** @type {Map<object, Map<string, Promise<Record<any, any>>>>} */
|
|
4465
4750
|
const moduleLoads= new Map();
|
|
4466
4751
|
/** @type {Array<Error>} */
|
|
4467
4752
|
const errors= [];
|
|
@@ -4505,7 +4790,7 @@ const load= async(
|
|
|
4505
4790
|
};$h_once.load(load);
|
|
4506
4791
|
})
|
|
4507
4792
|
,
|
|
4508
|
-
// === functors[
|
|
4793
|
+
// === functors[20] ===
|
|
4509
4794
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let makeAlias,Proxy,TypeError,create,freeze,mapGet,mapHas,mapSet,ownKeys,reflectGet,reflectGetOwnPropertyDescriptor,reflectHas,reflectIsExtensible,reflectPreventExtensions,weakmapSet,assert;$h_imports([["./module-load.js", [["makeAlias", [$h_a => (makeAlias = $h_a)]]]],["./commons.js", [["Proxy", [$h_a => (Proxy = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["create", [$h_a => (create = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["mapGet", [$h_a => (mapGet = $h_a)]],["mapHas", [$h_a => (mapHas = $h_a)]],["mapSet", [$h_a => (mapSet = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["reflectGet", [$h_a => (reflectGet = $h_a)]],["reflectGetOwnPropertyDescriptor", [$h_a => (reflectGetOwnPropertyDescriptor = $h_a)]],["reflectHas", [$h_a => (reflectHas = $h_a)]],["reflectIsExtensible", [$h_a => (reflectIsExtensible = $h_a)]],["reflectPreventExtensions", [$h_a => (reflectPreventExtensions = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
4510
4795
|
|
|
4511
4796
|
|
|
@@ -4680,7 +4965,7 @@ $h_once.deferExports(deferExports);const getDeferredExports=(
|
|
|
4680
4965
|
};$h_once.getDeferredExports(getDeferredExports);
|
|
4681
4966
|
})
|
|
4682
4967
|
,
|
|
4683
|
-
// === functors[
|
|
4968
|
+
// === functors[21] ===
|
|
4684
4969
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let assert,getDeferredExports,ReferenceError,SyntaxError,TypeError,arrayForEach,arrayIncludes,arrayPush,arraySome,arraySort,create,defineProperty,entries,freeze,isArray,keys,mapGet,weakmapGet,reflectHas,assign,compartmentEvaluate;$h_imports([["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]],["./module-proxy.js", [["getDeferredExports", [$h_a => (getDeferredExports = $h_a)]]]],["./commons.js", [["ReferenceError", [$h_a => (ReferenceError = $h_a)]],["SyntaxError", [$h_a => (SyntaxError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["arrayForEach", [$h_a => (arrayForEach = $h_a)]],["arrayIncludes", [$h_a => (arrayIncludes = $h_a)]],["arrayPush", [$h_a => (arrayPush = $h_a)]],["arraySome", [$h_a => (arraySome = $h_a)]],["arraySort", [$h_a => (arraySort = $h_a)]],["create", [$h_a => (create = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["isArray", [$h_a => (isArray = $h_a)]],["keys", [$h_a => (keys = $h_a)]],["mapGet", [$h_a => (mapGet = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["reflectHas", [$h_a => (reflectHas = $h_a)]],["assign", [$h_a => (assign = $h_a)]]]],["./compartment-evaluate.js", [["compartmentEvaluate", [$h_a => (compartmentEvaluate = $h_a)]]]]]);
|
|
4685
4970
|
|
|
4686
4971
|
|
|
@@ -4872,6 +5157,7 @@ $h_once.makeThirdPartyModuleInstance(makeThirdPartyModuleInstance);const make
|
|
|
4872
5157
|
// fixed binding state
|
|
4873
5158
|
let value;
|
|
4874
5159
|
let tdz= true;
|
|
5160
|
+
/** @type {null | Array<(value: any) => void>} */
|
|
4875
5161
|
let optUpdaters= [];
|
|
4876
5162
|
|
|
4877
5163
|
// tdz sensitive getter
|
|
@@ -4897,7 +5183,7 @@ $h_once.makeThirdPartyModuleInstance(makeThirdPartyModuleInstance);const make
|
|
|
4897
5183
|
const updaters= optUpdaters;
|
|
4898
5184
|
optUpdaters= null;
|
|
4899
5185
|
tdz= false;
|
|
4900
|
-
for( const updater of updaters) {
|
|
5186
|
+
for( const updater of updaters|| []) {
|
|
4901
5187
|
updater(initValue);
|
|
4902
5188
|
}
|
|
4903
5189
|
return initValue;
|
|
@@ -4911,7 +5197,7 @@ $h_once.makeThirdPartyModuleInstance(makeThirdPartyModuleInstance);const make
|
|
|
4911
5197
|
return;
|
|
4912
5198
|
}
|
|
4913
5199
|
if( tdz) {
|
|
4914
|
-
arrayPush(optUpdaters, updater);
|
|
5200
|
+
arrayPush(optUpdaters|| [], updater);
|
|
4915
5201
|
}else {
|
|
4916
5202
|
updater(value);
|
|
4917
5203
|
}
|
|
@@ -5174,7 +5460,7 @@ $h_once.makeThirdPartyModuleInstance(makeThirdPartyModuleInstance);const make
|
|
|
5174
5460
|
};$h_once.makeModuleInstance(makeModuleInstance);
|
|
5175
5461
|
})
|
|
5176
5462
|
,
|
|
5177
|
-
// === functors[
|
|
5463
|
+
// === functors[22] ===
|
|
5178
5464
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let assert,makeModuleInstance,makeThirdPartyModuleInstance,Map,ReferenceError,TypeError,entries,isArray,isObject,mapGet,mapHas,mapSet,weakmapGet;$h_imports([["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]],["./module-instance.js", [["makeModuleInstance", [$h_a => (makeModuleInstance = $h_a)]],["makeThirdPartyModuleInstance", [$h_a => (makeThirdPartyModuleInstance = $h_a)]]]],["./commons.js", [["Map", [$h_a => (Map = $h_a)]],["ReferenceError", [$h_a => (ReferenceError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["isArray", [$h_a => (isArray = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["mapGet", [$h_a => (mapGet = $h_a)]],["mapHas", [$h_a => (mapHas = $h_a)]],["mapSet", [$h_a => (mapSet = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]]]]]);
|
|
5179
5465
|
|
|
5180
5466
|
|
|
@@ -5354,7 +5640,7 @@ const instantiate= (
|
|
|
5354
5640
|
};$h_once.instantiate(instantiate);
|
|
5355
5641
|
})
|
|
5356
5642
|
,
|
|
5357
|
-
// === functors[
|
|
5643
|
+
// === functors[23] ===
|
|
5358
5644
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Map,ReferenceError,TypeError,WeakMap,assign,defineProperties,entries,promiseThen,weakmapGet,weakmapSet,setGlobalObjectSymbolUnscopables,setGlobalObjectConstantProperties,setGlobalObjectMutableProperties,setGlobalObjectEvaluators,sharedGlobalPropertyNames,load,link,getDeferredExports,assert,compartmentEvaluate,makeSafeEvaluator;$h_imports([["./commons.js", [["Map", [$h_a => (Map = $h_a)]],["ReferenceError", [$h_a => (ReferenceError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["WeakMap", [$h_a => (WeakMap = $h_a)]],["assign", [$h_a => (assign = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["promiseThen", [$h_a => (promiseThen = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]]]],["./global-object.js", [["setGlobalObjectSymbolUnscopables", [$h_a => (setGlobalObjectSymbolUnscopables = $h_a)]],["setGlobalObjectConstantProperties", [$h_a => (setGlobalObjectConstantProperties = $h_a)]],["setGlobalObjectMutableProperties", [$h_a => (setGlobalObjectMutableProperties = $h_a)]],["setGlobalObjectEvaluators", [$h_a => (setGlobalObjectEvaluators = $h_a)]]]],["./whitelist.js", [["sharedGlobalPropertyNames", [$h_a => (sharedGlobalPropertyNames = $h_a)]]]],["./module-load.js", [["load", [$h_a => (load = $h_a)]]]],["./module-link.js", [["link", [$h_a => (link = $h_a)]]]],["./module-proxy.js", [["getDeferredExports", [$h_a => (getDeferredExports = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]],["./compartment-evaluate.js", [["compartmentEvaluate", [$h_a => (compartmentEvaluate = $h_a)]]]],["./make-safe-evaluator.js", [["makeSafeEvaluator", [$h_a => (makeSafeEvaluator = $h_a)]]]]]);
|
|
5359
5645
|
|
|
5360
5646
|
|
|
@@ -5398,10 +5684,6 @@ const moduleAliases= new WeakMap();
|
|
|
5398
5684
|
// privateFields captures the private state for each compartment.
|
|
5399
5685
|
const privateFields= new WeakMap();
|
|
5400
5686
|
|
|
5401
|
-
/**
|
|
5402
|
-
* @typedef {(source: string) => string} Transform
|
|
5403
|
-
*/
|
|
5404
|
-
|
|
5405
5687
|
// Compartments do not need an importHook or resolveHook to be useful
|
|
5406
5688
|
// as a vessel for evaluating programs.
|
|
5407
5689
|
// However, any method that operates the module system will throw an exception
|
|
@@ -5454,7 +5736,7 @@ const CompartmentPrototype= {
|
|
|
5454
5736
|
/**
|
|
5455
5737
|
* @param {string} source is a JavaScript program grammar construction.
|
|
5456
5738
|
* @param {object} [options]
|
|
5457
|
-
* @param {Array<Transform>} [options.transforms]
|
|
5739
|
+
* @param {Array<import('./lockdown-shim').Transform>} [options.transforms]
|
|
5458
5740
|
* @param {boolean} [options.sloppyGlobalsMode]
|
|
5459
5741
|
* @param {object} [options.__moduleShimLexicals__]
|
|
5460
5742
|
* @param {boolean} [options.__evadeHtmlCommentTest__]
|
|
@@ -5653,8 +5935,9 @@ const makeCompartmentConstructor= (
|
|
|
5653
5935
|
};$h_once.makeCompartmentConstructor(makeCompartmentConstructor);
|
|
5654
5936
|
})
|
|
5655
5937
|
,
|
|
5656
|
-
// === functors[
|
|
5657
|
-
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,WeakSet,arrayFilter,defineProperty,entries,freeze,getOwnPropertyDescriptor,getOwnPropertyDescriptors,globalThis,is,isObject,objectHasOwnProperty,values,weaksetHas,constantProperties,sharedGlobalPropertyNames,universalPropertyNames,whitelist;$h_imports([["./commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["WeakSet", [$h_a => (WeakSet = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["is", [$h_a => (is = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["values", [$h_a => (values = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]],["./whitelist.js", [["constantProperties", [$h_a => (constantProperties = $h_a)]],["sharedGlobalPropertyNames", [$h_a => (sharedGlobalPropertyNames = $h_a)]],["universalPropertyNames", [$h_a => (universalPropertyNames = $h_a)]],["whitelist", [$h_a => (whitelist = $h_a)]]]]]);
|
|
5938
|
+
// === functors[24] ===
|
|
5939
|
+
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,WeakSet,arrayFilter,create,defineProperty,entries,freeze,getOwnPropertyDescriptor,getOwnPropertyDescriptors,globalThis,is,isObject,objectHasOwnProperty,values,weaksetHas,constantProperties,sharedGlobalPropertyNames,universalPropertyNames,whitelist;$h_imports([["./commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["WeakSet", [$h_a => (WeakSet = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["create", [$h_a => (create = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["is", [$h_a => (is = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["values", [$h_a => (values = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]],["./whitelist.js", [["constantProperties", [$h_a => (constantProperties = $h_a)]],["sharedGlobalPropertyNames", [$h_a => (sharedGlobalPropertyNames = $h_a)]],["universalPropertyNames", [$h_a => (universalPropertyNames = $h_a)]],["whitelist", [$h_a => (whitelist = $h_a)]]]]]);
|
|
5940
|
+
|
|
5658
5941
|
|
|
5659
5942
|
|
|
5660
5943
|
|
|
@@ -5690,6 +5973,7 @@ function initProperty(obj, name, desc) {
|
|
|
5690
5973
|
if( objectHasOwnProperty(obj, name)) {
|
|
5691
5974
|
const preDesc= getOwnPropertyDescriptor(obj, name);
|
|
5692
5975
|
if(
|
|
5976
|
+
!preDesc||
|
|
5693
5977
|
!is(preDesc.value, desc.value)||
|
|
5694
5978
|
preDesc.get!== desc.get||
|
|
5695
5979
|
preDesc.set!== desc.set||
|
|
@@ -5726,7 +6010,8 @@ function sampleGlobals(globalObject, newPropertyNames) {
|
|
|
5726
6010
|
}
|
|
5727
6011
|
|
|
5728
6012
|
const makeIntrinsicsCollector= ()=> {
|
|
5729
|
-
|
|
6013
|
+
/** @type {Record<any, any>} */
|
|
6014
|
+
const intrinsics= create(null);
|
|
5730
6015
|
let pseudoNatives;
|
|
5731
6016
|
|
|
5732
6017
|
const addIntrinsics= (newIntrinsics)=>{
|
|
@@ -5827,7 +6112,7 @@ const getGlobalIntrinsics= (globalObject)=>{
|
|
|
5827
6112
|
};$h_once.getGlobalIntrinsics(getGlobalIntrinsics);
|
|
5828
6113
|
})
|
|
5829
6114
|
,
|
|
5830
|
-
// === functors[
|
|
6115
|
+
// === functors[25] ===
|
|
5831
6116
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { $h_imports([]); /**
|
|
5832
6117
|
* @file Exports {@code enablements}, a recursively defined
|
|
5833
6118
|
* JSON record defining the optimum set of intrinsics properties
|
|
@@ -5871,7 +6156,7 @@ const getGlobalIntrinsics= (globalObject)=>{
|
|
|
5871
6156
|
* <ul>
|
|
5872
6157
|
* <li>true, in which case this property is simply repaired. The
|
|
5873
6158
|
* value associated with that property is not traversed. For
|
|
5874
|
-
*
|
|
6159
|
+
* example, {@code "Function.prototype.name"} leads to true,
|
|
5875
6160
|
* meaning that the {@code "name"} property of {@code
|
|
5876
6161
|
* "Function.prototype"} should be repaired (which is needed
|
|
5877
6162
|
* when inheriting from @code{Function} and setting the subclass's
|
|
@@ -6050,7 +6335,7 @@ const severeEnablements= {
|
|
|
6050
6335
|
'%SetPrototype%': '*'};$h_once.severeEnablements(severeEnablements);
|
|
6051
6336
|
})
|
|
6052
6337
|
,
|
|
6053
|
-
// === functors[
|
|
6338
|
+
// === functors[26] ===
|
|
6054
6339
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Set,String,TypeError,arrayForEach,defineProperty,getOwnPropertyDescriptor,getOwnPropertyDescriptors,getOwnPropertyNames,isObject,objectHasOwnProperty,ownKeys,setHas,minEnablements,moderateEnablements,severeEnablements;$h_imports([["./commons.js", [["Set", [$h_a => (Set = $h_a)]],["String", [$h_a => (String = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["arrayForEach", [$h_a => (arrayForEach = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["getOwnPropertyNames", [$h_a => (getOwnPropertyNames = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["setHas", [$h_a => (setHas = $h_a)]]]],["./enablements.js", [["minEnablements", [$h_a => (minEnablements = $h_a)]],["moderateEnablements", [$h_a => (moderateEnablements = $h_a)]],["severeEnablements", [$h_a => (severeEnablements = $h_a)]]]]]);
|
|
6055
6340
|
|
|
6056
6341
|
|
|
@@ -6257,7 +6542,7 @@ function enablePropertyOverrides(
|
|
|
6257
6542
|
}$h_once.default( enablePropertyOverrides);
|
|
6258
6543
|
})
|
|
6259
6544
|
,
|
|
6260
|
-
// === functors[
|
|
6545
|
+
// === functors[27] ===
|
|
6261
6546
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let arrayPush,freeze,assert;$h_imports([["./commons.js", [["arrayPush", [$h_a => (arrayPush = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
6262
6547
|
|
|
6263
6548
|
|
|
@@ -6377,7 +6662,7 @@ const makeEnvironmentCaptor= (aGlobal)=>{
|
|
|
6377
6662
|
freeze(makeEnvironmentCaptor);
|
|
6378
6663
|
})
|
|
6379
6664
|
,
|
|
6380
|
-
// === functors[
|
|
6665
|
+
// === functors[28] ===
|
|
6381
6666
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let WeakSet,arrayFilter,arrayMap,arrayPush,defineProperty,freeze,fromEntries,isError,stringEndsWith,weaksetAdd,weaksetHas;$h_imports([["../commons.js", [["WeakSet", [$h_a => (WeakSet = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["arrayPush", [$h_a => (arrayPush = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["fromEntries", [$h_a => (fromEntries = $h_a)]],["isError", [$h_a => (isError = $h_a)]],["stringEndsWith", [$h_a => (stringEndsWith = $h_a)]],["weaksetAdd", [$h_a => (weaksetAdd = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]],["./types.js", []],["./internal-types.js", []]]);
|
|
6382
6667
|
|
|
6383
6668
|
|
|
@@ -6759,7 +7044,7 @@ const filterConsole= (baseConsole, filter, _topic= undefined)=> {
|
|
|
6759
7044
|
freeze(filterConsole);
|
|
6760
7045
|
})
|
|
6761
7046
|
,
|
|
6762
|
-
// === functors[
|
|
7047
|
+
// === functors[29] ===
|
|
6763
7048
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FinalizationRegistry,Map,mapGet,mapDelete,WeakMap,mapSet,finalizationRegistryRegister,weakmapSet,weakmapGet,mapEntries,mapHas;$h_imports([["../commons.js", [["FinalizationRegistry", [$h_a => (FinalizationRegistry = $h_a)]],["Map", [$h_a => (Map = $h_a)]],["mapGet", [$h_a => (mapGet = $h_a)]],["mapDelete", [$h_a => (mapDelete = $h_a)]],["WeakMap", [$h_a => (WeakMap = $h_a)]],["mapSet", [$h_a => (mapSet = $h_a)]],["finalizationRegistryRegister", [$h_a => (finalizationRegistryRegister = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["mapEntries", [$h_a => (mapEntries = $h_a)]],["mapHas", [$h_a => (mapHas = $h_a)]]]]]);
|
|
6764
7049
|
|
|
6765
7050
|
|
|
@@ -6884,7 +7169,7 @@ const makeRejectionHandlers= (reportReason)=>{
|
|
|
6884
7169
|
};$h_once.makeRejectionHandlers(makeRejectionHandlers);
|
|
6885
7170
|
})
|
|
6886
7171
|
,
|
|
6887
|
-
// === functors[
|
|
7172
|
+
// === functors[30] ===
|
|
6888
7173
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,globalThis,defaultHandler,makeCausalConsole,makeRejectionHandlers;$h_imports([["../commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]]]],["./assert.js", [["loggedErrorHandler", [$h_a => (defaultHandler = $h_a)]]]],["./console.js", [["makeCausalConsole", [$h_a => (makeCausalConsole = $h_a)]]]],["./unhandled-rejection.js", [["makeRejectionHandlers", [$h_a => (makeRejectionHandlers = $h_a)]]]],["./types.js", []],["./internal-types.js", []]]);
|
|
6889
7174
|
|
|
6890
7175
|
|
|
@@ -7027,7 +7312,7 @@ const tameConsole= (
|
|
|
7027
7312
|
};$h_once.tameConsole(tameConsole);
|
|
7028
7313
|
})
|
|
7029
7314
|
,
|
|
7030
|
-
// === functors[
|
|
7315
|
+
// === functors[31] ===
|
|
7031
7316
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let WeakMap,WeakSet,apply,arrayFilter,arrayJoin,arrayMap,arraySlice,create,defineProperties,fromEntries,reflectSet,regexpExec,regexpTest,weakmapGet,weakmapSet,weaksetAdd,weaksetHas;$h_imports([["../commons.js", [["WeakMap", [$h_a => (WeakMap = $h_a)]],["WeakSet", [$h_a => (WeakSet = $h_a)]],["apply", [$h_a => (apply = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["arrayJoin", [$h_a => (arrayJoin = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["arraySlice", [$h_a => (arraySlice = $h_a)]],["create", [$h_a => (create = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["fromEntries", [$h_a => (fromEntries = $h_a)]],["reflectSet", [$h_a => (reflectSet = $h_a)]],["regexpExec", [$h_a => (regexpExec = $h_a)]],["regexpTest", [$h_a => (regexpTest = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]],["weaksetAdd", [$h_a => (weaksetAdd = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]]]);
|
|
7032
7317
|
|
|
7033
7318
|
|
|
@@ -7237,7 +7522,7 @@ const tameV8ErrorConstructor= (
|
|
|
7237
7522
|
// Mapping from error instance to the stack for that instance.
|
|
7238
7523
|
// The stack info is either the structured stack trace
|
|
7239
7524
|
// or the generated tamed stack string
|
|
7240
|
-
/** @type {WeakMap<Error, ParsedStackInfo | StructuredStackInfo} */
|
|
7525
|
+
/** @type {WeakMap<Error, ParsedStackInfo | StructuredStackInfo>} */
|
|
7241
7526
|
const stackInfos= new WeakMap();
|
|
7242
7527
|
|
|
7243
7528
|
// Use concise methods to obtain named functions without constructors.
|
|
@@ -7367,7 +7652,7 @@ const tameV8ErrorConstructor= (
|
|
|
7367
7652
|
};$h_once.tameV8ErrorConstructor(tameV8ErrorConstructor);
|
|
7368
7653
|
})
|
|
7369
7654
|
,
|
|
7370
|
-
// === functors[
|
|
7655
|
+
// === functors[32] ===
|
|
7371
7656
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_ERROR,TypeError,apply,construct,defineProperties,setPrototypeOf,getOwnPropertyDescriptor,defineProperty,NativeErrors,tameV8ErrorConstructor;$h_imports([["../commons.js", [["FERAL_ERROR", [$h_a => (FERAL_ERROR = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["apply", [$h_a => (apply = $h_a)]],["construct", [$h_a => (construct = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["setPrototypeOf", [$h_a => (setPrototypeOf = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]]]],["../whitelist.js", [["NativeErrors", [$h_a => (NativeErrors = $h_a)]]]],["./tame-v8-error-constructor.js", [["tameV8ErrorConstructor", [$h_a => (tameV8ErrorConstructor = $h_a)]]]]]);
|
|
7372
7657
|
|
|
7373
7658
|
|
|
@@ -7621,7 +7906,7 @@ function tameErrorConstructor(
|
|
|
7621
7906
|
}$h_once.default( tameErrorConstructor);
|
|
7622
7907
|
})
|
|
7623
7908
|
,
|
|
7624
|
-
// === functors[
|
|
7909
|
+
// === functors[33] ===
|
|
7625
7910
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_FUNCTION,Float32Array,Map,Set,String,getOwnPropertyDescriptor,getPrototypeOf,iterateArray,iterateMap,iterateSet,iterateString,matchAllRegExp,matchAllSymbol,regexpPrototype,InertCompartment;$h_imports([["./commons.js", [["FERAL_FUNCTION", [$h_a => (FERAL_FUNCTION = $h_a)]],["Float32Array", [$h_a => (Float32Array = $h_a)]],["Map", [$h_a => (Map = $h_a)]],["Set", [$h_a => (Set = $h_a)]],["String", [$h_a => (String = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getPrototypeOf", [$h_a => (getPrototypeOf = $h_a)]],["iterateArray", [$h_a => (iterateArray = $h_a)]],["iterateMap", [$h_a => (iterateMap = $h_a)]],["iterateSet", [$h_a => (iterateSet = $h_a)]],["iterateString", [$h_a => (iterateString = $h_a)]],["matchAllRegExp", [$h_a => (matchAllRegExp = $h_a)]],["matchAllSymbol", [$h_a => (matchAllSymbol = $h_a)]],["regexpPrototype", [$h_a => (regexpPrototype = $h_a)]]]],["./compartment-shim.js", [["InertCompartment", [$h_a => (InertCompartment = $h_a)]]]]]);
|
|
7626
7911
|
|
|
7627
7912
|
|
|
@@ -7669,10 +7954,8 @@ const getAnonymousIntrinsics= ()=> {
|
|
|
7669
7954
|
|
|
7670
7955
|
// 9.2.4.1 %ThrowTypeError%
|
|
7671
7956
|
|
|
7672
|
-
const
|
|
7673
|
-
|
|
7674
|
-
'callee').
|
|
7675
|
-
get;
|
|
7957
|
+
const argsCalleeDesc= getOwnPropertyDescriptor(makeArguments(), 'callee');
|
|
7958
|
+
const ThrowTypeError= argsCalleeDesc&& argsCalleeDesc.get;
|
|
7676
7959
|
|
|
7677
7960
|
// 21.1.5.2 The %StringIteratorPrototype% Object
|
|
7678
7961
|
|
|
@@ -7764,8 +8047,9 @@ const getAnonymousIntrinsics= ()=> {
|
|
|
7764
8047
|
};$h_once.getAnonymousIntrinsics(getAnonymousIntrinsics);
|
|
7765
8048
|
})
|
|
7766
8049
|
,
|
|
7767
|
-
// === functors[
|
|
7768
|
-
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Set,String,TypeError,WeakMap,WeakSet,apply,arrayForEach,defineProperty,freeze,getOwnPropertyDescriptor,getOwnPropertyDescriptors,getPrototypeOf,isInteger,isObject,objectHasOwnProperty,ownKeys,preventExtensions,setAdd,setForEach,setHas,toStringTagSymbol,typedArrayPrototype,weakmapGet,weakmapSet,weaksetAdd,weaksetHas,assert;$h_imports([["./commons.js", [["Set", [$h_a => (Set = $h_a)]],["String", [$h_a => (String = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["WeakMap", [$h_a => (WeakMap = $h_a)]],["WeakSet", [$h_a => (WeakSet = $h_a)]],["apply", [$h_a => (apply = $h_a)]],["arrayForEach", [$h_a => (arrayForEach = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["getPrototypeOf", [$h_a => (getPrototypeOf = $h_a)]],["isInteger", [$h_a => (isInteger = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["preventExtensions", [$h_a => (preventExtensions = $h_a)]],["setAdd", [$h_a => (setAdd = $h_a)]],["setForEach", [$h_a => (setForEach = $h_a)]],["setHas", [$h_a => (setHas = $h_a)]],["toStringTagSymbol", [$h_a => (toStringTagSymbol = $h_a)]],["typedArrayPrototype", [$h_a => (typedArrayPrototype = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]],["weaksetAdd", [$h_a => (weaksetAdd = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
8050
|
+
// === functors[34] ===
|
|
8051
|
+
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Set,String,TypeError,WeakMap,WeakSet,globalThis,apply,arrayForEach,defineProperty,freeze,getOwnPropertyDescriptor,getOwnPropertyDescriptors,getPrototypeOf,isInteger,isObject,objectHasOwnProperty,ownKeys,preventExtensions,setAdd,setForEach,setHas,toStringTagSymbol,typedArrayPrototype,weakmapGet,weakmapSet,weaksetAdd,weaksetHas,assert;$h_imports([["./commons.js", [["Set", [$h_a => (Set = $h_a)]],["String", [$h_a => (String = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["WeakMap", [$h_a => (WeakMap = $h_a)]],["WeakSet", [$h_a => (WeakSet = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["apply", [$h_a => (apply = $h_a)]],["arrayForEach", [$h_a => (arrayForEach = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["getPrototypeOf", [$h_a => (getPrototypeOf = $h_a)]],["isInteger", [$h_a => (isInteger = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["preventExtensions", [$h_a => (preventExtensions = $h_a)]],["setAdd", [$h_a => (setAdd = $h_a)]],["setForEach", [$h_a => (setForEach = $h_a)]],["setHas", [$h_a => (setHas = $h_a)]],["toStringTagSymbol", [$h_a => (toStringTagSymbol = $h_a)]],["typedArrayPrototype", [$h_a => (typedArrayPrototype = $h_a)]],["weakmapGet", [$h_a => (weakmapGet = $h_a)]],["weakmapSet", [$h_a => (weakmapSet = $h_a)]],["weaksetAdd", [$h_a => (weaksetAdd = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
8052
|
+
|
|
7769
8053
|
|
|
7770
8054
|
|
|
7771
8055
|
|
|
@@ -7894,6 +8178,12 @@ const freezeTypedArray= (array)=>{
|
|
|
7894
8178
|
* @returns {Harden}
|
|
7895
8179
|
*/
|
|
7896
8180
|
const makeHardener= ()=> {
|
|
8181
|
+
// Use a native hardener if possible.
|
|
8182
|
+
if( typeof globalThis.harden=== 'function') {
|
|
8183
|
+
const safeHarden= globalThis.harden;
|
|
8184
|
+
return safeHarden;
|
|
8185
|
+
}
|
|
8186
|
+
|
|
7897
8187
|
const hardened= new WeakSet();
|
|
7898
8188
|
|
|
7899
8189
|
const { harden}= {
|
|
@@ -8007,7 +8297,7 @@ const makeHardener= ()=> {
|
|
|
8007
8297
|
};$h_once.makeHardener(makeHardener);
|
|
8008
8298
|
})
|
|
8009
8299
|
,
|
|
8010
|
-
// === functors[
|
|
8300
|
+
// === functors[35] ===
|
|
8011
8301
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Date,TypeError,apply,construct,defineProperties;$h_imports([["./commons.js", [["Date", [$h_a => (Date = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["apply", [$h_a => (apply = $h_a)]],["construct", [$h_a => (construct = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]]]]]);
|
|
8012
8302
|
|
|
8013
8303
|
|
|
@@ -8124,7 +8414,7 @@ function tameDateConstructor(dateTaming= 'safe') {
|
|
|
8124
8414
|
}$h_once.default( tameDateConstructor);
|
|
8125
8415
|
})
|
|
8126
8416
|
,
|
|
8127
|
-
// === functors[
|
|
8417
|
+
// === functors[36] ===
|
|
8128
8418
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,globalThis,getOwnPropertyDescriptor,defineProperty;$h_imports([["./commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]]]]]);Object.defineProperty(tameDomains, 'name', {value: "tameDomains"});$h_once.tameDomains(tameDomains);
|
|
8129
8419
|
|
|
8130
8420
|
|
|
@@ -8174,7 +8464,7 @@ function tameDomains(domainTaming= 'safe') {
|
|
|
8174
8464
|
}
|
|
8175
8465
|
})
|
|
8176
8466
|
,
|
|
8177
|
-
// === functors[
|
|
8467
|
+
// === functors[37] ===
|
|
8178
8468
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_FUNCTION,SyntaxError,TypeError,defineProperties,getPrototypeOf,setPrototypeOf,freeze;$h_imports([["./commons.js", [["FERAL_FUNCTION", [$h_a => (FERAL_FUNCTION = $h_a)]],["SyntaxError", [$h_a => (SyntaxError = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["getPrototypeOf", [$h_a => (getPrototypeOf = $h_a)]],["setPrototypeOf", [$h_a => (setPrototypeOf = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]]]]]);
|
|
8179
8469
|
|
|
8180
8470
|
|
|
@@ -8313,7 +8603,7 @@ function tameFunctionConstructors() {
|
|
|
8313
8603
|
}$h_once.default( tameFunctionConstructors);
|
|
8314
8604
|
})
|
|
8315
8605
|
,
|
|
8316
|
-
// === functors[
|
|
8606
|
+
// === functors[38] ===
|
|
8317
8607
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let WeakSet,defineProperty,freeze,functionPrototype,functionToString,stringEndsWith,weaksetAdd,weaksetHas;$h_imports([["./commons.js", [["WeakSet", [$h_a => (WeakSet = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]],["functionPrototype", [$h_a => (functionPrototype = $h_a)]],["functionToString", [$h_a => (functionToString = $h_a)]],["stringEndsWith", [$h_a => (stringEndsWith = $h_a)]],["weaksetAdd", [$h_a => (weaksetAdd = $h_a)]],["weaksetHas", [$h_a => (weaksetHas = $h_a)]]]]]);
|
|
8318
8608
|
|
|
8319
8609
|
|
|
@@ -8343,7 +8633,7 @@ const tameFunctionToString= ()=> {
|
|
|
8343
8633
|
|
|
8344
8634
|
const tamingMethods= {
|
|
8345
8635
|
toString() {
|
|
8346
|
-
const str= functionToString(this
|
|
8636
|
+
const str= functionToString(this);
|
|
8347
8637
|
if(
|
|
8348
8638
|
stringEndsWith(str, nativeSuffix)||
|
|
8349
8639
|
!weaksetHas(virtualizedNativeFunctions, this))
|
|
@@ -8366,7 +8656,39 @@ const tameFunctionToString= ()=> {
|
|
|
8366
8656
|
};$h_once.tameFunctionToString(tameFunctionToString);
|
|
8367
8657
|
})
|
|
8368
8658
|
,
|
|
8369
|
-
// === functors[
|
|
8659
|
+
// === functors[39] ===
|
|
8660
|
+
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let TypeError,freeze;$h_imports([["./commons.js", [["TypeError", [$h_a => (TypeError = $h_a)]],["freeze", [$h_a => (freeze = $h_a)]]]]]);
|
|
8661
|
+
|
|
8662
|
+
|
|
8663
|
+
const tameHarden= (safeHarden, hardenTaming)=> {
|
|
8664
|
+
if( hardenTaming!== 'safe'&& hardenTaming!== 'unsafe') {
|
|
8665
|
+
throw new TypeError( `unrecognized fakeHardenOption ${hardenTaming}`);
|
|
8666
|
+
}
|
|
8667
|
+
|
|
8668
|
+
if( hardenTaming=== 'safe') {
|
|
8669
|
+
return safeHarden;
|
|
8670
|
+
}
|
|
8671
|
+
|
|
8672
|
+
// In on the joke
|
|
8673
|
+
Object.isExtensible= ()=> false;
|
|
8674
|
+
Object.isFrozen= ()=> true;
|
|
8675
|
+
Object.isSealed= ()=> true;
|
|
8676
|
+
Reflect.isExtensible= ()=> false;
|
|
8677
|
+
|
|
8678
|
+
if( safeHarden.isFake) {
|
|
8679
|
+
// The "safe" hardener is already a fake hardener.
|
|
8680
|
+
// Just use it.
|
|
8681
|
+
return safeHarden;
|
|
8682
|
+
}
|
|
8683
|
+
|
|
8684
|
+
const fakeHarden= (arg)=>arg;
|
|
8685
|
+
fakeHarden.isFake= true;
|
|
8686
|
+
return freeze(fakeHarden);
|
|
8687
|
+
};$h_once.tameHarden(tameHarden);
|
|
8688
|
+
freeze(tameHarden);
|
|
8689
|
+
})
|
|
8690
|
+
,
|
|
8691
|
+
// === functors[40] ===
|
|
8370
8692
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Number,String,TypeError,defineProperty,getOwnPropertyNames,isObject,regexpExec,assert;$h_imports([["./commons.js", [["Number", [$h_a => (Number = $h_a)]],["String", [$h_a => (String = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["defineProperty", [$h_a => (defineProperty = $h_a)]],["getOwnPropertyNames", [$h_a => (getOwnPropertyNames = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["regexpExec", [$h_a => (regexpExec = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
8371
8693
|
|
|
8372
8694
|
|
|
@@ -8450,7 +8772,7 @@ function tameLocaleMethods(intrinsics, localeTaming= 'safe') {
|
|
|
8450
8772
|
}$h_once.default( tameLocaleMethods);
|
|
8451
8773
|
})
|
|
8452
8774
|
,
|
|
8453
|
-
// === functors[
|
|
8775
|
+
// === functors[41] ===
|
|
8454
8776
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let Math,TypeError,create,getOwnPropertyDescriptors,objectPrototype;$h_imports([["./commons.js", [["Math", [$h_a => (Math = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["create", [$h_a => (create = $h_a)]],["getOwnPropertyDescriptors", [$h_a => (getOwnPropertyDescriptors = $h_a)]],["objectPrototype", [$h_a => (objectPrototype = $h_a)]]]]]);
|
|
8455
8777
|
|
|
8456
8778
|
|
|
@@ -8478,7 +8800,7 @@ function tameMathObject(mathTaming= 'safe') {
|
|
|
8478
8800
|
}$h_once.default( tameMathObject);
|
|
8479
8801
|
})
|
|
8480
8802
|
,
|
|
8481
|
-
// === functors[
|
|
8803
|
+
// === functors[42] ===
|
|
8482
8804
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_REG_EXP,TypeError,construct,defineProperties,getOwnPropertyDescriptor,speciesSymbol;$h_imports([["./commons.js", [["FERAL_REG_EXP", [$h_a => (FERAL_REG_EXP = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["construct", [$h_a => (construct = $h_a)]],["defineProperties", [$h_a => (defineProperties = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["speciesSymbol", [$h_a => (speciesSymbol = $h_a)]]]]]);
|
|
8483
8805
|
|
|
8484
8806
|
|
|
@@ -8496,6 +8818,9 @@ function tameRegExpConstructor(regExpTaming= 'safe') {
|
|
|
8496
8818
|
|
|
8497
8819
|
const makeRegExpConstructor= (_= {})=> {
|
|
8498
8820
|
// RegExp has non-writable static properties we need to omit.
|
|
8821
|
+
/**
|
|
8822
|
+
* @param {Parameters<typeof FERAL_REG_EXP>} rest
|
|
8823
|
+
*/
|
|
8499
8824
|
const ResultRegExp= function RegExp(...rest) {
|
|
8500
8825
|
if( new.target=== undefined) {
|
|
8501
8826
|
return FERAL_REG_EXP(...rest);
|
|
@@ -8503,6 +8828,11 @@ function tameRegExpConstructor(regExpTaming= 'safe') {
|
|
|
8503
8828
|
return construct(FERAL_REG_EXP, rest, new.target);
|
|
8504
8829
|
};
|
|
8505
8830
|
|
|
8831
|
+
const speciesDesc= getOwnPropertyDescriptor(FERAL_REG_EXP, speciesSymbol);
|
|
8832
|
+
if( !speciesDesc) {
|
|
8833
|
+
throw new TypeError('no RegExp[Symbol.species] descriptor');
|
|
8834
|
+
}
|
|
8835
|
+
|
|
8506
8836
|
defineProperties(ResultRegExp, {
|
|
8507
8837
|
length: { value: 2},
|
|
8508
8838
|
prototype: {
|
|
@@ -8511,7 +8841,7 @@ function tameRegExpConstructor(regExpTaming= 'safe') {
|
|
|
8511
8841
|
enumerable: false,
|
|
8512
8842
|
configurable: false},
|
|
8513
8843
|
|
|
8514
|
-
[speciesSymbol]:
|
|
8844
|
+
[speciesSymbol]: speciesDesc});
|
|
8515
8845
|
|
|
8516
8846
|
return ResultRegExp;
|
|
8517
8847
|
};
|
|
@@ -8520,6 +8850,7 @@ function tameRegExpConstructor(regExpTaming= 'safe') {
|
|
|
8520
8850
|
const SharedRegExp= makeRegExpConstructor();
|
|
8521
8851
|
|
|
8522
8852
|
if( regExpTaming!== 'unsafe') {
|
|
8853
|
+
// @ts-expect-error Deleted properties must be optional
|
|
8523
8854
|
delete RegExpPrototype.compile;
|
|
8524
8855
|
}
|
|
8525
8856
|
defineProperties(RegExpPrototype, {
|
|
@@ -8533,7 +8864,7 @@ function tameRegExpConstructor(regExpTaming= 'safe') {
|
|
|
8533
8864
|
}$h_once.default( tameRegExpConstructor);
|
|
8534
8865
|
})
|
|
8535
8866
|
,
|
|
8536
|
-
// === functors[
|
|
8867
|
+
// === functors[43] ===
|
|
8537
8868
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let whitelist,FunctionInstance,isAccessorPermit,Map,String,TypeError,arrayFilter,arrayIncludes,arrayMap,entries,getOwnPropertyDescriptor,getPrototypeOf,isObject,mapGet,objectHasOwnProperty,ownKeys,symbolKeyFor;$h_imports([["./whitelist.js", [["whitelist", [$h_a => (whitelist = $h_a)]],["FunctionInstance", [$h_a => (FunctionInstance = $h_a)]],["isAccessorPermit", [$h_a => (isAccessorPermit = $h_a)]]]],["./commons.js", [["Map", [$h_a => (Map = $h_a)]],["String", [$h_a => (String = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["arrayIncludes", [$h_a => (arrayIncludes = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["entries", [$h_a => (entries = $h_a)]],["getOwnPropertyDescriptor", [$h_a => (getOwnPropertyDescriptor = $h_a)]],["getPrototypeOf", [$h_a => (getPrototypeOf = $h_a)]],["isObject", [$h_a => (isObject = $h_a)]],["mapGet", [$h_a => (mapGet = $h_a)]],["objectHasOwnProperty", [$h_a => (objectHasOwnProperty = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["symbolKeyFor", [$h_a => (symbolKeyFor = $h_a)]]]]]);
|
|
8538
8869
|
|
|
8539
8870
|
|
|
@@ -8748,6 +9079,9 @@ function whitelistIntrinsics(
|
|
|
8748
9079
|
*/
|
|
8749
9080
|
function isAllowedProperty(path, obj, prop, permit) {
|
|
8750
9081
|
const desc= getOwnPropertyDescriptor(obj, prop);
|
|
9082
|
+
if( !desc) {
|
|
9083
|
+
throw new TypeError( `Property ${prop} not found at ${path}`);
|
|
9084
|
+
}
|
|
8751
9085
|
|
|
8752
9086
|
// Is this a value property?
|
|
8753
9087
|
if( objectHasOwnProperty(desc, 'value')) {
|
|
@@ -8848,8 +9182,9 @@ function whitelistIntrinsics(
|
|
|
8848
9182
|
}$h_once.default( whitelistIntrinsics);
|
|
8849
9183
|
})
|
|
8850
9184
|
,
|
|
8851
|
-
// === functors[
|
|
8852
|
-
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_FUNCTION,FERAL_EVAL,TypeError,arrayFilter,arrayMap,globalThis,is,ownKeys,stringSplit,noEvalEvaluate,enJoin,makeHardener,makeIntrinsicsCollector,whitelistIntrinsics,tameFunctionConstructors,tameDateConstructor,tameMathObject,tameRegExpConstructor,enablePropertyOverrides,tameLocaleMethods,setGlobalObjectConstantProperties,setGlobalObjectMutableProperties,setGlobalObjectEvaluators,makeSafeEvaluator,initialGlobalPropertyNames,tameFunctionToString,tameDomains,tameConsole,tameErrorConstructor,assert,makeAssert,makeEnvironmentCaptor,getAnonymousIntrinsics,makeCompartmentConstructor;$h_imports([["./commons.js", [["FERAL_FUNCTION", [$h_a => (FERAL_FUNCTION = $h_a)]],["FERAL_EVAL", [$h_a => (FERAL_EVAL = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["is", [$h_a => (is = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["stringSplit", [$h_a => (stringSplit = $h_a)]],["noEvalEvaluate", [$h_a => (noEvalEvaluate = $h_a)]]]],["./error/stringify-utils.js", [["enJoin", [$h_a => (enJoin = $h_a)]]]],["./make-hardener.js", [["makeHardener", [$h_a => (makeHardener = $h_a)]]]],["./intrinsics.js", [["makeIntrinsicsCollector", [$h_a => (makeIntrinsicsCollector = $h_a)]]]],["./whitelist-intrinsics.js", [["default", [$h_a => (whitelistIntrinsics = $h_a)]]]],["./tame-function-constructors.js", [["default", [$h_a => (tameFunctionConstructors = $h_a)]]]],["./tame-date-constructor.js", [["default", [$h_a => (tameDateConstructor = $h_a)]]]],["./tame-math-object.js", [["default", [$h_a => (tameMathObject = $h_a)]]]],["./tame-regexp-constructor.js", [["default", [$h_a => (tameRegExpConstructor = $h_a)]]]],["./enable-property-overrides.js", [["default", [$h_a => (enablePropertyOverrides = $h_a)]]]],["./tame-locale-methods.js", [["default", [$h_a => (tameLocaleMethods = $h_a)]]]],["./global-object.js", [["setGlobalObjectConstantProperties", [$h_a => (setGlobalObjectConstantProperties = $h_a)]],["setGlobalObjectMutableProperties", [$h_a => (setGlobalObjectMutableProperties = $h_a)]],["setGlobalObjectEvaluators", [$h_a => (setGlobalObjectEvaluators = $h_a)]]]],["./make-safe-evaluator.js", [["makeSafeEvaluator", [$h_a => (makeSafeEvaluator = $h_a)]]]],["./whitelist.js", [["initialGlobalPropertyNames", [$h_a => (initialGlobalPropertyNames = $h_a)]]]],["./tame-function-tostring.js", [["tameFunctionToString", [$h_a => (tameFunctionToString = $h_a)]]]],["./tame-domains.js", [["tameDomains", [$h_a => (tameDomains = $h_a)]]]],["./error/tame-console.js", [["tameConsole", [$h_a => (tameConsole = $h_a)]]]],["./error/tame-error-constructor.js", [["default", [$h_a => (tameErrorConstructor = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]],["makeAssert", [$h_a => (makeAssert = $h_a)]]]],["./environment-options.js", [["makeEnvironmentCaptor", [$h_a => (makeEnvironmentCaptor = $h_a)]]]],["./get-anonymous-intrinsics.js", [["getAnonymousIntrinsics", [$h_a => (getAnonymousIntrinsics = $h_a)]]]],["./compartment-shim.js", [["makeCompartmentConstructor", [$h_a => (makeCompartmentConstructor = $h_a)]]]]]);
|
|
9185
|
+
// === functors[44] ===
|
|
9186
|
+
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let FERAL_FUNCTION,FERAL_EVAL,TypeError,arrayFilter,arrayMap,globalThis,is,ownKeys,stringSplit,noEvalEvaluate,enJoin,makeHardener,makeIntrinsicsCollector,whitelistIntrinsics,tameFunctionConstructors,tameDateConstructor,tameMathObject,tameRegExpConstructor,enablePropertyOverrides,tameLocaleMethods,setGlobalObjectConstantProperties,setGlobalObjectMutableProperties,setGlobalObjectEvaluators,makeSafeEvaluator,initialGlobalPropertyNames,tameFunctionToString,tameDomains,tameConsole,tameErrorConstructor,assert,makeAssert,makeEnvironmentCaptor,getAnonymousIntrinsics,makeCompartmentConstructor,tameHarden;$h_imports([["./commons.js", [["FERAL_FUNCTION", [$h_a => (FERAL_FUNCTION = $h_a)]],["FERAL_EVAL", [$h_a => (FERAL_EVAL = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["arrayFilter", [$h_a => (arrayFilter = $h_a)]],["arrayMap", [$h_a => (arrayMap = $h_a)]],["globalThis", [$h_a => (globalThis = $h_a)]],["is", [$h_a => (is = $h_a)]],["ownKeys", [$h_a => (ownKeys = $h_a)]],["stringSplit", [$h_a => (stringSplit = $h_a)]],["noEvalEvaluate", [$h_a => (noEvalEvaluate = $h_a)]]]],["./error/stringify-utils.js", [["enJoin", [$h_a => (enJoin = $h_a)]]]],["./make-hardener.js", [["makeHardener", [$h_a => (makeHardener = $h_a)]]]],["./intrinsics.js", [["makeIntrinsicsCollector", [$h_a => (makeIntrinsicsCollector = $h_a)]]]],["./whitelist-intrinsics.js", [["default", [$h_a => (whitelistIntrinsics = $h_a)]]]],["./tame-function-constructors.js", [["default", [$h_a => (tameFunctionConstructors = $h_a)]]]],["./tame-date-constructor.js", [["default", [$h_a => (tameDateConstructor = $h_a)]]]],["./tame-math-object.js", [["default", [$h_a => (tameMathObject = $h_a)]]]],["./tame-regexp-constructor.js", [["default", [$h_a => (tameRegExpConstructor = $h_a)]]]],["./enable-property-overrides.js", [["default", [$h_a => (enablePropertyOverrides = $h_a)]]]],["./tame-locale-methods.js", [["default", [$h_a => (tameLocaleMethods = $h_a)]]]],["./global-object.js", [["setGlobalObjectConstantProperties", [$h_a => (setGlobalObjectConstantProperties = $h_a)]],["setGlobalObjectMutableProperties", [$h_a => (setGlobalObjectMutableProperties = $h_a)]],["setGlobalObjectEvaluators", [$h_a => (setGlobalObjectEvaluators = $h_a)]]]],["./make-safe-evaluator.js", [["makeSafeEvaluator", [$h_a => (makeSafeEvaluator = $h_a)]]]],["./whitelist.js", [["initialGlobalPropertyNames", [$h_a => (initialGlobalPropertyNames = $h_a)]]]],["./tame-function-tostring.js", [["tameFunctionToString", [$h_a => (tameFunctionToString = $h_a)]]]],["./tame-domains.js", [["tameDomains", [$h_a => (tameDomains = $h_a)]]]],["./error/tame-console.js", [["tameConsole", [$h_a => (tameConsole = $h_a)]]]],["./error/tame-error-constructor.js", [["default", [$h_a => (tameErrorConstructor = $h_a)]]]],["./error/assert.js", [["assert", [$h_a => (assert = $h_a)]],["makeAssert", [$h_a => (makeAssert = $h_a)]]]],["./environment-options.js", [["makeEnvironmentCaptor", [$h_a => (makeEnvironmentCaptor = $h_a)]]]],["./get-anonymous-intrinsics.js", [["getAnonymousIntrinsics", [$h_a => (getAnonymousIntrinsics = $h_a)]]]],["./compartment-shim.js", [["makeCompartmentConstructor", [$h_a => (makeCompartmentConstructor = $h_a)]]]],["./tame-harden.js", [["tameHarden", [$h_a => (tameHarden = $h_a)]]]]]);
|
|
9187
|
+
|
|
8853
9188
|
|
|
8854
9189
|
|
|
8855
9190
|
|
|
@@ -8918,7 +9253,7 @@ let priorLockdown;
|
|
|
8918
9253
|
* @param {T} ref
|
|
8919
9254
|
* @returns {T}
|
|
8920
9255
|
*/
|
|
8921
|
-
const
|
|
9256
|
+
const safeHarden= makeHardener();
|
|
8922
9257
|
|
|
8923
9258
|
/**
|
|
8924
9259
|
* @callback Transform
|
|
@@ -9025,6 +9360,7 @@ const repairIntrinsics= (options= {})=> {
|
|
|
9025
9360
|
/** @param {string} debugName */
|
|
9026
9361
|
(debugName)=>debugName!== ''),
|
|
9027
9362
|
|
|
9363
|
+
__hardenTaming__= getenv('LOCKDOWN_HARDEN_TAMING', 'safe'),
|
|
9028
9364
|
dateTaming= 'safe', // deprecated
|
|
9029
9365
|
mathTaming= 'safe', // deprecated
|
|
9030
9366
|
...extraOptions}=
|
|
@@ -9115,7 +9451,8 @@ const repairIntrinsics= (options= {})=> {
|
|
|
9115
9451
|
const { addIntrinsics, completePrototypes, finalIntrinsics}=
|
|
9116
9452
|
makeIntrinsicsCollector();
|
|
9117
9453
|
|
|
9118
|
-
|
|
9454
|
+
const tamedHarden= tameHarden(safeHarden, __hardenTaming__);
|
|
9455
|
+
addIntrinsics({ harden: tamedHarden});
|
|
9119
9456
|
|
|
9120
9457
|
addIntrinsics(tameFunctionConstructors());
|
|
9121
9458
|
|
|
@@ -9228,7 +9565,7 @@ const repairIntrinsics= (options= {})=> {
|
|
|
9228
9565
|
|
|
9229
9566
|
// Finally register and optionally freeze all the intrinsics. This
|
|
9230
9567
|
// must be the operation that modifies the intrinsics.
|
|
9231
|
-
|
|
9568
|
+
tamedHarden(intrinsics);
|
|
9232
9569
|
|
|
9233
9570
|
// Reveal harden after lockdown.
|
|
9234
9571
|
// Harden is dangerous before lockdown because hardening just
|
|
@@ -9238,7 +9575,7 @@ const repairIntrinsics= (options= {})=> {
|
|
|
9238
9575
|
// scope signals whether such code should attempt to use harden in the
|
|
9239
9576
|
// defense of its own API.
|
|
9240
9577
|
// @ts-ignore harden not yet recognized on globalThis.
|
|
9241
|
-
globalThis.harden=
|
|
9578
|
+
globalThis.harden= tamedHarden;
|
|
9242
9579
|
|
|
9243
9580
|
// Returning `true` indicates that this is a JS to SES transition.
|
|
9244
9581
|
return true;
|
|
@@ -9256,7 +9593,7 @@ const lockdown= (options= {})=> {
|
|
|
9256
9593
|
};$h_once.lockdown(lockdown);
|
|
9257
9594
|
})
|
|
9258
9595
|
,
|
|
9259
|
-
// === functors[
|
|
9596
|
+
// === functors[45] ===
|
|
9260
9597
|
(({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => { let globalThis,TypeError,assign,tameFunctionToString,getGlobalIntrinsics,lockdown,makeCompartmentConstructor,assert;$h_imports([["./src/commons.js", [["globalThis", [$h_a => (globalThis = $h_a)]],["TypeError", [$h_a => (TypeError = $h_a)]],["assign", [$h_a => (assign = $h_a)]]]],["./src/tame-function-tostring.js", [["tameFunctionToString", [$h_a => (tameFunctionToString = $h_a)]]]],["./src/intrinsics.js", [["getGlobalIntrinsics", [$h_a => (getGlobalIntrinsics = $h_a)]]]],["./src/lockdown-shim.js", [["lockdown", [$h_a => (lockdown = $h_a)]]]],["./src/compartment-shim.js", [["makeCompartmentConstructor", [$h_a => (makeCompartmentConstructor = $h_a)]]]],["./src/error/assert.js", [["assert", [$h_a => (assert = $h_a)]]]]]);
|
|
9261
9598
|
|
|
9262
9599
|
|
|
@@ -9360,6 +9697,8 @@ assign(globalThis, {
|
|
|
9360
9697
|
getOwnPropertyNames: cell("getOwnPropertyNames"),
|
|
9361
9698
|
getPrototypeOf: cell("getPrototypeOf"),
|
|
9362
9699
|
is: cell("is"),
|
|
9700
|
+
isFrozen: cell("isFrozen"),
|
|
9701
|
+
isSealed: cell("isSealed"),
|
|
9363
9702
|
isExtensible: cell("isExtensible"),
|
|
9364
9703
|
keys: cell("keys"),
|
|
9365
9704
|
objectPrototype: cell("objectPrototype"),
|
|
@@ -9441,7 +9780,6 @@ assign(globalThis, {
|
|
|
9441
9780
|
weakmapHas: cell("weakmapHas"),
|
|
9442
9781
|
weakmapSet: cell("weakmapSet"),
|
|
9443
9782
|
weaksetAdd: cell("weaksetAdd"),
|
|
9444
|
-
weaksetGet: cell("weaksetGet"),
|
|
9445
9783
|
weaksetHas: cell("weaksetHas"),
|
|
9446
9784
|
functionToString: cell("functionToString"),
|
|
9447
9785
|
promiseAll: cell("promiseAll"),
|
|
@@ -9459,6 +9797,10 @@ assign(globalThis, {
|
|
|
9459
9797
|
},
|
|
9460
9798
|
{
|
|
9461
9799
|
},
|
|
9800
|
+
{
|
|
9801
|
+
makeLRUCacheMap: cell("makeLRUCacheMap"),
|
|
9802
|
+
makeNoteLogArgsArrayKit: cell("makeNoteLogArgsArrayKit"),
|
|
9803
|
+
},
|
|
9462
9804
|
{
|
|
9463
9805
|
an: cell("an"),
|
|
9464
9806
|
bestEffortStringify: cell("bestEffortStringify"),
|
|
@@ -9608,6 +9950,9 @@ assign(globalThis, {
|
|
|
9608
9950
|
{
|
|
9609
9951
|
tameFunctionToString: cell("tameFunctionToString"),
|
|
9610
9952
|
},
|
|
9953
|
+
{
|
|
9954
|
+
tameHarden: cell("tameHarden"),
|
|
9955
|
+
},
|
|
9611
9956
|
{
|
|
9612
9957
|
default: cell("default"),
|
|
9613
9958
|
},
|
|
@@ -9688,6 +10033,8 @@ function observeImports(map, importName, importIndex) {
|
|
|
9688
10033
|
getOwnPropertyNames: cells[0].getOwnPropertyNames.set,
|
|
9689
10034
|
getPrototypeOf: cells[0].getPrototypeOf.set,
|
|
9690
10035
|
is: cells[0].is.set,
|
|
10036
|
+
isFrozen: cells[0].isFrozen.set,
|
|
10037
|
+
isSealed: cells[0].isSealed.set,
|
|
9691
10038
|
isExtensible: cells[0].isExtensible.set,
|
|
9692
10039
|
keys: cells[0].keys.set,
|
|
9693
10040
|
objectPrototype: cells[0].objectPrototype.set,
|
|
@@ -9769,7 +10116,6 @@ function observeImports(map, importName, importIndex) {
|
|
|
9769
10116
|
weakmapHas: cells[0].weakmapHas.set,
|
|
9770
10117
|
weakmapSet: cells[0].weakmapSet.set,
|
|
9771
10118
|
weaksetAdd: cells[0].weaksetAdd.set,
|
|
9772
|
-
weaksetGet: cells[0].weaksetGet.set,
|
|
9773
10119
|
weaksetHas: cells[0].weaksetHas.set,
|
|
9774
10120
|
functionToString: cells[0].functionToString.set,
|
|
9775
10121
|
promiseAll: cells[0].promiseAll.set,
|
|
@@ -9800,55 +10146,56 @@ function observeImports(map, importName, importIndex) {
|
|
|
9800
10146
|
functors[2]({
|
|
9801
10147
|
imports(entries) {
|
|
9802
10148
|
const map = new Map(entries);
|
|
9803
|
-
observeImports(map, "
|
|
10149
|
+
observeImports(map, "./internal-types.js", 1);
|
|
9804
10150
|
},
|
|
9805
10151
|
liveVar: {
|
|
9806
10152
|
},
|
|
9807
10153
|
onceVar: {
|
|
9808
|
-
|
|
9809
|
-
|
|
9810
|
-
enJoin: cells[2].enJoin.set,
|
|
10154
|
+
makeLRUCacheMap: cells[2].makeLRUCacheMap.set,
|
|
10155
|
+
makeNoteLogArgsArrayKit: cells[2].makeNoteLogArgsArrayKit.set,
|
|
9811
10156
|
},
|
|
9812
10157
|
importMeta: {},
|
|
9813
10158
|
});
|
|
9814
10159
|
functors[3]({
|
|
9815
10160
|
imports(entries) {
|
|
9816
10161
|
const map = new Map(entries);
|
|
10162
|
+
observeImports(map, "../commons.js", 0);
|
|
9817
10163
|
},
|
|
9818
10164
|
liveVar: {
|
|
9819
10165
|
},
|
|
9820
10166
|
onceVar: {
|
|
10167
|
+
an: cells[3].an.set,
|
|
10168
|
+
bestEffortStringify: cells[3].bestEffortStringify.set,
|
|
10169
|
+
enJoin: cells[3].enJoin.set,
|
|
9821
10170
|
},
|
|
9822
10171
|
importMeta: {},
|
|
9823
10172
|
});
|
|
9824
10173
|
functors[4]({
|
|
9825
10174
|
imports(entries) {
|
|
9826
10175
|
const map = new Map(entries);
|
|
9827
|
-
observeImports(map, "../commons.js", 0);
|
|
9828
|
-
observeImports(map, "./internal-types.js", 1);
|
|
9829
|
-
observeImports(map, "./stringify-utils.js", 2);
|
|
9830
|
-
observeImports(map, "./types.js", 3);
|
|
9831
10176
|
},
|
|
9832
10177
|
liveVar: {
|
|
9833
10178
|
},
|
|
9834
10179
|
onceVar: {
|
|
9835
|
-
unredactedDetails: cells[4].unredactedDetails.set,
|
|
9836
|
-
loggedErrorHandler: cells[4].loggedErrorHandler.set,
|
|
9837
|
-
makeAssert: cells[4].makeAssert.set,
|
|
9838
|
-
assert: cells[4].assert.set,
|
|
9839
10180
|
},
|
|
9840
10181
|
importMeta: {},
|
|
9841
10182
|
});
|
|
9842
10183
|
functors[5]({
|
|
9843
10184
|
imports(entries) {
|
|
9844
10185
|
const map = new Map(entries);
|
|
9845
|
-
observeImports(map, "
|
|
9846
|
-
observeImports(map, "./
|
|
10186
|
+
observeImports(map, "../commons.js", 0);
|
|
10187
|
+
observeImports(map, "./internal-types.js", 1);
|
|
10188
|
+
observeImports(map, "./note-log-args.js", 2);
|
|
10189
|
+
observeImports(map, "./stringify-utils.js", 3);
|
|
10190
|
+
observeImports(map, "./types.js", 4);
|
|
9847
10191
|
},
|
|
9848
10192
|
liveVar: {
|
|
9849
10193
|
},
|
|
9850
10194
|
onceVar: {
|
|
9851
|
-
|
|
10195
|
+
unredactedDetails: cells[5].unredactedDetails.set,
|
|
10196
|
+
loggedErrorHandler: cells[5].loggedErrorHandler.set,
|
|
10197
|
+
makeAssert: cells[5].makeAssert.set,
|
|
10198
|
+
assert: cells[5].assert.set,
|
|
9852
10199
|
},
|
|
9853
10200
|
importMeta: {},
|
|
9854
10201
|
});
|
|
@@ -9856,12 +10203,12 @@ function observeImports(map, importName, importIndex) {
|
|
|
9856
10203
|
imports(entries) {
|
|
9857
10204
|
const map = new Map(entries);
|
|
9858
10205
|
observeImports(map, "./commons.js", 0);
|
|
10206
|
+
observeImports(map, "./error/assert.js", 5);
|
|
9859
10207
|
},
|
|
9860
10208
|
liveVar: {
|
|
9861
10209
|
},
|
|
9862
10210
|
onceVar: {
|
|
9863
|
-
|
|
9864
|
-
getScopeConstants: cells[6].getScopeConstants.set,
|
|
10211
|
+
makeEvalScopeKit: cells[6].makeEvalScopeKit.set,
|
|
9865
10212
|
},
|
|
9866
10213
|
importMeta: {},
|
|
9867
10214
|
});
|
|
@@ -9869,12 +10216,12 @@ function observeImports(map, importName, importIndex) {
|
|
|
9869
10216
|
imports(entries) {
|
|
9870
10217
|
const map = new Map(entries);
|
|
9871
10218
|
observeImports(map, "./commons.js", 0);
|
|
9872
|
-
observeImports(map, "./scope-constants.js", 6);
|
|
9873
10219
|
},
|
|
9874
10220
|
liveVar: {
|
|
9875
10221
|
},
|
|
9876
10222
|
onceVar: {
|
|
9877
|
-
|
|
10223
|
+
isValidIdentifierName: cells[7].isValidIdentifierName.set,
|
|
10224
|
+
getScopeConstants: cells[7].getScopeConstants.set,
|
|
9878
10225
|
},
|
|
9879
10226
|
importMeta: {},
|
|
9880
10227
|
});
|
|
@@ -9882,14 +10229,12 @@ function observeImports(map, importName, importIndex) {
|
|
|
9882
10229
|
imports(entries) {
|
|
9883
10230
|
const map = new Map(entries);
|
|
9884
10231
|
observeImports(map, "./commons.js", 0);
|
|
9885
|
-
observeImports(map, "./
|
|
10232
|
+
observeImports(map, "./scope-constants.js", 7);
|
|
9886
10233
|
},
|
|
9887
10234
|
liveVar: {
|
|
9888
10235
|
},
|
|
9889
10236
|
onceVar: {
|
|
9890
|
-
|
|
9891
|
-
strictScopeTerminatorHandler: cells[8].strictScopeTerminatorHandler.set,
|
|
9892
|
-
strictScopeTerminator: cells[8].strictScopeTerminator.set,
|
|
10237
|
+
makeEvaluate: cells[8].makeEvaluate.set,
|
|
9893
10238
|
},
|
|
9894
10239
|
importMeta: {},
|
|
9895
10240
|
});
|
|
@@ -9897,12 +10242,14 @@ function observeImports(map, importName, importIndex) {
|
|
|
9897
10242
|
imports(entries) {
|
|
9898
10243
|
const map = new Map(entries);
|
|
9899
10244
|
observeImports(map, "./commons.js", 0);
|
|
9900
|
-
observeImports(map, "./
|
|
10245
|
+
observeImports(map, "./error/assert.js", 5);
|
|
9901
10246
|
},
|
|
9902
10247
|
liveVar: {
|
|
9903
10248
|
},
|
|
9904
10249
|
onceVar: {
|
|
9905
|
-
|
|
10250
|
+
alwaysThrowHandler: cells[9].alwaysThrowHandler.set,
|
|
10251
|
+
strictScopeTerminatorHandler: cells[9].strictScopeTerminatorHandler.set,
|
|
10252
|
+
strictScopeTerminator: cells[9].strictScopeTerminator.set,
|
|
9906
10253
|
},
|
|
9907
10254
|
importMeta: {},
|
|
9908
10255
|
});
|
|
@@ -9910,11 +10257,12 @@ function observeImports(map, importName, importIndex) {
|
|
|
9910
10257
|
imports(entries) {
|
|
9911
10258
|
const map = new Map(entries);
|
|
9912
10259
|
observeImports(map, "./commons.js", 0);
|
|
10260
|
+
observeImports(map, "./strict-scope-terminator.js", 9);
|
|
9913
10261
|
},
|
|
9914
10262
|
liveVar: {
|
|
9915
10263
|
},
|
|
9916
10264
|
onceVar: {
|
|
9917
|
-
|
|
10265
|
+
createSloppyGlobalsScopeTerminator: cells[10].createSloppyGlobalsScopeTerminator.set,
|
|
9918
10266
|
},
|
|
9919
10267
|
importMeta: {},
|
|
9920
10268
|
});
|
|
@@ -9922,19 +10270,11 @@ function observeImports(map, importName, importIndex) {
|
|
|
9922
10270
|
imports(entries) {
|
|
9923
10271
|
const map = new Map(entries);
|
|
9924
10272
|
observeImports(map, "./commons.js", 0);
|
|
9925
|
-
observeImports(map, "./get-source-url.js", 10);
|
|
9926
10273
|
},
|
|
9927
10274
|
liveVar: {
|
|
9928
10275
|
},
|
|
9929
10276
|
onceVar: {
|
|
9930
|
-
|
|
9931
|
-
evadeHtmlCommentTest: cells[11].evadeHtmlCommentTest.set,
|
|
9932
|
-
rejectImportExpressions: cells[11].rejectImportExpressions.set,
|
|
9933
|
-
evadeImportExpressionTest: cells[11].evadeImportExpressionTest.set,
|
|
9934
|
-
rejectSomeDirectEvalExpressions: cells[11].rejectSomeDirectEvalExpressions.set,
|
|
9935
|
-
mandatoryTransforms: cells[11].mandatoryTransforms.set,
|
|
9936
|
-
applyTransforms: cells[11].applyTransforms.set,
|
|
9937
|
-
transforms: cells[11].transforms.set,
|
|
10277
|
+
getSourceURL: cells[11].getSourceURL.set,
|
|
9938
10278
|
},
|
|
9939
10279
|
importMeta: {},
|
|
9940
10280
|
});
|
|
@@ -9942,17 +10282,19 @@ function observeImports(map, importName, importIndex) {
|
|
|
9942
10282
|
imports(entries) {
|
|
9943
10283
|
const map = new Map(entries);
|
|
9944
10284
|
observeImports(map, "./commons.js", 0);
|
|
9945
|
-
observeImports(map, "./
|
|
9946
|
-
observeImports(map, "./eval-scope.js", 5);
|
|
9947
|
-
observeImports(map, "./make-evaluate.js", 7);
|
|
9948
|
-
observeImports(map, "./sloppy-globals-scope-terminator.js", 9);
|
|
9949
|
-
observeImports(map, "./strict-scope-terminator.js", 8);
|
|
9950
|
-
observeImports(map, "./transforms.js", 11);
|
|
10285
|
+
observeImports(map, "./get-source-url.js", 11);
|
|
9951
10286
|
},
|
|
9952
10287
|
liveVar: {
|
|
9953
10288
|
},
|
|
9954
10289
|
onceVar: {
|
|
9955
|
-
|
|
10290
|
+
rejectHtmlComments: cells[12].rejectHtmlComments.set,
|
|
10291
|
+
evadeHtmlCommentTest: cells[12].evadeHtmlCommentTest.set,
|
|
10292
|
+
rejectImportExpressions: cells[12].rejectImportExpressions.set,
|
|
10293
|
+
evadeImportExpressionTest: cells[12].evadeImportExpressionTest.set,
|
|
10294
|
+
rejectSomeDirectEvalExpressions: cells[12].rejectSomeDirectEvalExpressions.set,
|
|
10295
|
+
mandatoryTransforms: cells[12].mandatoryTransforms.set,
|
|
10296
|
+
applyTransforms: cells[12].applyTransforms.set,
|
|
10297
|
+
transforms: cells[12].transforms.set,
|
|
9956
10298
|
},
|
|
9957
10299
|
importMeta: {},
|
|
9958
10300
|
});
|
|
@@ -9960,75 +10302,75 @@ function observeImports(map, importName, importIndex) {
|
|
|
9960
10302
|
imports(entries) {
|
|
9961
10303
|
const map = new Map(entries);
|
|
9962
10304
|
observeImports(map, "./commons.js", 0);
|
|
9963
|
-
observeImports(map, "./
|
|
9964
|
-
observeImports(map, "./
|
|
10305
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10306
|
+
observeImports(map, "./eval-scope.js", 6);
|
|
10307
|
+
observeImports(map, "./make-evaluate.js", 8);
|
|
10308
|
+
observeImports(map, "./sloppy-globals-scope-terminator.js", 10);
|
|
10309
|
+
observeImports(map, "./strict-scope-terminator.js", 9);
|
|
10310
|
+
observeImports(map, "./transforms.js", 12);
|
|
9965
10311
|
},
|
|
9966
10312
|
liveVar: {
|
|
9967
10313
|
},
|
|
9968
10314
|
onceVar: {
|
|
9969
|
-
|
|
9970
|
-
compartmentEvaluate: cells[13].compartmentEvaluate.set,
|
|
10315
|
+
makeSafeEvaluator: cells[13].makeSafeEvaluator.set,
|
|
9971
10316
|
},
|
|
9972
10317
|
importMeta: {},
|
|
9973
10318
|
});
|
|
9974
10319
|
functors[14]({
|
|
9975
10320
|
imports(entries) {
|
|
9976
10321
|
const map = new Map(entries);
|
|
10322
|
+
observeImports(map, "./commons.js", 0);
|
|
10323
|
+
observeImports(map, "./make-safe-evaluator.js", 13);
|
|
10324
|
+
observeImports(map, "./transforms.js", 12);
|
|
9977
10325
|
},
|
|
9978
10326
|
liveVar: {
|
|
9979
10327
|
},
|
|
9980
10328
|
onceVar: {
|
|
9981
|
-
|
|
10329
|
+
provideCompartmentEvaluator: cells[14].provideCompartmentEvaluator.set,
|
|
10330
|
+
compartmentEvaluate: cells[14].compartmentEvaluate.set,
|
|
9982
10331
|
},
|
|
9983
10332
|
importMeta: {},
|
|
9984
10333
|
});
|
|
9985
10334
|
functors[15]({
|
|
9986
10335
|
imports(entries) {
|
|
9987
10336
|
const map = new Map(entries);
|
|
9988
|
-
observeImports(map, "./commons.js", 0);
|
|
9989
|
-
observeImports(map, "./error/assert.js", 4);
|
|
9990
10337
|
},
|
|
9991
10338
|
liveVar: {
|
|
9992
10339
|
},
|
|
9993
10340
|
onceVar: {
|
|
9994
|
-
|
|
10341
|
+
makeEvalFunction: cells[15].makeEvalFunction.set,
|
|
9995
10342
|
},
|
|
9996
10343
|
importMeta: {},
|
|
9997
10344
|
});
|
|
9998
10345
|
functors[16]({
|
|
9999
10346
|
imports(entries) {
|
|
10000
10347
|
const map = new Map(entries);
|
|
10348
|
+
observeImports(map, "./commons.js", 0);
|
|
10349
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10001
10350
|
},
|
|
10002
10351
|
liveVar: {
|
|
10003
10352
|
},
|
|
10004
10353
|
onceVar: {
|
|
10005
|
-
|
|
10006
|
-
universalPropertyNames: cells[16].universalPropertyNames.set,
|
|
10007
|
-
initialGlobalPropertyNames: cells[16].initialGlobalPropertyNames.set,
|
|
10008
|
-
sharedGlobalPropertyNames: cells[16].sharedGlobalPropertyNames.set,
|
|
10009
|
-
uniqueGlobalPropertyNames: cells[16].uniqueGlobalPropertyNames.set,
|
|
10010
|
-
NativeErrors: cells[16].NativeErrors.set,
|
|
10011
|
-
FunctionInstance: cells[16].FunctionInstance.set,
|
|
10012
|
-
isAccessorPermit: cells[16].isAccessorPermit.set,
|
|
10013
|
-
whitelist: cells[16].whitelist.set,
|
|
10354
|
+
makeFunctionConstructor: cells[16].makeFunctionConstructor.set,
|
|
10014
10355
|
},
|
|
10015
10356
|
importMeta: {},
|
|
10016
10357
|
});
|
|
10017
10358
|
functors[17]({
|
|
10018
10359
|
imports(entries) {
|
|
10019
10360
|
const map = new Map(entries);
|
|
10020
|
-
observeImports(map, "./commons.js", 0);
|
|
10021
|
-
observeImports(map, "./make-eval-function.js", 14);
|
|
10022
|
-
observeImports(map, "./make-function-constructor.js", 15);
|
|
10023
|
-
observeImports(map, "./whitelist.js", 16);
|
|
10024
10361
|
},
|
|
10025
10362
|
liveVar: {
|
|
10026
10363
|
},
|
|
10027
10364
|
onceVar: {
|
|
10028
|
-
|
|
10029
|
-
|
|
10030
|
-
|
|
10031
|
-
|
|
10365
|
+
constantProperties: cells[17].constantProperties.set,
|
|
10366
|
+
universalPropertyNames: cells[17].universalPropertyNames.set,
|
|
10367
|
+
initialGlobalPropertyNames: cells[17].initialGlobalPropertyNames.set,
|
|
10368
|
+
sharedGlobalPropertyNames: cells[17].sharedGlobalPropertyNames.set,
|
|
10369
|
+
uniqueGlobalPropertyNames: cells[17].uniqueGlobalPropertyNames.set,
|
|
10370
|
+
NativeErrors: cells[17].NativeErrors.set,
|
|
10371
|
+
FunctionInstance: cells[17].FunctionInstance.set,
|
|
10372
|
+
isAccessorPermit: cells[17].isAccessorPermit.set,
|
|
10373
|
+
whitelist: cells[17].whitelist.set,
|
|
10032
10374
|
},
|
|
10033
10375
|
importMeta: {},
|
|
10034
10376
|
});
|
|
@@ -10036,13 +10378,17 @@ function observeImports(map, importName, importIndex) {
|
|
|
10036
10378
|
imports(entries) {
|
|
10037
10379
|
const map = new Map(entries);
|
|
10038
10380
|
observeImports(map, "./commons.js", 0);
|
|
10039
|
-
observeImports(map, "./
|
|
10381
|
+
observeImports(map, "./make-eval-function.js", 15);
|
|
10382
|
+
observeImports(map, "./make-function-constructor.js", 16);
|
|
10383
|
+
observeImports(map, "./whitelist.js", 17);
|
|
10040
10384
|
},
|
|
10041
10385
|
liveVar: {
|
|
10042
10386
|
},
|
|
10043
10387
|
onceVar: {
|
|
10044
|
-
|
|
10045
|
-
|
|
10388
|
+
setGlobalObjectSymbolUnscopables: cells[18].setGlobalObjectSymbolUnscopables.set,
|
|
10389
|
+
setGlobalObjectConstantProperties: cells[18].setGlobalObjectConstantProperties.set,
|
|
10390
|
+
setGlobalObjectMutableProperties: cells[18].setGlobalObjectMutableProperties.set,
|
|
10391
|
+
setGlobalObjectEvaluators: cells[18].setGlobalObjectEvaluators.set,
|
|
10046
10392
|
},
|
|
10047
10393
|
importMeta: {},
|
|
10048
10394
|
});
|
|
@@ -10050,14 +10396,13 @@ function observeImports(map, importName, importIndex) {
|
|
|
10050
10396
|
imports(entries) {
|
|
10051
10397
|
const map = new Map(entries);
|
|
10052
10398
|
observeImports(map, "./commons.js", 0);
|
|
10053
|
-
observeImports(map, "./error/assert.js",
|
|
10054
|
-
observeImports(map, "./module-load.js", 18);
|
|
10399
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10055
10400
|
},
|
|
10056
10401
|
liveVar: {
|
|
10057
10402
|
},
|
|
10058
10403
|
onceVar: {
|
|
10059
|
-
|
|
10060
|
-
|
|
10404
|
+
makeAlias: cells[19].makeAlias.set,
|
|
10405
|
+
load: cells[19].load.set,
|
|
10061
10406
|
},
|
|
10062
10407
|
importMeta: {},
|
|
10063
10408
|
});
|
|
@@ -10065,15 +10410,14 @@ function observeImports(map, importName, importIndex) {
|
|
|
10065
10410
|
imports(entries) {
|
|
10066
10411
|
const map = new Map(entries);
|
|
10067
10412
|
observeImports(map, "./commons.js", 0);
|
|
10068
|
-
observeImports(map, "./
|
|
10069
|
-
observeImports(map, "./
|
|
10070
|
-
observeImports(map, "./module-proxy.js", 19);
|
|
10413
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10414
|
+
observeImports(map, "./module-load.js", 19);
|
|
10071
10415
|
},
|
|
10072
10416
|
liveVar: {
|
|
10073
10417
|
},
|
|
10074
10418
|
onceVar: {
|
|
10075
|
-
|
|
10076
|
-
|
|
10419
|
+
deferExports: cells[20].deferExports.set,
|
|
10420
|
+
getDeferredExports: cells[20].getDeferredExports.set,
|
|
10077
10421
|
},
|
|
10078
10422
|
importMeta: {},
|
|
10079
10423
|
});
|
|
@@ -10081,14 +10425,15 @@ function observeImports(map, importName, importIndex) {
|
|
|
10081
10425
|
imports(entries) {
|
|
10082
10426
|
const map = new Map(entries);
|
|
10083
10427
|
observeImports(map, "./commons.js", 0);
|
|
10084
|
-
observeImports(map, "./
|
|
10085
|
-
observeImports(map, "./
|
|
10428
|
+
observeImports(map, "./compartment-evaluate.js", 14);
|
|
10429
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10430
|
+
observeImports(map, "./module-proxy.js", 20);
|
|
10086
10431
|
},
|
|
10087
10432
|
liveVar: {
|
|
10088
10433
|
},
|
|
10089
10434
|
onceVar: {
|
|
10090
|
-
|
|
10091
|
-
|
|
10435
|
+
makeThirdPartyModuleInstance: cells[21].makeThirdPartyModuleInstance.set,
|
|
10436
|
+
makeModuleInstance: cells[21].makeModuleInstance.set,
|
|
10092
10437
|
},
|
|
10093
10438
|
importMeta: {},
|
|
10094
10439
|
});
|
|
@@ -10096,21 +10441,14 @@ function observeImports(map, importName, importIndex) {
|
|
|
10096
10441
|
imports(entries) {
|
|
10097
10442
|
const map = new Map(entries);
|
|
10098
10443
|
observeImports(map, "./commons.js", 0);
|
|
10099
|
-
observeImports(map, "./
|
|
10100
|
-
observeImports(map, "./
|
|
10101
|
-
observeImports(map, "./global-object.js", 17);
|
|
10102
|
-
observeImports(map, "./make-safe-evaluator.js", 12);
|
|
10103
|
-
observeImports(map, "./module-link.js", 21);
|
|
10104
|
-
observeImports(map, "./module-load.js", 18);
|
|
10105
|
-
observeImports(map, "./module-proxy.js", 19);
|
|
10106
|
-
observeImports(map, "./whitelist.js", 16);
|
|
10444
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10445
|
+
observeImports(map, "./module-instance.js", 21);
|
|
10107
10446
|
},
|
|
10108
10447
|
liveVar: {
|
|
10109
10448
|
},
|
|
10110
10449
|
onceVar: {
|
|
10111
|
-
|
|
10112
|
-
|
|
10113
|
-
makeCompartmentConstructor: cells[22].makeCompartmentConstructor.set,
|
|
10450
|
+
link: cells[22].link.set,
|
|
10451
|
+
instantiate: cells[22].instantiate.set,
|
|
10114
10452
|
},
|
|
10115
10453
|
importMeta: {},
|
|
10116
10454
|
});
|
|
@@ -10118,39 +10456,48 @@ function observeImports(map, importName, importIndex) {
|
|
|
10118
10456
|
imports(entries) {
|
|
10119
10457
|
const map = new Map(entries);
|
|
10120
10458
|
observeImports(map, "./commons.js", 0);
|
|
10121
|
-
observeImports(map, "./
|
|
10459
|
+
observeImports(map, "./compartment-evaluate.js", 14);
|
|
10460
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10461
|
+
observeImports(map, "./global-object.js", 18);
|
|
10462
|
+
observeImports(map, "./make-safe-evaluator.js", 13);
|
|
10463
|
+
observeImports(map, "./module-link.js", 22);
|
|
10464
|
+
observeImports(map, "./module-load.js", 19);
|
|
10465
|
+
observeImports(map, "./module-proxy.js", 20);
|
|
10466
|
+
observeImports(map, "./whitelist.js", 17);
|
|
10122
10467
|
},
|
|
10123
10468
|
liveVar: {
|
|
10124
10469
|
},
|
|
10125
10470
|
onceVar: {
|
|
10126
|
-
|
|
10127
|
-
|
|
10471
|
+
InertCompartment: cells[23].InertCompartment.set,
|
|
10472
|
+
CompartmentPrototype: cells[23].CompartmentPrototype.set,
|
|
10473
|
+
makeCompartmentConstructor: cells[23].makeCompartmentConstructor.set,
|
|
10128
10474
|
},
|
|
10129
10475
|
importMeta: {},
|
|
10130
10476
|
});
|
|
10131
10477
|
functors[24]({
|
|
10132
10478
|
imports(entries) {
|
|
10133
10479
|
const map = new Map(entries);
|
|
10480
|
+
observeImports(map, "./commons.js", 0);
|
|
10481
|
+
observeImports(map, "./whitelist.js", 17);
|
|
10134
10482
|
},
|
|
10135
10483
|
liveVar: {
|
|
10136
10484
|
},
|
|
10137
10485
|
onceVar: {
|
|
10138
|
-
|
|
10139
|
-
|
|
10140
|
-
severeEnablements: cells[24].severeEnablements.set,
|
|
10486
|
+
makeIntrinsicsCollector: cells[24].makeIntrinsicsCollector.set,
|
|
10487
|
+
getGlobalIntrinsics: cells[24].getGlobalIntrinsics.set,
|
|
10141
10488
|
},
|
|
10142
10489
|
importMeta: {},
|
|
10143
10490
|
});
|
|
10144
10491
|
functors[25]({
|
|
10145
10492
|
imports(entries) {
|
|
10146
10493
|
const map = new Map(entries);
|
|
10147
|
-
observeImports(map, "./commons.js", 0);
|
|
10148
|
-
observeImports(map, "./enablements.js", 24);
|
|
10149
10494
|
},
|
|
10150
10495
|
liveVar: {
|
|
10151
10496
|
},
|
|
10152
10497
|
onceVar: {
|
|
10153
|
-
|
|
10498
|
+
minEnablements: cells[25].minEnablements.set,
|
|
10499
|
+
moderateEnablements: cells[25].moderateEnablements.set,
|
|
10500
|
+
severeEnablements: cells[25].severeEnablements.set,
|
|
10154
10501
|
},
|
|
10155
10502
|
importMeta: {},
|
|
10156
10503
|
});
|
|
@@ -10158,29 +10505,25 @@ function observeImports(map, importName, importIndex) {
|
|
|
10158
10505
|
imports(entries) {
|
|
10159
10506
|
const map = new Map(entries);
|
|
10160
10507
|
observeImports(map, "./commons.js", 0);
|
|
10161
|
-
observeImports(map, "./
|
|
10508
|
+
observeImports(map, "./enablements.js", 25);
|
|
10162
10509
|
},
|
|
10163
10510
|
liveVar: {
|
|
10164
10511
|
},
|
|
10165
10512
|
onceVar: {
|
|
10166
|
-
|
|
10513
|
+
default: cells[26].default.set,
|
|
10167
10514
|
},
|
|
10168
10515
|
importMeta: {},
|
|
10169
10516
|
});
|
|
10170
10517
|
functors[27]({
|
|
10171
10518
|
imports(entries) {
|
|
10172
10519
|
const map = new Map(entries);
|
|
10173
|
-
observeImports(map, "
|
|
10174
|
-
observeImports(map, "./
|
|
10175
|
-
observeImports(map, "./types.js", 3);
|
|
10520
|
+
observeImports(map, "./commons.js", 0);
|
|
10521
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10176
10522
|
},
|
|
10177
10523
|
liveVar: {
|
|
10178
10524
|
},
|
|
10179
10525
|
onceVar: {
|
|
10180
|
-
|
|
10181
|
-
makeCausalConsole: cells[27].makeCausalConsole.set,
|
|
10182
|
-
filterConsole: cells[27].filterConsole.set,
|
|
10183
|
-
consoleWhitelist: cells[27].consoleWhitelist.set,
|
|
10526
|
+
makeEnvironmentCaptor: cells[27].makeEnvironmentCaptor.set,
|
|
10184
10527
|
},
|
|
10185
10528
|
importMeta: {},
|
|
10186
10529
|
});
|
|
@@ -10188,11 +10531,16 @@ function observeImports(map, importName, importIndex) {
|
|
|
10188
10531
|
imports(entries) {
|
|
10189
10532
|
const map = new Map(entries);
|
|
10190
10533
|
observeImports(map, "../commons.js", 0);
|
|
10534
|
+
observeImports(map, "./internal-types.js", 1);
|
|
10535
|
+
observeImports(map, "./types.js", 4);
|
|
10191
10536
|
},
|
|
10192
10537
|
liveVar: {
|
|
10193
10538
|
},
|
|
10194
10539
|
onceVar: {
|
|
10195
|
-
|
|
10540
|
+
makeLoggingConsoleKit: cells[28].makeLoggingConsoleKit.set,
|
|
10541
|
+
makeCausalConsole: cells[28].makeCausalConsole.set,
|
|
10542
|
+
filterConsole: cells[28].filterConsole.set,
|
|
10543
|
+
consoleWhitelist: cells[28].consoleWhitelist.set,
|
|
10196
10544
|
},
|
|
10197
10545
|
importMeta: {},
|
|
10198
10546
|
});
|
|
@@ -10200,16 +10548,11 @@ function observeImports(map, importName, importIndex) {
|
|
|
10200
10548
|
imports(entries) {
|
|
10201
10549
|
const map = new Map(entries);
|
|
10202
10550
|
observeImports(map, "../commons.js", 0);
|
|
10203
|
-
observeImports(map, "./assert.js", 4);
|
|
10204
|
-
observeImports(map, "./console.js", 27);
|
|
10205
|
-
observeImports(map, "./internal-types.js", 1);
|
|
10206
|
-
observeImports(map, "./types.js", 3);
|
|
10207
|
-
observeImports(map, "./unhandled-rejection.js", 28);
|
|
10208
10551
|
},
|
|
10209
10552
|
liveVar: {
|
|
10210
10553
|
},
|
|
10211
10554
|
onceVar: {
|
|
10212
|
-
|
|
10555
|
+
makeRejectionHandlers: cells[29].makeRejectionHandlers.set,
|
|
10213
10556
|
},
|
|
10214
10557
|
importMeta: {},
|
|
10215
10558
|
});
|
|
@@ -10217,13 +10560,16 @@ function observeImports(map, importName, importIndex) {
|
|
|
10217
10560
|
imports(entries) {
|
|
10218
10561
|
const map = new Map(entries);
|
|
10219
10562
|
observeImports(map, "../commons.js", 0);
|
|
10563
|
+
observeImports(map, "./assert.js", 5);
|
|
10564
|
+
observeImports(map, "./console.js", 28);
|
|
10565
|
+
observeImports(map, "./internal-types.js", 1);
|
|
10566
|
+
observeImports(map, "./types.js", 4);
|
|
10567
|
+
observeImports(map, "./unhandled-rejection.js", 29);
|
|
10220
10568
|
},
|
|
10221
10569
|
liveVar: {
|
|
10222
10570
|
},
|
|
10223
10571
|
onceVar: {
|
|
10224
|
-
|
|
10225
|
-
shortenCallSiteString: cells[30].shortenCallSiteString.set,
|
|
10226
|
-
tameV8ErrorConstructor: cells[30].tameV8ErrorConstructor.set,
|
|
10572
|
+
tameConsole: cells[30].tameConsole.set,
|
|
10227
10573
|
},
|
|
10228
10574
|
importMeta: {},
|
|
10229
10575
|
});
|
|
@@ -10231,26 +10577,27 @@ function observeImports(map, importName, importIndex) {
|
|
|
10231
10577
|
imports(entries) {
|
|
10232
10578
|
const map = new Map(entries);
|
|
10233
10579
|
observeImports(map, "../commons.js", 0);
|
|
10234
|
-
observeImports(map, "../whitelist.js", 16);
|
|
10235
|
-
observeImports(map, "./tame-v8-error-constructor.js", 30);
|
|
10236
10580
|
},
|
|
10237
10581
|
liveVar: {
|
|
10238
10582
|
},
|
|
10239
10583
|
onceVar: {
|
|
10240
|
-
|
|
10584
|
+
filterFileName: cells[31].filterFileName.set,
|
|
10585
|
+
shortenCallSiteString: cells[31].shortenCallSiteString.set,
|
|
10586
|
+
tameV8ErrorConstructor: cells[31].tameV8ErrorConstructor.set,
|
|
10241
10587
|
},
|
|
10242
10588
|
importMeta: {},
|
|
10243
10589
|
});
|
|
10244
10590
|
functors[32]({
|
|
10245
10591
|
imports(entries) {
|
|
10246
10592
|
const map = new Map(entries);
|
|
10247
|
-
observeImports(map, "
|
|
10248
|
-
observeImports(map, "
|
|
10593
|
+
observeImports(map, "../commons.js", 0);
|
|
10594
|
+
observeImports(map, "../whitelist.js", 17);
|
|
10595
|
+
observeImports(map, "./tame-v8-error-constructor.js", 31);
|
|
10249
10596
|
},
|
|
10250
10597
|
liveVar: {
|
|
10251
10598
|
},
|
|
10252
10599
|
onceVar: {
|
|
10253
|
-
|
|
10600
|
+
default: cells[32].default.set,
|
|
10254
10601
|
},
|
|
10255
10602
|
importMeta: {},
|
|
10256
10603
|
});
|
|
@@ -10258,13 +10605,12 @@ function observeImports(map, importName, importIndex) {
|
|
|
10258
10605
|
imports(entries) {
|
|
10259
10606
|
const map = new Map(entries);
|
|
10260
10607
|
observeImports(map, "./commons.js", 0);
|
|
10261
|
-
observeImports(map, "./
|
|
10608
|
+
observeImports(map, "./compartment-shim.js", 23);
|
|
10262
10609
|
},
|
|
10263
10610
|
liveVar: {
|
|
10264
10611
|
},
|
|
10265
10612
|
onceVar: {
|
|
10266
|
-
|
|
10267
|
-
makeHardener: cells[33].makeHardener.set,
|
|
10613
|
+
getAnonymousIntrinsics: cells[33].getAnonymousIntrinsics.set,
|
|
10268
10614
|
},
|
|
10269
10615
|
importMeta: {},
|
|
10270
10616
|
});
|
|
@@ -10272,11 +10618,13 @@ function observeImports(map, importName, importIndex) {
|
|
|
10272
10618
|
imports(entries) {
|
|
10273
10619
|
const map = new Map(entries);
|
|
10274
10620
|
observeImports(map, "./commons.js", 0);
|
|
10621
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10275
10622
|
},
|
|
10276
10623
|
liveVar: {
|
|
10277
10624
|
},
|
|
10278
10625
|
onceVar: {
|
|
10279
|
-
|
|
10626
|
+
isTypedArray: cells[34].isTypedArray.set,
|
|
10627
|
+
makeHardener: cells[34].makeHardener.set,
|
|
10280
10628
|
},
|
|
10281
10629
|
importMeta: {},
|
|
10282
10630
|
});
|
|
@@ -10288,7 +10636,7 @@ function observeImports(map, importName, importIndex) {
|
|
|
10288
10636
|
liveVar: {
|
|
10289
10637
|
},
|
|
10290
10638
|
onceVar: {
|
|
10291
|
-
|
|
10639
|
+
default: cells[35].default.set,
|
|
10292
10640
|
},
|
|
10293
10641
|
importMeta: {},
|
|
10294
10642
|
});
|
|
@@ -10300,7 +10648,7 @@ function observeImports(map, importName, importIndex) {
|
|
|
10300
10648
|
liveVar: {
|
|
10301
10649
|
},
|
|
10302
10650
|
onceVar: {
|
|
10303
|
-
|
|
10651
|
+
tameDomains: cells[36].tameDomains.set,
|
|
10304
10652
|
},
|
|
10305
10653
|
importMeta: {},
|
|
10306
10654
|
});
|
|
@@ -10312,7 +10660,7 @@ function observeImports(map, importName, importIndex) {
|
|
|
10312
10660
|
liveVar: {
|
|
10313
10661
|
},
|
|
10314
10662
|
onceVar: {
|
|
10315
|
-
|
|
10663
|
+
default: cells[37].default.set,
|
|
10316
10664
|
},
|
|
10317
10665
|
importMeta: {},
|
|
10318
10666
|
});
|
|
@@ -10320,12 +10668,11 @@ function observeImports(map, importName, importIndex) {
|
|
|
10320
10668
|
imports(entries) {
|
|
10321
10669
|
const map = new Map(entries);
|
|
10322
10670
|
observeImports(map, "./commons.js", 0);
|
|
10323
|
-
observeImports(map, "./error/assert.js", 4);
|
|
10324
10671
|
},
|
|
10325
10672
|
liveVar: {
|
|
10326
10673
|
},
|
|
10327
10674
|
onceVar: {
|
|
10328
|
-
|
|
10675
|
+
tameFunctionToString: cells[38].tameFunctionToString.set,
|
|
10329
10676
|
},
|
|
10330
10677
|
importMeta: {},
|
|
10331
10678
|
});
|
|
@@ -10337,7 +10684,7 @@ function observeImports(map, importName, importIndex) {
|
|
|
10337
10684
|
liveVar: {
|
|
10338
10685
|
},
|
|
10339
10686
|
onceVar: {
|
|
10340
|
-
|
|
10687
|
+
tameHarden: cells[39].tameHarden.set,
|
|
10341
10688
|
},
|
|
10342
10689
|
importMeta: {},
|
|
10343
10690
|
});
|
|
@@ -10345,6 +10692,7 @@ function observeImports(map, importName, importIndex) {
|
|
|
10345
10692
|
imports(entries) {
|
|
10346
10693
|
const map = new Map(entries);
|
|
10347
10694
|
observeImports(map, "./commons.js", 0);
|
|
10695
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10348
10696
|
},
|
|
10349
10697
|
liveVar: {
|
|
10350
10698
|
},
|
|
@@ -10357,7 +10705,6 @@ function observeImports(map, importName, importIndex) {
|
|
|
10357
10705
|
imports(entries) {
|
|
10358
10706
|
const map = new Map(entries);
|
|
10359
10707
|
observeImports(map, "./commons.js", 0);
|
|
10360
|
-
observeImports(map, "./whitelist.js", 16);
|
|
10361
10708
|
},
|
|
10362
10709
|
liveVar: {
|
|
10363
10710
|
},
|
|
@@ -10370,45 +10717,71 @@ function observeImports(map, importName, importIndex) {
|
|
|
10370
10717
|
imports(entries) {
|
|
10371
10718
|
const map = new Map(entries);
|
|
10372
10719
|
observeImports(map, "./commons.js", 0);
|
|
10373
|
-
observeImports(map, "./compartment-shim.js", 22);
|
|
10374
|
-
observeImports(map, "./enable-property-overrides.js", 25);
|
|
10375
|
-
observeImports(map, "./environment-options.js", 26);
|
|
10376
|
-
observeImports(map, "./error/assert.js", 4);
|
|
10377
|
-
observeImports(map, "./error/stringify-utils.js", 2);
|
|
10378
|
-
observeImports(map, "./error/tame-console.js", 29);
|
|
10379
|
-
observeImports(map, "./error/tame-error-constructor.js", 31);
|
|
10380
|
-
observeImports(map, "./get-anonymous-intrinsics.js", 32);
|
|
10381
|
-
observeImports(map, "./global-object.js", 17);
|
|
10382
|
-
observeImports(map, "./intrinsics.js", 23);
|
|
10383
|
-
observeImports(map, "./make-hardener.js", 33);
|
|
10384
|
-
observeImports(map, "./make-safe-evaluator.js", 12);
|
|
10385
|
-
observeImports(map, "./tame-date-constructor.js", 34);
|
|
10386
|
-
observeImports(map, "./tame-domains.js", 35);
|
|
10387
|
-
observeImports(map, "./tame-function-constructors.js", 36);
|
|
10388
|
-
observeImports(map, "./tame-function-tostring.js", 37);
|
|
10389
|
-
observeImports(map, "./tame-locale-methods.js", 38);
|
|
10390
|
-
observeImports(map, "./tame-math-object.js", 39);
|
|
10391
|
-
observeImports(map, "./tame-regexp-constructor.js", 40);
|
|
10392
|
-
observeImports(map, "./whitelist-intrinsics.js", 41);
|
|
10393
|
-
observeImports(map, "./whitelist.js", 16);
|
|
10394
10720
|
},
|
|
10395
10721
|
liveVar: {
|
|
10396
10722
|
},
|
|
10397
10723
|
onceVar: {
|
|
10398
|
-
|
|
10399
|
-
lockdown: cells[42].lockdown.set,
|
|
10724
|
+
default: cells[42].default.set,
|
|
10400
10725
|
},
|
|
10401
10726
|
importMeta: {},
|
|
10402
10727
|
});
|
|
10403
10728
|
functors[43]({
|
|
10729
|
+
imports(entries) {
|
|
10730
|
+
const map = new Map(entries);
|
|
10731
|
+
observeImports(map, "./commons.js", 0);
|
|
10732
|
+
observeImports(map, "./whitelist.js", 17);
|
|
10733
|
+
},
|
|
10734
|
+
liveVar: {
|
|
10735
|
+
},
|
|
10736
|
+
onceVar: {
|
|
10737
|
+
default: cells[43].default.set,
|
|
10738
|
+
},
|
|
10739
|
+
importMeta: {},
|
|
10740
|
+
});
|
|
10741
|
+
functors[44]({
|
|
10742
|
+
imports(entries) {
|
|
10743
|
+
const map = new Map(entries);
|
|
10744
|
+
observeImports(map, "./commons.js", 0);
|
|
10745
|
+
observeImports(map, "./compartment-shim.js", 23);
|
|
10746
|
+
observeImports(map, "./enable-property-overrides.js", 26);
|
|
10747
|
+
observeImports(map, "./environment-options.js", 27);
|
|
10748
|
+
observeImports(map, "./error/assert.js", 5);
|
|
10749
|
+
observeImports(map, "./error/stringify-utils.js", 3);
|
|
10750
|
+
observeImports(map, "./error/tame-console.js", 30);
|
|
10751
|
+
observeImports(map, "./error/tame-error-constructor.js", 32);
|
|
10752
|
+
observeImports(map, "./get-anonymous-intrinsics.js", 33);
|
|
10753
|
+
observeImports(map, "./global-object.js", 18);
|
|
10754
|
+
observeImports(map, "./intrinsics.js", 24);
|
|
10755
|
+
observeImports(map, "./make-hardener.js", 34);
|
|
10756
|
+
observeImports(map, "./make-safe-evaluator.js", 13);
|
|
10757
|
+
observeImports(map, "./tame-date-constructor.js", 35);
|
|
10758
|
+
observeImports(map, "./tame-domains.js", 36);
|
|
10759
|
+
observeImports(map, "./tame-function-constructors.js", 37);
|
|
10760
|
+
observeImports(map, "./tame-function-tostring.js", 38);
|
|
10761
|
+
observeImports(map, "./tame-harden.js", 39);
|
|
10762
|
+
observeImports(map, "./tame-locale-methods.js", 40);
|
|
10763
|
+
observeImports(map, "./tame-math-object.js", 41);
|
|
10764
|
+
observeImports(map, "./tame-regexp-constructor.js", 42);
|
|
10765
|
+
observeImports(map, "./whitelist-intrinsics.js", 43);
|
|
10766
|
+
observeImports(map, "./whitelist.js", 17);
|
|
10767
|
+
},
|
|
10768
|
+
liveVar: {
|
|
10769
|
+
},
|
|
10770
|
+
onceVar: {
|
|
10771
|
+
repairIntrinsics: cells[44].repairIntrinsics.set,
|
|
10772
|
+
lockdown: cells[44].lockdown.set,
|
|
10773
|
+
},
|
|
10774
|
+
importMeta: {},
|
|
10775
|
+
});
|
|
10776
|
+
functors[45]({
|
|
10404
10777
|
imports(entries) {
|
|
10405
10778
|
const map = new Map(entries);
|
|
10406
10779
|
observeImports(map, "./src/commons.js", 0);
|
|
10407
|
-
observeImports(map, "./src/compartment-shim.js",
|
|
10408
|
-
observeImports(map, "./src/error/assert.js",
|
|
10409
|
-
observeImports(map, "./src/intrinsics.js",
|
|
10410
|
-
observeImports(map, "./src/lockdown-shim.js",
|
|
10411
|
-
observeImports(map, "./src/tame-function-tostring.js",
|
|
10780
|
+
observeImports(map, "./src/compartment-shim.js", 23);
|
|
10781
|
+
observeImports(map, "./src/error/assert.js", 5);
|
|
10782
|
+
observeImports(map, "./src/intrinsics.js", 24);
|
|
10783
|
+
observeImports(map, "./src/lockdown-shim.js", 44);
|
|
10784
|
+
observeImports(map, "./src/tame-function-tostring.js", 38);
|
|
10412
10785
|
},
|
|
10413
10786
|
liveVar: {
|
|
10414
10787
|
},
|