CVE-2021-39164
JSON

3.1low

Improper authorisation of /members discloses room membership to non-members

Severity
3.1low CVSS:3.1 by GitHub_M
Exploit likelihood
1.45% (higher than 74% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-3x4c-pq33-4w3qPYSEC-2021-425

Description

Matrix is an ecosystem for open federated Instant Messaging and Voice over IP. In versions 1.41.0 and prior, unauthorised users can access the membership (list of members, with their display names) of a room if they know the ID of the room. The vulnerability is limited to rooms with `shared` history visibility. Furthermore, the unauthorised user must be using an account on a vulnerable homeserver that is in the room. Server administrators should upgrade to 1.41.1 or later in order to receive the patch. One workaround is available. Administrators of servers that use a reverse proxy could, with potentially unacceptable loss of functionality, block the endpoints: `/_matrix/client/r0/rooms/{room_id}/members` with `at` query parameter, and `/_matrix/client/unstable/rooms/{room_id}/members` with `at` query parameter.

Affected

Product or packageVersionsReported by
matrix-org synapse< 1.41.1CVE List
matrix-synapse (PyPI)before 1.41.1, before cb35df940a828bc40b96daed997b5ad4c7842fd3GitHub Advisory Database, PyPA Advisory Database
matrix synapsebefore 1.41.1NVD
fedoraproject fedora34, 35NVD

All scores

GitHub_M3.1low CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N
GitHub3.1low CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N
NVD3.1low CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N
NVD3.5low CVSS:2.0AV:N/AC:M/Au:S/C:P/I:N/A:N

Classification

What each source says

CVE List

Matrix is an ecosystem for open federated Instant Messaging and Voice over IP. In versions 1.41.0 and prior, unauthorised users can access the membership (list of members, with their display names) of a room if they know the ID of the room. The vulnerability is limited to rooms with `shared` history visibility. Furthermore, the unauthorised user must be using an account on a vulnerable homeserver that is in the room. Server administrators should upgrade to 1.41.1 or later in order to receive the patch. One workaround is available. Administrators of servers that use a reverse proxy could, with potentially unacceptable loss of functionality, block the endpoints: `/_matrix/client/r0/rooms/{room_id}/members` with `at` query parameter, and `/_matrix/client/unstable/rooms/{room_id}/members` with `at` query parameter.

GitHub Advisory Database
Impact

Unauthorised users can access the membership (list of members, with their display names) of a room if they know the ID of the room. The vulnerability is limited to rooms with shared history visibility. Furthermore, the unauthorised user must be using an account on a vulnerable homeserver that is in the room.

Patches

Server administrators should upgrade to 1.41.1 or later.

Workarounds

Administrators of servers that use a reverse proxy could, with potentially unacceptable loss of functionality, block the following endpoints:

  • /_matrix/client/r0/rooms/{room_id}/members with at query parameter
  • /_matrix/client/unstable/rooms/{room_id}/members with at query parameter
References

n/a

For more information

If you have any questions or comments about this advisory, e-mail us at security@matrix.org.

NVD (es)

Matrix es un ecosistema para la Mensajería Instantánea federada abierta y voz sobre IP. En versiones 1.41.0 y anteriores, unos usuarios no autorizados pueden acceder a la membresía (lista de miembros, con sus nombres para mostrar) de una sala si conocen el ID de la misma. La vulnerabilidad es limitada a las salas con visibilidad del historial "shared". Además, el usuario no autorizado debe estar usando una cuenta en un servidor doméstico vulnerable que esté en la sala. Los administradores de servidores deben actualizar a versión 1.41.1 o posterior para recibir el parche. Se presenta una solución disponible. Los administradores de servidores que usan un proxy inverso podrían, con una pérdida de funcionalidad potencialmente inaceptable, bloquear los endpoints: "/_matrix/client/r0/rooms/{room_id}/members" con el parámetro de consulta "at", y "/_matrix/client/unstable/rooms/{room_id}/members" con el parámetro de consulta "at"

References

https://github.com/matrix-org/synapse/commit/cb35df940afix, patch, third-party-advisory, web
https://github.com/matrix-org/synapse/releases/tag/v1.41.1release-notes, third-party-advisory, web
https://github.com/matrix-org/synapse/security/advisories/GHSA-3x4c-pq33-4w3qadvisory, third-party-advisory, web
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/PXT7ID7DNBRN2TVTETU3SYQHJKEG6PXN/vendor-advisory
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/2VHDEPCZ22GJFMZCWA2XZAGPOEV72POF/vendor-advisory
https://nvd.nist.gov/vuln/detail/CVE-2021-39164advisory
https://github.com/matrix-org/synapsepackage
https://github.com/pypa/advisory-database/tree/main/vulns/matrix-synapse/PYSEC-2021-425.yamlweb
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/2VHDEPCZ22GJFMZCWA2XZAGPOEV72POFweb
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/PXT7ID7DNBRN2TVTETU3SYQHJKEG6PXNweb
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/PXT7ID7DNBRN2TVTETU3SYQHJKEG6PXN/web
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/2VHDEPCZ22GJFMZCWA2XZAGPOEV72POF/web

Sources

SourceRecordLicence
CVE ListCVE-2021-39164 changed 2024-08-04CVE Terms of Use
GitHub Advisory DatabaseGHSA-3x4c-pq33-4w3q changed 2026-07-08CC-BY-4.0
NVDCVE-2021-39164 changed 2026-06-17Public domain
PyPA Advisory DatabasePYSEC-2021-425 changed 2026-02-26CC-BY-4.0