Skip to content
Heist/ feed
Back to feed
High

Mastodon: SSRF protection bypass on older Ruby versions

Type: advisorySources: OSV

Mastodon is a free, open-source social network server based on ActivityPub. Prior to 4.5.10, 4.4.17, and 4.3.23, when using Ruby versions older than 3.4, PrivateAddressCheck.private_address? returns false for IPv4-mapped IPv6 addresses (::ffff:a.b.c.d) corresponding to some private IPv4 addresses, depending on Ruby version, this can include loopback, RFC1918 private networks, and link-local space. An attacker who controls DNS for any domain can publish an AAAA record with such a mapped address; any outbound HTTP fetch Mastodon performs against that hostname then opens a real TCP connection to the underlying IPv4 address, including 127.0.0.1 and cloud-metadata endpoints such as 169.254.169.254. This vulnerability is fixed in 4.5.10, 4.4.17, and 4.3.23.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-47389
Confirmed fixed CVEs
Not specified
Updated in this feed
3 Nov 2026, 09:52 UTC · Revision 1

Source evidence

Mastodon: SSRF protection bypass on older Ruby versions

core-osv · Original source

Published 24 Jun 2026, 19:41 UTC

Mastodon is a free, open-source social network server based on ActivityPub. Prior to 4.5.10, 4.4.17, and 4.3.23, when using Ruby versions older than 3.4, PrivateAddressCheck.private_address? returns false for IPv4-mapped IPv6 addresses (::ffff:a.b.c.d) corresponding to some private IPv4 addresses, depending on Ruby version, this can include loopback, RFC1918 private networks, and link-local space. An attacker who controls DNS for any domain can publish an AAAA record with such a mapped address; any outbound HTTP fetch Mastodon performs against that hostname then opens a real TCP connection to the underlying IPv4 address, including 127.0.0.1 and cloud-metadata endpoints such as 169.254.169.254. This vulnerability is fixed in 4.5.10, 4.4.17, and 4.3.23.

osv:CVE-2026-47389
Complete source record
{
  "id": "a4f3b97c66f8c86bdd89539dbae2e37c7b72c38b083718297b573c7453e3306a",
  "url": "https://osv.dev/vulnerability/CVE-2026-47389",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Mastodon: SSRF protection bypass on older Ruby versions",
    "summary": "Mastodon is a free, open-source social network server based on ActivityPub. Prior to 4.5.10, 4.4.17, and 4.3.23, when using Ruby versions older than 3.4, PrivateAddressCheck.private_address? returns false for IPv4-mapped IPv6 addresses (::ffff:a.b.c.d) corresponding to some private IPv4 addresses, depending on Ruby version, this can include loopback, RFC1918 private networks, and link-local space. An attacker who controls DNS for any domain can publish an AAAA record with such a mapped address; any outbound HTTP fetch Mastodon performs against that hostname then opens a real TCP connection to the underlying IPv4 address, including 127.0.0.1 and cloud-metadata endpoints such as 169.254.169.254. This vulnerability is fixed in 4.5.10, 4.4.17, and 4.3.23.",
    "evidence": "osv:CVE-2026-47389",
    "products": [],
    "severity": "high",
    "structured": {
      "id": "CVE-2026-47389",
      "aliases": [
        "BIT-mastodon-2026-47389",
        "CVE-2026-47389",
        "GHSA-xx55-4rrg-8xg6"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/mastodon/mastodon",
              "type": "GIT",
              "events": [
                {
                  "introduced": "5a8ab0a3e62a8825e28bb74c1760ba6488d20c97"
                },
                {
                  "fixed": "f80b1ba92e63c3da771b405b9100f5c9abda909f"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "4.5.0-beta.1"
                      },
                      {
                        "fixed": "4.5.10"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StringRangeExpression"
                  },
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "4.5.10"
                      }
                    ],
                    "source": "DESCRIPTION"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v4.5.9",
            "v4.5.8",
            "v4.5.7",
            "v4.5.6",
            "v4.5.5",
            "v4.5.4",
            "v4.5.3",
            "v4.5.2",
            "v4.5.1",
            "v4.5.0",
            "v4.5.0-rc.3",
            "v4.5.0-rc.2",
            "v4.5.0-rc.1",
            "v4.5.0-beta.2",
            "v4.5.0-beta.1"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-47389.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:27.723523368Z",
      "provider": "osv",
      "references": [
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/47xxx/CVE-2026-47389.json",
        "https://github.com/mastodon/mastodon/security/advisories/GHSA-xx55-4rrg-8xg6",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-47389"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-184",
          "CWE-200",
          "CWE-918"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/47xxx/CVE-2026-47389.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-47389",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 494316,
  "published_at": "2026-06-24T19:41:21.15+00:00"
}