CVE-2026-126075
Medium 4.7No known exploitationFix availableActive Support: Possible XSS vulnerability in Active Support MessagePack serializer
Vendor advisory: GHSA-2w9f-fxwj-w2qf
Record last updated
CVSS score
Medium on a 0 to 10 scale
EPSS, chance of exploitation in 30 days
Higher than 28% of scored CVEs. A prediction, not evidence.
CISA remediation deadline
Not in the KEV catalog
Description
Active Support is a collection of utility classes and standard library extensions used by Rails and other Ruby projects. From 8.1 until 8.1.4.1, ActiveSupport::MessagePack serializes an ActiveSupport::SafeBuffer as its bytes alone and deserializes it as a new SafeBuffer, so a buffer that is no longer html_safe? (for example, one mutated in place with gsub!) is restored as html_safe. If such a buffer holds untrusted input and is stored through a MessagePack serializer, rendering it after it is loaded bypasses ERB auto-escaping, possibly leading to XSS. Applications on Rails 8.1 are affected if they use a MessagePack serializer, such as config.action_dispatch.cookies_serializer = :message_pack or :message_pack_allow_marshal, or serializer: :message_pack for Rails.cache, ActiveSupport::MessageVerifier or ActiveSupport::MessageEncryptor, and store a SafeBuffer that was mutated in place with untrusted input. Rails 8.0 and earlier do not serialize SafeBuffer with MessagePack and are not affected. This issue is fixed in version 8.1.4.1.
Weakness: CWE-79
Patching and mitigation
- Patch status
- Fix available (source: GitHub Advisory Database)
- Fix documented (source date)
- Mitigation
- None documented
- Vendor guidance
- github.com (opens in a new tab)
Affected products
| Vendor | Product | Affected versions | Fixed in | Per |
|---|---|---|---|---|
| rails | rails | >= 8.1, < 8.1.4.1 | Not documented | CVE Program |
| rubygems | activesupport | from 8.1.0.beta1 before 8.1.4.1 | 8.1.4.1 | GitHub Advisory Database |
Timeline
Disclosure
CVE record published by GitHub_M
Source: CVE Program (opens in a new tab)
Patch
Fix documented by GitHub Advisory Database
Vendor guidance and references
- GitHub Advisory GHSA-2w9f-fxwj-w2qf (opens in a new tab)github-advisory
- https://github.com/rails/rails/commit/4ca090665976e6fbc471c38689b399f84b43cdc7 (opens in a new tab)x_refsource_misc
- https://github.com/rails/rails/releases/tag/v8.1.4.1 (opens in a new tab)x_refsource_misc
- https://github.com/rails/rails/security/advisories/GHSA-2w9f-fxwj-w2qf (opens in a new tab)x_refsource_confirm