CVE-2025-55194

Persistent Denial of Service

Uncaught Exception from Misleading File Extension in Avatar Upload in Part-DB ≤ 1.17.2

Overview

A vulnerability in Part-DB 1.17.2 allows any authenticated user to upload a profile picture with a misleading file extension (e.g., .jpg.txt), resulting in a persistent 500 Internal Server Error when accessing that user’s profile. This effectively locks the affected profile in the UI for both users and administrators, constituting a Denial of Service.

Affected Versions

Patched Versions

Technical Details

The issue is in src/Services/Attachments/AttachmentURLGenerator.php, specifically the getThumbnailURL() method. It assumes uploaded files are valid images based solely on their extension. If a file has a valid image binary but a misleading extension (like .jpg.txt), the function throws an uncaught InvalidArgumentException:

if (!$attachment->isPicture()) {
    throw new InvalidArgumentException('Thumbnail creation only works for picture attachments!');
}

This method is invoked when rendering user profiles in templates/admin/user_admin.html.twig:

{% block preview_picture %}
    <img src="{{ avatar_helper.avatarURL(entity) }}" style="height: 50px;">
{% endblock %}

Steps to reproduce:

1. Log in as a user with permissions to change their avatar (admin or standard user).
2. Navigate to /en/user/settings.
3. Upload a valid image file but rename it with a double extension, e.g: avatar.jpg.txt
4. Submit the form to save settings.
5. Attempt to revisit the profile settings or access the user from the admin panel.
6. Result: a persistent 500 Internal Server Error occurs.

Video PoC: View PoC - https://drive.google.com/file/d/10exp_BS9kRKHrFSPjiA_ZYUVJbHN8doW/view

Impact

Solution

Timeline

References