critical curated alias of CVE-2017-12615

CVE-2017-12615

Web app · Unrestricted File Upload

Summary

Unrestricted file upload occurs when an application accepts an uploaded file without validating its type or content and stores it inside a web-accessible directory where the server will execute it, letting an attacker upload a script such as a .php or .jsp webshell and request it to run arbitrary code as the web user. At the code level the flaw is trusting client-supplied data (the filename extension or the Content-Type header) instead of verifying actual content, and saving to an executable path; weak filters are also bypassable, for example a regex without an anchoring $ or extension checks that ignore trailing characters. CVE-2017-12615 (disclosed 19 September 2017) is a documented case: Apache Tomcat 7.0.0 to 7.0.79 on Windows with the Default servlet's readonly parameter set to false allowed HTTP PUT uploads, and appending a trailing slash like shell.jsp/ bypassed the extension check, writing a JSP that Tomcat then executed for full remote code execution. This class maps to OWASP A04:2021 Insecure Design and overlaps A05 Security Misconfiguration; CWE-434.

Severity
critical
EPSS
99.6% (p100)
CWE
CWE-434
Also known as
APPSEC-FILE-UPLOAD, Unrestricted File Upload, Webshell Upload
Published
2017-09-19

How to avoid it

References

Related advisories

Is your project exposed to this? Stateward checks every dependency on every pull request and flags it only if your code actually reaches it.

Check my repo

Summarize with AI

ChatGPTClaudePerplexity

Sources: CISA KEV (public domain), OSV.dev & GitHub Advisory Database (CC-BY-4.0), FIRST EPSS, NVD/CWE (public domain). Served live from the Stateward advisory database.