Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependency stylelint to v15 [SECURITY] - autoclosed #1126

Closed
wants to merge 1 commit into from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jul 7, 2023

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
stylelint (source) 14.11.0 -> 15.10.1 age adoption passing confidence

GitHub Vulnerability Alerts

GHSA-f7xj-rg7h-mc87

Summary

Our meow dependency (which we use for our CLI) depended on semver@5.7.1 . A vulnerability in this version of semver was recently identified and surfaced by npm audit:

Regular Expression Denial of Service - GHSA-c2qf-rxjj-qqgw

Details

Original post by the reporter:

"my npm audit show the report

semver <7.5.2
Severity: moderate
semver vulnerable to Regular Expression Denial of Service - GHSA-c2qf-rxjj-qqgw
No fix available

And my dependencies tree for semver show your package

├─┬ stylelint@15.9.0
│ └─┬ meow@9.0.0
│ └─┬ read-pkg-up@7.0.1
│ └─┬ read-pkg@5.2.0
│ └─┬ normalize-package-data@2.5.0
│ └── semver@5.7.1 deduped

I found that meow@10.x.x contains normalize-package-data@5 and I can fix this vulnerability because it uses semver@7. But I can't update meow to the new major version because your package doesn't allow it."

Update your package to use the 'meow' version >=10"

PoC

N/A

Impact

We anticipate the impact to be low as Stylelint is a dev tool and meow is only used on the CLI pathway.


⬇️ EDITED AFTER PUBLISHED ⬇️

Security fix backported to older semver versions

The same security fix has been backported to older semver versions of 5.x and 6.x. See the CVE-2022-25883 details.

So, you can fix this vulnerability by just updating semver in your project's dependency tree, instead of updating stylelint. For details, see the example:

package.json:

{
  "dependencies": {
    "stylelint": "15.10.0"
  }
}

Run npm audit (here is no alert for semver):

$ npm ci
...

$ npm audit
...
stylelint  8.0.0 - 15.10.0
Stylelint has vulnerability in semver dependency - https://github.com/advisories/GHSA-f7xj-rg7h-mc87
fix available via `npm audit fix --force`
Will install stylelint@15.10.1, which is outside the stated dependency range
node_modules/stylelint

1 low severity vulnerability
...

$ npm ls semver
...
└─┬ stylelint@15.10.0
  └─┬ meow@9.0.0
    ├─┬ normalize-package-data@3.0.3
    │ └── semver@7.5.4
    └─┬ read-pkg-up@7.0.1
      └─┬ read-pkg@5.2.0
        └─┬ normalize-package-data@2.5.0
          └── semver@5.7.2

Release Notes

stylelint/stylelint (stylelint)

v15.10.1

Compare Source

v15.10.0

Compare Source

v15.9.0

