Skip to content
OpenAdvisories
High · 8.1 CVE-2024-4990 EUVD-2024-2024GHSA-cjcc-p67m-7qxm

Unsafe Reflection in base Component class in yiisoft/yii2

Published Mar 20, 2025 · Updated Mar 20, 2025 · Assigned by @huntr_ai

Description

In yiisoft/yii2 version 2.0.48, the base Component class contains a vulnerability where the `__set()` magic method does not validate that the value passed is a valid Behavior class name or configuration. This allows an attacker to instantiate arbitrary classes, passing parameters to their constructors and invoking setter methods. Depending on the installed dependencies, various types of attacks are possible, including the execution of arbitrary code, retrieval of sensitive information, and unauthorized access.

Affected products

VendorProductAffectedFixed
yiisoft yiisoft/yii2 unspecified – ≤ latest —

Affected packages

EcosystemPackageAffectedFixedRecord
Packagist yiisoft/yii2 < 2.0.49.4 2.0.49.4 GHSA-cjcc-p67m-7qxm

References