Read the docs

Mechanize leaks configured headers to other origins on meta refresh

Priority LOW 30CWE-200Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
High
Impact type
Information disclosure
Confidentiality · integrity · availability
High · None · None
Fix status
Partial Red Hat: 1 without a fix

Attack profile from CVSS 3.1 · CNA. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-200.

Summary

Mechanize before 2.14.1 applies no origin trust boundary to meta refresh redirects when follow_meta_refresh is enabled. A page with a meta refresh to another origin causes headers set through request_headers= to be sent to that origin (CWE-522). A remote attacker who controls content in a crawl can capture bearer tokens or session cookies. The default configuration is not affected because follow_meta_refresh is false.

Written with Claude Haiku 5.5 from the sources below · 2026-10-29

Description from the CNA

The Mechanize library is used for automating interaction with websites. Prior to 2.14.1, Mechanize applies no origin trust boundary in Mechanize::HTTP::Agent#response_follow_meta_refresh when Mechanize#follow_meta_refresh is enabled. A page containing a meta refresh to another origin causes headers configured through Mechanize#request_headers= to be reapplied to the refresh request, allowing an attacker who controls content in the crawl to capture bearer tokens or session cookies. The default configuration is not affected because follow_meta_refresh is false, and the exposure is limited to caller-supplied default headers. This issue is fixed in version 2.14.1.

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.00362 30th percentileScored 2026-11-07
Fix Partial mechanize (sparklemotion): 2.15.0mechanize (RubyGems): 2.14.1Red Hat: 1 without a fix

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
No
Technical impact
Partial

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
sparklemotionmechanizebefore 2.15.02.15.0Patch availableCNA
—mechanize (RubyGems)before 2.14.12.14.1Patch availableGHSA-c6rp-p8xm-4q9f
  • mechanize Vendorsparklemotion Affected before 2.15.0 Fixed in 2.15.0 Patch available CNA
  • mechanize (RubyGems) Vendor— Affected before 2.14.1 Fixed in 2.14.1 Patch available GHSA-c6rp-p8xm-4q9f

Remediation

Upgrade the RubyGems package mechanize to version 2.14.1, which fixes the issue. The sources list no fixed version for sparklemotion mechanize, which lists versions before 2.15.0 as affected. Red Hat rates this Moderate and plans no fix for Red Hat 3scale API Management Platform 2.

Written with Claude Haiku 5.5 from the sources below · 2026-10-29

  • Fix · CNA mechanize (sparklemotion) Fixed in 2.15.0
  • Fix · GHSA-c6rp-p8xm-4q9f mechanize (RubyGems) Fixed in 2.14.1 Advisory →

Vendor assessments

Red Hat

Red Hat rating: Moderate. Red Hat's page for this CVE →

ProductStatusPlan or fix
Red Hat 3scale API Management Platform 2AffectedNo fix planned: Out of support scope

Timeline

  1. 2026-10-09 Threatist record created from CVE-2026-107399
  2. 2026-10-09 Alias added: GHSA-c6rp-p8xm-4q9f
  3. 2026-10-09 Affected versions changed · Red Hat
  4. 2026-10-09 CVSS score added · Red Hat
  5. 2026-10-10 Priority changed: MEDIUM → LOW
  6. 2026-10-14 CISA SSVC decision points changed

References

  • TI-2022-11724 Improper Handling of Unexpected Data Type in Nokogiri CVSS 3.1HIGH 8.2
  • TI-2018-15259 zlib before 1.2.12 allows memory corruption when deflating (i.e., when compressing) if… CVSS 3.1HIGH 7.5
  • TI-2026-69678 Mechanize leaks credential headers to other hosts after redirects CVSS 3.1MEDIUM 6.8
  • TI-2025-05895 sparklemotion nokogiri hashmap.c hashmap_get_with_hash heap-based overflow CVSS 4.0MEDIUM 4.8
  • TI-2025-05891 sparklemotion nokogiri hashmap.c hashmap_set_with_hash heap-based overflow CVSS 4.0MEDIUM 4.8
  • TI-2019-03885 OS command injection in Nokogiri CVSS 3.1CRITICAL 9.8
See all 31 →

Sources