CVE-2024-39480

kdb: Fix buffer overflow during tab-complete

HIGH
7.8
CVSS Score
Published: July 5, 2024 at 06:55 AM UTC
Updated: August 5, 2026 at 12:04 PM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
HIGH7.8
Exploit prediction
EPSS 0.3%
SSVC
No known exploit

Description

In the Linux kernel, the following vulnerability has been resolved: kdb: Fix buffer overflow during tab-complete Currently, when the user attempts symbol completion with the Tab key, kdb will use strncpy() to insert the completed symbol into the command buffer. Unfortunately it passes the size of the source buffer rather than the destination to strncpy() with predictably horrible results. Most obviously if the command buffer is already full but cp, the cursor position, is in the middle of the buffer, then we will write past the end of the supplied buffer. Fix this by replacing the dubious strncpy() calls with memmove()/memcpy() calls plus explicit boundary checks to make sure we have enough space before we start moving characters around.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

2.6.35 ≤ v < 4.19.3162.6.35 ≤ v < 5.10.2192.6.35 ≤ v < 5.15.1612.6.35 ≤ v < 5.4.2782.6.35 ≤ v < 6.1.942.6.35 ≤ v < 6.102.6.35 ≤ v < 6.6.342.6.35 ≤ v < 6.9.54.19 ≤ v < 4.19.3165.10 ≤ v < 5.10.2195.15 ≤ v < 5.15.1615.4 ≤ v < 5.4.2786.1 ≤ v < 6.1.946.6 ≤ v < 6.6.346.9 ≤ v < 6.9.51da177e4c3f42.6.355d5314d6795f3c1c0f415348ff8c51f7de042b77
Vendor states this is fixed in 107e825cc448 (fixed)
Vendor states this is fixed in 107e825cc448b7834b31e8b1b3cf0f57426d46d5 (fixed)
Vendor states this is fixed in 33d9c814652b (fixed)
Vendor states this is fixed in 33d9c814652b971461d1e30bead6792851c209e7 (fixed)
Vendor states this is fixed in cfdc2fa4db57 (fixed)
Vendor states this is fixed in cfdc2fa4db57503bc6d3817240547c8ddc55fa96 (fixed)
Vendor states this is fixed in ddd2972d8e2d (fixed)
Vendor states this is fixed in ddd2972d8e2dee3b33e8121669d55def59f0be8a (fixed)
Vendor states this is fixed in e9730744bf3a (fixed)
Vendor states this is fixed in e9730744bf3af04cda23799029342aa3cddbc454 (fixed)
Vendor states this is fixed in f636a40834d2 (fixed)
Vendor states this is fixed in f636a40834d22e5e3fc748f060211879c056cd33 (fixed)
Vendor states this is fixed in f694da720dcf (fixed)
Vendor states this is fixed in f694da720dcf795dc3eb97bf76d220213f76aaa7 (fixed)
Vendor states this is fixed in fb824a99e148 (fixed)
Vendor states this is fixed in fb824a99e148ff272a53d71d84122728b5f00992 (fixed)
Vendor states this is fixed in 2.6.35 (unaffected)
Vendor states this is fixed in 4.19.316 (unaffected)
Vendor states this is fixed in 5.10.219 (unaffected)
Vendor states this is fixed in 5.15.161 (unaffected)
Vendor states this is fixed in 5.4.278 (unaffected)
Vendor states this is fixed in 6.1.94 (unaffected)
Vendor states this is fixed in 6.10 (unaffected)
Vendor states this is fixed in 6.6.34 (unaffected)
Vendor states this is fixed in 6.9.5 (unaffected)

References (8)

Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/107e825cc448b7834b31e8b1b3cf0f57426d46d5
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/33d9c814652b971461d1e30bead6792851c209e7
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/cfdc2fa4db57503bc6d3817240547c8ddc55fa96
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/ddd2972d8e2dee3b33e8121669d55def59f0be8a
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/e9730744bf3af04cda23799029342aa3cddbc454
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/f636a40834d22e5e3fc748f060211879c056cd33
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/f694da720dcf795dc3eb97bf76d220213f76aaa7
Mailing ListPatch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/fb824a99e148ff272a53d71d84122728b5f00992

SSVC — Action Prioritization

SSVCNo known exploitNot automatableTotal impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

7.8HIGHCISA-ADP
Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
HIGH
Integrity
HIGH
Availability
HIGH
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-120CWE-121

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card