CVE-2021-32708Time-of-check Time-of-use (TOCTOU) Race Condition in league/flysystem
- 9.8CriticalCVSS base score
- 3.5%Exploitation in 30 daysEPSS · top 11% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
Description
Flysystem is an open source file storage library for PHP. The whitespace normalisation using in 1.x and 2.x removes any unicode whitespace. Under certain specific conditions this could potentially allow a malicious user to execute code remotely. The conditions are: A user is allowed to supply the path or filename of an uploaded file, the supplied path or filename is not checked against unicode chars, the supplied pathname checked against an extension deny-list, not an allow-list, the supplied path or filename contains a unicode whitespace char in the extension, the uploaded file is stored in a directory that allows PHP code to be executed. Given these conditions are met a user can upload and execute arbitrary code on the system under attack. The unicode whitespace removal has been replaced with a rejection (exception). For 1.x users, upgrade to 1.1.4. For 2.x users, upgrade to 2.1.1.
Timeline
ID reserved
By GitHub_M
- 43 days later
· 43 days later
Published
- 3 years later
· 3 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| GitHub_MCNA (assigner) | 3.1 | Critical9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVDNVD · Modified | 3.1 | High8.1 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H |
- EPSS (exploitation in 30 days)
- 3.5% · top 11% of all CVEs (13 Nov 2026)
The list uses the assigner's score when there is one, then CISA's, then NVD's: Critical 9.8.
Affected products
- affected < 1.1.4
- affected >= 2.0.0, < 2.1.1
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- Packagistleague/flysystemGHSA-9f46-5r25-5wfm (opens in a new tab)
References
References6
- https://github.com/thephpleague/flysystem/security/advisories/GHSA-9f46-5r25-5wfm (opens in a new tab)x_refsource_CONFIRMx_transferred
- https://github.com/thephpleague/flysystem/commit/a3c694de9f7e844b76f9d1b61296ebf6e8d89d74 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/thephpleague/flysystem/commit/f3ad69181b8afed2c9edf7be5a2918144ff4ea32 (opens in a new tab)x_refsource_MISCx_transferred
- https://packagist.org/packages/league/flysystem (opens in a new tab)x_refsource_MISCx_transferred
- FEDORA-2021-717516a2e9 (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
- FEDORA-2021-b9187c535c (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2021-1300 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-9f46-5r25-5wfm (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2021-32708)Record last updated .