# CVE-2026-86119: Webstudio through 0.296.0 SSRF via /cgi proxy routes

The Markdown version of <https://upatch.dev/cve/CVE-2026-86119>. Last updated 25 Nov 2026.

## At a glance

CVE-2026-86119 is rated Critical 9.2 (CVSS 4.0, CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X). It affects Webstudio (webstudio-is) and was published on 5 Sept 2026. It is not in CISA's Known Exploited Vulnerabilities catalog. Its EPSS score is 0.6%: the estimated chance it is exploited in the next 30 days, as of 24 Nov 2026. The upatch `cve-2026-86119-ssrf-block` mitigates it, and is vetted (merged into the registry).

A upatch is a signed BPF program that shirudo loads into a running Linux kernel to block the code path this CVE's exploit takes. It holds the line until the fix ships; it does not replace patching.

## The vulnerability

CVE-2026-86119 was published on 5 September 2026. In Webstudio through 0.296.0, the Remix loader routes `apps/builder/app/routes/cgi.asset.$.ts`, `apps/builder/app/routes/cgi.image.$.ts`, and `apps/builder/app/routes/cgi.video.$.ts` decode the path suffix after `/cgi/asset/`, `/cgi/image/`, or `/cgi/video/` with `decodePathFragment()` and, when the `RESIZE_ORIGIN` environment variable is unset, check `if (URL.canParse(name)) { return fetch(name); }`. Because these routes require no authentication and only check that an optional `Referer` header matches the request `Host`, an unauthenticated client can pass a URL-encoded target such as `/cgi/asset/http%3A%2F%2F169.254.169.254%2Flatest%2Fmeta-data%2F` and receive the upstream response body directly.

### Official description

Webstudio through 0.296.0 contains an unauthenticated server-side request forgery vulnerability in the /cgi/image, /cgi/video, and /cgi/asset proxy routes when RESIZE_ORIGIN environment variable is unset. Attackers can supply arbitrary URLs to these endpoints to read cloud instance metadata, access internal services, and perform network reconnaissance on the instance infrastructure.

## What the upatch does

It attaches to `lsm/socket_connect` and checks the destination socket address first:

- For `AF_INET`, it refuses connections to `169.254.0.0/16` (RFC 3927 link-local and AWS/GCP/Azure instance metadata `169.254.169.254`), `100.100.100.254/32` (Alibaba Cloud metadata), and `192.0.0.0/24` (IETF protocol assignments including Oracle Cloud metadata `192.0.0.192`).
- For `AF_INET6`, it refuses connections to IPv4-mapped IPv6 addresses (`::ffff:0:0/96`) matching those IPv4 ranges, IPv6 link-local addresses (`fe80::/10`), and the AWS IMDSv2 IPv6 endpoint (`fd00:ec2::254`).

When the destination matches, it checks whether the calling task's executable (`task->mm->exe_file->f_path.dentry`) or task command name (`comm`) is `node`, increments the `refused` per-CPU counter, and returns `-EPERM`. Any refusal from an earlier BPF LSM program on the same hook is preserved.

