CVE-2024-26818

tools/rtla: Fix clang warning about mount_point var size

State
Published
Severity
Not scored
Published
Apr 17, 2024
Updated
May 11, 2026
Reserved
Feb 19, 2024

Read the record on cve.org

Description

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

tools/rtla: Fix clang warning about mount_point var size

clang is reporting this warning:

$ make HOSTCC=clang CC=clang LLVM_IAS=1 [...] clang -O -g -DVERSION=\"6.8.0-rc3\" -flto=auto -fexceptions -fstack-protector-strong -fasynchronous-unwind-tables -fstack-clash-protection -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS $(pkg-config --cflags libtracefs) -c -o src/utils.o src/utils.c

src/utils.c:548:66: warning: 'fscanf' may overflow; destination buffer in argument 3 has size 1024, but the corresponding specifier may require size 1025 [-Wfortify-source] 548 | while (fscanf(fp, "%*s %" STR(MAX_PATH) "s %99s %*s %*d %*d\n", mount_point, type) == 2) { | ^

Increase mount_point variable size to MAX_PATH+1 to avoid the overflow.

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
LinuxLinux
  • a957cbc02531a23beeac6dd9e751f8d4dadaf7a9 to before 8a585914c266dc044f53b5c83c170f79b45fcf9aAffected
  • a957cbc02531a23beeac6dd9e751f8d4dadaf7a9 to before 6bdd43f62ab3bb5a306af7f0ab857af45777f5a8Affected
  • a957cbc02531a23beeac6dd9e751f8d4dadaf7a9 to before 30369084ac6e27479a347899e74f523e6ca29b89Affected
LinuxLinux
  • 6.5Affected
  • before 6.5Not affected
  • 6.6.18 through 6.6.*Not affected
  • 6.7.6 through 6.7.*Not affected
  • 6.8 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.