Wordfence disclosed a critical Ghostscript vulnerability on October 12, 2026 that reaches WordPress through a feature most site owners never think about: the PDF thumbnail generator that has shipped in core since version 4.7. Tracked as CVE-2026-39919 and rated CVSS 9.8, the flaw is a heap buffer overflow that a crafted PDF can trigger during image conversion, with code execution possible before anyone logs in. Ghostscript versions before 10.08.0 are affected, and there is no WordPress plugin update that fixes it. The patch has to come from your server’s operating system or container image.
What Wordfence Actually Found
Argus, Wordfence’s AI research agent, found the bug while auditing WordPress 7.1 and reported it to Artifex, the company behind Ghostscript, on August 23, 2026. Artifex confirmed it the next day and shipped Ghostscript 10.08.0 on September 8, closing the hole. Wordfence held its technical writeup until October 12, which is standard responsible-disclosure timing rather than anything unusual.
The bug itself sits in Ghostscript’s JPEG 2000 output adapter. A PDF containing a JPEG 2000 image with mismatched subsampling factors makes Ghostscript write more data into a row buffer than was allocated for it, corrupting allocator metadata in a way that can be steered toward code execution.
Why a PDF Upload Can Reach Your Server
WordPress core has generated PDF previews by handing uploaded files to the Imagick PHP extension, which calls out to ImageMagick, which in turn shells out to Ghostscript to render the page. That chain runs by default wherever Imagick is the active image library on the server. Ghostscript’s -dSAFER sandbox flag does not block this overflow either. Wordfence triggered it with that protection switched on.
Stock WordPress does not let anonymous visitors drop files straight into the Media Library, so out of the box this needs at least a contributor-level account. The actual exposure sits wherever else PDFs come in from the public: a Gravity Forms or WPForms upload field, a job application page, a client portal plugin, anything that calls wp_handle_upload() on a form the whole internet can see.
Wordfence tested the exploit against ten common Linux and Docker builds, including the official WordPress Docker image, and got reliable code execution there. The same proof of concept failed across more than ten thousand attempts against ten other builds. Build and installed library version matter more here than the CVSS score alone suggests, which is also why nobody is treating this as a guaranteed drive-by yet.
What to Check on Your Own Sites
- Find your installed Ghostscript build with
dpkg -s ghostscripton Debian or Ubuntu, orrpm -q ghostscripton RHEL-based hosts, and compare the revision against your distro’s fixed version. Ubuntu shipped fixes on September 21 under USN-8791-1. - If you run managed WordPress hosting, ask the host directly whether their stack ships a patched Ghostscript. There’s nothing to update from inside wp-admin.
- If WordPress runs in containers you control, rebuild the image from a current base rather than assuming a cached layer already picked up the fix.
- Until you’ve confirmed the fix is in place, turn off public-facing PDF uploads anywhere you control them, or tighten file-type validation at the plugin level.
This is the second time this specific pipeline has caused trouble this year. WordPress 7.0.4 patched an authenticated RCE in the same Imagick-to-Ghostscript path back in August. That one needed an Author-level account to reach it. This one only needs a form that accepts PDFs from strangers, which is a lower bar on a lot of client sites.
Wordfence had not seen this exploited in the wild as of its October 12 writeup, and third-party trackers put the odds of exploitation within 30 days at around 1 percent. That is not a reason to skip the check. It is a reason to handle it on your own schedule instead of treating it as an emergency.
None of this shows up in a typical plugin vulnerability scanner, since the vulnerable code is not a WordPress plugin at all. It is exactly the kind of server-level detail we check for during WordPress Development work when we take over an existing site: what’s actually installed underneath the hosting stack, not just what’s listed on the plugins page.



