CVE-2022-31033 json
Authorization header leak in rubygem Mechanize
published 2022-06-09 4 y ago modified 2026-06-17 4 mo ago also GHSA-64qm-hrgp-pgr9 , EUVD-2022-5951
- cvss
- 5.9
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.5%
- EPSS 1.5% chance of exploitation in 30 days, percentile 74%
- public exploits
- 0
- none known
Summary
The Mechanize library is used for automating interaction with websites. Mechanize automatically stores and sends cookies, follows redirects, and can follow links and submit forms. In versions prior to 2.8.5 the Authorization header is leaked after a redirect to a different port on the same site. Users are advised to upgrade to Mechanize v2.8.5 or later. There are no known workarounds for this issue.
Patch / fix
- rubygems mechanize 2.8.5
- mechanize_project mechanize 2.8.5
- ruby-mechanize Debian 14, Debian 13, Debian 12 2.8.5-1
debian advisories DEBIAN-CVE-2022-31033
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2022-31033 updated cvss 6.5
rubygem-mechanize: authorization header leak on port redirect
-
Red Hat All currently supported Red Hat productsnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
- Assessed
- 18 mo ago
Exploit prediction
1.52% chance of exploitation in the next 30 days, higher than 74% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 5.9 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N |
| NVD | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
| NVD | 2.0 | 5.0 | AV:N/AC:L/Au:N/C:P/I:N/A:N |
| GitHub | 3.1 | 5.9 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| rubygems | mechanize | <2.8.5 |
2.8.5 |
Affected products
- sparklemotion mechanize
Classification
References
-
github.com
/sparklemotion/mechanize/commit/c7fe6996a5b95f9880653ba3bc548a8d4ef72317
web, patch, third-party-advisory
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/OA2FJROTX2U6EBWDPKRQ2VAM67A5TQXF/
vendor-advisory
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/7OKZMR5O3T5HQ2V737TC7IU4WZRT2LGX/
vendor-advisory
-
github.com
/sparklemotion/mechanize/security/advisories/GHSA-64qm-hrgp-pgr9
web, third-party-advisory
-
nvd.nist.gov
/vuln/detail/CVE-2022-31033
advisory
-
github.com
/rubysec/ruby-advisory-db/blob/master/gems/mechanize/CVE-2022-31033.yml
web
-
github.com
/sparklemotion/mechanize
package
Sources
- CVE List CVE-2022-31033
- GitHub Advisory GHSA-64qm-hrgp-pgr9
- NVD CVE-2022-31033
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.