Medium

Server Side Request Forgery (SSRF) attack in Fedify

  • Disclosed: 05.07.2024
  • Updated: 11.10.2026 10:22

Summary

At present, when Fedify needs to retrieve an object or activity from a remote activitypub server, it makes a HTTP request to the @id or other resources present within the activity it has received from the web. This activity could reference an @id that points to an internal IP address, allowing an attacker to send request to resources internal to the fedify server's network.

This applies to not just resolution of documents containing activities or objects, but also to media URLs as well.

Specifically this is a Server Side Request Forgery attack. You can learn more about SSRF attacks via CWE-918

Details

When Fedify makes a request at runtime via the DocLoader [1] [2], the fetch API does not first check the URI's to assert that it resolve to a public IP address. Additionally, any downstream software of Fedify that may fetch data from URIs contained within Activities or Objects maybe be at risk of requesting non-public resources, and storing those, exposing non-public information to the public.

Additionally, in many cases the URIs are not asserted to be either strictly HTTPS or HTTP protocols, which could lead to further attacks, and there is no check that the URI contains a hostname part. Whilst the fetch() specification may provide some safety here, along with underlying fetch implementations, there is still potential for attacks through using data: URIs, or just attacking some other protocol entirely, e.g., FTP or CalDav.

[1] https://github.com/dahlia/fedify/blob/main/runtime/docloader.ts#L141 [2] https://github.com/dahlia/fedify/blob/main/runtime/docloader.ts#L175

Deno-specific Attack Vectors

In Deno specifically, the fetch() API allows accessing local filesystem, I'm not sure how Deno's Permissions model may prevent attacks utilising file: URIs.

Fetch also supports fetching from file URLs to retrieve static files. For more info on static files, see the filesystem API documentation.

ActivityPub Security Considerations

This is also noted in the ActivityPub spec in Section B.3 Security Considerations, however, there it is more limited in scope.

Other Implementations

It may be acceptable to allow a server operator to allow access to given non-public IP addresses, for instance in Mastodon they allow requests to non-public IP addresses, i.e., localhost in development and those in the ALLOWED_PRIVATE_ADDRESSES environment variable.

PoC

I'm not sure a PoC is necessary given this is a reasonably well known vulnerability vector.

Impact

This impacts server operates, as resources that are internal to their network may find themselves being improperly accessed or potentially even attacked or exposed to the public.

Notes for resolution:

When implementing public IP address validation, be careful of CWE-1389 and CWE-1286 both of which recently caused a CVE to be filed against the popular node.js ip package, although this package was not originally intended for security purposes.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
npm package @fedify/fedify < 0.9.2, >= 0.10.0, < 0.10.2, >= 0.11.0, < 0.11.2 0.9.2, 0.10.2, 0.11.2

References

CVSS score 7.2/10
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:L
Weakness (CWE)
CWE-918
Platform
npm
Package
@fedify/fedify
Disclosed
05.07.2024
Updated
11.10.2026 10:22

Sources and licenses

OSV / GitHub Advisory Database - GHSA-p9cg-vqcc-grcx - CC BY 4.0

Vulnerability history: @fedify/fedify

All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.

Total entries
7
First → latest
07.2024 07.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • High 5
  • Medium 2

Disclosures per year

  1. 2024: 1
  2. 2025: 3
  3. 2026: 3
  1. High · 8.6 CVE-2026-50131 >= 0.11.2, < 1.9.12, >= 1.10.0, < 1.10.11, >= 2.0.0, < 2.0.19, >= 2.1.0, < 2.1.15, >= 2.2.0, < 2.2.4 1.9.12, 1.10.11, 2.0.19, 2.1.15, 2.2.4
  2. High · 7.0 CVE-2026-42462 >= 2.2.0, < 2.2.3, >= 2.1.0, < 2.1.14, >= 2.0.0, < 2.0.18, >= 1.10.0, < 1.10.10, < 1.9.11 2.2.3, 2.1.14, 2.0.18, 1.10.10, 1.9.11
  3. High · 7.5 CVE-2026-34148 < 1.9.6, >= 1.10.0, < 1.10.5, >= 2.0.0, < 2.0.8, >= 2.1.0, < 2.1.1 1.9.6, 1.10.5, 2.0.8, 2.1.1
  4. High · 7.5 CVE-2025-68475 < 1.6.13, >= 1.7.0, < 1.7.14, >= 1.8.0, < 1.8.15, >= 1.9.0, < 1.9.2 1.6.13, 1.7.14, 1.8.15, 1.9.2
  5. High CVE-2025-54888 < 1.3.20, >= 1.4.0-dev.585, < 1.4.13, >= 1.5.0-dev.636, < 1.5.5, >= 1.6.0-dev.754, < 1.6.8, >= 1.7.0-pr.251.885, < 1.7.9, >= 1.8.0-dev.909, < 1.8.5 1.3.20, 1.4.13, 1.5.5, 1.6.8, 1.7.9, 1.8.5
  6. Medium · 5.4 CVE-2025-23221 >= 1.0.13, < 1.0.14, >= 1.1.10, < 1.1.11, >= 1.2.10, < 1.2.11, >= 1.3.3, < 1.3.4 1.0.14, 1.1.11, 1.2.11, 1.3.4
  7. Server Side Request Forgery (SSRF) attack in Fedify this entry
    Medium · 7.2 CVE-2024-39687 < 0.9.2, >= 0.10.0, < 0.10.2, >= 0.11.0, < 0.11.2 0.9.2, 0.10.2, 0.11.2

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.