Skip to content

[Snyk] Security upgrade rimraf from 2.7.1 to 6.1.1#152

Open
MHxGH-ServiceAccount wants to merge 1 commit intomasterfrom
snyk-fix-09abaeb54fead36f9cdd6ffd14b46c9e
Open

[Snyk] Security upgrade rimraf from 2.7.1 to 6.1.1#152
MHxGH-ServiceAccount wants to merge 1 commit intomasterfrom
snyk-fix-09abaeb54fead36f9cdd6ffd14b46c9e

Conversation

@MHxGH-ServiceAccount
Copy link

@MHxGH-ServiceAccount MHxGH-ServiceAccount commented Feb 27, 2026

snyk-top-banner

Snyk has created this PR to fix 1 vulnerabilities in the npm dependencies of this project.

Snyk changed the following file(s):

  • packages/navy/package.json
  • packages/navy/package-lock.json

Vulnerabilities that will be fixed with an upgrade:

Issue Score
high severity Inefficient Algorithmic Complexity
SNYK-JS-MINIMATCH-15353389
  170  

Breaking Change Risk

Merge Risk: High

Notice: This assessment is enhanced by AI.


Important

  • Check the changes in this PR to ensure they won't cause issues with your project.
  • Max score is 1000. Note that the real score may have changed since the PR was raised.
  • This PR was automatically created by Snyk using the credentials of a real user.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.

For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic


Learn how to fix vulnerabilities with free interactive lessons:

🦉 Learn about vulnerability in an interactive lesson of Snyk Learn.


Note

Medium Risk
Medium risk because it upgrades rimraf across a major version jump, which can subtly change file deletion semantics and glob behavior in CLI cleanup/state deletion paths.

Overview
Upgrades rimraf in packages/navy from ^2.7.1 to ^6.1.1 to remediate a vulnerability in the dependency chain (via newer glob/minimatch).

The lockfile is updated accordingly, replacing older transitive packages (e.g., glob@7, minimatch@3, brace-expansion@1) with newer versions and adding new supporting deps (e.g., foreground-child, path-scurry, lru-cache, cross-spawn).

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

…reduce vulnerabilities

The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-MINIMATCH-15353389
@MHxGH-ServiceAccount
Copy link
Author

Merge Risk: High

This is a major version upgrade from v2 to v6, introducing several significant breaking changes that require code and environment updates.

Key Breaking Changes:

  • Node.js Requirement: Version 6.x requires Node.js v20 or higher.
  • ESM Imports: v5.x removed the default export. You must now use named imports. For example, const rimraf = require('rimraf') must be changed to const { rimraf } = require('rimraf') or import { rimraf } from 'rimraf'.
  • Promise-based API: v4.x changed the asynchronous API to return Promises instead of using callbacks. Code using callbacks with rimraf will need to be updated to use async/await or .then().
  • Globbing Disabled by Default: Starting with v4.x, glob patterns are no longer matched by default. To remove files using glob patterns, you must set the glob option to true.

Recommendation:
Due to the multiple breaking changes, this upgrade requires careful code review and refactoring. Pay close attention to asynchronous calls, import statements, and any usage of glob patterns. Ensure your Node.js environment meets the new version requirement.

Source: Package documentation

Notice 🤖: This content was augmented using artificial intelligence. AI-generated content may contain errors and should be reviewed for accuracy before use.

@MHxGH-ServiceAccount
Copy link
Author

MHxGH-ServiceAccount commented Feb 27, 2026

Snyk checks have passed. No issues have been found so far.

Status Scanner Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

"ramda": "^0.28.0",
"resolve": "^1.20.0",
"rimraf": "^2.7.1",
"rimraf": "^6.1.1",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rimraf v6 removes default export, breaking existing usage

High Severity

Upgrading rimraf to v6 breaks the existing call sites. require('rimraf') no longer returns a function — it returns an object with named exports. Both state.js and clean-compose-files.js use bluebird.promisify(require('rimraf')), which will fail at runtime because promisify expects a callback-style function but receives an object. The correct v6 usage is const { rimraf } = require('rimraf'), and since rimraf v6 already returns Promises, bluebird.promisify is no longer needed.

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants