Junglewise Threat Intelligence

CVE-2026-47389: Mastodon SSRF protection bypass in PrivateAddressCheck

CVE-2026-47389 · Severity: high · CVSS 8.6 · Published 2026-06-24

Technologies: Mastodon. Vendors: Mastodon.

Executive brief

Mastodon, a popular open-source social networking platform, is vulnerable to a security flaw that allows attackers to trick the server into making unauthorized requests to internal systems. By exploiting how the server handles certain network addresses, an attacker could gain access to sensitive internal data, such as cloud infrastructure credentials or private administrative interfaces. This could lead to the exposure of private configuration details or unauthorized access to the server's hosting environment.

Technical details

A Server-Side Request Forgery (SSRF) vulnerability exists in Mastodon due to an incomplete remediation of a previous flaw (GHSA-xfrj-c749-jxxq). When running on Ruby versions older than 3.4, the 'PrivateAddressCheck.private_address?' method fails to correctly identify IPv4-mapped IPv6 addresses (::ffff:a.b.c.d) as private. An attacker can exploit this by controlling DNS for a domain and publishing an AAAA record pointing to a mapped private address (e.g., loopback, RFC1918, or cloud metadata endpoints like 169.254.169.254). When Mastodon performs an outbound HTTP fetch against such a hostname, it establishes a TCP connection to the internal IPv4 target. This can result in the exposure of sensitive information, including IAM credentials from cloud metadata services. The issue is patched in versions 4.5.10, 4.4.17, and 4.3.23.

Affected products

  • Mastodon Mastodon < 4.5.10, < 4.4.17, < 4.3.23

Timeline

  • 2026-05-20: advisory: GitHub security advisory published
  • 2026-06-24: disclosed: CVE published to NVD

References

Related threats