# CVE-2024-57923: btrfs: zlib: fix avail\_in bytes for s390 zlib HW compression path

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.26% (percentile 11, 2026-11-26)
- **CWE:** CWE-617
- **Published:** 2025-01-19T11:52:41.798Z
- **Modified:** 2026-06-17T08:14:14.547Z

## Who should check

- Anyone running Linux \>= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, \< 25adbb08aeadcff883ab801df99fd20fefbb6ca4; \>= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, \< 0ee4736c003daded513de0ff112d4a1e9c85bbab
- Anyone running Linux 6.12

## Description

In the Linux kernel, the following vulnerability has been resolved:

btrfs: zlib: fix avail\_in bytes for s390 zlib HW compression path

Since the input data length passed to zlib\_compress\_folios() can be
arbitrary, always setting strm.avail\_in to a multiple of PAGE\_SIZE may
cause read-in bytes to exceed the input range. Currently this triggers
an assert in btrfs\_compress\_folios() on the debug kernel (see below).
Fix strm.avail\_in calculation for S390 hardware acceleration path.

  assertion failed: \*total\_in \<= orig\_len, in fs/btrfs/compression.c:1041
  ------------\[ cut here \]------------
  kernel BUG at fs/btrfs/compression.c:1041!
  monitor event: 0040 ilc:2 \[\#1\] PREEMPT SMP
  CPU: 16 UID: 0 PID: 325 Comm: kworker/u273:3 Not tainted 6.13.0-20241204.rc1.git6.fae3b21430ca.300.fc41.s390x+debug \#1
  Hardware name: IBM 3931 A01 703 (z/VM 7.4.0)
  Workqueue: btrfs-delalloc btrfs\_work\_helper
  Krnl PSW : 0704d00180000000 0000021761df6538 (btrfs\_compress\_folios+0x198/0x1a0)
             R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:3 CC:1 PM:0 RI:0 EA:3
  Krnl GPRS: 0000000080000000 0000000000000001 0000000000000047 0000000000000000
             0000000000000006 ffffff01757bb000 000001976232fcc0 000000000000130c
             000001976232fcd0 000001976232fcc8 00000118ff4a0e30 0000000000000001
             00000111821ab400 0000011100000000 0000021761df6534 000001976232fb58
  Krnl Code: 0000021761df6528: c020006f5ef4        larl    %r2,0000021762be2310
             0000021761df652e: c0e5ffbd09d5        brasl   %r14,00000217615978d8
            \#0000021761df6534: af000000            mc      0,0
            \>0000021761df6538: 0707                bcr     0,%r7
             0000021761df653a: 0707                bcr     0,%r7
             0000021761df653c: 0707                bcr     0,%r7
             0000021761df653e: 0707                bcr     0,%r7
             0000021761df6540: c004004bb7ec        brcl    0,000002176276d518
  Call Trace:
   \[\<0000021761df6538\>\] btrfs\_compress\_folios+0x198/0x1a0
  (\[\<0000021761df6534\>\] btrfs\_compress\_folios+0x194/0x1a0)
   \[\<0000021761d97788\>\] compress\_file\_range+0x3b8/0x6d0
   \[\<0000021761dcee7c\>\] btrfs\_work\_helper+0x10c/0x160
   \[\<0000021761645760\>\] process\_one\_work+0x2b0/0x5d0
   \[\<000002176164637e\>\] worker\_thread+0x20e/0x3e0
   \[\<000002176165221a\>\] kthread+0x15a/0x170
   \[\<00000217615b859c\>\] \_\_ret\_from\_fork+0x3c/0x60
   \[\<00000217626e72d2\>\] ret\_from\_fork+0xa/0x38
  INFO: lockdep is turned off.
  Last Breaking-Event-Address:
   \[\<0000021761597924\>\] \_printk+0x4c/0x58
  Kernel panic - not syncing: Fatal exception: panic\_on\_oops

## Affected and fixed versions

- Linux: \>= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, \< 25adbb08aeadcff883ab801df99fd20fefbb6ca4; \>= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, \< 0ee4736c003daded513de0ff112d4a1e9c85bbab (cvelist)
- Linux: 6.12 (cvelist)

## Mitigation

- Upgrade Linux to 0ee4736c003daded513de0ff112d4a1e9c85bbab or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2024-57923. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2024-57923.md
Affected: Linux >= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, < 25adbb08aeadcff883ab801df99fd20fefbb6ca4; >= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, < 0ee4736c003daded513de0ff112d4a1e9c85bbab; Linux 6.12
Fixed in: Linux 25adbb08aeadcff883ab801df99fd20fefbb6ca4, Linux 0ee4736c003daded513de0ff112d4a1e9c85bbab

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2024-57923 being exploited?

There is no confirmed exploitation: CVE-2024-57923 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.26% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2024-57923?

Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2024-57923?

Linux \>= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, \< 25adbb08aeadcff883ab801df99fd20fefbb6ca4; \>= fd1e75d0105d2289e24b6d63cee49e6f7952c8bf, \< 0ee4736c003daded513de0ff112d4a1e9c85bbab; Linux 6.12.

### Is there a fix for CVE-2024-57923?

Yes. Fixed in Linux 25adbb08aeadcff883ab801df99fd20fefbb6ca4, Linux 0ee4736c003daded513de0ff112d4a1e9c85bbab. Upgrade Linux to 0ee4736c003daded513de0ff112d4a1e9c85bbab or later.

### How do I check if I'm affected by CVE-2024-57923?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/25adbb08aeadcff883ab801df99fd20fefbb6ca4>
- patch: <https://git.kernel.org/stable/c/0ee4736c003daded513de0ff112d4a1e9c85bbab>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2024-57923>

HTML: <https://flawdb.com/CVE-2024-57923> · JSON: <https://flawdb.com/api/v1/entries/CVE-2024-57923>
