NIST deprecates RSA-2048 from 2030. Find every one of them before attackers do.
🐘
🐘 Packagist
Not in CISA KEV
MEDIUM severity

CVE-2026-142642 — framework

MEDIUMFix: laravel/framework@d214178

CVE-2026-142642 is a medium-severity (CVSS 5.4) CWE-83 vulnerability in laravel/framework. A fix is available for laravel/framework — see the affected versions and patch details below.

Laravel: XSS via unescaped Stringable values in Blade component attribute bag

Also known asGHSA-hv67-wfqj-w9xv
Published
Updated
Affected
2 pkgs
Patched
2 / 2
Exploits
None indexed
Exploitation data as of Dec 3, 2026 · OSV.dev, NVD, FIRST.org (EPSS)

Real-World Exposure

2 pkgs affected
🐘laravel/framework🐘laravel/framework

Real-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.

Description

Impact

Blade component attribute bags did not HTML-escape non-Htmlable object values, such as Illuminate\Support\Stringable, passed to ComponentAttributeBag::merge() or prepends(). Applications that place user-controlled Stringable values (for example, the result of request()->string()) into component attributes could allow an attacker to break out of the attribute and inject arbitrary attributes, such as event handlers. This results in cross-site scripting that runs in the origin of the application.

Patches

The fix escapes all attribute values except null, booleans and Htmlable instances, and also escapes values wrapped with prepends(). It was merged to the 12.x branch in https://github.com/laravel/framework/pull/62503.

Workarounds

Cast user-controlled values to plain strings, for example request()->string('title')->toString(), before passing them to merge() or prepends().

Affected Packages

2 total 2 fixed
EcosystemPackageVulnerable rangeFix
🐘Packagistlaravel/framework≥ 13.0.0&&< 13.43.013.43.0composer require laravel/framework:^13.43.0
🐘Packagistlaravel/frameworkall versions12.73.0composer require laravel/framework:^12.73.0

Detection & mitigation playbook

Open-source dependency
  1. Detect

    Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for laravel/framework, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.

  2. Fix

    Update laravel/framework to 13.43.0 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2026-142642 is resolved across your whole dependency graph.

  3. Workarounds

    Escape or sanitise the affected output on the server side rather than relying on client-side filtering, and add a Content-Security-Policy that blocks inline script execution so injected markup cannot run even if it reaches the page.

Frequently Asked Questions

### Impact Blade component attribute bags did not HTML-escape non-`Htmlable` object values, such as `Illuminate\Support\Stringable`, passed to `ComponentAttributeBag::merge()` or `prepends()`. Applications that place user-controlled `Stringable` values (for example, the result of `request()->string()`) into component attributes could allow an attacker to break out of the attribute and inject arbitrary attributes, such as event handlers. This results in cross-site scripting that runs in the origin of the application. ### Patches The fix escapes all attribute values except `null`, booleans an
O3 Security · Impact-Aware SCA

Is CVE-2026-142642 in your dependencies?

Find it across Packagist, including transitive dependencies.