CVE-2018-9206: blueimp jQuery File Upload arbitrary file upload

CVE-2018-9206 · Severity: low · CVSS 3.1 · Published 2018-10-22

blueimp jQuery File Upload is a popular JavaScript library used to handle file uploads in web applications. Versions up to 9.22.0 allow unauthenticated attackers to upload arbitrary files to the server with no restrictions, enabling them to upload malicious scripts (such as PHP webshells) that execute on the server and compromise the entire application or underlying system.

Vendors: npm.

Quick answers

Is CVE-2018-9206 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2018-9206 being exploited in the wild.
How severe is CVE-2018-9206?
Low severity, with a CVSS score of 3.1, published 22 October 2018.
Which products and versions are affected?
blueimp-file-upload (npm) SEMVER:introduced=0,fixed=9.22.1.
Is there a fix for CVE-2018-9206?
Yes. blueimp-file-upload (npm): upgrade to 9.22.1 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2018-9206 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2018-9206?
Check whether you run blueimp-file-upload (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • blueimp-file-upload (npm): upgrade to 9.22.1 or later
    npm install blueimp-file-upload@9.22.1

Technical details

The vulnerability is a CWE-434 unrestricted file upload weakness in blueimp jQuery File Upload through version 9.22.0. The sample PHP upload handler (UploadHandler.php or index.php in /server/php/) does not properly validate or restrict file types before processing uploads. Due to a default Apache 2.3.9+ configuration where .htaccess override rules may be disabled, PHP files uploaded to the widget's /files/ directory are directly executable. An unauthenticated attacker can send a POST request with a multipart/form-data payload containing a malicious PHP script to the upload endpoint, and the file is written to disk with no restrictions. The attacker can then directly access the uploaded script via HTTP GET, resulting in arbitrary code execution on the server with the privileges of the web server process. The vulnerability has been exploited in the wild since at least 2015. Patch version 9.22.1 addresses this issue.

Affected products

  • blueimp jQuery-File-Upload <= 9.22.0

Identifiers

  • CVE-2018-9206
  • GHSA-4cj8-g9cp-v5wr

Timeline

  • 2018-10: disclosed: Publicly disclosed to vendor in October 2018; advisory published October 22, 2018
  • 2018: patched: Fix released in version 9.22.1
  • 2015: exploited: Vulnerability actively exploited in the wild since at least 2015

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.