{"id":"CVE-2021-29471","aliases":["CVE-2021-29471","GHSA-x345-32rc-8h85","PYSEC-2021-135"],"related":[],"kind":"vulnerability","state":"published","title":"Denial of service in Matrix Synapse","summary":"Synapse is a Matrix reference homeserver written in python (pypi package matrix-synapse). Matrix is an ecosystem for open federated Instant Messaging and VoIP. In Synapse before version 1.33.2 \"Push rules\" can specify conditions under which they will match, including `event_match`, which matches event content against a pattern including wildcards. Certain patterns can cause very poor performance in the matching engine, leading to a denial-of-service when processing moderate length events. The issue is patched in version 1.33.2. A potential workaround might be to prevent users from making custom push rules, by blocking such requests at a reverse-proxy.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Synapse is a Matrix reference homeserver written in python (pypi package matrix-synapse). Matrix is an ecosystem for open federated Instant Messaging and VoIP. In Synapse before version 1.33.2 \"Push rules\" can specify conditions under which they will match, including `event_match`, which matches event content against a pattern including wildcards. Certain patterns can cause very poor performance in the matching engine, leading to a denial-of-service when processing moderate length events. The issue is patched in version 1.33.2. A potential workaround might be to prevent users from making custom push rules, by blocking such requests at a reverse-proxy.","source":"cvelist"},{"lang":"en","text":"### Impact\n\n\"Push rules\" can specify [conditions](https://matrix.org/docs/spec/client_server/r0.6.1#conditions) under which they will match, including `event_match`, which matches event content against a pattern including wildcards.\n\nCertain patterns can cause very poor performance in the matching engine, leading to a denial-of-service when processing moderate length events.\n\n### Patches\n\nThe issue is patched by https://github.com/matrix-org/synapse/commit/03318a766cac9f8b053db2214d9c332a977d226c.\n\n### Workarounds\n\nA potential workaround might be to prevent users from making custom push rules, by blocking such requests at a reverse-proxy.\n\n### For more information\n\nIf you have any questions or comments about this advisory, email us at security@matrix.org.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Synapse es un servidor doméstico de referencia de Matrix escrito en python (paquete pypi matrix-synapse). Matrix es un ecosistema para VoIP y mensajería instantánea federada abierta. En Synapse versiones anteriores a 1.33.2, unas \"Push rules\" pueden especificar condiciones bajo las cuales coincidirán, incluyendo \"event_match\", que compara el contenido del evento con un patrón que incluye comodines. Determinados patrones pueden causar un rendimiento muy deficiente en el motor de coincidencia, conllevando a una denegación de servicio cuando se procesan eventos de duración moderada. El problema está parcheado en versión 1.33.2. Una posible solución alternativa podría ser impedir a unos usuarios crear reglas de inserción personalizadas, al bloquear dichas peticiones en un proxy inverso","source":"nvd"}],"published":"2021-05-11T15:05:12.000Z","modified":"2026-07-08T06:27:40.962Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","score":3.7,"rating":"LOW"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","score":3.7,"rating":"LOW"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","score":3.7,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N","rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","score":5.3,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:N/C:N/I:N/A:P","score":5,"rating":"MEDIUM"}],"cwes":["CWE-331","CWE-400"],"affected":[{"ranges":[{"version":"< 1.33.2","status":"affected"}],"vendor":"matrix-org","product":"synapse","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"1.33.2"}],"ecosystem":"PyPI","package":"matrix-synapse","purl":"pkg:pypi/matrix-synapse","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"1.33.2"}],"vendor":"matrix","product":"synapse","cpe":"cpe:2.3:a:matrix:synapse:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"34"}],"vendor":"fedoraproject","product":"fedora","cpe":"cpe:2.3:o:fedoraproject:fedora:34:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"git","introduced":"0","status":"affected","fixed":"03318a766cac9f8b053db2214d9c332a977d226c"},{"type":"ecosystem","introduced":"0","status":"affected","fixed":"1.33.2"}],"ecosystem":"PyPI","package":"matrix-synapse","purl":"pkg:pypi/matrix-synapse","repo":"https://github.com/matrix-org/synapse","source":"pysec"}],"references":[{"url":"https://github.com/matrix-org/synapse/security/advisories/GHSA-x345-32rc-8h85","tags":["advisory","patch","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/matrix-org/synapse/commit/03318a766cac9f8b053db2214d9c332a977d226c","tags":["fix","patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/matrix-org/synapse/releases/tag/v1.33.2","tags":["release-notes","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/TNNAJOZNMVMXM6AS7RFFKB4QLUJ4IFEY/","tags":["vendor-advisory","x-refsource-fedora","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-29471","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/matrix-org/synapse","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/pypa/advisory-database/tree/main/vulns/matrix-synapse/PYSEC-2021-135.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/TNNAJOZNMVMXM6AS7RFFKB4QLUJ4IFEY","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2021-29471","url":"https://www.cve.org/CVERecord?id=CVE-2021-29471","licence":"CVE Terms of Use","modified":"2024-08-03T22:11:05.476Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-x345-32rc-8h85","url":"https://github.com/advisories/GHSA-x345-32rc-8h85","licence":"CC-BY-4.0","modified":"2026-07-08T06:27:40.962Z"},{"source":"nvd","name":"NVD","id":"CVE-2021-29471","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-29471","licence":"Public domain","modified":"2026-06-17T03:47:42.517Z"},{"source":"pysec","name":"PyPA Advisory Database","id":"PYSEC-2021-135","url":"https://osv.dev/vulnerability/PYSEC-2021-135","licence":"CC-BY-4.0","modified":"2023-11-08T04:05:34.987Z"}],"updatedAt":"2026-11-25T22:58:01.280Z","epss":{"score":0.01647,"percentile":0.77179,"date":"2026-12-01T12:00:22.000Z"}}