Skip to content

Update dependency gatsby-plugin-sharp to v4.25.1 [SECURITY]#472

Open
renovate[bot] wants to merge 1 commit intomasterfrom
renovate/npm-gatsby-plugin-sharp-vulnerability
Open

Update dependency gatsby-plugin-sharp to v4.25.1 [SECURITY]#472
renovate[bot] wants to merge 1 commit intomasterfrom
renovate/npm-gatsby-plugin-sharp-vulnerability

Conversation

@renovate
Copy link
Contributor

@renovate renovate bot commented May 29, 2023

This PR contains the following updates:

Package Change Age Confidence
gatsby-plugin-sharp (source) 4.23.04.25.1 age confidence

GitHub Vulnerability Alerts

CVE-2023-30548

Impact

The gatsby-plugin-sharp plugin prior to versions 5.8.1 and 4.25.1 contains a path traversal vulnerability exposed when running the Gatsby develop server (gatsby develop).

The following steps can be used to reproduce the vulnerability:


# Create a new Gatsby project, and install gatsby-plugin-sharp
$ npm init gatsby
$ cd my-gatsby-site
$ npm install gatsby-plugin-sharp

# Add the plugin to gatsby-config.js
module.exports = {
  plugins: [
    {
      resolve: `gatsby-plugin-sharp`,
    },
  ]
}

# Start the Gatsby develop server
$ gatsby develop

# Execute the path traversal vulnerability
$ curl "http://127.0.0.1:8000/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/etc/passwd"

It should be noted that by default gatsby develop is only accessible via the localhost 127.0.0.1, and one would need to intentionally expose the server to other interfaces to exploit this vulnerability by using server options such as --host 0.0.0.0, -H 0.0.0.0, or the GATSBY_HOST=0.0.0.0 environment variable.

Patches

A patch has been introduced in gatsby-plugin-sharp@5.8.1 and gatsby-plugin-sharp@4.25.1 which mitigates the issue by ensuring that included paths remain within the project directory.

Workarounds

As stated above, by default gatsby develop is only exposed to the localhost 127.0.0.1. For those using the develop server in the default configuration no risk is posed. If other ranges are required, preventing the develop server from being exposed to untrusted interfaces or IP address ranges would mitigate the risk from this vulnerability.

We encourage projects to upgrade to the latest major release branch for all Gatsby plugins to ensure the latest security updates and bug fixes are received in a timely manner.

Credits

We would like to thank Patrick Rombouts and Bart Veneman [drukwerkdeal.nl] for bringing the issue to our attention.

For more information

Email us at security@gatsbyjs.com.


Release Notes

gatsbyjs/gatsby (gatsby-plugin-sharp)

v4.25.1

Compare Source

v4.25.0

Compare Source

v4.24.0

Compare Source

🧾 Release notes

Note: Version bump only for package gatsby-plugin-sharp

4.23.1 (2022-09-22)

Note: Version bump only for package gatsby-plugin-sharp

v4.23.1

Compare Source

🧾 Release notes

Note: Version bump only for package gatsby-plugin-sharp

4.23.1 (2022-09-22)

Note: Version bump only for package gatsby-plugin-sharp


Configuration

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

🚦 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.


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

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot changed the title Update dependency gatsby-plugin-sharp to v4.25.1 [SECURITY] Update dependency gatsby-plugin-sharp to v4.25.1 [SECURITY] - autoclosed Sep 19, 2023
@renovate renovate bot closed this Sep 19, 2023
@renovate renovate bot deleted the renovate/npm-gatsby-plugin-sharp-vulnerability branch September 19, 2023 22:44
@renovate renovate bot changed the title Update dependency gatsby-plugin-sharp to v4.25.1 [SECURITY] - autoclosed Update dependency gatsby-plugin-sharp to v4.25.1 [SECURITY] Sep 20, 2023
@renovate renovate bot reopened this Sep 20, 2023
@renovate renovate bot restored the renovate/npm-gatsby-plugin-sharp-vulnerability branch September 20, 2023 00:47
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch from cc03822 to 5e7bb84 Compare September 20, 2023 00:48
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch 2 times, most recently from d83cd1e to 70d70dd Compare August 13, 2025 14:31
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch from 70d70dd to 22af025 Compare August 19, 2025 12:46
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch from 22af025 to 4ed9b0c Compare September 25, 2025 16:58
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch from 4ed9b0c to 2ab8817 Compare November 10, 2025 19:35
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch from 2ab8817 to 0a5b6fb Compare November 18, 2025 12:04
@renovate renovate bot force-pushed the renovate/npm-gatsby-plugin-sharp-vulnerability branch from 0a5b6fb to a64b8b9 Compare January 19, 2026 18:57
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.

0 participants