Miggo Logo

CVE-2022-31152: Denial of service due to incorrect application of event authorization rules

7.5

CVSS Score
3.1

Basic Information

EPSS Score
0.36388%
Published
8/31/2022
Updated
9/30/2024
KEV Status
No
Technology
TechnologyPython

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Package NameEcosystemVulnerable VersionsFirst Patched Version
matrix-synapsepip< 1.62.0rc11.62.0rc1

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from missing checks in the event authorization flow. The patch in commit d4b1c0d adds critical validation for: 1) duplicate auth_events entries (CWE-703), and 2) auth_events not matching expected types (CWE-755). The modified function check_state_independent_auth_rules in synapse/event_auth.py lacked these checks in vulnerable versions, as shown by the added validation logic and corresponding test cases in the diff. This directly matches the described vulnerability where invalid events could be accepted.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

### Imp**t T** M*trix sp**i*i**tion sp**i*i*s * list o* [*v*nt *ut*oriz*tion rul*s](*ttps://sp**.m*trix.or*/v*.*/rooms/v**/#*ut*oriz*tion-rul*s) w*i** must ** ****k** w**n **t*rminin* i* *n *v*nt s*oul* ** ****pt** into * room. In v*rsions o* Syn*p

Reasoning

T** vuln*r**ility st*ms *rom missin* ****ks in t** *v*nt *ut*oriz*tion *low. T** p*t** in *ommit ******* ***s *riti**l v*li**tion *or: *) *upli**t* *ut*_*v*nts *ntri*s (*W*-***), *n* *) *ut*_*v*nts not m*t**in* *xp**t** typ*s (*W*-***). T** mo*i*i**