Lucene search

K
vulnrichmentLinuxVULNRICHMENT:CVE-2024-35905
HistoryMay 19, 2024 - 8:34 a.m.

CVE-2024-35905 bpf: Protect against int overflow for stack access size

2024-05-1908:34:58
Linux
github.com
2
linux kernel
vulnerability
patched
protection
int overflow
stack access size

7.2 High

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

10.4%

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

bpf: Protect against int overflow for stack access size

This patch re-introduces protection against the size of access to stack
memory being negative; the access size can appear negative as a result
of overflowing its signed int representation. This should not actually
happen, as there are other protections along the way, but we should
protect against it anyway. One code path was missing such protections
(fixed in the previous patch in the series), causing out-of-bounds array
accesses in check_stack_range_initialized(). This patch causes the
verification of a program with such a non-sensical access size to fail.

This check used to exist in a more indirect way, but was inadvertendly
removed in a833a17aeac7.

CNA Affected

[
  {
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "vendor": "Linux",
    "product": "Linux",
    "versions": [
      {
        "status": "affected",
        "version": "afea95d319cc",
        "lessThan": "9970e059af47",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "02962684258e",
        "lessThan": "37dc1718dc0c",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "b1d4d54d32ce",
        "lessThan": "98cdac206b11",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "08b91babccbb",
        "lessThan": "3f0784b2f1eb",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "a833a17aeac7",
        "lessThan": "203a68151e8e",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "a833a17aeac7",
        "lessThan": "ecc6a2101840",
        "versionType": "git"
      }
    ],
    "programFiles": [
      "kernel/bpf/verifier.c"
    ],
    "defaultStatus": "unaffected"
  },
  {
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "vendor": "Linux",
    "product": "Linux",
    "versions": [
      {
        "status": "affected",
        "version": "6.8"
      },
      {
        "status": "unaffected",
        "version": "0",
        "lessThan": "6.8",
        "versionType": "custom"
      },
      {
        "status": "unaffected",
        "version": "5.10.215",
        "versionType": "custom",
        "lessThanOrEqual": "5.10.*"
      },
      {
        "status": "unaffected",
        "version": "5.15.154",
        "versionType": "custom",
        "lessThanOrEqual": "5.15.*"
      },
      {
        "status": "unaffected",
        "version": "6.1.85",
        "versionType": "custom",
        "lessThanOrEqual": "6.1.*"
      },
      {
        "status": "unaffected",
        "version": "6.6.26",
        "versionType": "custom",
        "lessThanOrEqual": "6.6.*"
      },
      {
        "status": "unaffected",
        "version": "6.8.5",
        "versionType": "custom",
        "lessThanOrEqual": "6.8.*"
      },
      {
        "status": "unaffected",
        "version": "6.9",
        "versionType": "original_commit_for_fix",
        "lessThanOrEqual": "*"
      }
    ],
    "programFiles": [
      "kernel/bpf/verifier.c"
    ],
    "defaultStatus": "affected"
  }
]

7.2 High

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

10.4%