Description
Strapi is an open source headless content management system. In Strapi versions prior to 5.33.3, the Upload plugin's Content API endpoints did not enforce the administrator-configured MIME type restrictions (`plugin.upload.security.allowedTypes` and `deniedTypes`). The same restrictions were correctly enforced on the Admin Panel upload path. The upload plugin's `enforceUploadSecurity` security check was invoked in the admin upload controller but was missing from the Content API controller. The Content API handlers `uploadFiles` and `replaceFile` (and the `upload` wrapper that dispatches to them) called the underlying upload service directly, bypassing both the magic-byte MIME detection and the configured allow/deny lists. An authenticated user with the Content API upload permission could therefore upload file types the administrator had explicitly disallowed, including HTML and SVG content. In deployments serving uploaded files from the same origin as the admin panel (default), an attacker could upload an HTML or SVG file that, when opened directly by an admin, executed JavaScript in the admin origin, enabling admin-session hijack and authenticated administrative actions against the admin API. The patch in version 5.33.3 introduces a shared `prepareUploadRequest` helper that wraps `enforceUploadSecurity` and is called from both the Content API and admin upload controllers, ensuring identical security policy enforcement on every upload entry point.
Published: 2026-05-14
Score: 5.3 Medium
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability stems from the Upload plugin’s Content API missing the security check that enforces administrator‑configured MIME type restrictions. Because the `enforceUploadSecurity` routine was only called by the Admin Panel controller, the Content API upload handlers invoked the upload service directly, bypassing magic‑byte detection and the allowed/denied type lists. An authenticated user with Content API upload permission could therefore upload any file type, including HTML and SVG. If such files are stored in the default location served from the same origin as the admin panel, an administrator who opens the file can execute JavaScript in the admin context, which can hijack the admin session or carry out authenticated administrative actions against the admin API.

Affected Systems

This flaw affects installations of Strapi, specifically the @strapi/upload plugin and the core strapi package, in all versions released before 5.33.3. Administrators that have enabled the upload feature and configured MIME type restrictions with `plugin.upload.security.allowedTypes` and `deniedTypes` are vulnerable.

Risk and Exploitability

The CVSS score is 5.3, indicating a medium impact, and the EPSS score is not available. The vulnerability is not listed in CISA’s KEV catalog. Attack requires an authenticated user with Content API upload permission; the attacker can upload an HTML or SVG file, and the real damage occurs when an administrator accesses the file, leading to XSS and potential session hijack. The deployment must serve uploads from the same origin, which is the default configuration, to realize the full exploitation path.

Generated by OpenCVE AI on May 14, 2026 at 20:25 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade Strapi to version 5.33.3 or later, where a shared `prepareUploadRequest` helper enforces MIME type checks on all upload endpoints.
  • If an immediate upgrade is not possible, remove the Content API upload permission from all authenticated roles or restrict upload access to only the admin panel controller.
  • Verify that the configured MIME type restrictions (`plugin.upload.security.allowedTypes` and `deniedTypes`) correctly reflect your security policy by attempting to upload a disallowed file type.
  • Monitor upload logs and access patterns for anomalous file uploads that may indicate exploitation attempts.

Generated by OpenCVE AI on May 14, 2026 at 20:25 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-pcw7-5633-82vv Strapi Upload Plugin MIME Validation Bypass via Content API
History

Sat, 16 May 2026 03:30:00 +0000

Type Values Removed Values Added
First Time appeared Strapi
Strapi strapi
CPEs cpe:2.3:a:strapi:strapi:*:*:*:*:*:node.js:*:*
Vendors & Products Strapi
Strapi strapi
Metrics cvssV3_1

{'score': 5.4, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N'}


Thu, 14 May 2026 19:00:00 +0000

Type Values Removed Values Added
Description Strapi is an open source headless content management system. In Strapi versions prior to 5.33.3, the Upload plugin's Content API endpoints did not enforce the administrator-configured MIME type restrictions (`plugin.upload.security.allowedTypes` and `deniedTypes`). The same restrictions were correctly enforced on the Admin Panel upload path. The upload plugin's `enforceUploadSecurity` security check was invoked in the admin upload controller but was missing from the Content API controller. The Content API handlers `uploadFiles` and `replaceFile` (and the `upload` wrapper that dispatches to them) called the underlying upload service directly, bypassing both the magic-byte MIME detection and the configured allow/deny lists. An authenticated user with the Content API upload permission could therefore upload file types the administrator had explicitly disallowed, including HTML and SVG content. In deployments serving uploaded files from the same origin as the admin panel (default), an attacker could upload an HTML or SVG file that, when opened directly by an admin, executed JavaScript in the admin origin, enabling admin-session hijack and authenticated administrative actions against the admin API. The patch in version 5.33.3 introduces a shared `prepareUploadRequest` helper that wraps `enforceUploadSecurity` and is called from both the Content API and admin upload controllers, ensuring identical security policy enforcement on every upload entry point.
Title Strapi Upload Plugin MIME Validation Bypass via Content API
Weaknesses CWE-434
CWE-693
References
Metrics cvssV4_0

{'score': 5.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-05-14T19:40:11.102Z

Reserved: 2026-01-08T19:23:09.857Z

Link: CVE-2026-22707

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Analyzed

Published: 2026-05-14T19:16:30.837

Modified: 2026-05-16T03:22:21.560

Link: CVE-2026-22707

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-05-14T20:30:04Z

Weaknesses