CVE-2025-25301: Rembg allows SSRF via /api/remove

CVE-2025-25301 · Severity: low · CVSS 3.1 · Published 2025-03-03

Rembg is a tool to remove images background. In Rembg 2.0.57 and earlier, the /api/remove endpoint takes a URL query parameter that allows an image to be fetched, processed and returned. An attacker may be able to query this endpoint to view pictures hosted on the internal network of the rembg server. This issue may lead to Information Disclosure.

Technologies: rembg (PyPI). Vendors: PyPI.

Quick answers

Is CVE-2025-25301 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2025-25301 being exploited in the wild.
How severe is CVE-2025-25301?
Low severity, with a CVSS score of 3.1, published 3 March 2025.
Which products and versions are affected?
rembg (PyPI) ECOSYSTEM:introduced=0,fixed=2.0.58, ECOSYSTEM:introduced=0,last_affected=2.0.57.
Is there a fix for CVE-2025-25301?
Yes. rembg (PyPI): upgrade to 2.0.58 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
Am I affected by CVE-2025-25301?
Check whether you run rembg (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • rembg (PyPI): upgrade to 2.0.58 or later
    pip install "rembg>=2.0.58"

Affected products

  • rembg (PyPI) ECOSYSTEM:introduced=0,fixed=2.0.58, ECOSYSTEM:introduced=0,last_affected=2.0.57

Identifiers

  • CVE-2025-25301
  • GHSA-r5gx-c49x-h878
  • PYSEC-2025-24

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.