Feed
6.1MEDIUM

CVE-2021-43808Laravel Framework XSS in Blade templating engine

A medium-severity vulnerability reachable over the network, needing no privileges and user interaction. EPSS estimates a 0.8% chance of exploitation in the next 30 days. A fixed version is named.

Exploited in the wild
Not in KEV
EPSS
0.8%
percentile 55%
Priority
19/100 low
how it is computed
Fix
Named by a source
CVE published 8 Dec 2021

Reference

None of the "Needs attention" rules apply right now.

EPSS 0.8% (+1) · Network attack vector (+10) · No privileges required (+5)

Immediate actions

Who should check

  • illuminate/view (Packagist) pkg:composer/illuminate/view

    • Affected< 6.20.42Fixed in6.20.42OSV (GHSA-66hf-2p6w-jqfw)
    • Affected>= 7.0.0, < 7.30.6Fixed in7.30.6OSV (GHSA-66hf-2p6w-jqfw)
    • Affected>= 8.0.0, < 8.75.0Fixed in8.75.0OSV (GHSA-66hf-2p6w-jqfw)
  • laravel/framework (Packagist) pkg:composer/laravel/framework

    • Affected< 6.20.42Fixed in6.20.42OSV (GHSA-66hf-2p6w-jqfw)
    • Affected>= 7.0.0, < 7.30.6Fixed in7.30.6OSV (GHSA-66hf-2p6w-jqfw)
    • Affected>= 8.0.0, < 8.75.0Fixed in8.75.0OSV (GHSA-66hf-2p6w-jqfw)

Confirmed facts

CVSS
6.1 MEDIUM (version 3.1)
Score from
GitHub Advisory Database (GHSA-66hf-2p6w-jqfw)
Attack vector
network
Attack complexity
low
Privileges required
none
User interaction
required
Weakness
CWE-327, CWE-79

Unknowns

  • We show one CVSS score. Other sources may score this CVE differently.

Advisory text

Quoted from the source advisory (untrusted)A security researcher has disclosed a possible XSS vulnerability in the Blade templating engine. Given the following two Blade templates: resources/views/parent.blade.php: ```html @section('content') <input value="{{ $value }}"> @show ``` resources/views/child.blade.php: ```html @extends('parent') @section('content') <input value="{{ $value }}"> @endsection ``` And a route like the following: ```php Route::get('/example', function() { $value = '//localhost/###parent-placeholder-040f06fd774092478d450774f5ba30c5da78acc8## onclick=location.assign(this.value);//'; return view('child', ['value' => $value]); }); ``` The broken HTML element may be clicked and the user is taken to another location in their browser due to XSS. This is due to the user being able to guess the parent placeholder SHA-1 hash by trying common names of sections. If the parent template contains an exploitable HTML structure an XSS vulnerability can be exposed. This vulnerability has been patched by determining the parent placeholder at runtime and using a random hash that is unique to each request.

Update history

No events recorded. Our history starts on 1 Jan 2025.

References

Sources

This page is our own presentation: records are shortened, normalised and merged. Licences

Last checked: kev 8 min ago · osv 8 min ago · nvd 69 min ago · epss 7 min ago · JSON · ask via MCP: explain_vulnerability

Also known as GHSA-66hf-2p6w-jqfw