Skip to content

Update dependency preact to v10.27.3 [SECURITY]#40

Open
renovate[bot] wants to merge 1 commit intomainfrom
renovate/npm-preact-vulnerability
Open

Update dependency preact to v10.27.3 [SECURITY]#40
renovate[bot] wants to merge 1 commit intomainfrom
renovate/npm-preact-vulnerability

Conversation

@renovate
Copy link
Copy Markdown
Contributor

@renovate renovate Bot commented Jan 7, 2026

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
preact (source) 10.27.210.27.3 age adoption passing confidence

Preact has JSON VNode Injection issue

CVE-2026-22028 / GHSA-36hm-qxxp-pg3m

More information

Details

Impact

Vulnerability Type: HTML Injection via JSON Type Confusion

Affected Versions: Preact 10.26.5 through 10.28.1

Severity: Low to Medium (see below)

Who is Impacted?

Applications using affected Preact versions are vulnerable if they meet all of the following conditions:

  1. Pass unmodified, unsanitized values from user-modifiable data sources (APIs, databases, local storage, etc.) directly into the render tree
  2. Assume these values are strings but the data source could return actual JavaScript objects instead of JSON strings
  3. The data source either:
    • Fails to perform type sanitization AND blindly stores/returns raw objects interchangeably with strings, OR
    • Is compromised (e.g., poisoned local storage, filesystem, or database)
Technical Details

Preact includes JSON serialization protection to prevent Virtual DOM elements from being constructed from arbitrary JSON. A regression introduced in Preact 10.26.5 caused this protection to be softened. In applications where values from JSON payloads are assumed to be strings and passed unmodified to Preact as children, a specially-crafted JSON payload could be constructed that would be incorrectly treated as a valid VNode. When this chain of failures occurs it can result in HTML injection, which can allow arbitrary script execution if not mitigated by CSP or other means.

Important Notes:

  • This regression was never present in preact-render-to-string
  • This is primarily an "expanded attack surface" issue rather than a standalone vulnerability
  • Exploitation requires either insecure API design (no type validation) or a compromised data source
Patches

Patched Versions:

  • 10.26.10 (for 10.26.x users)
  • 10.27.3 (for 10.27.x users)
  • 10.28.2 (for 10.28.x users)

Users should upgrade to the latest patch version of whatever minor version they are on, which can be done via npm update preact or by installing one of the above versions directly.

The patch versions simply restore the previous strict equality checks that prevent JSON-parsed objects from being treated as valid VNodes.

Mitigations

If you cannot upgrade immediately, implement the following mitigations:

  • Validate input types: Don't accept arbitrary objects as inputs in your API and blindly store them. Enforce strict type contracts at API boundaries.
  • Cast or validate network data: Don't assume strings are strings if your code got them from the network. Always cast to the expected type or validate before rendering.
  • Sanitize external data: Validate that data from external sources (APIs, storage, databases) matches expected types before passing it to preact.
  • Use Content Security Policy (CSP): Implement a strict CSP to prevent inline script execution as a defense-in-depth measure.
References
  • Reporter: YoungGeun Choi
  • Affected Versions: 10.26.5 - 10.28.1
  • Patched Versions: 10.26.10, 10.27.3, 10.28.2
Credits

Preact thanks YoungGeun Choi (Xvezda) for the responsible disclosure of this vulnerability and for providing detailed reproduction steps and proof-of-concept demonstrations.

Timeline
  • 2026-01-04: Initial vulnerability report received
  • 2026-01-05: Clarification requested regarding network/serialization boundary
  • 2026-01-06: Network PoC provided demonstrating real-world exploitatibility
  • 2026-01-06: Hotfix patches released (10.26.10, 10.27.3, 10.28.2)

Recommendation: All users of Preact 10.26.5 through 10.28.1 should upgrade to the appropriate patched version (10.26.10, 10.27.3, or 10.28.2) as soon as possible, and review their applications for proper input validation and sanitization practices.

Severity

  • CVSS Score: 7.2 / 10 (High)
  • Vector String: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U

References

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


Release Notes

preactjs/preact (preact)

v10.27.3

Compare Source

Fixes

  • Enforce strict equality for VNode object constructors

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.

@netlify
Copy link
Copy Markdown

netlify Bot commented Jan 7, 2026

Deploy Preview for mmert9008-astroblogtutorial ready!

Name Link
🔨 Latest commit 872cb02
🔍 Latest deploy log https://app.netlify.com/projects/mmert9008-astroblogtutorial/deploys/6980f1747f3c1e0008b7bb0b
😎 Deploy Preview https://deploy-preview-40--mmert9008-astroblogtutorial.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.

@renovate renovate Bot force-pushed the renovate/npm-preact-vulnerability branch from 5e8d30b to 872cb02 Compare February 2, 2026 18:48
@renovate renovate Bot changed the title Update dependency preact to v10.27.3 [SECURITY] Update dependency preact to v10.27.3 [SECURITY] - autoclosed Mar 27, 2026
@renovate renovate Bot closed this Mar 27, 2026
@renovate renovate Bot deleted the renovate/npm-preact-vulnerability branch March 27, 2026 01:24
@renovate renovate Bot changed the title Update dependency preact to v10.27.3 [SECURITY] - autoclosed Update dependency preact to v10.27.3 [SECURITY] Mar 30, 2026
@renovate renovate Bot reopened this Mar 30, 2026
@renovate renovate Bot force-pushed the renovate/npm-preact-vulnerability branch from 872cb02 to 0ee88d0 Compare March 30, 2026 21:32
@netlify
Copy link
Copy Markdown

netlify Bot commented Mar 30, 2026

Deploy Preview for mmert9008-astroblogtutorial ready!

Name Link
🔨 Latest commit 1061237
🔍 Latest deploy log https://app.netlify.com/projects/mmert9008-astroblogtutorial/deploys/69efdb53787e330008970eda
😎 Deploy Preview https://deploy-preview-40--mmert9008-astroblogtutorial.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.

@renovate renovate Bot changed the title Update dependency preact to v10.27.3 [SECURITY] Update dependency preact to v10.27.3 [SECURITY] - autoclosed Apr 27, 2026
@renovate renovate Bot closed this Apr 27, 2026
@renovate renovate Bot changed the title Update dependency preact to v10.27.3 [SECURITY] - autoclosed Update dependency preact to v10.27.3 [SECURITY] Apr 27, 2026
@renovate renovate Bot reopened this Apr 27, 2026
@renovate renovate Bot force-pushed the renovate/npm-preact-vulnerability branch 2 times, most recently from 0ee88d0 to 1061237 Compare April 27, 2026 21:55
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