The policy: [`cve-2026-86119-ssrf-block.bpf.c`](https://github.com/copper-helm/upatch-registry/tree/main/upatches/cve-2026-86119), 126 lines of BPF C attached at `lsm/socket_connect`, licensed GPL-2.0 OR BSD-2-Clause.

## Side effects

- `node` processes on the machine cannot connect to `169.254.0.0/16`, `100.100.100.254`, `192.0.0.0/24`, `fe80::/10`, or `fd00:ec2::254`, failing with `EPERM`.
- Local asset serving from disk and outbound connections from `node` to loopback (`127.0.0.1`) or regular network addresses keep working.
- Non-`node` processes on the host (including system services, cloud agents, and shells) can still reach link-local and cloud metadata endpoints as usual.

## Preemption model and cost

The program runs only on `connect()` system calls, never per packet. The fast path inspects `sa_family` and the destination IP address before reading task metadata, so non-matching connections finish in a few instructions. Refusals are counted in a `BPF_MAP_TYPE_PERCPU_ARRAY` map with `__sync_fetch_and_add`, making the program safe under `PREEMPT_LAZY`, preemptible RCU, and `PREEMPT_RT`.

## Affected versions

| Branch | Vulnerable      | Fixed in                       |
| ------ | --------------- | ------------------------------ |
| 0.x    | through 0.296.0 | unfixed upstream as of 0.296.0 |

## How it was tested

On Webstudio 0.296.0, the loaded upatch refused the /cgi/asset SSRF fetch to the link-local metadata endpoint with HTTP 500 (EPERM) while local asset serving continued to succeed.

- **Tested:** 25 Nov 2026
- **Target:** Webstudio 0.296.0 (/cgi/asset/$, /cgi/image/$, /cgi/video/$ routes on Node.js, RESIZE_ORIGIN unset, loopback only)
- **Kernel:** 7.4-shirudo-ci-20261123
- **Architecture:** x86_64
- **Machine:** shirudo test VM
- **Distribution:** Ubuntu 26.04

### Results

| State           | GET /cgi/asset/http%3A%2F%2F169.254.169.250%3A8081%2Flatest%2Fmeta-data%2F | GET /cgi/asset/hello.txt |
| --------------- | -------------------------------------------------------------------------- | ------------------------ |
| Before loading  | reached (HTTP 200)                                                         | 200                      |
| Upatch loaded   | blocked (HTTP 500)                                                         | 200                      |
| After unloading | reached (HTTP 200)                                                         | 200                      |

## How to apply

Build the upatch from source, sign it with your own shirudo key, and publish it to your own OCI registry. Machines that follow your upatch tree load it within about a minute.

Build and sign:

```sh
git clone https://github.com/copper-helm/upatch-registry
cd upatch-registry
tools/build <shirudo-checkout> <keys-dir> 1.0.0 upatches/cve-2026-86119
```

Publish and roll out:

```sh
shirudo bpm push build/packages/cve-2026-86119-1.0.0.bee oci://<registry>/<namespace>/cve-2026-86119 --keys-dir <keys-dir>
shirudo bpm tree append build/packages/cve-2026-86119-1.0.0.bee oci://<registry>/<namespace>/<tree> --tree-id <tree-id> --keys-dir <keys-dir>
```

## Review

- Contributors: romanlab.
- Reviewers: none recorded yet.

## Sources and links

- [CVE-2026-86119 record (CVE API)](https://cveawg.mitre.org/api/cve/CVE-2026-86119)
- [VulnCheck advisory](https://www.vulncheck.com/advisories/webstudio-through-0.296.0-ssrf-via-cgi-proxy-routes)
- [GitHub issue #5816](https://github.com/webstudio-is/webstudio/issues/5816)
- [cgi.asset.$.ts at 55920c57c4d3](https://github.com/webstudio-is/webstudio/blob/55920c57c4d3e128a0fa48fceabbbc3a1d73f1ef/apps/builder/app/routes/cgi.asset.$.ts)
- [cgi.image.$.ts at 55920c57c4d3](https://github.com/webstudio-is/webstudio/blob/55920c57c4d3e128a0fa48fceabbbc3a1d73f1ef/apps/builder/app/routes/cgi.image.$.ts)
- [cgi.video.$.ts at 55920c57c4d3](https://github.com/webstudio-is/webstudio/blob/55920c57c4d3e128a0fa48fceabbbc3a1d73f1ef/apps/builder/app/routes/cgi.video.$.ts)

### Links

- [CVE-2026-86119 on upatch.dev](https://upatch.dev/cve/CVE-2026-86119) (this page, as HTML)
- [NVD](https://nvd.nist.gov/vuln/detail/CVE-2026-86119)
- [CVE.org](https://www.cve.org/CVERecord?id=CVE-2026-86119)
- [CWE-918](https://cwe.mitre.org/data/definitions/918.html)
- Upatch source: [upatches/cve-2026-86119](https://github.com/copper-helm/upatch-registry/tree/main/upatches/cve-2026-86119)

### More references from NVD (6)

- [github.com](https://github.com/webstudio-is/webstudio)
- [github.com](https://github.com/webstudio-is/webstudio/blob/55920c57c4d3e128a0fa48fceabbbc3a1d73f1ef/apps/builder/app/routes/cgi.asset.$.ts)
- [github.com](https://github.com/webstudio-is/webstudio/blob/55920c57c4d3e128a0fa48fceabbbc3a1d73f1ef/apps/builder/app/routes/cgi.image.$.ts)
- [github.com](https://github.com/webstudio-is/webstudio/blob/55920c57c4d3e128a0fa48fceabbbc3a1d73f1ef/apps/builder/app/routes/cgi.video.$.ts)
- [github.com](https://github.com/webstudio-is/webstudio/issues/5816)
- [vulncheck.com](https://www.vulncheck.com/advisories/webstudio-through-0.296.0-ssrf-via-cgi-proxy-routes)
