Skip to content
Heist/ feed
Back to feed
High

ruby-mechanize — security advisory

Type: advisorySources: OSVAdvisory ID: UBUNTU-CVE-2022-31033

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.

Products
ruby-mechanize
Affected versions
2.10.1-1, 2.10.1-1.1, 2.14.0-2, 2.8.5-1
Fixed versions
Not specified
CVEs
CVE-2022-31033
Confirmed fixed CVEs
Not specified
Updated in this feed
31 Oct 2026, 01:01 UTC · Revision 1

Source evidence

UBUNTU-CVE-2022-31033

core-osv · Original source

Published 9 Jun 2022, 20:15 UTC

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.

osv:UBUNTU-CVE-2022-31033

ruby-mechanize

Fixed versions: Not specified

ruby-mechanize

Fixed versions: Not specified

ruby-mechanize

Fixed versions: Not specified

ruby-mechanize

Fixed versions: Not specified

Complete source record
{
  "id": "41d5f25f2fcf3eb5e731b5a7816157cbb4993d9d09fa5e2d1acc4a08adcf8555",
  "url": "https://osv.dev/vulnerability/UBUNTU-CVE-2022-31033",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "UBUNTU-CVE-2022-31033",
    "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.",
    "evidence": "osv:UBUNTU-CVE-2022-31033",
    "products": [
      {
        "name": {
          "value": "ruby-mechanize",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.8.5-1",
            "evidence": "/affected/0/versions"
          }
        ]
      },
      {
        "name": {
          "value": "ruby-mechanize",
          "evidence": "/affected/1/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.10.1-1",
            "evidence": "/affected/1/versions"
          },
          {
            "value": "2.10.1-1.1",
            "evidence": "/affected/1/versions"
          }
        ]
      },
      {
        "name": {
          "value": "ruby-mechanize",
          "evidence": "/affected/2/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.10.1-1.1",
            "evidence": "/affected/2/versions"
          },
          {
            "value": "2.14.0-2",
            "evidence": "/affected/2/versions"
          }
        ]
      },
      {
        "name": {
          "value": "ruby-mechanize",
          "evidence": "/affected/3/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.10.1-1.1",
            "evidence": "/affected/3/versions"
          }
        ]
      }
    ],
    "severity": "high",
    "structured": {
      "id": "UBUNTU-CVE-2022-31033",
      "aliases": [
        "UBUNTU-CVE-2022-31033"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N"
        },
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
        },
        {
          "type": "Ubuntu",
          "score": "medium"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "ruby-mechanize",
            "purl": "pkg:deb/ubuntu/ruby-mechanize?arch=source&distro=noble",
            "ecosystem": "Ubuntu:24.04:LTS"
          },
          "versions": [
            "2.8.5-1"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2022/UBUNTU-CVE-2022-31033.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "ruby-mechanize",
                "binary_version": "2.8.5-1"
              }
            ]
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "ruby-mechanize",
            "purl": "pkg:deb/ubuntu/ruby-mechanize?arch=source&distro=questing",
            "ecosystem": "Ubuntu:25.10"
          },
          "versions": [
            "2.10.1-1",
            "2.10.1-1.1"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2022/UBUNTU-CVE-2022-31033.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "ruby-mechanize",
                "binary_version": "2.10.1-1.1"
              }
            ]
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "ruby-mechanize",
            "purl": "pkg:deb/ubuntu/ruby-mechanize?arch=source&distro=stonking",
            "ecosystem": "Ubuntu:26.10"
          },
          "versions": [
            "2.10.1-1.1",
            "2.14.0-2"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2022/UBUNTU-CVE-2022-31033.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "ruby-mechanize",
                "binary_version": "2.14.0-2"
              }
            ]
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "ruby-mechanize",
            "purl": "pkg:deb/ubuntu/ruby-mechanize?arch=source&distro=resolute",
            "ecosystem": "Ubuntu:26.04:LTS"
          },
          "versions": [
            "2.10.1-1.1"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2022/UBUNTU-CVE-2022-31033.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "ruby-mechanize",
                "binary_version": "2.10.1-1.1"
              }
            ]
          }
        }
      ],
      "modified": "2026-10-17T12:56:21.849992197Z",
      "provider": "osv",
      "upstream": [
        "CVE-2022-31033"
      ],
      "references": [
        "https://ubuntu.com/security/CVE-2022-31033",
        "https://github.com/sparklemotion/mechanize/security/advisories/GHSA-64qm-hrgp-pgr9",
        "https://github.com/sparklemotion/mechanize/commit/17e5381032c90caf240ac3d2e52b353f40c18d83",
        "https://www.cve.org/CVERecord?id=CVE-2022-31033"
      ]
    },
    "related_cves": [
      {
        "value": "CVE-2022-31033",
        "evidence": "/upstream"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/1/score"
  },
  "source_id": "core-osv",
  "document_id": 355435,
  "published_at": "2022-06-09T20:15:00+00:00"
}