CVE-2022-44289: Thinkphp - Code Logic Error in File Upload

topthink/framework Updated 02 Oct 2025

Summary

06/12/2022
No i
High
8.8

CVE-2022-44289: Thinkphp has a code logic error. Affects topthink/framework across 2 version ranges.

< 5.0.24 >= 5.1, <= 5.1.41

No fix is published. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

Thinkphp is a PHP framework used for web application development. It provides a range of features and functionalities to simplify the development process. However, versions 5.1.41 and 5.0.24 of Thinkphp have a code logic error that can lead to a file upload vulnerability.

Vulnerability Detail

The code logic error in Thinkphp allows an attacker to exploit the file upload functionality and gain unauthorized access to the server. This can result in remote code execution, enabling the attacker to execute arbitrary commands and potentially take control of the affected system. The vulnerability has a CVSS score of 8.8, indicating a high severity level.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

If updating Thinkphp is not immediately feasible, a temporary workaround is to disable the file upload functionality or implement strict validation checks on uploaded files. This can help mitigate the risk of exploitation until the framework is updated.

Conclusion

Thinkphp versions 5.1.41 and 5.0.24 have a code logic error that allows for unauthorized file uploads and potential remote code execution. It is crucial to update Thinkphp to the latest version (5.1.42 or higher) to mitigate this vulnerability. If immediate update is not possible, disabling the file upload functionality or implementing strict validation checks can provide temporary protection. For further assistance and support in vulnerability remediation, contact DevNack.com.

See every vulnerability recorded for topthink/framework →

Share this vulnerability

FAQ

The vulnerability allows an attacker to upload malicious files and execute arbitrary commands on the server, potentially leading to a complete compromise of the system.

No, only versions 5.1.41 and 5.0.24 of Thinkphp are affected. It is recommended to update to the latest version to ensure the vulnerability is patched.

At the time of this report, there are no known public exploits for this vulnerability. However, it is crucial to address the issue promptly to prevent any potential exploitation.

Yes, this vulnerability can be exploited remotely. An attacker can upload malicious files to the server and execute arbitrary commands without authentication.

Yes, the CVSS score for this vulnerability is 8.8, indicating a high severity level.

Related vulnerabilities

Recent vulnerabilities recorded for topthink/framework.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback