CVE-2024-57874

Medium

In the Linux kernel, the following vulnerability has been resolved: arm64: ptrace: fix partial SETREGSET for NT_ARM_TAGGED_ADDR_CTRL Currently tagged_addr_ctrl_set() doesn't initialize the temporary 'ctrl' variable, and a SETREGSET call with a length of zero will leave this uninitialized. Consequently tagged_addr_ctrl_set() will consume an arbitrary value, potentially leaking up to 64 bits of memory from the kernel stack. The read is limited to a specific slot on the stack, and the issue does not provide a write mechanism. As set_tagged_addr_ctrl() only accepts values where bits [63:4] zero and rejects other values, a partial SETREGSET attempt will randomly succeed or fail depending on the value of the uninitialized value, and the exposure is significantly limited. Fix this by initializing the temporary value before copying the regset from userspace, as for other regsets (e.g. NT_PRSTATUS, NT_PRFPREG, NT_ARM_SYSTEM_CALL). In the case of a zero-length write, the existing value of the tagged address ctrl will be retained. The NT_ARM_TAGGED_ADDR_CTRL regset is only visible in the user_aarch64_view used by a native AArch64 task to manipulate another native AArch64 task. As get_tagged_addr_ctrl() only returns an error value when called for a compat task, tagged_addr_ctrl_get() and tagged_addr_ctrl_set() should never observe an error value from get_tagged_addr_ctrl(). Add a WARN_ON_ONCE() to both to indicate that such an error would be unexpected, and error handlnig is not missing in either case.

Package Linux Kernel
Published 2025-01-11
Last modified 2025-11-03
CVSS version 3.1
Patch available
Yes

CVSS 3.1 score

6.1

out of 10
Medium
Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
None
Availability
High
Vector string
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:H

Weakness type

CWE-908

CVE-2024-57874 is classified as CWE-908

See CWE-908 on MITRE CWE for full details on this weakness type.

Affected versions

Linux kernel versions 5.10 and later are affected. Fixed in 5.10.231, 5.15.174, 6.1.120, 6.6.66, 6.12.5, 6.13 and their respective stable series.

Affected from
≥ 5.10
Fixed in
✓ 5.10.231 5.10.x ✓ 5.15.174 5.15.x ✓ 6.1.120 6.1.x ✓ 6.6.66 6.6.x ✓ 6.12.5 6.12.x ✓ 6.13

References

The following references provide additional information about CVE-2024-57874 including vendor advisories, patch commits, exploit details, and third-party analysis. Links are sourced from the NIST NVD database.

Frequently asked questions

  • What is CVE-2024-57874?

    CVE-2024-57874 is a Medium severity Linux kernel vulnerability with a CVSS score of 6.1 out of 10 . It affects Linux kernel versions from 5.10 onward and has been patched in 5.10.231, 5.15.174, 6.1.120 and others. CVE-2024-57874 has not been confirmed as actively exploited and is not listed in the CISA KEV catalog.

  • What is the CVSS score for CVE-2024-57874?

    CVE-2024-57874 has a CVSS score of 6.1 out of 10, rated Medium severity (CVSS 3.1). The vector string is CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:H .

  • Is there a patch available for CVE-2024-57874?

    Yes — CVE-2024-57874 has been patched. Fixed versions include 5.10.231, 5.15.174, 6.1.120 and others. If you are running Linux kernel 5.10 or later up to the fix versions, apply the relevant patch for your kernel branch.

  • Is CVE-2024-57874 actively exploited?

    No — CVE-2024-57874 has not been confirmed as actively exploited. It is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog.