CVE-2024-56828: ChestnutCMS · File Upload
Affects ChestnutCMSSource CVE Database V5
Not known to be exploited · CVSS 9.8 Critical.
Data as of 26 Oct 2026, 12:54 UTC
- EPSS
- 0.9% chance of exploitation in 30 days – higher than 59% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:HExploitation evidence
Disclosed: evidence found.
CVE published 6 Jan 2025
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Affected software
| Product | Affected | Fixed in |
|---|---|---|
GitHubliweiyi/ChestnutCMSpkg:github/liweiyi/ChestnutCMSOther threats | Affected
| Fixed in– |
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
To mitigate CVE-2024-56828, organizations should immediately implement the following measures: 1) Apply any available official patches or updates from ChestnutCMS as soon as they are released. 2) Implement strict server-side validation of file types by enforcing a whitelist of allowed MIME types and file extensions for uploaded avatars, rejecting any files that do not conform. 3) Sanitize and validate the base64 input thoroughly before decoding, ensuring the data URI prefix matches expected image formats (e.g., image/png, image/jpeg). 4) Store uploaded files outside the web root or in directories with restricted execution permissions to prevent execution of uploaded malicious files. 5) Employ web application firewalls (WAFs) to detect and block suspicious upload attempts. 6) Monitor server logs for unusual file upload patterns or unexpected file types. 7) Restrict API endpoint access where possible, such as requiring authentication or rate limiting to reduce exposure. 8) Conduct regular security audits and penetration testing focused on file upload functionalities. These targeted actions go beyond generic advice and address the root cause of the vulnerability effectively.
Description
File Upload vulnerability in ChestnutCMS through 1.5.0. Based on the code analysis, it was determined that the /api/member/avatar API endpoint receives a base64 string as input. This string is then passed to the memberService.uploadAvatarByBase64 method for processing. Within the service, the base64-encoded image is parsed. For example, given a string like: data:image/html;base64,PGh0bWw+PGltZyBzcmM9eCBvbmVycm9yPWFsZXJ0KDEpPjwvaHRtbD4= the content after the comma is extracted and decoded using Base64.getDecoder().decode(). The substring from the 11th character up to the first occurrence of a semicolon (;) is assigned to the suffix variable (representing the file extension). The decoded content is then written to a file. However, the file extension is not validated, and since this functionality is exposed to the frontend, it poses significant security risks.