forked from MetaMask/snaps
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bump SES and LavaMoat (MetaMask#2105)
Bumps all LavaMoat packages to their latest versions. This solves a problem where the snaps execution environment would fail to function in the latest version of Chrome Canary. It also means we can remove some of our patches as some changes have been upstreamed!
- Loading branch information
1 parent
f87b45a
commit fbef4f1
Showing
48 changed files
with
509 additions
and
504 deletions.
There are no files selected for viewing
17 changes: 4 additions & 13 deletions
17
...amoat-lavapack-npm-5.4.1-2548b3e225.patch → ...amoat-lavapack-npm-6.0.2-abebdc70c1.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 0 additions & 30 deletions
30
.yarn/patches/lavamoat-browserify-npm-15.9.1-12130e68ce.patch
This file was deleted.
Oops, something went wrong.
39 changes: 39 additions & 0 deletions
39
.yarn/patches/lavamoat-browserify-npm-17.0.2-7b95761e43.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
diff --git a/src/index.js b/src/index.js | ||
index db802666fb1126700dc604008d51c0f152b6cb37..f9f232171db273991334c9a4b3746ccc66fdda4d 100644 | ||
--- a/src/index.js | ||
+++ b/src/index.js | ||
@@ -8,6 +8,7 @@ const createLavaPack = require('@lavamoat/lavapack') | ||
const { createSesWorkaroundsTransform } = require('./sesTransforms') | ||
const { loadCanonicalNameMap } = require('@lavamoat/aa') | ||
const browserResolve = require('browser-resolve') | ||
+const { isBuiltin } = require('node:module') | ||
|
||
// these are the reccomended arguments for lavaMoat to work well with browserify | ||
const reccomendedArgs = { | ||
@@ -72,7 +73,7 @@ function plugin(browserify, pluginOpts) { | ||
createModuleInspectorSpy({ | ||
policyOverride, | ||
// no builtins in the browser (yet!) | ||
- isBuiltin: () => false, | ||
+ isBuiltin: (name) => browserify._options.node && isBuiltin(name), | ||
// should prepare debug info | ||
includeDebugInfo: configuration.writeAutoPolicyDebug, | ||
// write policy files to disk | ||
@@ -321,7 +322,7 @@ function validatePolicy(policy) { | ||
Object.entries(policy.resources).forEach(([, packageOpts]) => { | ||
const packageOptions = Object.keys(packageOpts) | ||
const packageEntries = Object.values(packageOpts) | ||
- const optionsWhitelist = ['globals', 'packages'] | ||
+ const optionsWhitelist = ['globals', 'packages', 'builtin'] | ||
const valuesWhitelist = [true, 'write'] | ||
|
||
if ( | ||
@@ -330,7 +331,7 @@ function validatePolicy(policy) { | ||
) | ||
) { | ||
throw new Error( | ||
- "LavaMoat - Unrecognized package options. Expected 'globals' or 'packages'" | ||
+ "LavaMoat - Unrecognized package options. Expected 'globals', 'packages' or 'builtin'" | ||
) | ||
} | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.