mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-29 15:50:28 +01:00
8fc2c3272a
* update ses * build - reference ses directly * deps - unify regenerator-runtime versions on 0.13.7 * patches - apply regenerator-runtime ses compat patch\nhttps://github.com/facebook/regenerator/pull/411 * patches - patch regenerator-runtime for latest ses fix * reduc patch, new lockdown severe override taming * updated redux patch * update redux patch for production * ignore lockdown in lint * deps - bump patch-package just in case * trailing comma * remove ses as dep * fix path for frozen promise * remove js extension in lockdown require * Revert "ignore lockdown in lint" This reverts commit 8cefdc94dd25d7781bb09eed8af36441397676da. * Revert "build - reference ses directly" This reverts commit 30371a377dcdd781c1bf9abe55e9c8ae34da26b5. * deps - update ses * Revert "fix path for frozen promise" This reverts commit 966e4c60921a25befe8ca8dea58313cc25852f72. Co-authored-by: kumavis <aaron@kumavis.me>
21 lines
684 B
JavaScript
21 lines
684 B
JavaScript
// Freezes all intrinsics
|
|
try {
|
|
// eslint-disable-next-line no-undef,import/unambiguous
|
|
lockdown({
|
|
consoleTaming: 'unsafe',
|
|
errorTaming: 'unsafe',
|
|
mathTaming: 'unsafe',
|
|
dateTaming: '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 (window.sentry && window.sentry.captureException) {
|
|
window.sentry.captureException(error);
|
|
}
|
|
}
|