# CVE-2024-53111: mm/mremap: fix address wraparound in move\_page\_tables()

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

- **Severity:** HIGH 7.1
- **CVSS:** 7.1 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: High; 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.27% (percentile 13, 2026-11-26)
- **CWE:** CWE-190
- **Published:** 2024-12-02T13:44:43.478Z
- **Modified:** 2026-08-05T11:43:49.792Z

## Who should check

- Anyone running Linux \>= af8ca1c149069176e6322a77b532e3ffd99ccffe, \< 909543dc279a91122fb08e4653a72b82f0ad28f4; \>= af8ca1c149069176e6322a77b532e3ffd99ccffe, \< a4a282daf1a190f03790bf163458ea3c8d28d217
- Anyone running Linux 6.7

## Description

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

mm/mremap: fix address wraparound in move\_page\_tables()

On 32-bit platforms, it is possible for the expression \`len + old\_addr \<
old\_end\` to be false-positive if \`len + old\_addr\` wraps around. 
\`old\_addr\` is the cursor in the old range up to which page table entries
have been moved; so if the operation succeeded, \`old\_addr\` is the \*end\* of
the old region, and adding \`len\` to it can wrap.

The overflow causes mremap() to mistakenly believe that PTEs have been
copied; the consequence is that mremap() bails out, but doesn't move the
PTEs back before the new VMA is unmapped, causing anonymous pages in the
region to be lost.  So basically if userspace tries to mremap() a
private-anon region and hits this bug, mremap() will return an error and
the private-anon region's contents appear to have been zeroed.

The idea of this check is that \`old\_end - len\` is the original start
address, and writing the check that way also makes it easier to read; so
fix the check by rearranging the comparison accordingly.

(An alternate fix would be to refactor this function by introducing an
"orig\_old\_start" variable or such.)


Tested in a VM with a 32-bit X86 kernel; without the patch:

\`\`\`
user@horn:~/big\_mremap$ cat test.c
\#define \_GNU\_SOURCE
\#include \<stdlib.h\>
\#include \<stdio.h\>
\#include \<err.h\>
\#include \<sys/mman.h\>

\#define ADDR1 ((void\*)0x60000000)
\#define ADDR2 ((void\*)0x10000000)
\#define SIZE          0x50000000uL

int main(void) {
  unsigned char \*p1 = mmap(ADDR1, SIZE, PROT\_READ\|PROT\_WRITE,
      MAP\_ANONYMOUS\|MAP\_PRIVATE\|MAP\_FIXED\_NOREPLACE, -1, 0);
  if (p1 == MAP\_FAILED)
    err(1, "mmap 1");
  unsigned char \*p2 = mmap(ADDR2, SIZE, PROT\_NONE,
      MAP\_ANONYMOUS\|MAP\_PRIVATE\|MAP\_FIXED\_NOREPLACE, -1, 0);
  if (p2 == MAP\_FAILED)
    err(1, "mmap 2");
  \*p1 = 0x41;
  printf("first char is 0x%02hhx\\n", \*p1);
  unsigned char \*p3 = mremap(p1, SIZE, SIZE,
      MREMAP\_MAYMOVE\|MREMAP\_FIXED, p2);
  if (p3 == MAP\_FAILED) {
    printf("mremap() failed; first char is 0x%02hhx\\n", \*p1);
  } else {
    printf("mremap() succeeded; first char is 0x%02hhx\\n", \*p3);
  }
}
user@horn:~/big\_mremap$ gcc -static -o test test.c
user@horn:~/big\_mremap$ setarch -R ./test
first char is 0x41
mremap() failed; first char is 0x00
\`\`\`

With the patch:

\`\`\`
user@horn:~/big\_mremap$ setarch -R ./test
first char is 0x41
mremap() succeeded; first char is 0x41
\`\`\`

## Affected and fixed versions

- Linux: \>= af8ca1c149069176e6322a77b532e3ffd99ccffe, \< 909543dc279a91122fb08e4653a72b82f0ad28f4; \>= af8ca1c149069176e6322a77b532e3ffd99ccffe, \< a4a282daf1a190f03790bf163458ea3c8d28d217 (cvelist)
- Linux: 6.7 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2024-53111.md
Affected: Linux >= af8ca1c149069176e6322a77b532e3ffd99ccffe, < 909543dc279a91122fb08e4653a72b82f0ad28f4; >= af8ca1c149069176e6322a77b532e3ffd99ccffe, < a4a282daf1a190f03790bf163458ea3c8d28d217; Linux 6.7
Fixed in: Linux 909543dc279a91122fb08e4653a72b82f0ad28f4

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

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

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

High: CVSS 7.1 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

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

Linux \>= af8ca1c149069176e6322a77b532e3ffd99ccffe, \< 909543dc279a91122fb08e4653a72b82f0ad28f4; \>= af8ca1c149069176e6322a77b532e3ffd99ccffe, \< a4a282daf1a190f03790bf163458ea3c8d28d217; Linux 6.7.

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

Yes. Fixed in Linux 909543dc279a91122fb08e4653a72b82f0ad28f4. No fix listed yet: follow the vendor advisory.

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

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/909543dc279a91122fb08e4653a72b82f0ad28f4>
- patch: <https://git.kernel.org/stable/c/a4a282daf1a190f03790bf163458ea3c8d28d217>

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

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