---
id: CVE-2022-32114
title: >-
  An unrestricted file upload vulnerability in the Add New Assets function of
  Strapi 4.1.12 allows attackers to conduct XSS attacks via a crafted PDF file
summary: >-
  An unrestricted file upload vulnerability in the Add New Assets function of
  Strapi 4.1.12 allows attackers to conduct XSS attacks via a crafted PDF file.
  NOTE: the project documentation suggests that a user with the Media Library
  "Create…
severity: high
cvss: 8.8
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H'
cwe:
  - CWE-434
vendor: strapi
product: strapi
affected:
  - strapi = 4.1.12
published: '2022-07-13'
updated: '2026-07-02'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2022-32114'
references:
  - url: 'https://docs.strapi.io/dev-docs/configurations/public-assets'
    label: cve@mitre.org
  - url: >-
      https://docs.strapi.io/user-docs/users-roles-permissions/configuring-administrator-roles
    label: cve@mitre.org
  - url: 'https://github.com/bypazs/strapi'
    label: cve@mitre.org
  - url: >-
      https://github.com/strapi/strapi/blob/d9277d616b4478a3839e79e47330a4aaf167a2f1/packages/core/content-type-builder/admin/src/components/AllowedTypesSelect/index.js#L14
    label: cve@mitre.org
  - url: >-
      https://github.com/strapi/strapi/blob/d9277d616b4478a3839e79e47330a4aaf167a2f1/packages/core/upload/admin/src/components/MediaLibraryInput/index.js#L33
    label: cve@mitre.org
  - url: >-
      https://grimthereaperteam.medium.com/strapi-v4-1-12-unrestricted-file-upload-b993bfd07e4e
    label: cve@mitre.org
  - url: 'https://docs.strapi.io/dev-docs/configurations/public-assets'
    label: af854a3a-2127-422b-91ae-364da2661108
  - url: >-
      https://docs.strapi.io/user-docs/users-roles-permissions/configuring-administrator-roles
    label: af854a3a-2127-422b-91ae-364da2661108
  - url: 'https://github.com/bypazs/strapi'
    label: af854a3a-2127-422b-91ae-364da2661108
  - url: >-
      https://github.com/strapi/strapi/blob/d9277d616b4478a3839e79e47330a4aaf167a2f1/packages/core/content-type-builder/admin/src/components/AllowedTypesSelect/index.js#L14
    label: af854a3a-2127-422b-91ae-364da2661108
  - url: >-
      https://github.com/strapi/strapi/blob/d9277d616b4478a3839e79e47330a4aaf167a2f1/packages/core/upload/admin/src/components/MediaLibraryInput/index.js#L33
    label: af854a3a-2127-422b-91ae-364da2661108
  - url: >-
      https://grimthereaperteam.medium.com/strapi-v4-1-12-unrestricted-file-upload-b993bfd07e4e
    label: af854a3a-2127-422b-91ae-364da2661108
tags:
  - nvd
  - exploit-available
epss: 0.01999
epssPercentile: 0.79842
ingestedAt: '2026-07-02T16:39:34.545Z'
exploits:
  github: 1
  githubRepos:
    - 'https://github.com/bypazs/CVE-2022-32114'
  checkedAt: '2026-09-25T08:20:40.714Z'
exploitAvailable: true
---

## Overview

An unrestricted file upload vulnerability in the Add New Assets function of Strapi 4.1.12 allows attackers to conduct XSS attacks via a crafted PDF file. NOTE: the project documentation suggests that a user with the Media Library "Create (upload)" permission is supposed to be able to upload PDF files containing JavaScript, and that all files in a public assets folder are accessible to the outside world (unless the filename begins with a dot character). The administrator can choose to allow only image, video, and audio files (i.e., not PDF) if desired.

## Affected

- `strapi = 4.1.12`

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.
