CVE-2026-115924: Rembg: Unauthenticated SAM model injection permits local-file disclosure through malicious ONNX graphs
The public /api/remove endpoint uses attacker-controlled extras.sam_model in both SAM filenames and GitHub download URLs. Path traversal plus a URL fragment lets an unauthenticated attacker place malicious ONNX models beside a target file. The models read the file as ONNX external data and encode its bytes into the returned PNG.
This issue affects SAM’s sam_model in 2.0.81 and returns complete file contents.
Screenshot 1 — First unauthenticated request primes the path and returns HTTP 500.
References
Code Behaviors & Features
Detect and mitigate CVE-2026-115924 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →