Skip to content
SSRF Write-up Beginner

SSRF in Lychee: CVE-2025–53018

The Lychee photo management tool's /api/v2/Photo::fromUrl endpoint accepts a user-supplied URL and makes an HTTP request to it without validation. An attacker could use this to access internal services and potentially sensitive data.

medium.com

Published on medium.com

I discovered a Server-Side Request Forgery (SSRF) vulnerability in Lychee, an open-source photo management tool. This post walks through my full triage process — from route mapping to source analysis and exploitation — leading to CVE-2025–53018.

Baran TEYİN, on medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the application did not validate or restrict the URLs supplied to the photo import endpoint before making server-side requests.

Impact

An attacker could force the server to make requests to internal or external systems, potentially accessing sensitive data or bypassing firewalls.

What the attacker needed

Access to the Lychee web interface; ability to send POST requests to the API

The fix

The application should implement an allowlist of trusted domains and reject localhost and private IP addresses, or avoid letting users control URL fetches entirely.

How it was found

  1. List all available routes using php artisan route:list.
  2. Identify the /api/v2/Photo::fromUrl endpoint as interesting.
  3. Search the source code for Photo::fromUrl to find the handler.
  4. Start a local HTTP server with python3 -m http.server 8000.
  5. Send a POST request to /api/v2/Photo::fromUrl with a JSON body containing a url pointing to the local server.
  6. Observe that the server makes a request to the supplied URL, confirming SSRF.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

Server-Side Request Forgery (SSRF) is when a website lets you give it a web address, and the website's server then fetches that address for you. If the server can reach internal systems that you cannot, you can use the website as a proxy to access them. Here, the photo import feature fetched any URL, including internal ones.

What is SSRF?

The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.

Similar reports

View all

Same bug class and techniques, clearest first.

Server-side request forgery (SSRF)

The lesson behind this report.

The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.