snaps icon indicating copy to clipboard operation
snaps copied to clipboard

chore: Replace `lavamoat` with `@lavamoat/node`

Open Mrtenz opened this issue 1 month ago • 3 comments

@lavamoat/node is not production-ready yet, just testing.

[!NOTE] Switches from lavamoat to @lavamoat/node and refreshes the lockfile to reflect new/transitive dependencies and version bumps.

  • Build/Tooling:
    • Replace lavamoat with @lavamoat/node in packages/snaps-execution-environments/package.json devDependencies and workspace deps.
    • Update yarn.lock to add @lavamoat/node and its transitive deps (@endo/*, lavamoat-core@^17, terminal-link, loggerr, etc.) and remove lavamoat and its native build-related deps.
    • Refresh lockfile versions for several packages (notably @babel/*, @jridgewell/*, @types/node, chalk, supports-color) aligning with new dependency graph.

Written by Cursor Bugbot for commit 4d21bc1a637effe2260cca555608340a4500a3ea. This will update automatically on new commits. Configure here.

Mrtenz avatar Oct 28 '25 11:10 Mrtenz

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​babel/​types@​7.28.4 ⏵ 7.28.598 +110081 +197100
Updated@​types/​node@​22.7.5 ⏵ 22.18.12100 +110081 +195100
Added@​lavamoat/​node@​0.4.6100100100100100

View full report

socket-security[bot] avatar Oct 28 '25 11:10 socket-security[bot]

[!CAUTION] MetaMask internal reviewing guidelines:

  • Do not ignore-all
  • Each alert has instructions on how to review if you don't know what it means. If lost, ask your Security Liaison or the supply-chain group
  • Copy-paste ignore lines for specific packages or a group of one kind with a note on what research you did to deem it safe.
    @SocketSecurity ignore npm/PACKAGE@VERSION
Action Severity Alert  (click "▶" to expand/collapse)
Block Low
[email protected] has a New author.

New Author: sindresorhus

Previous Author: jamestalmage

From: ?npm/@lavamoat/[email protected]npm/[email protected]

ℹ Read more on: This package | This alert | What is new author?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at [email protected].

Suggestion: Scrutinize new collaborator additions to packages because they now have the ability to publish code into your dependency tree. Packages should avoid frequent or unnecessary additions or changes to publishing rights.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/[email protected]. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Warn Low
[email protected] is a AI-detected potential code anomaly.

Notes: The code is a standard Function.prototype.bind polyfill implementation. It carefully handles this binding, constructor behavior, and argument binding without introducing observable malicious behavior. The dynamic Function constructor is used as part of a legitimate polyfill technique and does not indicate an attack by itself in this context.

Confidence: 1.00

Severity: 0.60

From: ?npm/[email protected]npm/[email protected]npm/@lavamoat/[email protected]npm/[email protected]

ℹ Read more on: This package | This alert | What is an AI-detected potential code anomaly?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at [email protected].

Suggestion: An AI system found a low-risk anomaly in this package. It may still be fine to use, but you should check that it is safe before proceeding.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/[email protected]. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

View full report

socket-security[bot] avatar Oct 28 '25 11:10 socket-security[bot]

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 98.28%. Comparing base (4900021) to head (74f6817). :warning: Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3710   +/-   ##
=======================================
  Coverage   98.28%   98.28%           
=======================================
  Files         418      418           
  Lines       12152    12152           
  Branches     1876     1876           
=======================================
  Hits        11943    11943           
  Misses        209      209           

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Oct 28 '25 11:10 codecov[bot]