Yii 2: Local file inclusion via view parameter name collision
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- High
- Impact type
- Code execution
- Confidentiality · integrity · availability
- High · High · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-98.
Summary
Yii 2 is a PHP application framework. Versions 2.0.54 and prior contain flawed logic in the core view rendering method View::renderPhpFile() that leads to Local File Inclusion. The function calls extract($_params_, EXTR_OVERWRITE) before the require statement that loads the view file. As a result, a caller-controlled _file_ key in the $params array overwrites the internal local variable specifying which file to include, potentially enabling RCE if an attacker can write PHP files through a separate primitive, as well as information disclosure. This issue has been fixed in version 2.0.55.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Yiiframework | yii2 | before 2.0.55 | 2.0.55 | Patch available | CNA |
| — | yiisoft/yii2 (Packagist) | before 2.0.55 | 2.0.55 | Patch available | GHSA-5vpg-rj7q-qpw2 |
- yii2 VendorYiiframework Affected before 2.0.55 Fixed in 2.0.55 Patch available CNA
- yiisoft/yii2 (Packagist) Vendor— Affected before 2.0.55 Fixed in 2.0.55 Patch available GHSA-5vpg-rj7q-qpw2
CPE names Threatist (inferred) · 1
Inferred from how NVD named this product before; not given by a source.
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:yiiframework:yii:*:*:*:*:*:*:*:* | — | — | Yiiframework |
- cpe:2.3:a:yiiframework:yii:*:*:*:*:*:*:*:* Versions — — ·Yiiframework
Remediation
- Fix · CNA yii2 (yiisoft) Fixed in 2.0.55
- Fix · GHSA-5vpg-rj7q-qpw2 yiisoft/yii2 (Packagist) Fixed in 2.0.55 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2026-39850
- 2026-10-03 Alias added: GHSA-5vpg-rj7q-qpw2
References
More Yiiframework vulnerabilities
- TI-2024-38344 Yii 2 before 2.0.52 mishandles the attaching of behavior that is defined by an __class… KEVCVSS 3.1CRITICAL 9.8
- TI-2020-11920 Unsafe deserialization in Yii 2 CVSS 3.1CRITICAL 10.0
- TI-2024-04634 Unsafe Reflection in base Component class in yiisoft/yii2 CVSS 3.1CRITICAL 9.1
- TI-2020-18848 Yii Yii2 Gii before 2.2.2 allows remote attackers to execute arbitrary code via the… CVSS 3.1HIGH 8.8
- TI-2025-02355 yiisoft Yii2 MockClass.php generate deserialization CVSS 4.0MEDIUM 5.3
- TI-2025-02354 yiisoft Yii2 SortableIterator.php getIterator deserialization CVSS 4.0MEDIUM 5.3
Sources
- CVE-2026-39850 · CVE Program
- CVE-2026-39850 · NVD
- FIRST EPSS
- GHSA-5vpg-rj7q-qpw2 · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences