Description
WordPress through 5.0.3 allows Path Traversal in wp_crop_image(). An attacker (who has privileges to crop an image) can write the output image to an arbitrary directory via a filename containing two image extensions and ../ sequences, such as a filename ending with the .jpg?/../../file.jpg substring.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | wordpress | No fix yet | — |
| Debian 13 | wordpress | No fix yet | — |
| Debian 12 | wordpress | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | wordpress | No fix yet | — |
| Ubuntu 26.04 LTS | wordpress | No fix yet | — |
| Ubuntu 25.10 | wordpress | No fix yet | — |
| Ubuntu 24.04 LTS | wordpress | No fix yet | — |
| Ubuntu 22.04 LTS | wordpress | No fix yet | — |
Show 3 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 20.04 LTS | wordpress | No fix yet | — |
| Ubuntu 18.04 LTS | wordpress | No fix yet | — |
| Ubuntu 16.04 LTS | wordpress | No fix yet | — |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
Metasploit 1 module
-
WordPress Crop-image Shell Upload
exploit/multi/http/wp_crop_rce
Exploit-DB 2
- WordPress Core 5.0.0 - Crop-image Shell Upload (Metasploit) EDB-46662 · remote · Apr 5, 2019 · verified
- WordPress Core 5.0 - Remote Code Execution EDB-46511 · webapps · Mar 1, 2019
GitHub 2 repositories
-
oussama-rahali/CVE-2019-8943 ★ 24 · Feb 1, 2021
Exploit of CVE-2019-8942 and CVE-2019-8943
-
hadrian3689/wordpress_cropimage ★ 3 · Sep 20, 2022
CVE-2019-8943 WordPress Crop-Image
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Automated scanner template
A ready-made Nuclei template detects this vulnerability automatically. Vulnerabilities with public scanner templates are typically probed across the internet soon after the template appears — exposed systems should be patched first.
- WordPress Core 5.0.0 - Crop-image Shell Upload http/cves/2019/CVE-2019-8943.yaml
Source: projectdiscovery/nuclei-templates (MIT) — updated daily. Only links are listed.
References
- 46511 exploit
- https://blog.ripstech.com/2019/wordpress-image-remote-code-execution/
- 107089 vdb-entry
- http://packetstormsecurity.com/files/152396/WordPress-5.0.0-crop-image-Shell-Upload.html
- http://www.rapid7.com/db/modules/exploit/multi/http/wp_crop_rce
- 46662 exploit
- http://packetstormsecurity.com/files/161213/WordPress-5.0.0-Remote-Code-Execution.html