Patchfirst
CVE-2022-47945 Public exploit Critical · 9.8 EPSS 30.2%

ThinkPHP Framework before 6.0.14 allows local file inclusion via the lang parameter when the language pack feature is…

Fix:upgrade framework to 6.0.14 or later also fixes CVE-2021-44892 Details ↓

Summary

ThinkPHP Framework versions before 6.0.14 contain a local file inclusion flaw in the handling of the lang parameter, which is exposed when the language pack feature is enabled (lang_switch_on=true). A remote attacker with no authentication and no user interaction can exploit this to execute arbitrary operating system commands, as demonstrated by including pearcmd.php.

Official description · CVE.org

ThinkPHP Framework before 6.0.14 allows local file inclusion via the lang parameter when the language pack feature is enabled (lang_switch_on=true). An unauthenticated and remote attacker can exploit this to execute arbitrary operating system commands, as demonstrated by including pearcmd.php.

Breakdown
68.8 / 100
Exploited
Yes, in VulnCheck KEV
Reports
0
Tactics
0/15

First seen exploited 16 months after disclosure.

  1. Disclosedday 0
  2. First seen exploitedVulnCheck KEV evidence+16 mo

5 fixes in topthink/framework over 6 years. The latest fix listed for topthink/framework is 8.0.4.

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

  1. 5.1.23CVE-2018-163853 Sep 2018
  2. 6.0.9CVE-2021-365646 Dec 2021
  3. 6.0.12CVE-2021-235926 May 2022
  4. 6.0.14CVE-2022-4794523 Dec 2022
  5. 8.0.4CVE-2024-344674 May 2024Latest listed

Am I affected? What do I upgrade to?

From GitHub Security Advisories and OSV

1 package in 1 ecosystem. Main package: topthink/framework.

Packagisttopthink/frameworkGHSA-p4qr-vq2g-22wp

Upgrade to 6.0.14 or later

Fixes this CVE and 1 other known vulnerability in this package (CVE-2021-44892).

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

The first fix for CVE-2022-47945.

Affected versions

If you runUpgrade to
All versions before 6.0.146.0.14

“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

References

3 links, grouped by NVD tag
↑ ↓ chooseEnter openEsc close