Mitigate supply chain attacks with npmMinimalAgeGate and Lavamoat#88
Merged
Merged
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub. |
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. Ignoring alerts on:
|
Collaborator
Author
|
@SocketSecurity ignore npm/node-gyp@10.3.1 Reviewed release history and socket security page. Well maintained and utilised package. One major version behind latest. |
npmMinimalAgeGate and Lavamoat
hanzel98
approved these changes
Oct 21, 2025
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Yarn 4.10.0 introduces the
npmMinimalAgeGatesetting that allows a package to specify the minimum age that a package must be before it is installed. It has been recommended that we set a value of 3 days to mitigate supply chain attacks such as the recent event that targeted developer environments via compromised npm publisher accounts.https://medium.com/@roman_fedyskyi/yarn-4-10-adds-a-release-age-gate-for-safer-dependency-management-765c2d18149a
This PR updates the package manager to 4.10.0 and sets the value for
npmMinimalAgeGateto 3 days (4320 minutes).Yarn 4 also includes yarn org plugins by default, so it is no longer necessary to specify these.
This PR also introduced
@lavamoat/allow-scriptsand@lavamoat/preinstall-always-failto ensure that no malicious lifecycle scripts are run.📋 Checklist
Check off completed items:
🔗 Related Issues
Link to related issues:
Closes #
Related to #
📚 Additional Notes
Any additional information, concerns, or context:
Note
Upgrades Yarn to 4.10.0, enforces a 3‑day package age gate, and adds LavaMoat allow-scripts/preinstall safeguards.
packageManagertoyarn@4.10.0; configurenpmMinimalAgeGate: 4320in.yarnrc.yml.@lavamoat/allow-scriptsand@lavamoat/preinstall-always-failtodevDependencies.lavamoat.allowScriptsconfig inpackage.json(disables scripts for@lavamoat/preinstall-always-failandkeccak).allow-scriptsnpm script.Written by Cursor Bugbot for commit 586d593. This will update automatically on new commits. Configure here.