Skip to content

Insufficient content-type validation for uploaded files

High
sergei-maertens published GHSA-h85r-xv4w-cg8g Jun 13, 2022

Package

open-forms (open-formulieren)

Affected versions

< 1.0.9, < 1.1.1

Patched versions

1.0.9, 1.1.1

Description

Impact

Open Forms supports file uploads as one of the form field types. These fields can be configured to allow only certain file extensions to be uploaded by end users (e.g. only PDF / Excel / ...). The input validation of uploaded files is insufficient in this case. Users could alter or strip file extensions to bypass this validation.

This results in files being uploaded to the server that are of a different file type than indicated by the file name extension. These files may be downloaded (manually or automatically) by staff and/or other applications for further processing. Malicious files can therefore find their way into internal/trusted networks.

Patches

This will be patched in the master branch and subsequently released in 1.0.9 and 1.1.1. You should upgrade to a supported version asap.

Workarounds

An API gateway or intrusion detection solution in front of open-forms may be able to scan for and block malicious content before it reaches the Open Forms application.

For more information

If you have any questions or comments about this advisory:

Severity

High
7.6
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
High
Availability
Low
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:H/A:L

CVE ID

CVE-2022-31041