CVE-2021-36567: Deserialization of Untrusted Data in topthink/framework

topthink/framework Updated 02 Oct 2025

Summary

07/12/2021
No i
Critical
9.8

CVE-2021-36567: Deserialization of Untrusted Data in topthink/framework. Affects topthink/framework versions < 6.0.8. 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 Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

ThinkPHP is a popular PHP framework that provides a range of features and functionalities for web application development. It is widely used in the Packagist ecosystem. The vulnerability identified as CVE-2021-36567 affects ThinkPHP version 6.0.8. This vulnerability arises due to a deserialization flaw in the component League\Flysystem\Cached\Storage\AbstractCache.

Vulnerability Detail

The deserialization vulnerability in ThinkPHP v6.0.8 allows an attacker to exploit the deserialization of untrusted data, potentially leading to remote code execution. By leveraging this vulnerability, an attacker can execute arbitrary code on the affected system, compromising its integrity, confidentiality, and availability. The vulnerability has a CVSS score of 9.8, indicating its critical severity.

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

As a workaround, users can implement input validation and sanitization techniques to mitigate the risk of deserialization attacks. By carefully validating and filtering user-supplied data, the impact of this vulnerability can be reduced. Here is an example of input validation using PHP's filter_var() function:

$input = $_POST['data'];

if (filter_var($input, FILTER_VALIDATE_INT)) {
    // Proceed with safe deserialization
} else {
    // Handle invalid input
}

Conclusion

The deserialization vulnerability in ThinkPHP v6.0.8 poses a significant risk to the security of web applications built on this framework. It is crucial for users to update their ThinkPHP installation to a version beyond 6.0.8 to mitigate this vulnerability. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for topthink/framework →

Share this vulnerability

FAQ

This vulnerability allows an attacker to execute arbitrary code on the affected system, potentially compromising its integrity, confidentiality, and availability.

ThinkPHP version 6.0.8 is confirmed to be affected by this vulnerability.

Yes, the maintainers of ThinkPHP have addressed this vulnerability in subsequent releases. Users are advised to update their ThinkPHP installation to a version beyond 6.0.8.

Yes, users can implement input validation and sanitization techniques to mitigate the risk of deserialization attacks. By carefully validating and filtering user-supplied data, the impact of this vulnerability can be reduced.

The CVSS score of this vulnerability is 9.8, indicating its critical severity.

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