Track vulnerabilities like this one.
Sign up free to get alerted when software you use is affected.
8.7
CVE-2021-41281: Synapse Media Download Security Risk for Some Homeservers
CVE-2021-41281 · published 4 years ago
Summary
A security issue affects Synapse homeservers with media repositories enabled. If not patched, an attacker could trick the server into downloading a file from a remote location without permission. To fix this, update to version 1.47.1 or later, or consider disabling the media repository or using a workaround like blocking certain endpoints or using a hardened configuration.
What to do
- Update matrix.org team and contributors matrix-synapse to version 1.47.1.
- Update debian matrix-synapse to version 1.47.1-1.
- Update matrix synapse to version 1.47.1 or later.
Affected software
| Ecosystem | Vendor | Product | Affected versions |
|---|---|---|---|
| pip | matrix.org team and contributors | matrix-synapse |
< 1.47.1 Fix: upgrade to 1.47.1
|
| – | matrix | synapse |
< 1.47.1 cpe:2.3:a:matrix:synapse:*:*:*:*:*:*:*:* |
| – | fedoraproject | fedora |
34 35 cpe:2.3:o:fedoraproject:fedora:34:*:*:*:*:*:*:* |
| Debian:14 | debian | matrix-synapse |
< 1.47.1-1 Fix: upgrade to 1.47.1-1
|
Original advisory text
Synapse is a package for Matrix homeservers written in Python 3/Twisted. Prior to version 1.47.1, Synapse instances with the media repository enabled can be tricked into downloading a file from a r...
Synapse is a package for Matrix homeservers written in Python 3/Twisted. Prior to version 1.47.1, Synapse instances with the media repository enabled can be tricked into downloading a file from a remote server into an arbitrary directory. No authentication is required for the affected endpoint. The last 2 directories and file name of the path are chosen randomly by Synapse and cannot be controlled by an attacker, which limits the impact. Homeservers with the media repository disabled are unaffected. Homeservers with a federation whitelist are also unaffected, since Synapse will check the remote hostname, including the trailing `../`s, against the whitelist. Server administrators should upgrade to 1.47.1 or later. Server administrators using a reverse proxy could, at the expense of losing media functionality, may block the certain endpoints as a workaround. Alternatively, non-containerized deployments can be adapted to use the hardened systemd config.
References
- https://github.com/matrix-org/synapse/security/advisories/GHSA-3hfw-x7gx-437c
- https://nvd.nist.gov/vuln/detail/CVE-2021-41281
- https://github.com/matrix-org/synapse/commit/91f2bd090
- https://github.com/matrix-org/synapse/releases/tag/v1.47.1
- https://github.com/pypa/advisory-database/tree/main/vulns/matrix-synapse/PYSEC-2...
- https://lists.fedoraproject.org/archives/list/[email protected]...
- https://lists.fedoraproject.org/archives/list/[email protected]...
- https://github.com/advisories/GHSA-3hfw-x7gx-437c
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedorapro...
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedorapro...
- https://security-tracker.debian.org/tracker/CVE-2021-41281 Vendor Advisory
Internet-facing
14 days
Internal
60 days
- Not known to be exploited
- Can be exploited automatically (estimated)
- Gives an attacker partial control (estimated)
Type
CWE-22Path Traversal
Timeline
Published23 Nov 2021
Updated3 Nov 2026
First seen6 Mar 2026
Track software like this
Free during beta