Compare Source

  • Added: insideFunctions: {"function": int} to number-max-precision (#​6932) (@​romainmenke).
  • Fixed: declaration-block-no-redundant-longhand-properties autofix for border-radius shorthand (#​6958) (@​mattxwang).
  • Fixed: declaration-block-no-redundant-longhand-properties autofix for border-width shorthand (#​6956) (@​mattxwang).
  • Fixed: declaration-block-no-redundant-longhand-properties autofix for grid-column and grid-row (#​6957) (@​mattxwang).

v15.8.0

Compare Source

v15.7.0

Compare Source

v15.6.3

Compare Source

v15.6.2

Compare Source

v15.6.1

Compare Source

v15.6.0

Compare Source

  • Added: allowEmptyInput, cache, fix options to configuration object (#​6778) (@​mattxwang).
  • Added: ignore: ["with-var-inside"] to color-function-notation (#​6802) (@​mattxwang).
  • Fixed: declaration-block-no-duplicate-properties autofix for 3 or more duplicates (#​6801) (@​mattxwang).
  • Fixed: declaration-block-no-duplicate-properties false positives with option ignore: ["consecutive-duplicates-with-different-syntaxes"] (#​6797) (@​romainmenke).
  • Fixed: declaration-block-no-duplicate-properties syntax error (#​6792) (@​yoyo837).
  • Fixed: declaration-block-no-redundant-longhand-properties autofix for grid-template (#​6777) (@​mattxwang).
  • Fixed: function-url-quotes autofix for comments in SCSS function (#​6800) (@​ybiquitous).

v15.5.0

Compare Source

v15.4.0

Compare Source

v15.3.0

Compare Source

v15.2.0

Compare Source

v15.1.0

Compare Source

v15.0.0

Compare Source

Migrating to 15.0.0 guide.

v14.16.1

Compare Source

  • Fixed: customSyntax resolution with configBasedir (#​6536) (@​ybiquitous).
  • Fixed: declaration-block-no-duplicate-properties autofix for !important (#​6528) (@​sidx1024).
  • Fixed: function-no-unknown false positives for scroll, -webkit-gradient, color-stop, from, and to (#​6539) (@​Mouvedia).
  • Fixed: value-keyword-case false positives for mixed case ignoreFunctions option (#​6517) (@​kimulaco).
  • Fixed: unexpected output in Node.js API lint result when any rule contains disableFix: true (#​6543) (@​adrianjost).

v14.16.0

Compare Source

v14.15.0

Compare Source

v14.14.1

Compare Source

  • Fixed: declaration-block-no-redundant-longhand-properties false positives for inherit keyword (#​6419) (@​kimulaco).
  • Fixed: shorthand-property-no-redundant-values message to be consistent (#​6417) (@​fpetrakov).
  • Fixed: unit-no-unknown false positives for *vi & *vb viewport units (#​6428) (@​sidverma32).

v14.14.0

Compare Source

v14.13.0

Compare Source

v14.12.1

Compare Source

v14.12.0

Compare Source


Configuration

📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot added the Renovate Renovate App label Jul 7, 2023
@renovate
Copy link
Contributor Author

renovate bot commented Jul 7, 2023

⚠ Artifact update problem

Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.

♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

  • any of the package files in this branch needs updating, or
  • the branch becomes conflicted, or
  • you click the rebase/retry checkbox if found above, or
  • you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:

File name: package-lock.json
/usr/local/bin/docker: line 4: .: filename argument required
.: usage: . filename [arguments]
npm notice 
npm notice New major version of npm available! 8.19.4 -> 9.8.0
npm notice Changelog: <https://github.com/npm/cli/releases/tag/v9.8.0>
npm notice Run `npm install -g npm@9.8.0` to update!
npm notice 
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: grunt-stylelint@0.18.0
npm ERR! Found: stylelint@15.10.1
npm ERR! node_modules/stylelint
npm ERR!   dev stylelint@"15.10.1" from the root project
npm ERR!   peer stylelint@">=10.1.0" from stylelint-config-recommended@3.0.0
npm ERR!   node_modules/stylelint-config-recommended
npm ERR!     stylelint-config-recommended@"^3.0.0" from stylelint-config-recommended-scss@4.2.0
npm ERR!     node_modules/stylelint-config-recommended-scss
npm ERR!       stylelint-config-recommended-scss@"^4.2.0" from stylelint-config-wordpress@17.0.0
npm ERR!       node_modules/stylelint-config-wordpress
npm ERR!         dev stylelint-config-wordpress@"17.0.0" from the root project
npm ERR!     stylelint-config-recommended@"^3.0.0" from stylelint-config-wordpress@17.0.0
npm ERR!     node_modules/stylelint-config-wordpress
npm ERR!       dev stylelint-config-wordpress@"17.0.0" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer stylelint@"14.x" from grunt-stylelint@0.18.0
npm ERR! node_modules/grunt-stylelint
npm ERR!   dev grunt-stylelint@"0.18.0" from the root project
npm ERR! 
npm ERR! Conflicting peer dependency: stylelint@14.16.1
npm ERR! node_modules/stylelint
npm ERR!   peer stylelint@"14.x" from grunt-stylelint@0.18.0
npm ERR!   node_modules/grunt-stylelint
npm ERR!     dev grunt-stylelint@"0.18.0" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR! 
npm ERR! See /tmp/worker/4348d9/030fe8/cache/others/npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     /tmp/worker/4348d9/030fe8/cache/others/npm/_logs/2023-07-10T11_29_58_203Z-debug-0.log

@renovate renovate bot force-pushed the renovate/npm-stylelint-vulnerability branch from 7618461 to 11de28d Compare July 10, 2023 11:30
@renovate renovate bot changed the title Update dependency stylelint to v15 [SECURITY] Update dependency stylelint to v15 [SECURITY] - autoclosed Jul 13, 2023
@renovate renovate bot closed this Jul 13, 2023
@renovate renovate bot deleted the renovate/npm-stylelint-vulnerability branch July 13, 2023 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Renovate Renovate App
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants