Flask-Reuploaded
Flask-Reuploaded vulnerable to Remote Code Execution via Server-Side Template Injection
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.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 1.5.0
Fixed in 1.5.0
Mitigation
Upgrade flask-reuploaded to 1.5.0 or later.
References
Timeline
Days relative to CVE publicationFirst public PoC 148 days after publication; not in CISA KEV. First PoC: Max78000/CVE-2026-27641-Flask-Reuploaded (created 23 Jul 2026, found by us: backfilled).
PoC repositories
Found on GitHub.1 PoCs
PoCs 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| Max78000/CVE-2026-27641-Flask-Reuploaded | 23 Jul 2026 +148 d | 0 | PoC |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.
PoC characteristics
What to hunt for in your logs · from 1 PoC repoPOST /file_uploads
- Body markers
name="file"; filename="../..//test.txt"file=inmultipart/form-data- Ports
- 5000
- Seen in
- 1 repo: Max78000/CVE-2026-27641-Flask-Reuploaded
- Evidence
- Max78000/CVE-2026-27641-Flask-Reuploaded/PoC.py:37 Max78000/CVE-2026-27641-Flask-Reuploaded/PoC.py:9
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/file_uploads(?:[?#].*)?$
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET [5000] (msg:"GG PoC-Monitor CVE-2026-27641 jugmac00 flask-reuploaded exploit attempt"; flow:established,to_server; http.method; content:"POST"; http.uri; content:"/file_uploads"; http.request_body; content:"name=|22|file|22||3b| filename=|22|../..//test.txt|22|"; http.request_body; content:"file="; reference:url,poc.griffinguard.io/cve/CVE-2026-27641; classtype:web-application-attack; sid:9371063; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: jugmac00 flask-reuploaded exploit attempt (CVE-2026-27641)
id: gg-pocmon-cve-2026-27641-9371063
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-27641. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-27641
logsource:
category: webserver
detection:
selection:
cs-method: POST
cs-uri-stem|contains|all:
- '/file_uploads'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: critical
tags:
- attack.initial_access
- attack.t1190
- cve.2026.27641