fluentcms / fluentcms/FluentCMS

Cross-site scripting (XSS) via SVG image upload

Open
#2,404 1 comment 1 reaction 2 assignees Claimed by @pournasserian View on GitHub
bug
Dominant language
C#
Stars
565
Forks
107
PR merge metrics
No merged PRs in 30d

Description

## Description
### Overview
A Stored Cross-Site Scripting (XSS) vulnerability has been identified in the File Management module of FluentCMS. The vulnerability allows an authenticated administrator to upload SVG files containing malicious JavaScript code. This code is executed in the user's browser whenever the URL of the uploaded image is accessed.
### Details
The application allows authenticated administrators to upload SVG files via the File Management module without proper sanitization. Since SVG files can contain embedded JavaScript, the malicious code executes automatically when the image is rendered in a browser. Because files are stored in a public directory and served without restrictive security headers, the XSS executes for any user accessing the file URL, including unauthenticated visitors.

### PoC
To replicate this vulnerability:

1. Log in to the FluentCMS admin panel.

Image

2. Navigate to File Management

Image

3. Upload SVG file

Image

Image

4. Path to file in request

Image

5. Observe that the JavaScript code executes in the browser.

Image

### Impact
This could lead to unauthorized actions, UI manipulation, or redirecting users to malicious external websites.

### Note
This public disclosure is being made after coordinating with the team

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.