Skip to content

fix(deps): update dependency gatsby-transformer-remark to v6 [security]#840

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/npm-gatsby-transformer-remark-vulnerability
Open

fix(deps): update dependency gatsby-transformer-remark to v6 [security]#840
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/npm-gatsby-transformer-remark-vulnerability

Conversation

@renovate
Copy link
Copy Markdown
Contributor

@renovate renovate Bot commented Apr 15, 2026

This PR contains the following updates:

Package Change Age Confidence
gatsby-transformer-remark (source) ^5.24.0^6.0.0 age confidence

gatsby-transformer-remark has possible unsanitized JavaScript code injection

CVE-2023-22491 / GHSA-7ch4-rr99-cqcw

More information

Details

Impact

The gatsby-transformer-remark plugin prior to versions 5.25.1 and 6.3.2 passes input through to the gray-matter npm package, which is vulnerable to JavaScript injection in its default configuration, unless input is sanitized. The vulnerability is present in gatsby-transformer-remark when passing input in data mode (querying MarkdownRemark nodes via GraphQL). Injected JavaScript executes in the context of the build server.

To exploit this vulnerability untrusted/unsanitized input would need to be sourced by or added into a file processed by gatsby-transformer-remark. The following payload demonstrates a vulnerable configuration:

---js
((require("child_process")).execSync("id >> /tmp/rce"))
--- 
Patches

A patch has been introduced in gatsby-transformer-remark@5.25.1 and gatsby-transformer-remark@6.3.2 which mitigates the issue by disabling the gray-matter JavaScript Frontmatter engine. The patch introduces a new option, JSFrontmatterEngine which is set to false by default. When setting JSFrontmatterEngine to true, input passed to gatsby-plugin-mdx must be sanitized before processing to avoid a security risk. Warnings are displayed when enabling JSFrontmatterEngine to true or if it appears that the MarkdownRemark input is attempting to use the Frontmatter engine.

Workarounds

If an older version of gatsby-transformer-remark must be used, input passed into the plugin should be sanitized ahead of processing.

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.

For more information

Email us at security@gatsbyjs.com.

Severity

  • CVSS Score: 8.1 / 10 (High)
  • Vector String: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N

References

This data is provided by the GitHub Advisory Database (CC-BY 4.0).


Release Notes

gatsbyjs/gatsby (gatsby-transformer-remark)

v6.3.2

Compare Source

🧾 Release notes

Bug Fixes
Chores
6.3.2 (2022-12-20)
Bug Fixes
6.3.1 (2022-12-14)

Note: Version bump only for package gatsby-transformer-remark

v6.3.1

Compare Source

🧾 Release notes

Bug Fixes
Chores
6.3.2 (2022-12-20)
Bug Fixes
6.3.1 (2022-12-14)

Note: Version bump only for package gatsby-transformer-remark

v6.3.0

Compare Source

🧾 Release notes

Bug Fixes
  • update minor and patch dependencies for gatsby-transformer-remark #​37164 (b7d1db7)

v6.2.0

Compare Source

🧾 Release notes

Other Changes

v6.1.0

Compare Source

🧾 Release notes

Note: Version bump only for package gatsby-transformer-remark

v6.0.0

Compare Source

🧾 Release notes

Chores

Configuration

📅 Schedule: (UTC)

  • Branch creation
    • ""
  • 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 requested a review from a team as a code owner April 15, 2026 18:34
@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 15, 2026

Deploy Preview for netlify-plugin-gatsby-demo-v5 ready!

Name Link
🔨 Latest commit 729d323
🔍 Latest deploy log https://app.netlify.com/projects/netlify-plugin-gatsby-demo-v5/deploys/69dfda2b541b040008825b50
😎 Deploy Preview https://deploy-preview-840--netlify-plugin-gatsby-demo-v5.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 15, 2026

Deploy Preview for netlify-plugin-gatsby-demo failed. Why did it fail? →

Name Link
🔨 Latest commit 729d323
🔍 Latest deploy log https://app.netlify.com/projects/netlify-plugin-gatsby-demo/deploys/69dfda2b3dadd10007122046

@renovate renovate Bot force-pushed the renovate/npm-gatsby-transformer-remark-vulnerability branch from 729d323 to 811a411 Compare May 12, 2026 14:56
@netlify
Copy link
Copy Markdown

netlify Bot commented May 12, 2026

Deploy Preview for netlify-plugin-gatsby-demo-v5 ready!

Name Link
🔨 Latest commit 154a561
🔍 Latest deploy log https://app.netlify.com/projects/netlify-plugin-gatsby-demo-v5/deploys/6a0b454a811d340008f16d69
😎 Deploy Preview https://deploy-preview-840--netlify-plugin-gatsby-demo-v5.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify
Copy link
Copy Markdown

netlify Bot commented May 12, 2026

Deploy Preview for netlify-plugin-gatsby-demo failed. Why did it fail? →

Name Link
🔨 Latest commit 154a561
🔍 Latest deploy log https://app.netlify.com/projects/netlify-plugin-gatsby-demo/deploys/6a0b454ad494010008cd6029

@renovate renovate Bot force-pushed the renovate/npm-gatsby-transformer-remark-vulnerability branch from 811a411 to 154a561 Compare May 18, 2026 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants