GHSA-7h5v-85w9-pq6c: Matrix synapse Remote Code Execution Vulnerability
MODERATEGHSA-7h5v-85w9-pq6c is a MODERATE remote code execution vulnerability (CWE-400: Uncontrolled Resource Consumption) affecting Matrix synapse libraries in the PyPI ecosystem. The issue involves denial of service (via resource exhaustion) due to improper input validation in third-party identifier endpoint. Remediation is available by upgrading affected packages to version 1.33.0.
GHSA-7h5v-85w9-pq6c at a Glance
How to Fix GHSA-7h5v-85w9-pq6c
To remediate this vulnerability, upgrade all affected Matrix synapse dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install matrix-synapse>=1.33.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show matrix-synapse
How to Check if You Are Affected
To determine whether your Python environment is affected by GHSA-7h5v-85w9-pq6c, inspect your installed packages using pip:
pip show matrix-synapse
Analyze the terminal output to locate any version of Matrix synapse in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.33.0), your application is affected.
Note: The pip show matrix-synapse command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-400: Uncontrolled Resource Consumption, where the product does not properly control the allocation and maintenance of a limited resource. In Matrix synapse, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-7h5v-85w9-pq6c Affected Matrix synapse Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
matrix-synapse
|
PyPI |
< 1.33.0
|
1.33.0
|
References
Frequently Asked Questions
What is GHSA-7h5v-85w9-pq6c?
Which Matrix synapse versions are affected?
What version fixes GHSA-7h5v-85w9-pq6c?
Is matrix-synapse affected?
What CWE is associated with GHSA-7h5v-85w9-pq6c?
How can I check PyPI dependencies for GHSA-7h5v-85w9-pq6c?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-7h5v-85w9-pq6c",
"modified" : "2021-05-19T19:34:56Z",
"published" : "2021-05-19T23:01:45Z",
"aliases" : [ ],
"summary" : "Denial of service (via resource exhaustion) due to improper input validation in third-party identifier endpoint",
"details" : "### Impact\nMissing input validation of some parameters on the endpoints used to confirm third-party identifiers could cause excessive use of disk space and memory leading to resource exhaustion.\n\n### Patches\nThe issue is fixed by https://github.com/matrix-org/synapse/pull/9855.\n\n### Workarounds\nThere are no known workarounds.\n\n### References\nn/a\n\n### For more information\nIf you have any questions or comments about this advisory, email us at security@matrix.org.\n",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "matrix-synapse"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.33.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/matrix-org/synapse/security/advisories/GHSA-7h5v-85w9-pq6c"
}, {
"type" : "WEB",
"url" : "https://github.com/matrix-org/synapse/pull/9855"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-400" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2021-05-19T19:34:56Z",
"nvd_published_at" : null
}
}