Arbitrary file upload in Onedev Project
CVE-2021-21245
OneDev is an all-in-one devops platform. In OneDev before version 4.0.3, AttachmentUploadServlet also saves user controlled data (`request.getInputStream()`) to a user specified location (`request.getHeader("File-Name")`). This issue may lead to arbitrary file upload which can be used to upload a WebShell to OneDev server. This issue is addressed in 4.0.3 by only allowing uploaded file to be in attachments folder. The webshell issue is not possible as OneDev never executes files in attachments folder.
Vulnerability class: Unrestricted File Upload
EPSS: 0.012 (66.0th percentile) — read the EPSS interpretation.
CVSS v3 metric
CVSS v3 base score 10.0 (Critical). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:N.
Affected products
- Onedev_project Onedev
- Theonedev Onedev — versions < 4.0.3
Weakness classification (CWE)
References
- security-advisories@github.com (x_refsource_CONFIRM, Third Party Advisory)
- security-advisories@github.com (Patch, Third Party Advisory, x_refsource_MISC)
Frequently asked questions
- What is CVE-2021-21245?
- CVE-2021-21245 is a critical-severity vulnerability in Onedev Project, classified under Unrestricted Upload of File with Dangerous Type. CVSS score: 10.0/10. Published 2021-01-15.
- How severe is CVE-2021-21245?
- Critical severity. CVSS v3 base score is 10.0 out of 10.