Process crash via unbounded HTML text traversal
Published Jun 28, 2022 · Updated Apr 23, 2025
Uncontrolled recursion in Matrix.org Synapse before 1.61.1 allows remote authenticated users to crash the process through URL previews. The preview_html.py _iterate_over_text function builds an unbounded nested itertools.chain traversal while extracting text from attacker-controlled HTML, exhausting available stack space. Direct access requires an authenticated homeserver account and url_preview_enabled set to true; remote attackers can instead induce an automatic preview through a local user's client.
Summary
What happened
Uncontrolled recursion in Matrix.org Synapse before 1.61.1 allows remote authenticated users to crash the process through URL previews. The preview_html.py _iterate_over_text function builds an unbounded nested itertools.chain traversal while extracting text from attacker-controlled HTML, exhausting available stack space. Direct access requires an authenticated homeserver account and url_preview_enabled set to true; remote attackers can instead induce an automatic preview through a local user's client.
The record
- CVE
- CVE-2022-31052
- Published
- Jun 28, 2022
- Updated
- Apr 23, 2025
- Vendor
- Matrix.org
- Product
- Synapse
- Classifications
- CWE-674, T1499.004
- Attack vector
- network
- Privileges
- authenticated
Timeline
How it unfolded
- Jun 28, 2022CVE publishedPublication date reported by the CVE source.
- Apr 23, 2025Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=< 1.61.1
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Public exploit references
No public exploit references are available in this record.
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo