Home › Vulnerabilities › TopThink
ThinkPHP Code Injection Flaws (CVE-2019-25782, CVE-2012-20007) Allow Unauthenticated Remote Command Execution
Two critical ThinkPHP flaws in older releases let unauthenticated attackers run commands or PHP code on affected servers, and the Shadowserver Foundation reportedly observed exploitation of both on 2023-10-14. The records do not state fixed versions or workarounds for these issues.
What to look into
- 2 vulnerabilities in TopThink ThinkPHP: 2 critical (CVSS up to 9.3).
- None of them is known to be exploited yet.
- Start with CVE-2019-25782 (9.3 critical): ThinkPHP 5.0.0 to 5.0.23 Code Injection Vulnerability. An attacker without an account can exploit this over the network, without any user action.
- 2 of 2 can be attacked over the network without logging in, 2 of them without anyone clicking anything.
- Kinds of flaws: Use of Externally-Controlled Input to Select Classes or Code ('Unsafe Reflection'); Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection').
Key points
- Two CRITICAL (CVSS 9.3) ThinkPHP code injection flaws were published together by NVD.
- CVE-2019-25782 affects ThinkPHP 5.0.0 before 5.0.24 and can lead to system command execution.
- CVE-2012-20007 affects ThinkPHP 2.0 through 2.2 and 3.0 Lite mode and can lead to arbitrary PHP code execution.
- Both need no authentication, according to the records.
- Shadowserver reportedly first observed exploitation of both on 2023-10-14.
Overview
NVD published two vulnerabilities in TopThink ThinkPHP on 2026-11-18. Both are rated CRITICAL with a CVSS score of 9.3, and both are code injection flaws that the records say can be triggered without authentication.
The flaws
The first, CVE-2019-25782, affects ThinkPHP 5.0.0 before 5.0.24. According to the record, an attacker can send POST data that sets method=construct to overwrite the Request filter property. Requests sent to endpoints reached through ?s=captcha or ?s=index/index/index, with filter[] and server[REQUESTMETHOD] values set, are described as enough to run arbitrary system commands.
The second, CVE-2012-20007, affects ThinkPHP 2.0 through 2.2 and 3.0 Lite mode. Its record describes an eval injection in the Dispatcher's PATHINFO parsing, which uses pregreplace with the /e modifier and a double-quoted replacement. A crafted request to index.php with a malicious 's' parameter containing PHP expressions is described as enough to execute arbitrary code.
Exploitation
Both records state that the Shadowserver Foundation first observed exploitation evidence on 2023-10-14. The sources do not describe who was behind this activity or what it achieved.
Affected systems and response
The affected ranges are the older branches named above. The records do not give a fixed version for either CVE, a vendor patch reference, a workaround, or detection guidance. Administrators should first establish whether any ThinkPHP installation falls within these ranges, and treat any internet-facing instance in those ranges as high priority until the vendor's guidance is confirmed.
What to do
- Identify any ThinkPHP installations on versions 5.0.0 to before 5.0.24, or 2.0 through 2.2 and 3.0 Lite mode, and prioritise internet-facing ones.
- Check vendor sources for a fixed release; the records do not name one.
The 2 vulnerabilities
- CVE-2019-25782 9.3 ThinkPHP 5.0.0 to 5.0.23 Code Injection Vulnerability
- CVE-2012-20007 9.3 ThinkPHP 2.0-2.2 and 3.0 Lite Mode Eval Injection Vulnerability
Frequently asked questions
How many TopThink ThinkPHP vulnerabilities were published on November 18, 2026?
2 vulnerabilities: 2 critical, with CVSS scores up to 9.3.
Are any of them being exploited?
None of them is in CISA's Known Exploited Vulnerabilities catalog yet.
Which one should be fixed first?
CVE-2019-25782 (CVSS 9.3): ThinkPHP 5.0.0 to 5.0.23 Code Injection Vulnerability.