CVE-2026-49136
Deferred Deferred - Pending Action
Path Traversal in Banana Slides AI Service

Publication date: 2026-06-01

Last updated on: 2026-06-01

Assigner: VulnCheck

Description
Banana Slides through 0.4.0, patched in commit e8bc490, contains a path traversal vulnerability in the generate_image() function within the AI service backend that allows unauthenticated attackers to read arbitrary image-format files outside the intended uploads directory by exploiting an incomplete path prefix check using os.path.startswith() without a trailing separator. Attackers can supply crafted markdown image references in user-controlled page descriptions that resolve to sibling directories whose names share the uploads folder prefix, bypassing the directory confinement check and causing the application to read files from unintended locations via PIL Image.open().
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-06-01
Last Modified
2026-06-01
Generated
2026-06-22
AI Q&A
2026-06-02
EPSS Evaluated
2026-06-20
NVD
Affected Vendors & Products
Showing 1 associated CPE
Vendor Product Version / Range
banana_slides banana_slides 0.4.0
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-22 The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.
Attack-Flow Graph
AI Quick Actions
Instant insights powered by AI
Detection Guidance

This vulnerability can be detected by attempting to exploit the path traversal flaw through crafted markdown image references in user-controlled page descriptions. Specifically, you can test if the application improperly reads files from sibling directories that share the uploads folder prefix by injecting payloads such as ![](/files/../uploads_secret/flag.png).

To detect exploitation or test the vulnerability, you can monitor server logs for unusual image generation requests containing traversal patterns like '/../uploads_secret/' or similar. Additionally, you can attempt to create a project or page description with such a payload and observe if the server reads files outside the intended uploads directory.

Since the vulnerability is triggered server-side during image generation, direct network commands may not reveal it, but you can use curl or similar HTTP clients to send crafted markdown content to the application endpoints that accept page descriptions.

  • Example curl command to test the vulnerability by injecting a markdown image reference payload:
  • curl -X POST https://your-banana-slides-instance/api/projects/{project_id}/pages -H 'Content-Type: application/json' -d '{"description": "![](/files/../uploads_secret/flag.png)"}'
  • Replace {project_id} with a valid project identifier and adjust the URL to your deployment.

If the vulnerability is present, the server will attempt to read the file at the crafted path during image generation, which may be confirmed by observing server-side logs or error messages indicating file access outside the uploads directory.

Compliance Impact

The vulnerability allows unauthenticated attackers to read arbitrary image-format files outside the intended uploads directory, potentially exposing sensitive data.

Such unauthorized data access could lead to violations of data protection regulations like GDPR and HIPAA, which require strict controls on access to personal and sensitive information.

Therefore, this vulnerability may negatively impact compliance with these standards by enabling data breaches through improper file access controls.

Mitigation Strategies

The vulnerability is patched in commit e8bc490 of Banana Slides through version 0.4.0. Immediate mitigation involves updating the Banana Slides software to a version that includes this patch.

Since the vulnerability allows unauthenticated attackers to read arbitrary image-format files outside the intended uploads directory by exploiting an incomplete path prefix check, it is important to ensure that the application is not running unpatched versions.

Executive Summary

This vulnerability exists in Banana Slides version 0.4.0 in the generate_image() function of the AI service backend. It is a path traversal vulnerability that allows unauthenticated attackers to read arbitrary image-format files outside the intended uploads directory.

The issue arises because the application uses an incomplete path prefix check with os.path.startswith() without a trailing separator. Attackers can craft markdown image references in user-controlled page descriptions that resolve to sibling directories sharing the uploads folder prefix, bypassing the directory confinement check.

As a result, the application may read files from unintended locations using the PIL Image.open() function.

Impact Analysis

This vulnerability can impact you by allowing attackers to read sensitive image files outside the designated uploads directory without authentication.

Since the vulnerability allows arbitrary file reading, attackers could potentially access confidential or private image data stored on the server, leading to information disclosure.

The CVSS v3.1 score of 7.5 (High) and v4.0 score of 8.7 (High) reflect the severity of this vulnerability, indicating a significant risk of confidentiality breach.

Chat Assistant
Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-49136. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70
EPSS Chart