Rails fixed a critical Active Storage flaw on 4 November 2026. If your app processes attachments with ImageMagick, an unauthenticated attacker may be able to write files on your server just by uploading a crafted file. Upgrade to activestorage 8.1.4.1 or 8.0.5.2 now.
The Rails advisory GHSA-f3w6-w445-fwh9 is rated Critical, CVSS 3.0 9.8. CERT-FR covers the 4 November release in CERTFR-2026-AVI-1452, which lists remote code execution among the risks.
Identity update, 16 November 2026: This article previously said the advisory listed no CVE. The Rails advisory now displays CVE-2026-126082. On 12 November, the CVE Program rejected that identifier as a duplicate and listed CVE-2026-122006 as its replacement. The two identifiers refer to one Rails Active Storage flaw.
Rails Active Storage ImageMagick: CVE Identity and Affected Apps
Brandefense Blackhole counted four dark-chat posts mentioning CVE-2026-122006 from 15 August through 13 November 2026. These are posts mentioning the identifier, not verified intrusions. A vulnerability intelligence platform can help teams prioritize affected applications alongside other current flaws.
An app is affected if it meets all three conditions in the advisory. It uses ImageMagick for Active Storage image processing (variant_processor = :mini_magick, the default for load_defaults 6.1 or earlier). It runs ImageMagick under a policy that does not already deny the coders involved, which includes the policies Debian and Ubuntu package. And it accepts uploads from untrusted users.
| Rails branch | Affected activestorage | Fixed in |
|---|---|---|
| 8.1 | 8.1 up to before 8.1.4.1 | 8.1.4.1 |
| 8.0 and older | before 8.0.5.2 | 8.0.5.2 |
The Rails announcement says older versions are unsupported and recommends moving to at least the 8.0 series. It adds that security support for 8.0 ends on 7 November 2026.
How Does an Upload Become a File Write?
ImageMagick picks a coder from the content of the file, and some coders act on files named inside the image. Active Storage constrained none of them, and the ImageMagick analyzer runs when a file is attached. An attacker who can upload a crafted file may therefore invoke one, and attaching it is enough.
The Rails advisory says one attack chain was reported, without limiting the risk to that case. It warns that a qualifying upload may write server files and, when the app stores attachments with the Disk service, read files accessible to the application process, including secrets and external-system credentials.
What Should You Do Now?
- Find affected apps. Run
bundle list | grep -E "activestorage|mini_magick"and searchconfig/forvariant_processor. - Upgrade Rails to 8.1.4.1 or 8.0.5.2. An app on
:mini_magickalso needs mini_magick 5.1 or later, or it raises at boot. - Check the policy loads:
bin/rails runner 'puts MiniMagick.identify { |i| i.list "policy" }', the command from the Rails guide. - Handle the exceptions. Apps that render PostScript or PDF through ImageMagick must re-allow the
gsdelegate in the host policy. Apps that replaceMiniMagick.cli_env, clear the environment withMiniMagick.cli_prefix, or install their ownMiniMagick::Shellmust carry the shipped rules in ImageMagick’s system policy. GraphicsMagick does not read ImageMagick policies, so this policy workaround does not apply to GraphicsMagick. - If you cannot upgrade today, copy the rules of the shipped
policy.xmlinto the system policy, for example/etc/ImageMagick-7/policy.xml. At a minimum deny the MSL coder, the Ghostscript coders and thegsdelegate. - Rotate secrets if the app uses the Disk service and takes untrusted uploads. Change
secret_key_base, the master key, everything inconfig/credentials.yml.encand the tokens the app holds. Changingsecret_key_basesigns users out and invalidates signed cookies and Active Storage URLs. - Review recent uploads and the app’s file system. Look for blobs with SVG, MSL, PostScript or PDF content from untrusted users, and for files in application directories that changed since the upload.
Steps 1, 3 and 7 and the review scope are our advice, and the rest follows the Rails advisory. For related reading, see our Exploit Public-Facing Application technique page, the credentials in files technique and the patch management entry.
What Do Rails and CISA KEV Say About Exploitation, and What Else Shipped?
The flaw is not in the CISA Known Exploited Vulnerabilities catalog as of its 10 November 2026 release, under CVE-2026-122006. A HackerOne researcher reported the flaw to Rails.
The same release fixes 21 issues. GHSA-v924-7rp8-4mxh (CVE-2026-126186; High, CVSS 3.1 8.8) covers uploads whose file extension steers FFmpeg or ImageMagick to a decoder, and its AviSynth path needs an FFmpeg built with that support. For earlier ImageMagick coverage, see CISA’s ImageMagick exploitation warning.
The CVE-2026-122006 Active Storage profile details affected versions, ImageMagick conditions, and remediation checks.
A separate Upload2Shell Ghostscript rendering analysis traces another downstream document-processing risk and the patch checks for CVE-2026-125396.
Frequently Asked Questions
Which CVE identifies this Rails Active Storage flaw?
Use CVE-2026-122006. Rails' advisory displays CVE-2026-126082, but the CVE Program rejected it as a duplicate and explicitly lists CVE-2026-122006 as its replacement.
Do I need to generate image variants to be affected?
No. The Rails advisory says attaching the upload is sufficient because the ImageMagick analyzer runs on attach. A separate variant, preview or analyze call is not required.
Does the flaw affect apps that use libvips?
This advisory concerns ImageMagick through the mini_magick processor. The separate GHSA-xr9x-r78c-5hrm covers a libvips issue, so check its fix independently.
Why would a Rails upgrade break PDF rendering?
The shipped policy denies Ghostscript coders and the gs delegate. Rails says applications rendering PostScript or PDF through ImageMagick must re-allow the required coders and delegate in the host policy.
What is the CERT-FR reference?
CERT-FR published CERTFR-2026-AVI-1452 on 4 November 2026. It lists affected Rails versions and points to the Rails security bulletin.
Sources
- Rails advisory GHSA-f3w6-w445-fwh9, Possible arbitrary file write and read in Active Storage image analysis, 4 November 2026
- Rails security releases 8.0.5.2 and 8.1.4.1, Rails community forum, 4 November 2026
- Rails advisory GHSA-v924-7rp8-4mxh, Active Storage video previews, analysis and image processing
- CERT-FR CERTFR-2026-AVI-1452, Multiples vulnerabilites dans Ruby on Rails, 4 November 2026
- CISA Known Exploited Vulnerabilities catalog
