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

chore(deps): update dependency sharp to 0.32.6 [security] #671

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

svc-secops
Copy link
Contributor

This PR contains the following updates:

Package Change
sharp 0.29.3 -> 0.32.6

GitHub Vulnerability Alerts

CVE-2022-29256

There's a possible vulnerability in logic that is run only at npm install time when installing versions of sharp prior to the latest v0.30.5.

This is not part of any runtime code, does not affect Windows users at all, and is unlikely to affect anyone that already cares about the security of their build environment. However, out of an abundance of caution, I've created this advisory.

If an attacker has the ability to set the value of the PKG_CONFIG_PATH environment variable in a build environment then they might be able to use this to inject an arbitrary command at npm install time.

I've used the Common Vulnerability Scoring System (CVSS) calculator to determine the maximum possible impact, which suggests a "medium" score of 5.9, but for most people the real impact will be dealing with the noise from automated security tooling that this advisory will bring.

AV:L/AC:L/PR:H/UI:R/S:U/C:H/I:H/A:H/E:P/RL:O/RC:C/CR:X/IR:X/AR:X/MAV:X/MAC:X/MPR:X/MUI:R/MS:X/MC:X/MI:X/MA:X

This problem was fixed in commit a6aeef6 and published as part of sharp v0.30.5.

Thank you very much to @​dwisiswant0 for the responsible disclosure.

Remember: if an attacker has control over environment variables in your build environment then you have a bigger problem to deal with than this issue.

GHSA-54xq-cgqr-rpm3

Overview

sharp uses libwebp to decode WebP images and versions prior to the latest 0.32.6 are vulnerable to the high severity GHSA-j7hp-h8jx-5ppr.

Who does this affect?

Almost anyone processing untrusted input with versions of sharp prior to 0.32.6.

How to resolve this?

Using prebuilt binaries provided by sharp?

Most people rely on the prebuilt binaries provided by sharp.

Please upgrade sharp to the latest 0.32.6, which provides libwebp 1.3.2.

Using a globally-installed libvips?

Please ensure you are using the latest libwebp 1.3.2.

Possible workaround

Add the following to your code to prevent sharp from decoding WebP images.

sharp.block({ operation: ["VipsForeignLoadWebp"] });

Configuration

📅 Schedule: Branch creation - "" in timezone Etc/UTC, Automerge - "after 8am and before 4pm on tuesday" in timezone Etc/UTC.

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

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.


This PR has been generated by Renovate Bot.

@svc-secops svc-secops requested a review from a team as a code owner December 19, 2023 12:38
@svc-secops svc-secops added dependencies Pull requests that update a dependency file vulnerability labels Dec 19, 2023
@svc-secops
Copy link
Contributor Author

svc-secops commented Dec 19, 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
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: docs@undefined
npm ERR! Found: gatsby@4.25.4
npm ERR! node_modules/gatsby
npm ERR!   gatsby@"4.25.4" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer gatsby@"^5.0.0-next" from gatsby-plugin-manifest@5.13.1
npm ERR! node_modules/gatsby-plugin-manifest
npm ERR!   gatsby-plugin-manifest@"^5.0.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/renovate/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/renovate/cache/others/npm/_logs/2024-05-09T12_42_49_988Z-debug-0.log

Copy link

netlify bot commented Dec 19, 2023

Deploy Preview for apollo-monodocs failed.

Name Link
🔨 Latest commit 5a00cc3
🔍 Latest deploy log https://app.netlify.com/sites/apollo-monodocs/deploys/6644a7f8d041a40008a7f90d

@Meschreiber
Copy link
Contributor

@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch from d806c51 to c0acf2c Compare December 21, 2023 13:14
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 6 times, most recently from 167336d to 1d25082 Compare January 10, 2024 13:04
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 4 times, most recently from f7948a4 to 996169e Compare January 17, 2024 13:02
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 5 times, most recently from 2c77ba9 to 368c72d Compare January 26, 2024 12:55
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 4 times, most recently from cd6f441 to 0ce237f Compare February 8, 2024 12:37
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 4 times, most recently from 9b2b747 to f482b77 Compare February 17, 2024 12:24
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 3 times, most recently from 58365f4 to a8676e9 Compare February 23, 2024 12:40
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 4 times, most recently from c8df648 to 5c326c6 Compare March 12, 2024 12:33
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 6 times, most recently from 1e08dfd to c405776 Compare March 20, 2024 12:13
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 3 times, most recently from 0300e34 to 825bf01 Compare March 23, 2024 11:37
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 3 times, most recently from dc2208d to 588375a Compare April 4, 2024 11:07
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 3 times, most recently from 72a9192 to d66ec08 Compare April 22, 2024 13:46
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 2 times, most recently from b7b93cd to 1752d63 Compare May 1, 2024 11:51
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch 2 times, most recently from 9a3ce09 to cbe23d1 Compare May 9, 2024 12:42
@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch from cbe23d1 to 83db8c6 Compare May 11, 2024 11:54
@svc-secops
Copy link
Contributor Author

svc-secops commented May 11, 2024

⚠️ 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
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: docs@undefined
npm ERR! Found: gatsby@4.25.4
npm ERR! node_modules/gatsby
npm ERR!   gatsby@"4.25.4" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer gatsby@"^5.0.0-next" from gatsby-plugin-manifest@5.13.1
npm ERR! node_modules/gatsby-plugin-manifest
npm ERR!   gatsby-plugin-manifest@"^5.0.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/renovate/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/renovate/cache/others/npm/_logs/2024-05-15T12_17_49_923Z-debug-0.log

@svc-secops svc-secops force-pushed the renovate/npm-sharp-vulnerability branch from 83db8c6 to 5a00cc3 Compare May 15, 2024 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file vulnerability
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants