mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 01:39:44 +01:00
bbb35dbe8d
* update ses import directory * agoric references removed * domainTaming set to unsafe --------- Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
24 lines
779 B
JavaScript
24 lines
779 B
JavaScript
// Freezes all intrinsics
|
|
try {
|
|
// eslint-disable-next-line no-undef,import/unambiguous
|
|
lockdown({
|
|
consoleTaming: 'unsafe',
|
|
errorTaming: 'unsafe',
|
|
mathTaming: 'unsafe',
|
|
dateTaming: 'unsafe',
|
|
domainTaming: 'unsafe',
|
|
overrideTaming: 'severe',
|
|
});
|
|
} catch (error) {
|
|
// If the `lockdown` call throws an exception, it interferes with the
|
|
// contentscript injection on some versions of Firefox. The error is
|
|
// caught and logged here so that the contentscript still gets injected.
|
|
// This affects Firefox v56 and Waterfox Classic.
|
|
console.error('Lockdown failed:', error);
|
|
if (globalThis.sentry && globalThis.sentry.captureException) {
|
|
globalThis.sentry.captureException(
|
|
new Error(`Lockdown failed: ${error.message}`),
|
|
);
|
|
}
|
|
}
|