# CVE-2026-25765: Faraday affected by SSRF via protocol-relative URL host override in build_exclusive_url

> An attacker can exploit a protocol-relative URL handling flaw in the Faraday Ruby library to redirect requests to arbitrary hosts, enabling Server-Side Request Forgery.

- **Severity:** Medium 5.8 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 9 Feb 2026
- **Updated:** 10 Feb 2026
- **Also known as:** AZL-77631, AZL-77639, CLEANSTART-2026-FV59211, CLEANSTART-2026-PM67470, DEBIAN-CVE-2026-25765, GHSA-33mh-2634-fwr2, MINI-2q6m-h48j-jpvq, MINI-4qxc-47j8-hf5c, MINI-534j-f9x3-p974, MINI-562x-fpgh-r3hp, MINI-6559-xmmm-j3cq, MINI-68fq-725p-cvw7, MINI-7497-3hh6-jcwm, MINI-77r2-8h78-jg8w, MINI-8rq8-vvfm-pf4g, MINI-9mqf-h3cm-xp5r, MINI-gc7m-2vwr-48xj, MINI-gfhw-72f2-4j49, MINI-mqg9-33ww-944p, MINI-pm9q-vh64-vp9r, MINI-q379-g6j8-v4wx, MINI-qv37-qh3g-j8fj, MINI-qvcw-3ggc-527p, MINI-qwqw-6ghr-5wwm, MINI-rv98-3v5r-mqph, MINI-v3qr-qf46-fcc7, MINI-v3vw-5phm-5754, MINI-wf6w-w39g-6r7c, UBUNTU-CVE-2026-25765

## What is CVE-2026-25765?

CVE-2026-25765 is a medium-severity server-side request forgery vulnerability in lostisland faraday, published on 9 Feb 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

Faraday is an HTTP client library abstraction layer that provides a common interface over many adapters. Prior to 2.14.1, Faraday's build_exclusive_url method (in lib/faraday/connection.rb) uses Ruby's URI#merge to combine the connection's base URL with a user-supplied path. Per RFC 3986, protocol-relative URLs (e.g. //evil.com/path) are treated as network-path references that override the base URL's host/authority component. This means that if any application passes user-controlled input to Faraday's get(), post(), build_url(), or other request methods, an attacker can supply a protocol-relative URL like //attacker.com/endpoint to redirect the request to an arbitrary host, enabling Server-Side Request Forgery (SSRF). This vulnerability is fixed in 2.14.1.

Weakness: CWE-918 (Server-Side Request Forgery)

## Which versions are affected by CVE-2026-25765?

4 open source packages ship an affected version, including faraday. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `faraday` | RubyGems | From 1.0.0 | 1.10.5 |
| `faraday` | RubyGems | From 1.0.0 | 1.10.5 |
| `faraday` | RubyGems | From 2.0.0 | 2.14.1 |
| `faraday` | RubyGems | From 2.0.0 | 2.14.1 |

Products: Faraday Project Faraday.

## How do I fix CVE-2026-25765?

Upgrade faraday to a fixed version for your release line: 1.10.5 or 2.14.1.

## Is CVE-2026-25765 being exploited?

There is no known exploitation of CVE-2026-25765 in the wild and no public exploit code.

## Other vulnerabilities in lostisland faraday

- [CVE-2026-54297](https://insights.sbomify.com/CVE-2026-54297/): Faraday: Uncontrolled recursion in NestedParamsEncoder allows stack exhaustion DoS via deeply nested query parameters (high 7.5)
- [CVE-2026-33637](https://insights.sbomify.com/CVE-2026-33637/): Faraday: Protocol-relative URI objects still bypass host scoping (possible incomplete fix for GHSA-33mh-2634-fwr2) (not scored)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-25765 and fix it if it is affected.

What it is: CVE-2026-25765 is a medium-severity server-side request forgery vulnerability in lostisland faraday, published on 9 Feb 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2026-25765 in the wild and no public exploit code.

Affected packages and fixed versions:
- faraday (RubyGems): affected from 1.0.0; fixed in 1.10.5
- faraday (RubyGems): affected from 1.0.0; fixed in 1.10.5
- faraday (RubyGems): affected from 2.0.0; fixed in 2.14.1
- faraday (RubyGems): affected from 2.0.0; fixed in 2.14.1

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2026-25765/ (Markdown: https://insights.sbomify.com/CVE-2026-25765/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-25765
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-25765
- OSV: https://osv.dev/vulnerability/CVE-2026-25765

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-25765/
Summaries are generated and may contain mistakes; the official description above is the record.
