# CVE-2024-42084: ftruncate: pass a signed offset

> 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:H/A:N`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: High; Availability impact: None
- **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.32% (percentile 17, 2026-11-28)
- **Published:** 2024-07-29T16:26:20.581Z
- **Modified:** 2026-06-17T07:48:46.520Z

## Who should check

- Anyone running Linux \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< c329760749b5419769e57cb2be80955d2805f9c9; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< f531d4bc6c5588d713359e42ed65e46816d841d8; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< dbb226d81cd02cee140139c2369791e6f61f2007; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 5ae6af68410bdad6181ec82104bb9985a7a6a0fa; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 836359247b0403e0634bfbc83e5bb8063fad287a; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 930a4c369f74da26816eaaa71b5888d29b759c27; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0
- Anyone running Linux 3.9

## Description

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

ftruncate: pass a signed offset

The old ftruncate() syscall, using the 32-bit off\_t misses a sign
extension when called in compat mode on 64-bit architectures.  As a
result, passing a negative length accidentally succeeds in truncating
to file size between 2GiB and 4GiB.

Changing the type of the compat syscall to the signed compat\_off\_t
changes the behavior so it instead returns -EINVAL.

The native entry point, the truncate() syscall and the corresponding
loff\_t based variants are all correct already and do not suffer
from this mistake.

## Affected and fixed versions

- Linux: \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< c329760749b5419769e57cb2be80955d2805f9c9; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< f531d4bc6c5588d713359e42ed65e46816d841d8; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< dbb226d81cd02cee140139c2369791e6f61f2007; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 5ae6af68410bdad6181ec82104bb9985a7a6a0fa; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 836359247b0403e0634bfbc83e5bb8063fad287a; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 930a4c369f74da26816eaaa71b5888d29b759c27; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0 (cvelist)
- Linux: 3.9 (cvelist)

## Mitigation

- Upgrade Linux to 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0 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-42084. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2024-42084.md
Affected: Linux >= 3f6d078d4accfff8b114f968259a060bfdc7c682, < c329760749b5419769e57cb2be80955d2805f9c9; >= 3f6d078d4accfff8b114f968259a060bfdc7c682, < f531d4bc6c5588d713359e42ed65e46816d841d8; >= 3f6d078d4accfff8b114f968259a060bfdc7c682, < 84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a; >= 3f6d078d4accfff8b114f96…
Fixed in: Linux 84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a, Linux 5ae6af68410bdad6181ec82104bb9985a7a6a0fa, Linux 836359247b0403e0634bfbc83e5bb8063fad287a, Linux 930a4c369f74da26816eaaa71b5888d29b759c27, Linux 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0

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-42084 being exploited?

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

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

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

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

Linux \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< c329760749b5419769e57cb2be80955d2805f9c9; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< f531d4bc6c5588d713359e42ed65e46816d841d8; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< dbb226d81cd02cee140139c2369791e6f61f2007; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 5ae6af68410bdad6181ec82104bb9985a7a6a0fa; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 836359247b0403e0634bfbc83e5bb8063fad287a; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 930a4c369f74da26816eaaa71b5888d29b759c27; \>= 3f6d078d4accfff8b114f968259a060bfdc7c682, \< 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0; Linux 3.9.

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

Yes. Fixed in Linux 84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a, Linux 5ae6af68410bdad6181ec82104bb9985a7a6a0fa, Linux 836359247b0403e0634bfbc83e5bb8063fad287a, Linux 930a4c369f74da26816eaaa71b5888d29b759c27, Linux 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0. Upgrade Linux to 4b8e88e563b5f666446d002ad0dc1e6e8e7102b0 or later.

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

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/c329760749b5419769e57cb2be80955d2805f9c9>
- patch: <https://git.kernel.org/stable/c/f531d4bc6c5588d713359e42ed65e46816d841d8>
- patch: <https://git.kernel.org/stable/c/84bf6b64a1a0dfc6de7e1b1c776d58d608e7865a>
- patch: <https://git.kernel.org/stable/c/dbb226d81cd02cee140139c2369791e6f61f2007>
- patch: <https://git.kernel.org/stable/c/5ae6af68410bdad6181ec82104bb9985a7a6a0fa>
- patch: <https://git.kernel.org/stable/c/836359247b0403e0634bfbc83e5bb8063fad287a>
- patch: <https://git.kernel.org/stable/c/930a4c369f74da26816eaaa71b5888d29b759c27>
- patch: <https://git.kernel.org/stable/c/4b8e88e563b5f666446d002ad0dc1e6e8e7102b0>
- other: <https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html>

## 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-42084>

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