<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet href="/static/style.xsl" type="text/xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <id>https://vulnerability.circl.lu/rss/recent/all/10</id>
  <title>Most recent entries from all</title>
  <updated>2026-10-08T19:07:58.970480+00:00</updated>
  <author>
    <name>Vulnerability-Lookup</name>
    <email>info@circl.lu</email>
  </author>
  <link href="https://vulnerability.circl.lu" rel="alternate"/>
  <generator uri="https://lkiesow.github.io/python-feedgen" version="1.0.0">python-feedgen</generator>
  <subtitle>Contains only the most 10 recent entries.</subtitle>
  <entry>
    <id>https://vulnerability.circl.lu/vuln/cve-2025-67720</id>
    <title>CVE-2025-67720 — Pyrofork has a Path Traversal in download_media Method</title>
    <updated>2026-10-08T19:07:59.242246+00:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml"><p><strong>Affected:</strong> Mayuri-Chan pyrofork</p>
<p>Pyrofork is a modern, asynchronous MTProto API framework. Versions 2.3.68 and earlier do not properly sanitize filenames received from Telegram messages in the download_media method before using them in file path construction. When downloading media, if the user does not specify a custom filename (which is the common/default usage), the method falls back to using the file_name attribute from the media object. The attribute originates from Telegram's DocumentAttributeFilename and is controlled by the message sender. This issue is fixed in version 2.3.69.</p></div>
    </content>
    <link href="https://vulnerability.circl.lu/vuln/cve-2025-67720"/>
  </entry>
  <entry>
    <id>https://vulnerability.circl.lu/vuln/ghsa-6h2f-wjhf-4wjx</id>
    <title>GHSA-6h2f-wjhf-4wjx — Pyrofork has a Path Traversal in download_media Method</title>
    <updated>2026-10-08T19:07:59.242383+00:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml"><p><strong>Affected:</strong> PyPI: pyrofork</p>
<p>## Summary</p>
<p>The `download_media` method in Pyrofork does not sanitize filenames received from Telegram messages before using them in file path construction. This allows a remote attacker to write files to arbitrary locations on the filesystem by sending a specially crafted document with path traversal sequences (e.g., `../`) or absolute paths in the filename.</p>
<p>---</p>
<p>## Details</p>
<p>When downloading media, if the user does not specify a custom filename (which is the common/default usage), the method falls back to using the `file_name` attribute from the media object. This attribute originates from Telegram's `DocumentAttributeFilename` and is controlled by the message sender.</p>
<p>### Vulnerable Code Path</p>
<p>**Step 1**: In `pyrogram/methods/messages/download_media.py` (lines 145-151):</p>
<p>```python
media_file_name = getattr(media, "file_name", "")  # Value from Telegram message</p>
<p>directory, file_name = os.path.split(file_name)    # Split user's path parameter
file_name = file_name or media_file_name or ""     # Falls back to media_file_name if empty
```</p>
<p>When a user calls `download_media(message)` or `download_media(message, "downloads/")`, the `os.path.split()` returns an empty filename, causing the code to use `media_file_name` which is attacker-controlled.</p>
<p>**Step 2**: In `pyrogram/client.py` (line 1125):</p>
<p>```python
temp_file_path = os.path.abspath(re.sub("\\\\", "/", os.path.join(directory, file_name))) + ".temp"
```</p>
<p>The `os.path.join()` function does not prevent path traversal. When `…</p></div>
    </content>
    <link href="https://vulnerability.circl.lu/vuln/ghsa-6h2f-wjhf-4wjx"/>
  </entry>
</feed>
