Patchfirst
CVE-2024-58136 KEVPublic exploit Critical · 9.8 EPSS 87.8%

Yiiframework Yii Improper Protection of Alternate Path Vulnerability

Yiiframework · Yii

Summary

The Yii framework (from Yiiframework) before version 2.0.52 contains an improper protection of alternate path flaw in how it attaches behaviors defined by an __class array key. An attacker with network access can exploit this without authentication, user interaction, or special configuration.

Official description · NVD

Yii 2 before 2.0.52 mishandles the attaching of behavior that is defined by an __class array key, a CVE-2024-4990 regression, as exploited in the wild in February through April 2025.

Breakdown
69.8 / 100
Exploited
Yes, in CISA KEV
Reports
0
Tactics
3/15

How an attack unfolds

Based on mappings. Select a step to see the evidence.
  1. How attackers get in

  2. What they do

First seen exploited 1 day before it was disclosed.

  1. First seen exploitedVulnCheck KEV evidence1 day before
  2. Disclosedday 0
  3. Added to CISA KEVEU database agrees+22 days

CISA KEV listing is when exploitation was confirmed, not necessarily the first attack.

See the family tree

A fix was bypassed or incomplete once over 10 months. The latest fix listed for yiisoft/yii2 is 2.0.55.

Same bug familyLinked by evidence that a fix failed or the same code was patched again. Oldest first.

  1. CVE-2024-32877Reflected Cross-site Scripting in yiisoft/yii2 Debug mode30 May 2024
  2. same family
    CVE-2024-4990Unsafe Reflection in base Component class in yiisoft/yii220 Mar 2025
  3. regression ofHigh

    Why these are linked:

    • Stated in the CVE textYii 2 before 2.0.52 mishandles the attaching of behavior that is defined by an __class array key, a CVE-2024-4990 regression, as exploited in the wild in February through April 2025.
    • Fixed one release later2.0.49.4 → 2.0.52 (yiisoft/yii2)
    • Same code patched: Component.php (machine-matched)Functions: __setcommit 628d406commit 62d081fcommit 40fe496
    This CVECVE-2024-58136Yiiframework Yii Improper Protection of Alternate Path10 Apr 2025KEV

Fixes in yiisoft/yii2Packagist package, by fixed version. Earlier and later fixes in the same package, not necessarily the same bug.

  1. 2.0.38CVE-2020-1514815 Sep 2020
  2. 2.0.49.4CVE-2024-3287730 May 2024
  3. 2.0.49.4CVE-2024-499020 Mar 2025
  4. 2.0.52CVE-2024-5813610 Apr 2025KEV
  5. 2.0.55CVE-2026-3985020 May 2026Latest listed

techniques

2 , grouped by in kill-chain order 2

ExecutionTA0002

Command and Scripting Interpreter T1059 Medium
MITRE CTID mapping of the KEV entry · primary impact

The Yii2 PHP framework, prior to version 2.0.52, contains an improper validation flaw that allows an attacker to input arbitrary PHP classes to a JSON file, which will then be instantiated and executed. This can lead to remote code execution and server-side request forgery, among other potential impacts.

Privilege EscalationTA0004

Process Injection T1055 Medium also Stealth
MITRE CTID mapping of the KEV entry · how it is exploited

Detection

0 rules for this CVE · 132 general rules for its techniques

Rules for this CVE

0 that reference CVE-2024-58136 directly.

CVE-specific rules are not available in this build. Search SigmaHQ ↗

Sigma rules © SigmaHQ, Detection Rule License 1.1; linked, not reproduced.

Am I affected? What do I upgrade to?

From GitHub Security Advisories and OSV

1 package in 1 ecosystem. Main package: yiisoft/yii2.

Packagistyiisoft/yii2GHSA-ggwg-cmwp-46r5

Upgrade to 2.0.52 or later

Fixes this CVE and 2 other known vulnerabilities in this package (CVE-2020-15148, CVE-2024-4990).

Set the version to 2.0.52 or later in your composer.json.

The first fix for CVE-2024-58136.

Affected versions

If you runUpgrade to
All versions before 2.0.522.0.52

“Up to” means the second version is the fix and is not affected.

Check your lockfile against all CVEs

What security researchers reported

Not named in any threat report yet

Also mentioned in 50 community threat pulses (AlienVault OTX)

Weaker evidence

Pulses are indicator collections that anyone can publish. A mention is not confirmation of exploitation.

References

6 links, grouped by NVD tag (1 duplicate merged)
↑ ↓ chooseEnter openEsc close